SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Addict whofarted's Avatar
    Join Date
    Aug 2001
    Location
    lost, If you find me please return me to St.Louis
    Posts
    396
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    URLs with variables in them...

    I'm trying to figure out what to put in the URL to make the link point to another page with the variables in the URL.

    Here's a sample part of my code. Everything is working I just can't get the URL to do what I want.

    PHP Code:
      <?php 
        
        
    // Request the names of Active players
    $resultactive mysql_query("SELECT playername,playerpoints,playerrank FROM player_profile WHERE playerstatus='Active'");
    if (!
    $resultactive) { echo("<P>Error performing query for Active players: " mysql_error() . "</P>");
     exit();}
       
    // Display the name of Active players
     
    while ( $rowactive mysql_fetch_array($resultactive) )
      { echo(
    "<tr><td><a href='profile.php?playername=WHAT GOES HERE?'>" $rowactive["playername"] . "</a><td>" $rowactive["playerrank"] . "<td>" $rowactive["playerpoints"] . "</td></tr>"); }

    ?>
    The URLs should be ex:
    profile.php?playername=Smokey

    or

    profile.php?playername=whatever

    The idea is you click the persons name & it takes you to their profile.

    Let me know if you need to see more of the code, I'll post the whole page if necessary.
    TIA!
    Last edited by whofarted; Sep 3, 2001 at 22:12.
    You smell something?

  2. #2
    SitePoint Addict whofarted's Avatar
    Join Date
    Aug 2001
    Location
    lost, If you find me please return me to St.Louis
    Posts
    396
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    NM I figured it out on my own!!!!

    I did the full page with no help on this one!

    Hey it's a new one on this newbie.
    You smell something?


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •