We don't want this to happen anymore in Nuke6.5
All theme selection shoudl be conttrolled ONLY from the theme selection on the Your Account page!
Here's how to remove the feature. You don't have to remove the Style selection option from the template tpl file, it won't work after this, but you can for cosmetics if you want. You'll have to find that yourself :-)
open
includes/usercp_register.php
Find around line 502(it's all one line)
Code:
SET " . $username_sql . $passwd_sql . "user_email = '" . str_replace("\'", "''", $email) ."', theme = '$save_nuke_theme', user_icq = '" . str_replace("\'", "''", $icq) . "', user_website = '" . str_replace("\'", "''", $website) . "', user_occ = '" . str_replace("\'", "''", $occupation) . "', user_from = '" . str_replace("\'", "''", $location) . "', user_interests = '" . str_replace("\'", "''", $interests) . "', user_sig = '" . str_replace("\'", "''", $signature) . "', user_sig_bbcode_uid = '$signature_bbcode_uid', user_viewemail = $viewemail, user_aim = '" . str_replace("\'", "''", str_replace(' ', '+', $aim)) . "', user_yim = '" . str_replace("\'", "''", $yim) . "', user_msnm = '" . str_replace("\'", "''", $msn) . "', user_attachsig = $attachsig, user_allowsmile = $allowsmilies, user_allowhtml = $allowhtml, user_allowbbcode = $allowbbcode, user_allow_viewonline = $allowviewonline, user_notify = $notifyreply, user_notify_pm = $notifypm, user_popup_pm = $popuppm, user_timezone = $user_timezone, user_dateformat = '" . str_replace("\'", "''", $user_dateformat) . "', user_lang = '" . str_replace("\'", "''", $user_lang) . "', user_style = $user_style, user_active = $user_active, user_actkey = '" . str_replace("\'", "''", $user_actkey) . "'" . $avatar_sql . "
remove this part from that line
Code:
theme = '$save_nuke_theme',
also you may want to comment out all these lines which are right above that line
Code:
$sql = "SELECT * FROM ".$prefix."_bbthemes WHERE themes_id='$user_style'";
$result = $db->sql_query($sql);
$get_info = $db->sql_fetchrow($result);
$nuketheme = $get_info[template_name];
$handle=opendir('themes');
while ($file = readdir($handle)) {
if ( (ereg("[$nuketheme]",$file)) ) {
$nuke_theme_exsist = "true";
}
}
closedir($handle);
if($nuke_theme_exsist == "true"){
$save_nuke_theme = "$nuketheme";
} else {
$save_nuke_theme = "$Default_Theme";
}
If we leave the style selction option working on the Forum side in the User's edit profile, then you may experience some not so nice effects. Trust me on this one...
mikem