Jump to content


Photo

Images and Categories in Mysql


  • Please log in to reply
1 reply to this topic

#1 Rama

Rama
  • New Members
  • Pip
  • Newbie
  • 3 posts

Posted 08 June 2006 - 11:35 PM

well guys.. I know some basic Php, and Mysql, but not much.

Im creating a small download script for my law Site, ( im studying law )
nothing important, its something really basic, that will help me to update the site easily...

1 question :

Is it better or faster to host images on MySQL ? or is it better to upload them to my site,
and just enter the url in the database ?


2 question :

While i work with categories for downloads, what is better, to create a table for each category,
or put them all toghether in one table by using a "categorie" fiels in the database ????


any help, will be much apreciated, and sorry if my english is not so good .... im from argentina...

thanks in advance-- [img src=\"style_emoticons/[#EMO_DIR#]/wink.gif\" style=\"vertical-align:middle\" emoid=\":wink:\" border=\"0\" alt=\"wink.gif\" /] [img src=\"style_emoticons/[#EMO_DIR#]/wink.gif\" style=\"vertical-align:middle\" emoid=\":wink:\" border=\"0\" alt=\"wink.gif\" /]

#2 Fyorl

Fyorl
  • Members
  • PipPipPip
  • Advanced Member
  • 273 posts
  • LocationUK

Posted 09 June 2006 - 01:01 AM

You can't actually store images in MySQL. You'd have to upload the images to your site and add the URL into one of the fields in your table. PHP can do both but you could do it manually if you wanted.

As for your other question, it would be better to create a new table with all the categories with unique ids for each row.
[table]



Don't worry, the printer fairies will sort it out.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users