Forum Moderators: open

Message Too Old, No Replies

How to go about updating a div with text and images

as the text is been written, along with many other ajax things

         

surrealillusions

10:47 pm on Aug 26, 2009 (gmt 0)

10+ Year Member



Hi all,

I'm sure I've seen this kind of thing done before, so looking for a way of doing it, preferably with jquery, and i would believe ajax is to be involved too with some parts.

The idea is to have, when the user types some text into a box, the text is automagically entered into another part of the page next to it, for like writing your own slogans/posters or something on a background image.

The other thing is to have a user upload an image, and then they can place and move that image around on top of that background image. I know that would involve some php for the upload part, but its the javascript part that I have no idea where to start with, once the image is uploaded, and to drag it across, preferably in the same window. And for the user to have a choice to email the design through to myself. So need to somehow save the image via javascript with what the user has inputted and email it across.

First thing is the text I would like to do, and then modify the text, so a simple WYSIWYG kind of editor with bold, italic, different fonts (if thats possible) kind of stuff.

Would it be best to modify an existing WYSIWYG editor to suit my needs to build my own? (which i have no idea how to, so..could be fun...).

I realise this is probably a fair bit to do all at once, so if we start at the beginning then that would be most helpful, and I can move onto other parts when ready.

Any help would be appreciated.

Thanks

:)

whoisgregg

8:14 pm on Aug 28, 2009 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



I happen to have quite a bit of experience with building a system like this. I used Prototype and Scriptaculous to handle all the AJAX and dragging to position elements. Server side I used PHP with the GD image functions.

Basically, the user entered text, font choices, colors, etc. is sent to PHP which generates a static PNG file. It returns the path to that file to the browser and Javascript adds a Draggable <img> tag to the design area.

It took me a year to build the app I made, but my particular use may be far more complex than what you have in mind. Good luck. :)