perfo4911 Posted July 25, 2012 Share Posted July 25, 2012 Gd day all. please can someone help me i have included the image header to the image but it gives me a blank page .please someone help me with an excellent method . Link to comment Share on other sites More sharing options...
birbal Posted July 25, 2012 Share Posted July 25, 2012 post your code Link to comment Share on other sites More sharing options...
Krewe Posted July 25, 2012 Share Posted July 25, 2012 Just store the link/path to the image you want in the database.Example: (Items in parenthesis are what you will put into the fields. Just examples though) tableField 1: id (1)Field 2: name (banner)Field 3: image (images/banner.png) Then all the php would look something like is. <?php$query = "SELECT * FROM table WHERE name = 'banner' LIMIT 1";$set = mysql_query($query, $connection);$result = mysql_fetch_array($set);echo "<img src=\"{$result['img']}\" alt=\"{$result['name']}\";?> Link to comment Share on other sites More sharing options...
Ingolme Posted July 25, 2012 Share Posted July 25, 2012 If the image data itself is in the database that wouldn't work. I don't usually like to put image data in the database, myself. 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now