user/editprefs.php: Finally fix ~20-year-old skin selecting bug! Here was the bug in question: If your future selected skin was going to be the same as the default site's selected skin, it would not change at all unless you selected it at the site's drop-down menu, then it now became your account's selected skin. Also forgotten formmating change
user/editprefs.php: Finally fix ~20-year-old skin selecting bug! Here was the bug in question: If your future selected skin was going to be the same as the default site's selected skin, it would not change at all unless you selected it at the site's drop-down menu, then it now became your account's selected skin. Also forgotten formmating change

--- a/user/editprefs.php
+++ b/user/editprefs.php
@@ -34,7 +34,7 @@
 		$storyindex = isset($_POST['storyindex']) && $_POST['storyindex'] == "on" ? 1 : 0;
 		$sortby = isset($_POST['sortby']) && $_POST['sortby'] == 1 ? 1 : 0;
 		$skinnew = descript(strip_tags($_POST['skinnew']));
-		if($skinnew != $skin) $_SESSION[$sitekey."_skin"] = $skinnew;
+		if(($skinnew) != $skin || ($skinnew) == $defaultskin) $_SESSION[$sitekey."_skin"] = $skinnew;
 		dbquery("UPDATE ".TABLEPREFIX."fanfiction_authorprefs SET alertson = '$useralertson', newreviews = '$newreviews', newrespond = '$newrespond', ageconsent = '$ageconsent', tinyMCE ='$tinyMCE', userskin = '$skinnew', storyindex = '$storyindex', sortby = '$sortby' WHERE uid = '".USERUID."'");
 		$output .= write_message(_ACTIONSUCCESSFUL." "._BACK2ACCT);
 	}
@@ -73,7 +73,7 @@
 		foreach($skinlist as $s) { $output .= $s; }
 		unset($skinlist, $s);
 		closedir($directory);
-		$output .= "</select><A HREF=\"#\" class=\"pophelp\">[?]<span>"._HELP_SKIN."</span></A><br /><INPUT style='margin-top: 0.5em;' type=\"submit\" class=\"button\" id=\"submit\" name=\"submit\" value=\""._SUBMIT."\"></form>";
+		$output .= "</select> <A HREF=\"#\" class=\"pophelp\">[?]<span>"._HELP_SKIN."</span></A><br /><INPUT style='margin-top: 0.5em;' type=\"submit\" class=\"button\" id=\"submit\" name=\"submit\" value=\""._SUBMIT."\"></form>";
 	}
 
 ?>