$planet_reserved_tags = stripslashes($blog_settings->get('planet_reserved_tags')); $votes = $blog_settings->get('planet_vote'); $contact = $blog_settings->get('planet_contact_page'); $theme = $blog_settings->get('planet_theme'); $lang = $blog_settings->get('planet_lang'); $moderation = $blog_settings->get('planet_moderation'); $maintenance = $blog_settings->get('planet_maint'); $system_votes = $blog_settings->get('planet_votes_system'); $allow_post_comments = $blog_settings->get('allow_post_comments'); $avatar = $blog_settings->get('planet_avatar'); $log_level = $blog_settings->get('planet_log'); $nb_posts_page = $blog_settings->get('planet_nb_post'); $subscription = $blog_settings->get('planet_subscription'); $subscription_content = html_entity_decode(stripslashes($blog_settings->get('planet_subscription_content')), ENT_QUOTES, 'UTF-8'); // $subscription_content = html_encode_code_tags($subscription_content); $subscription_content = code_htmlentities($subscription_content, 'code', 'code'); $ganalytics = $blog_settings->get('planet_ganalytics'); $planet_analytics = $blog_settings->get('planet_analytics'); $piwik_url = $blog_settings->get('piwik_url'); $piwik_id = $blog_settings->get('piwik_id'); $internal_links = $blog_settings->get('internal_links'); $allow_uncensored_feed = $blog_settings->get('allow_uncensored_feed'); $show_similar_posts = $blog_settings->get('show_similar_posts'); $planet_shaarli = $blog_settings->get('planet_shaarli'); # statusnet options : $statusnet = array('host' => $blog_settings->get('statusnet_host'), 'username' => stripslashes($blog_settings->get('statusnet_username')), 'password' => stripslashes($blog_settings->get('statusnet_password')), 'post_format' => stripslashes($blog_settings->get('statusnet_post_format')), 'auto_post' => $blog_settings->get('statusnet_auto_post')); $output = ""; $output .= '<table id="tbl1" class="table-news"> <thead> <tr> <th class="tc5 tcr" scope="col">' . T_('Option') . '</th>
$msg .= "<div class='informations'><h2 class='informations'>" . T_("In case of problem") . "</h2>"; $msg .= "<p>" . sprintf(T_("If you don't recieve any news from the administration team within the 5 days do not hesitate to contact us via %s with this information :"), $blog_settings->get('planet_mail')) . "<br /><ul>"; $msg .= "<li><b>" . T_("Subject") . "</b> : " . $blog_settings->get('planet_title') . " - " . $choice['value'] . "</li>"; $msg .= "<li><b>" . T_("Username") . "</b> : " . $user_id['value'] . "</li>"; $msg .= "<li><b>" . T_("Fullname") . "</b> : " . $fullname['value'] . "</li>"; $msg .= "<li><b>" . T_("Email") . "</b> : " . $email['value'] . "</li>"; $msg .= "</ul></p></div>"; $msg .= T_("You should have recieved a confirmation email. Please validate and then you'll be able to connect : ") . "<a href='" . BP_PLANET_URL . "/auth.php'>here</a>"; } $core->tpl->setVar('flashmsg', $msg); $core->tpl->render('signup.flash'); } $content = $blog_settings->get('planet_subscription_content'); $content = stripslashes($content); $content = html_entity_decode($content, ENT_QUOTES, 'UTF-8'); $content = code_htmlentities($content, 'code', 'code', 1); $captcha_html = recaptcha_get_html($publickey); $core->tpl->setVar('params', $params); $core->tpl->setVar('form', $form_values); $core->tpl->setVar('subscription_content', $content); $core->tpl->setVar('captcha_html', $captcha_html); $core->tpl->render('content.signup'); $core->renderTemplate(); } #---------------------------------------------------# # Function to add pending user # #---------------------------------------------------# function addUserSignup($user_id, $user_fullname, $user_email, $password, $lang, $token) { global $core; # Clean Up user_id
function strip_script($string, $rm = 1) { if (!$rm) { $s = array("/<(\\/script[^\\>]*)>/", "/<(script[^\\>]*)>/"); $r = array("<\$1></myScript>", "<myScript><\$1>"); //do $string = preg_replace($s, $r, $string); //while (preg_match($s, $string)!=0); return code_htmlentities($string, 'myScript', 'pre', 1); } else { $split1 = preg_split('(<script[^>]*>)', $string, -1); $result = array(); # Pour chaque element on test si on trouve une fin de balise foreach ($split1 as $el) { $split2 = preg_split('(<\\/script[^>]*>)', $el, -1); if (count($split2) == 2) { # si la longueur du tableau est de 2, c'est qu'il y avait une balise # l'element avec une valise est le premier des deux $content_text = ''; //$result[] = '<'.$tag2.'>'.$content_text.'</'.$tag2.'>'; $result[] = $split2[1]; } else { # s'il n'y a pas de balise, alors on ajoute simplement l'element au tableau $result[] = $el; } } # Maintenant que le texte est transforme en tableau, on l'affiche element par element $output = ""; foreach ($result as $el) { $output .= $el; } return $output; } }