Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Oct 2008
    Posts
    38
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Unhappy How to reterive picture from mysql db? and display it in while()?

    Hello guys!
    I have the following code !

    PHP Code:
    <?
    // mysql_connect(........
    // select db ........

    $SQL mysql_query("SELECT * FROM pictures limit 10");

    while(
    $row mysql_fetch_array($SQL)){

     echo 
    '<img src="'.$row['picName'].'" />'// I am sick of thinking about this! where should the extension would appear ? how the src value will be posted here?

    }

    ?>

    Help me please!

  • #2
    New Coder
    Join Date
    Oct 2008
    Posts
    38
    Thanks
    5
    Thanked 0 Times in 0 Posts

    Question

    Quote Originally Posted by valslophap View Post
    Hello everybody!
    I am a new member in this forum.I love it so much .
    I aslo want to ask you one question.Please tell me your idea.It is so important to me :
    How cam I make friend with a pretty girl ?
    Thank a lot!


    Are you serious !!!
    Last edited by Fou-Lu; 10-15-2009 at 09:21 AM.

  • #3
    God Emperor Fou-Lu's Avatar
    Join Date
    Sep 2002
    Location
    Saskatoon, Saskatchewan
    Posts
    16,994
    Thanks
    4
    Thanked 2,662 Times in 2,631 Posts
    You're a victim of spam there :P
    Is picName just a filepath to the image, or binary/encoded image data?
    PHP Code:
    header('HTTP/1.1 420 Enhance Your Calm'); 
    Been gone for a few months, and haven't programmed in that long of a time. Meh, I'll wing it ;)


  •  

    Posting Permissions

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