PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Ok. I have an idea that probably excedes my abilities and i don't know where to start.
I want to have a page that a user can upload an image and it would be placed in a folder with that users name on it. I would then like to have a gallery that the first page has a list of users who have up loaded images. then if you click on the name you would see a gallery of the images that person has posted.
I don't have enought experience to know what would be the best way to go about doing this.
Thank you for any imput
If it exceeds your ability, there are plenty of images gallerys available under GNU-license, which you could use as they are or adapt conform your needs
If you're planning to do it by learning (and kudos to you if you do) then the following information will help you onto the rigth track...
On php.net search for $HTTP_POST_FILES for information on how to transfer files without the use of FTP.
The gallery script itself would be fairly simple... Once again i give out the suggestion to draw it out on paper what you plan to do.
For example, do you want a single full-sized image per-page? Or do you want several thumbnails that can be full-sized by clicking on them?
You'll want to investigate arrays... One of the first gallery scripts i made used a manual array that i had to add to every time i had a new picture, but i soon realised that the easier way would be to simply get a list of files with jpg/gif/png extension within a certain directory.
Look up the following on php.net
directory functions (to look in a directory, which leads to...)
substr (to find the extension of a file in the directory you looked in, and then)
array functions (focusing on simple one-dimensional arrays to put the files that matched your mask into an array)
After that you can use things like imagesize (if that's the function name, can't remember clearly off the top of my head) and so on and so forth.