Advertisement
Guest User

login-userType

a guest
Sep 27th, 2016
322
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.87 KB | None | 0 0
  1. <?php
  2.  
  3.  
  4. if (Users::isLogged()){
  5. UserApi::addOutputData('PHPSESSID', session_id());
  6. $options = isset($_GET['options']) && is_array($_GET['options']) ? $_GET['options'] : array();
  7. UserApi::addOutputData('header', UserApi::getHeaderHtml($terminal, $options));
  8. } else {
  9.  
  10. $smarty = UserApi::getSmarty();
  11. $smarty->assign('inline', isset($_GET['inline']) ? $_GET['inline'] : 'false');
  12.  
  13. $smarty->assign('terminal', $terminal);
  14.  
  15. $textsIndexes = array(
  16. 'sign_in_with', 'no_registration_needed', 'remember_me', 'or', 'sign_in', 'register', 'password',
  17. 'forgot_password_link', 'requires_activation', 'name', 'e_mail', 'username', 'tooltip_username', 'tooltip_username_podsnack', 'tooltip_username_photosnack', 'password', 'receive_newsletter',
  18. 'forgot_pass_info', 'recover_password_button', 'access_to_all_apps', 'sign_in_register_to_continue',
  19. 'title_facebook', 'title_google', 'title_twitter', 'title_yahoo', 'title_myspace',
  20. 'sign_in_with_snacktools', 'edit_future_stuff', 'or_use_google_yahoo', 'just_keep_up', 'sign_in_more', 'sign_in_with_google', 'sign_in_with_twitter',
  21. 'keep_me_logged_in', 'sign_in_with_facebook', 'sign_in_with_email', 'no_registration', 'easy_sign_in',
  22. 'sign_in_new_user', 'sign_in_existing_user', 'sign_in_using_social_account', 'title_forgot_password', 'back_to_sign_in',
  23. 'create_account_txt','get_product_nl_and_offers', 'get_articles_on_banner_adv','or_quickly_connect_using', 'new_to_bannersnack', 'already_have_an_account'
  24. );
  25.  
  26. $textsIndexes1 = array(
  27. 'account_created_verify_email',
  28. 'account_created_important',
  29. 'account_created_time_left',
  30. 'continue_button',
  31. 'access_to_all_apps',
  32. 'thank_you_for_registering',
  33. 'account_created_verify_email_flipsnack'
  34. );
  35. $bsTextsIndexes = array(
  36. 'almost_there',
  37. 'best_experience',
  38. 'what_describes',
  39. 'business_owner',
  40. 'marketer',
  41. 'designer',
  42. 'developer',
  43. 'none_of_the_above',
  44. 'account_created_email_sent',
  45. 'bs_account_created_please_confirm'
  46. );
  47.  
  48. $textsIndexes = array_merge($textsIndexes, $textsIndexes1, $bsTextsIndexes);
  49.  
  50. $texts = Lang::getTexts($textsIndexes);
  51. $smarty->assign('texts', $texts);
  52. $outTexts = array('sign_in' => $texts['sign_in'], 'register' => $texts['register'], 'sign_in_register_to_continue' => $texts['sign_in_register_to_continue']);
  53. UserApi::addOutputData('texts', $outTexts);
  54.  
  55. $ip = isset($_GET['ip']) ? $_GET['ip'] : null;
  56. $requireCaptcha = UsersHistory::requireCaptcha($ip);
  57.  
  58. $smarty->assign('config', $config);
  59. $smarty->assign('lang', Lang::getLang());
  60. if ($requireCaptcha){
  61. $smarty->assign('captchaId', CaptchaGenerator::getNewDBId());
  62. }
  63.  
  64. UserApi::htmlContent($smarty->fetch('bannersnack/account-created/almost.tpl'));
  65. //UserApi::htmlContent($smarty->fetch('login-signup-compact.tpl'));
  66. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement