From eda7c24c4ef45c88287ee6580af5d373c3676da9 Mon Sep 17 00:00:00 2001 From: friendica Date: Wed, 25 Dec 2013 16:53:59 -0800 Subject: improve the register text until the new register page is finished --- mod/register.php | 11 +++++++++++ view/css/mod_register.css | 5 +++++ view/tpl/register.tpl | 10 ++++++++-- 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/mod/register.php b/mod/register.php index 3f1fc5400..990cce2ed 100644 --- a/mod/register.php +++ b/mod/register.php @@ -135,12 +135,19 @@ function register_post(&$a) { function register_content(&$a) { + $registration_is = ''; + $other_sites = ''; if(get_config('system','register_policy') == REGISTER_CLOSED) { require_once('mod/pubsites.php'); return pubsites_content($a); } + if(get_config('system','register_policy') == REGISTER_APPROVE) { + $registration_is = t('Registration on this site/hub is by approval only.'); + $other_sites = t('Register at another affiliated site/hub'); + } + $max_dailies = intval(get_config('system','max_daily_registrations')); if($max_dailies) { $r = q("select count(account_id) as total from account where account_created > UTC_TIMESTAMP() - INTERVAL 1 day"); @@ -175,10 +182,14 @@ function register_content(&$a) { $invite_code = ((x($_REQUEST,'invite_code')) ? strip_tags(trim($_REQUEST['invite_code'])) : "" ); + + $o = replace_macros(get_markup_template('register.tpl'), array( '$title' => t('Registration'), + '$reg_is' => $registration_is, '$registertext' => get_config('system','register_text'), + '$other_sites' => $other_sites, '$invitations' => get_config('system','invitation_only'), '$invite_desc' => t('Membership on this site is by invitation only.'), '$label_invite' => t('Please enter your invitation code'), diff --git a/view/css/mod_register.css b/view/css/mod_register.css index aca6ee002..870fb4634 100644 --- a/view/css/mod_register.css +++ b/view/css/mod_register.css @@ -10,6 +10,11 @@ h2 { margin-top: 5%; } +#register-desc, #register-text, #register-sites { + font-weight: bold; + margin-bottom: 15px; +} + .register-label { float: left; width: 275px; diff --git a/view/tpl/register.tpl b/view/tpl/register.tpl index 48c1ba525..6cec036fc 100755 --- a/view/tpl/register.tpl +++ b/view/tpl/register.tpl @@ -2,8 +2,14 @@
-{{if $registertext}} -
{{$registertext}}
+ + +{{if $reg_is}} +
{{$reg_is}} +{{/if}} +{{if $registertext}}
{{$registertext}}
+{{/if}} +{{if $other_sites}}
{{$other_sites}}
{{/if}} {{if $invitations}} -- cgit v1.2.3