| | |
images & web pages into db
Please support our MySQL advertiser: PostgreSQL or MySQL? Compare and contrast the two most popular open source databases
Thread Solved |
•
•
Join Date: Aug 2008
Posts: 94
Reputation:
Solved Threads: 0
Hello all!
I have a few questions about putting images into the database. I have chosen to put the images on my server and then the location will be put in the database, instead of doing the blog thing. However, I am having a hard time trying to figure out how to do this and where on my server I should place these files. I was told awhile back that through php I can even create files to put these images in if they are different clients. I'm clueless on how to do it.
Also, the program I'm using to build my software keeps shutting down and doing weird stuff because the web pages are too large. The creator of the software told me it would be wise to store the webpages into the database and then online pull them from the database. Is this done the same way that the images are done?
Thanks to all who can help
~Amy
I have a few questions about putting images into the database. I have chosen to put the images on my server and then the location will be put in the database, instead of doing the blog thing. However, I am having a hard time trying to figure out how to do this and where on my server I should place these files. I was told awhile back that through php I can even create files to put these images in if they are different clients. I'm clueless on how to do it.
Also, the program I'm using to build my software keeps shutting down and doing weird stuff because the web pages are too large. The creator of the software told me it would be wise to store the webpages into the database and then online pull them from the database. Is this done the same way that the images are done?
Thanks to all who can help

~Amy
•
•
Join Date: Aug 2008
Posts: 1,160
Reputation:
Solved Threads: 137
First part.
You are going the right route by storing files on the server and paths in the database. You should create a main image directory and possiblty have your images table have a subpath off of that. I'm sure each row will have an 'owner' or client column, so each client can have its own subfolder for images. Then each client, will have a house id lets say. So you can use something like this
/images/clientid/houseid/imagename.jpg
Second part.
This will work a little different. You will only want to load content, and not necessarily the entire webpage from the database.
If you can be a little more clear from the second part feel free.
You are going the right route by storing files on the server and paths in the database. You should create a main image directory and possiblty have your images table have a subpath off of that. I'm sure each row will have an 'owner' or client column, so each client can have its own subfolder for images. Then each client, will have a house id lets say. So you can use something like this
/images/clientid/houseid/imagename.jpg
Second part.
This will work a little different. You will only want to load content, and not necessarily the entire webpage from the database.
If you can be a little more clear from the second part feel free.
Custom Application & Software Development
www.houseshark.net
www.houseshark.net
•
•
Join Date: Aug 2008
Posts: 94
Reputation:
Solved Threads: 0
Hmmm...I'm still having a hard time following the first part. I'm trying to find the right place on my server to store them. Does it really matter where? For instance, I read in a php book that my httpdocs and uploads folder should be separate and the uploads folder is where I should store my uploads. Does this sound right? When I look on my server, however, the uploads folder is inside of the httpdocs file. Do you know the difference?
2nd part-okay, so pretty much the images from the website will be stored the same way and then I'll just write the php code on the static pages to pull at will?
Thanks,
~Amy
2nd part-okay, so pretty much the images from the website will be stored the same way and then I'll just write the php code on the static pages to pull at will?
Thanks,
~Amy
•
•
Join Date: Aug 2008
Posts: 1,160
Reputation:
Solved Threads: 137
Assuming you are using apache, here's a guide to setting up a virtual directory in apache
http://forums.htmlcenter.com/servers...ry-apache.html
I would recommend to set up possibly inside the uploads directory, you just want to be sure that permissions on this images directory aren't able to access your other directories, because you are allowing users to write to them.
http://forums.htmlcenter.com/servers...ry-apache.html
I would recommend to set up possibly inside the uploads directory, you just want to be sure that permissions on this images directory aren't able to access your other directories, because you are allowing users to write to them.
Custom Application & Software Development
www.houseshark.net
www.houseshark.net
![]() |
Similar Threads
- Firefox Compatibility help with script (JavaScript / DHTML / AJAX)
- IE quirk-no images showing on my index page (HTML and CSS)
- Loudobject | Template 8 and 10, Web Hosting Designs Web 2.0 & Coded - $250-$300 (Websites for Sale)
- Web Directory - Arcade Games Site With 1800 Games - Funny Pictures Site & Many Others (Websites for Sale)
- Diff between Website Hit & Visit (Search Engine Optimization)
- hover over text tips (JavaScript / DHTML / AJAX)
- Severe hijack & Trojan virus (Viruses, Spyware and other Nasties)
- updating 2 HTML tables on one PHP page (PHP)
Other Threads in the MySQL Forum
- Previous Thread: Trigger help
- Next Thread: build Mysql on WinXp
| Thread Tools | Search this Thread |
agplv3 alfresco amazon api aws bizspark breathalyzer changingprices cmg communityjournalism contentmanagement contractors copyright count court crm database design developer development distinct drupal dui ec2 email enterprise eudora facebook form foss gartner gnu government gpl greenit groklaw groupware hiring hyperic images innerjoins insert ip joebrockmeier join journalism keyword keywords kickfire laptop law legal license licensing linux maintenance managing mariadb matchingcolumns metron micromanage microsoft microsoftexchange mindtouch montywidenius mozilla multiple mysql mysqlcolumnupdating mysqldatetimeordermax() mysqlindex mysqlinternalqueries mysqlquery mysqlsearch news open-xchange opendatabasealliance opengovernment opensource oracle penelope php priceupdating query referencedesign reorderingcolumns resultset saas select sharepoint simpledb sourcecode spotify sql sugarcrm syntax techsupport thunderbird transparency virtualization






