UBB.Dev
Posted By: mi_trucker Extended User Editor v3.1 - 03/23/2004 4:52 PM
I installed this mod today and all seems to work well, except for this, that I'm seeing at the very bottom of the first screen you come to after clicking on the user you wish to edit.

[] echo " {$ubbt_lang['CHOOSE']}

"; $html -> open_admin_table(); echo " Edit profile {$ubbt_lang['PROFILE']} "; if ( ($user['U_Status'] == "Administrator") && ($Number != '1') ){ echo " Delete user {$ubbt_lang['DELETE']} "; } // ------------------------------------------- // Let's see if this user moderates any boards $query = " SELECT Mod_Board FROM {$config['tbprefix']}Moderators WHERE Mod_Uid = '$User' "; $sth = $dbh -> do_query($query); list($modcheck) = $dbh -> fetch_array($sth); // ----------------------------------------------------------------------- // If this is an admin and it's not the first admin, let them revoke privs if ( ($user['U_Status'] == "Administrator") && ($Status == "Administrator" && $Number != "1") ){ echo " Revoke admin privs {$ubbt_lang['REV_ADMIN']} "; if ($modcheck) { echo " {$ubbt_lang['ISMOD']}"; } else { echo " {$ubbt_lang['ISUSER']}"; } echo " {$ubbt_lang['IMMEDIATE']}"; } elseif ( ($Status != "Administrator") && ($user['U_Status'] == "Administrator") ){ echo " Grant admin privs {$ubbt_lang['GIVE_ADMIN']} {$ubbt_lang['IMMEDIATE']} "; if ($Status != "Moderator") { echo " Grant mod privs {$ubbt_lang['GIVE_MOD']} {$ubbt_lang['IMMEDIATE']} "; } } // -------------------------------------------------------------------------- // If they moderate a forum give a link to remove them from one of the forums if ( ($modcheck) && ($user['U_Status'] == "Administrator") ){ echo " Remove from moderator list {$ubbt_lang['REM_MOD']} "; // ----------------------------------------------------------------------- // Otherwise they do not moderate a board so they can be demoted to a user // if they are currently a moderator } elseif ( (!$modcheck) && ($Status == "Moderator") ) { echo " Revoke moderator privs {$ubbt_lang['REV_MOD']} "; } // -------------------------------------------------- // Give them the option of editing this user's groups echo " Edit groups {$ubbt_lang['EDIT_GROUP']} "; // -------------------------------------------- // Let's find out if this user is banned or not $query = " SELECT B_Uid FROM {$config['tbprefix']}Banned WHERE B_Uid = '$User' "; $sth = $dbh -> do_query ($query); list($bcheck) = $dbh -> fetch_array($sth); if (!$bcheck) { echo " Ban this user {$ubbt_lang['BANUSER']} "; } else { echo " Unban this user {$ubbt_lang['UNBANUSER']} "; } echo " Become this user {$ubbt_lang['LOGINAS']} "; $html -> close_table(); $html -> close_table(); // ---------------- // send the footer $html -> send_admin_footer(); ?> [/]

I've actually done the mod twice now with the same results. What, if anything, did I miss?
Posted By: JoshPet Re: Extended User Editor v3.1 - 03/23/2004 5:01 PM
Not sure exactly what you did - but it would seem that you're missing an opening PHP tag. I'm using this mod on a bunch of sites - so whatever file is that displays the code - make sure it's got a starting <? at the top.
Posted By: mi_trucker Re: Extended User Editor v3.1 - 03/23/2004 5:25 PM
Thanks. I'll go back through and see what it might be. I did my usual, Search/find and then cut and past over the old with the new copied directly from the instructions.
Posted By: JoshPet Re: Extended User Editor v3.1 - 03/23/2004 5:36 PM
Also - make sure there's no accidental "ending" tag ?> before that code either.
Posted By: scroungr Re: Extended User Editor v3.1 - 03/23/2004 6:26 PM
for another looks like all your code is whacked and not in nice neat straight lines.. or that could be the way you quoted it
Posted By: mi_trucker Re: Extended User Editor v3.1 - 03/23/2004 6:48 PM
Oops, I forgot to save my reply.

After Josh replied the first time, I went back in and realized, DOH!!! Said in my best Homer Simpson voice, that I hadn't highlighted ALL the text that needed to be replaced. Once I did that, all was well in Truckers Land and it's working perfectly.

Need to wait until my 2nd or 3rd cup of coffee before working on these things...LOL
© UBB.Developers