Jump to content
MakeWebGames

Recommended Posts

Posted

i was updating some codes in the global_func.php and my index and viewuser has gone it just shows a blank page i have fixed the index but still have no viewuser, we need help

Posted

obviously something is causing an error...

try setting php error reporting to all on your viewuser file and it might point you in the right direction

 

error_reporting(E_ALL);
Posted (edited)

Take a look....

echo "

<h3><font color=orange>Profile for {$r['username']}</font></h3>

<table width=100% cellspacing=1 class='' border='1'><tr style='background:darkred'><th>General Info</th><th>Financial Info</th> <th>Display Pic</th></tr>

<tr>

<td>

Name: $user_name<br />

User Level: $userl<br />

<font color=yellow>$u_duties</font>

<font color=#00FF00>Status Message: {$r['sm']}</font><br />

Gender: {$r['gender']}<br />

Married: $partner<br />

Signed Up: $sup<br />

Last Active: $lon<br />

Last Action: $ula<br />

Last Login: $ull<br />

 

Do you see anything wrong?

your $vars is not going to show the way you have them it should be

Name: '.$user_name.'<br />

also your query is screwed up...

give me a few and i will fix it for you.

Edited by lucky3809
Posted

After removing all your extras so i could test it the page loaded fine. So must be something in your extras from the default that is causing the problem. But I cannot see the datetime parse function in your global_func file

Posted (edited)

not exactly i have got it working with his extra stuff... You are right about the vars after i uploaded the script to my server. but his bccode stuff is fine... its his query that is causing the problem...

Edited by lucky3809
Posted

Replace query with:

 

$q =$db->query("SELECT u.*,us.strength,us.agility,us.guard,us.labour,us.IQ,c.cityname,h.hNAME,g.gangNAME,
f.fed_days,f.fed_reason FROM users u LEFT JOIN userstats us ON u.userid = us.userid LEFT JOIN cities c 
ON u.location=c.cityid LEFT JOIN houses h ON u.maxwill=h.hWILL LEFT JOIN gangs g ON g.gangID=u.gang 
LEFT JOIN fedjail f ON f.fed_userid=u.userid WHERE u.userid=".$_GET['u']."");

 

You do not need to select every single thing in the user table like you were if your going to select all use u.*....

 

I also found below the query you are missing a few IF statement endings...

Posted

I dont believe 2.3 comes with marriage so you would need to make sure you still have it in your users table. Or better still program it in again in a seperate table so your not cluttering up your users table which is already oversized in mc2.x anyway

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...