Gossamer Forum
Home : Products : DBMan : Customization :

graphics

Quote Reply
graphics
i'm sure a saw a posting about a while ago but couldnt find it again- so sorry in advance oif i am treading on a long and buried subject

but can you insert a graphic0 or peiec of music as fild entry-
eg a database of cds and one filed was the scan of the ablum cover?

thanks
Quote Reply
Re: graphics In reply to
It depends on how your database is set up.

If you have all the graphic files in the same directory, you can just enter the name of the file into the database field and use the following in sub html_record:

Code:
<img src="http://full/url/to/graphics/dir/$rec{'Graphic'}">

Be sure to change Graphic above to the actual name of the field that holds the name of the graphic file.

If your graphic files are not all in the same directory, you will need to add the full URL of the graphic file to your field and then use

Code:
<img src="$rec{'Graphic'}">

The same thing goes for a sound file, except that you would probably create a link.

Code:
<a href="http://full/url/to/sound/dir/$rec{'Sound'}">$rec{'Sound'}</a>

or

<a href="$rec{'Sound'}">$rec{'Sound'}</a>[/code]

------------------
JPD