SitePoint Sponsor

User Tag List

Results 1 to 3 of 3

Threaded View

  1. #1
    SitePoint Addict
    Join Date
    Jun 2007
    Location
    Plymouth uk
    Posts
    313
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Need a little more help Please

    basic is peeps join fill out form and details go to database with a temp pname
    then they can upload a photo to uploads after they have renamed it to there mysql id which is shown when they login so where would i put the code to update pname

    here is the code i have so far

    PHP Code:
    //Retrieves data from MySQL

     
    $data mysql_query("SELECT * FROM test where email='$myemail'") or die(mysql_error());
     
    $count mysql_num_rows($data);
     if (
    $count==0) { 
    header ("Location: wrong.html");
    } else {

    //Puts it into an array 
    while($info mysql_fetch_array$data )) 

    //Outputs the image and other data



    Echo "<p class=\"style1\"><b>This is your ID rename your photo to </b> ".$info['ID'] . ".jpg </p>";

    }
    ?>
    <h3 align="center">Upload Photo</h3>
                <p align="center">use this form to upload your photo as a jpg </p>
                 <p align="center">if you have no photo click no photo</p>
                
              <form action="formtoemailpro2.php" method="post" enctype="multipart/form-data">
                <table border="0" align="center" cellspacing="5" bgcolor="#ececec">
    <tr><td>Your Name:</td><td><input type="text" size="30" name="name"></td></tr>
    <tr><td> Photo:</td><td><input type="file" name="pic"></td></tr> 
    </td><td><input type="submit" value="Send"></td></tr>
    </td><td><input type="button" value="No Photo:" onclick="window.location.href='index.html'" /></td></tr>
    </table>
    </form>
    </div>

    </body>
    </html> 
    and this is what it looks like on screen

    cheers
    Doug
    Attached Images Attached Images
    an old man of 60 trying to keep up with the youngsters he he
    http://lostpetsplymouth.net16.net


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
  •