diff options
author | Friendika <info@friendika.com> | 2011-06-03 06:12:34 -0700 |
---|---|---|
committer | Friendika <info@friendika.com> | 2011-06-03 06:12:34 -0700 |
commit | 00c548cc8f91b6087fa923da7b939a0fa2c264dc (patch) | |
tree | 4268a3e019e594272d74f3f2721ecbfef1054ec9 | |
parent | a27391c33a6b2d3828182ca5f8e8b65998cf47a7 (diff) | |
download | volse-hubzilla-00c548cc8f91b6087fa923da7b939a0fa2c264dc.tar.gz volse-hubzilla-00c548cc8f91b6087fa923da7b939a0fa2c264dc.tar.bz2 volse-hubzilla-00c548cc8f91b6087fa923da7b939a0fa2c264dc.zip |
new member page
-rw-r--r-- | include/auth.php | 13 | ||||
-rw-r--r-- | mod/newmember.php | 43 | ||||
-rw-r--r-- | mod/profile.php | 3 |
3 files changed, 59 insertions, 0 deletions
diff --git a/include/auth.php b/include/auth.php index fd80a63e2..d1eb9d131 100644 --- a/include/auth.php +++ b/include/auth.php @@ -63,6 +63,12 @@ if((isset($_SESSION)) && (x($_SESSION,'authenticated')) && ((! (x($_POST,'auth-p $_SESSION['theme'] = $a->user['theme']; $_SESSION['page_flags'] = $a->user['page-flags']; + $member_since = strtotime($a->user['register_date']); + if(time() < ($member_since + ( 60 * 60 * 24 * 14))) + $_SESSION['new_member'] = true; + else + $_SESSION['new_member'] = false; + if(strlen($a->user['timezone'])) { date_default_timezone_set($a->user['timezone']); $a->timezone = $a->user['timezone']; @@ -211,6 +217,13 @@ else { else info( t("Welcome back ") . $a->user['username'] . EOL); + + $member_since = strtotime($a->user['register_date']); + if(time() < ($member_since + ( 60 * 60 * 24 * 14))) + $_SESSION['new_member'] = true; + else + $_SESSION['new_member'] = false; + if(strlen($a->user['timezone'])) { date_default_timezone_set($a->user['timezone']); $a->timezone = $a->user['timezone']; diff --git a/mod/newmember.php b/mod/newmember.php new file mode 100644 index 000000000..bc1fb7508 --- /dev/null +++ b/mod/newmember.php @@ -0,0 +1,43 @@ +<?php + +function newmember_content(&$a) { + + + $o = '<h3>' . t('Welcome to Friendika') . '</h3>'; + + $o .= '<h3>' . t('New Member Checklist') . '</h3>'; + + $o .= '<div style="font-size: 120%;">'; + + $o .= t('We would like to offer some tips and links to help make your experience enjoyable. Click any item to visit the relevant page.'); + + $o .= '<ul>'; + + $o .= '<li>' . '<a href="settings">' . t('On your <em>Settings</em> page - change your initial password. Also make a note of your Identity Address. This will be useful in making friends.') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="settings">' . t('Review the other settings, particularly the choice of publishing your profile to various directories. An unpublished directory is like an unlisted phone number. Great for privacy - but unless you inform all your friends, nobody can find you.') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="profile_photo">' . t('Upload a profile photo if you have not done so already. Studies have shown that people with real photos of themselves are ten times more likely to make friends than people who do not.') . '</a></li>' . EOL; + + if(in_array('facebook', $a->plugins)) + $o .= '<li>' . '<a href="facebook">' . t("Authorise the Facebook Connector if you currently have a Facebook account and we will \x28optionally\x29 import all your Facebook friends and conversations.") . '</a></li>' . EOL; + + $mail_disabled = ((function_exists('imap_open') && (! get_config('system','imap_disabled'))) ? 0 : 1); + + if(! $mail_disabled) + $o .= '<li>' . '<a href="settings">' . t('Enter your email access information on your Settings page if you wish to import and interact with friends or mailing lists from your email INBOX') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="profiles">' . t('Edit your <strong>default</strong> profile to your liking. Review the settings for hiding your list of friends and hiding the profile from unknown visitors.') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="profiles">' . t('Set some public keywords for your default profile which describe your interests. We may be able to find other people with similar interests and suggest friendships.') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="contacts">' . t('Your Contact page is your gateway to editing and connecting with friends on other networks. Typically you enter their address or site URL in the <em>Connect</em> dialog.') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="directory">' . t('The Directory page lets you find other people in this network or other federated sites. Look for a <em>Connect</em> or <em>Follow</em> link on their profile page. Provide your own Identity Address if requested.') . '</a></li>' . EOL; + + $o .= '<li>' . '<a href="help">' . t('Our <strong>help</strong> pages may be consulted for detail on other program features and resources.') . '</a></li>' . EOL; + + $o .= '</div>'; + + return $o; +}
\ No newline at end of file diff --git a/mod/profile.php b/mod/profile.php index 52551c45f..68110d761 100644 --- a/mod/profile.php +++ b/mod/profile.php @@ -126,6 +126,9 @@ function profile_content(&$a, $update = 0) { return $o; } + if(x($_SESSION,'new_user') && $_SESSION['new_user']) + $o .= '<a href="newmember">' . t('Tips for New Members') . '</a>' . EOL; + $commpage = (($a->profile['page-flags'] == PAGE_COMMUNITY) ? true : false); $commvisitor = (($commpage && $remote_contact == true) ? true : false); |