Cable Forum

Cable Forum (https://www.cableforum.uk/board/index.php)
-   General IT Discussion (https://www.cableforum.uk/board/forumdisplay.php?f=19)
-   -   need help with pointing to an ubuntu directory. Using LAMPP (https://www.cableforum.uk/board/showthread.php?t=33647734)

Raistlin 25-03-2009 14:25

Re: need help with pointing to an ubuntu directory. Using LAMPP
 
No worries, just glad you're sorted :tu:

(actually I'm secretly surprised I was able to help at all, I know nothing about PHP :eek: :erm: :D )

TheDon 25-03-2009 14:26

Re: need help with pointing to an ubuntu directory. Using LAMPP
 
Quote:

Originally Posted by funkyCable (Post 34761967)
What if a picture has been removed or the link in the table is old as the file has been moved to another location?

Do you know if you can create sceduled jobs in mysql like you do with ORACLE?

So I should perhaps have a temp directory that I use to pick up the files/directories
create a reference and store it in the table and once this is done successfully move it to the relivant permanent folder where the image will reside.

It depends how you want to deal with adding and deleting items.

One option is to manually delete the row in the table, which will throw out the indexes but that's pretty trivial to fix, but constantly editing the table can be time consuming.
The other easy option is to drop and rebuild the table anytime you make changes, this will ensure that you aren't missing any indexes, and that everything is up to date, but is the more resource heavy option.

As long as you're not making changes too often I'd personally go with the less hassle 2nd option.

You don't need mySQL to do scheduled jobs, you could just have a cron job running a php script that does the work for you. But even then, you don't really need to schedule it as I assume you'll only be editing the pictures yourself? so you can just run it manually once you've added or removed some pictures.

Alternatively, you could use a filesystem monitoring daemon to automatically run the script when changes in the directory are detected, but that would definitely be overkill.

funkyCable 25-03-2009 14:33

Re: need help with pointing to an ubuntu directory. Using LAMPP
 
I was thinking along the lines of option 2 and thought if there is such a schedule/cron job then it could run over night or once a week or something when there is less traffic so I dont need to remember to do it.


All times are GMT. The time now is 02:14.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
All Posts and Content are © Cable Forum