SunQuest
 
           General Programming Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
User Name:
Password:
Remember me
 
Go Back   Dev Articles Community ForumsProgrammingGeneral Programming Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Display Modes
 
Unread Dev Articles Community Forums Sponsor:
Stay one step ahead of the competition. Evaluate and give feedback on some of the hottest web development tools on the market today. Make your opinion heard! Click Here
  #1  
Old June 12th, 2003, 09:37 PM
thecharking thecharking is offline
Contributing User
Dev Articles Newbie (0 - 499 posts)
 
Join Date: Apr 2003
Posts: 187 thecharking User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 6
Send a message via AIM to thecharking
help with admin edit profile

I want to make an admin section where admins can edit any profile of any user. I have done this using the little article about the <<prev 1 2 3 next >> thing. But i think i dont understand the whole template thing. Well my editprofile page looks like this:

it grabs the logged-in users sessionid and compares it to that of the users in the database, to retrieve that users information to be edited. this works fine for one person.

But then my admin-main-edit page works like this:

it grabs info from the users database not the session database, and I can not figure out how to grab from both using the template.

so i decided that I would simply create a new $variable, use it to determine the user that was called on in the users database, compare that users info to the session database, so that it can simply get the right sessid and then call on the user info like it normally does.

i hope that made sense. at any rate the problem lies here:


PHP Code:
function MatchUp()
       {
         
$changeIt = @mysql_query("SELECT * FROM users WHERE userId ='" $strMethod "'") or die ("couldn't do it");
          while (
$changeRow mysql_fetch_row($changeIt))
              { 
$changeIt2 = @mysql_query("SELECT * FROM `session` WHERE username = '" $changeRow[1] . "'") or die ("couldn't do this");
                while (
$changeRow2 mysql_fetch_row($changeIt2))
                 {     
$strMethod2 $changeRow2[1]; } }
                    
header("Location: index.php?page=editprofile&strMethod=$strMethod2"); 


but this is returning nothing in my url for $strMethod2. I tried writting this [below] cause i thought it was how it was suppossed to be written:


PHP Code:
("Location: index.php?page=editprofile&strMethod='" $strMethod2 "'"); 


which returned:
index.php?page=editprofile&strMethod=''
it seems to be giving me an empty string for the variable.

i hopes this makes sense. anyone with help would be awesome. thanx.

Reply With Quote
Reply

Viewing: Dev Articles Community ForumsProgrammingGeneral Programming Help > help with admin edit profile


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 3 hosted by Hostway