my gallery script

i’m so tired of all the gallery scripts available. maybe i’m just not looking at the correct location. i really don’t care about all the functionalities such as comments, rating, hits etc. i don’t even know why the scripts need a database support. i just want a script that quickly loads the photos and give me A LOT OF control of the layout so it will work with all of my themes.

here’s my idea. designate a folder for ALL PHOTOS for the photo album. let’s call this folder the root folder. each directory created within the root folder would a specific category. all folders created within the category folder would be subcategories. within each folder are all the photo files nothing else. there will be on php file in the root folder that holds the description of all photos in one big array.

when the script loads, it simply reads the root folder and then figure everything out from here. the script is able to generate thumbnails.

this would mean, you can upload the photos in bulk with ftp along with a description file and boom, your gallery should be updated. NO UPLOAD, NO DATABASE UPDATE and all those crap.

after looking around and trying a few different free scripts, i did not find anything that totally satisfy my need. then inspired by leslie’s gallery script , i’ve decided to write my own. it’s pretty much done. i still need to add a few more descriptions. btw thank you leslie for all your help during my development!

current features include:

  • auto read dir and its subdir
  • auto create thumbnails
  • auto generate the next and previous photo link
  • display __ number of random photos
  • display __ number of newest photos
  • auto delete thumbnails if the orginal photos are deleted
  • an admin script that allows me to regenerate thumbnails if necessary
  • an admin script that would generate my big description array like this
  • most importantly it will be compatible with all my themes! this means it’s validated xhtml strict

blah that’s all i can think of. i don’t think it will be sharing this script any time soon. it involves too much. but then sometimes i feel bad not sharing. we will see. if you think you will use a script like this, let me know.

37 thoughts on “my gallery script

  1. I am sorry for asking you this in your comments. I know people can get annoying. I was just wondering, I am looking for a b2 comments hack, and there was one on this site. I found it on the b2 forums. Do you still have it or know where I can get it? Thanks, Marie

      1. Sorry I should have emailed you. I am looking for the “b2 commenter plugger hack”. I searched and found the post but the link to it did not work. Thanks =)

              1. if you just click on that link, it won’t work. if you copy and paste the url to a blank browser and load it, it will work. it’s my strict no hot link .htaccess

  2. Great script! I found a simple photo gallery (from squidfingers) but it didn’t have all the features of yours. You can offer it as a paid script. It’d definitely be something I would buy. Also the script could be improved with captions, but that’s all I can think of at the moment.

    1. well the caption is supposed to be your file name. you can add a description obviously. you are expected to give your photo file a meaningful name. i do want to improve it here and there. maybe allow a few options here and there. i will think about it. thanks 🙂

        1. i really don’t think an external caption file is necessary. since you already have the description file. just name your file give_a_very_good_name.jpg and the script will replace all _ with space and get rid of the extension and use that as the caption. should be perfect. no extra work.

            1. sarah.. are you talking about “caption” or “description” – i’d think caption is just a title for a photo. description can be lengthy. my script does support that. i.e. this photo. and i just improved my script last night so you can edit description thru cp. no longer have to do it manually.

  3. Hey Dodo, I would definitely use a script like this! I was hunting high and low for a gallery script which doesn’t require mySQL as well. 😛

  4. Ooh, looks very simple and clean. I use Cine’s gallery script , but it does use mysql. It’s very customizable. I do like the massive upload option yours has tho… Cine’s can only upload one at a time.

  5. awesome planning 🙂
    i personally never use the ‘hits’ a picture get, or the ratings xP

    But I do love SimpleViewer ( – and my demo It was so simple to set up and upload my pictures. The downside to this for your needs would be that it’s a flash viewer xD and obviously not very customizable with your layouts. But i’m just saying how that’s really simple too (i love it that it auto-generates thumbnails! which you plan to include, which is a nessessity! :D)

    Good luck with your gallery dodo! 🙂 And oh don’t be silly, and feel bad about not sharing. It’s YOUR HARD work, you should do what you please with it 🙂

    1. leslie said it must use a lot of bandwidth since it loads the images even if you don’t view them. tho very good quallity images but haha it will be a killer for a site like mine that already has very severe bandwidth problem.

      1. lol, ahh that leslie, always the party pooper! heeh, but i admit, it probably does use up a lot of bandwidth (good thing my gallery is small, and i doubt will grow too much xD) But yea, must conserve bandwidth 😡

    1. no the thumbnails are generated automatically like i mentioned in the feature list. it’s just a php function that uses GD.
      i don’t like coppermine coz i can not incoporate its design into my layout very easily. just like 4images, i will have to have a separate design for it. i don’t want that. also it has more features than i need. and also i don’t want to use a database.
      i’m still trying to improve the script so i can add description more easily.

      1. yah i dont like that about coppermine, but it was a quick solution.

        about the thumbnails – i noticed that they are actually cropped – does GD have functionality to know where to crop or something?

    1. aww thanks for sharing. great script but again i probably would have a lot more flexibility with layout with my own. plus i don’t see description.. and newest photos feature in the demo?

  6. Too be honest, I have no clue. I had that recommended to me and I noted some of the key features so I can recommend it if people ask for some gallery scripts to use.

    Is yours going to be made available for the public? Or is it a private thing?

    1. i might sell it. or trade it with graphics, like gorgeous xhtml validated layout for pe hehe.. but it’s not ready for release yet. lots work to do before that.

  7. I would love it if you could send me an email when you feel the need to share — this is EXACTLY what I have been looking for and I can’t find anything without frills. Everything else takes a while to modify and frankly I’m tired of learning someone elses completely different coding style just to make a decent photo gallery.

  8. Hey!
    Looks great, so if you ever feel like sharing it, I’ll be glad to use it! I’m currently looking for a gallery too and I agree about all the useless functions. Yours looks just perfect. 🙂

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s