Click here to Skip to main content
13,052,163 members (39,467 online)
Rate this:
Please Sign up or sign in to vote.
See more:
Hi there, I need help with creating a gallery for an HTML page but cannot find a tutorial anywhere and everyone I know doesn't know the answer X_X...

Basically I need a page with 2 rows (5 pics in each row), so 10 pics on a page with a next and previous button on each side. All the pictures are in a file on the server ( or in this case, in my site file, localhost).

Now I need the newest (date order) pics in slot 1-10, and when you click next, it loads the next 10 files in date order, and if you click previous.... it loads the newer 10 pictures in date order.

Can anyone help me explaining how I do this and where I can go to learn how to do this / help for this?

Thanx so much,

[Added below from the OP's "solution" which needs to be removed — SA]

Oh and I cant have it be a downloaded file from some company, I want to be able to write it myself / friends help and actually learn from it rather than download it.

Posted 8-Dec-11 8:48am
Updated 8-Dec-11 12:38pm
mjbohn 8-Dec-11 15:33pm
Please use 'Improve question' to alter your request. Do not add a solution.
SAKryukov 8-Dec-11 18:58pm
Please don't post a solution unless this is a real solution. Such posts will be removed, no one gets e-mail notification. Use "Improve question", add a comment, a reply to a comment.

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 2

Even your vague ideas about the design of the gallery are not good enough to start doing this project.

For example, fixed number of images on row is really bad, it would assume fixed size of a browser window which is ridiculous — this is not what happens in real life on the client side. Some (many) use the mobile devices. Any provisions of thumbnail? Without those you cannot make a gallery convenient, not even close. How about different viewing options? Smaller size, actual size, "real pixel"? Zoom? (This can be considered as too advanced.)

Even though you can easily make a gallery using only server-side programming (PHP), it's usually either too static or too slow without some client-side programming using JavaScript (but if your requirements are modest, you need only a bit of client-side programming. I find jQuery extremely helpful.

Now, you can find tons of projects to use for samples or just to learn some techniques:[^]

or may be[^].


This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.170713.1 | Last Updated 8 Dec 2011
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100