--- Hassan Schroeder <[EMAIL PROTECTED]> wrote:
> Actually, if you include the dimensions in your
> image *names* --
> which is a great timesaver -- you can store them as,
> say
>
> ak.200x150.gif
>
> and retrieve as
>
> SELECT
> img
> , SUBSTRING(img,4,3) AS width
> , SUBSTRING(img,8,3) AS height
> FROM
> images
> WHERE
> LEFT(img,2) = 'ak'
>
> You can put that into your own function and write
> the entire image
> tag out with the proper width and height, in one
> swell foop :-)
* * * * * * * * * *
It will take me a while to understand this, as I
haven't even begun to learn about strings, let alone
substrings, yet.
But I have a couple questions, for future reference:
1. When you talk about including dimensions in image
names, do you mean it literally? For example, if I
create an image in photoshop that measures 150px X
125px, I could save it as horse.jpg, or save it as
horse.150X125.jpg?
2. Are you talking about storing the actula image in
MySQL (as a BLOB), or just placing links to image
names (that include dimensions) in a field?...
ak.200x150.gif
wy.225X110.jpg
__________________________________
Do you Yahoo!?
Yahoo! Domains � Claim yours for only $14.70/year
http://smallbusiness.promotions.yahoo.com/offer
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]