Jump to content
Killersites Community

How do I auto populate a web page with audience response

Recommended Posts

I am looking to set up a page where a pup up asks the audience to submit images, quotes, and stories which would auto populate the spaces set aside for images, quotes, and stories. Can someone please send me in the right direction.

For example: I want to ask 'What is life?' and have the audience submit an image, quote, or story that represents what life means to them. Upon submitting, I would like their image, quote, or story to show up on the website in real time.

Edited by dakotarex

Share this post

Link to post
Share on other sites

Quotes & stories are just text, so that can be handled with a simple form.
The user inputs text and submits the form, your code saves it - probably in a database - and you're done.

Images might be an a URL to an existing image ( e.g. Photobucket ) or an actual image you allow them to upload via a form.
Either way, the end result is almost the same - a URL to an image - one being your-site.com/images/img-name.jpg and the other external-site.com/their-url-system/img.jpg

So you'd handle them differently but end up with a URL of some sort, that can be stored in the database. The uploaded image would have to be stored on your server.

For displaying the results you might want something like Javascript Masonry - check that out, it's quite fun :)


All text would have to be checked / cleaned to stop code injection, cross site scripting and all the nastiness that people WILL try !
If the site's meant to be "family safe" then removing swear words etc too.

Uploaded images would need to be coded so they can't upload huge pics; either flat out refuse them or shrink them down once uploaded.

"Family safe" pretty much goes out the window with images, unless you're going to get real people to moderate each and every one.

I believe there /might/ be some issues with external images and security, but I haven't researched it.
E.g. I post an external URL to an image like site.com/image.svg and that might not be an .svg at all, or maybe one crafted with malicious intent.

  • Like 1

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now