0

I'm using an HTML/PHP form to manage user input. On request users may select to attach an image to the message. Need a server side image picker.

Would like to allow users to browse server side images, possibly with an optional thumb to fasten image selection.

This could be achieved in the same form area, or with a sort of dialog, if possible.

Once image is chosen, the filename must be returned.

3
  • You need an example or a way to do that? Commented Mar 14, 2011 at 15:34
  • 1
    You could 1) List all the image files in folder X on your server 2) For each file, check if there's a cached thumbnail. If not, create a thumbnail 3) Load the resulting thumbnails into a separate (hidden) div upon page load; or load the content with AJAX upon entering your "filename" field 4) Upon clicking on one of the thumbnails, replace the value of the textfield with the image's filename That's just an idea. There are many ways that this could be done, IMHO. Commented Mar 14, 2011 at 18:06
  • How explained from isotrope, there are many ways to do that... Start from php gd reference: php.net/manual/en/function.imagegd2.php (there are many examples) for resizing thumb, and the jQuery("element").load() function reference from here: api.jquery.com/load for loading the gallery from a server side script or static html resource file... Commented Mar 15, 2011 at 10:59

1 Answer 1

0

If you are OK with GPL or LGPL then you can check some phpclasses.org scripts: http://www.phpclasses.org/package/3471-PHP-Browse-and-choose-images-without-page-reloading.html

http://www.phpclasses.org/package/1473-PHP-Create-a-picture-browser.html

Might require a little coding to implement image selection feature.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.