TalkPHP
 
 
Account Login
Latest Articles
» The basic usage of PHPTAL, a XML/XHTML template library for PHP
» Vulnerable methods and the areas they are commonly trusted in.
» Simple way to protect a form from bot
» The Basics On: How Session Stealing Works
» How to keep your forms from double posting data
IRC Channel
IRC Speech Bubble Join the friendly bunch on IRC...
(#TalkPHP on Freenode)

...Also available via a web interface.

See this thread for information on the TalkPHP Free Hugs Initiative™. Subject to availability.
Associates
Associates
CSS Tutorials
Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old 02-12-2008, 07:29 AM   #1 (permalink)
The Addict
 
sarmenhb's Avatar
 
Join Date: Jan 2008
Location: los angeles
Posts: 309
Thanks: 44
sarmenhb is on a distinguished road
Default viewing an image from a table in a database

first off,

heres the structure of my table, where content is where the image or file will be stored

Code:
-- Table: upload

-- DROP TABLE IF EXISTS `upload`;

CREATE TABLE `upload` (
  `id`       int AUTO_INCREMENT NOT NULL,
  `name`     varchar(30) NOT NULL,
  `type`     varchar(30) NOT NULL,
  `size`     int NOT NULL,
  `content`  mediumblob NOT NULL,
  `ip`       text COMMENT 'ip',
  `title`    text,
  /* Keys */
  PRIMARY KEY (`id`)
) ENGINE = InnoDB;
what im wondering is what kind of code do i type to show the image as a link.
__________________
no signature set
sarmenhb is offline  
Reply With Quote
Old 02-12-2008, 10:37 AM   #2 (permalink)
The Acquainted
 
EyeDentify's Avatar
 
Join Date: Nov 2007
Location: Sweden
Posts: 106
Thanks: 13
EyeDentify is on a distinguished road
Default

As usal, nobody would like to write all the code for you without you eaven making an effort to overcome the problem yourself.

I suggest you check out the PHP: Hypertext Preprocessor website as a first stop.
And a second stop would be to google.

Then come back with some sample code if you donīt get it to work and we all will be glad to help.

Good Luck

/EyeDentify
__________________
Of course the whole point of a doomsday machine, would have been lost if you keep it a secret.
EyeDentify is offline  
Reply With Quote
Old 02-12-2008, 11:18 AM   #3 (permalink)
The Frequenter
 
ReSpawN's Avatar
 
Join Date: Nov 2007
Location: Netherlands
Posts: 460
Thanks: 49
ReSpawN is on a distinguished road
Default

I agree with EyeDentify. Just latterly type into google what you need and the magic webguru will speak.

How to Store images in mysql database with php
__________________
"Life is a bitch, take that bitch on a ride"

Last edited by ReSpawN : 02-14-2008 at 09:50 AM.
Send a message via MSN to ReSpawN
ReSpawN is offline  
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT. The time now is 04:26 AM.

 
     

Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2013, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.1.0
Inactive Reminders By Icora Web Design