LostAndConfused Posted January 8, 2009 Share Posted January 8, 2009 Hey guys just real quick, I need to know how to make a url with a part of it being from a mysql value. /* Avatar */ echo "<img src="uploads/".$req_user_info['avatar']." border="0" alt="">"<br><br>"; thats the code sofar but obviously i'm doing it wrong since it's giving me errors. Basically $req_user_info['avatar'] will be the file name and tag so I need to somehow connect that with "uploads/" to make the link for where the picture is. Does that make since? I just don't know how to connect a string to a value in php... Link to comment https://forums.phpfreaks.com/topic/140071-showing-picture-from-a-mysql-value-with-php/ Share on other sites More sharing options...
timmah1 Posted January 8, 2009 Share Posted January 8, 2009 This is how I do it <img src="images/<?=$sport;?>/<?=$a2['image'];?>" width="125" /> $sport and $image are pulled from the database Link to comment https://forums.phpfreaks.com/topic/140071-showing-picture-from-a-mysql-value-with-php/#findComment-732888 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.