Hello, all! I had a few quick questions...and then some, perhaps.
Is it possible to make it so that when someone presses a certain key, or sequence of keys, on their keyboard a picture is posted instead of a letter? As in, if I type shift+c in a textarea or input box could an image be placed inside the textarea or input box instead of a "C"? If so, how can that be accomplished? Thanks!
I'm pretty sure you cannot post an image to a textarea or textbox region.
You might consider looking at the key entered and:
1. post an image to one or several <div> backgrounds
2. or possibly have the images hidden and display them when the key is received.
Might be pretty slow unless the images are pre-loaded.
You can put images in email boxes...so why not a regular textarea or input box? It just seems like this would have been done a long time ago simply because it's been a feature on yahoo email and gmail for years and years. That's odd. If anyone wants to give it shot I'm sure we'd all like to see it.
You can put images in email boxes...so why not a regular textarea or input box? It just seems like this would have been done a long time ago simply because it's been a feature on yahoo email and gmail for years and years. That's odd. If anyone wants to give it shot I'm sure we'd all like to see it.
- Lono
I don't think that section of yahoo and email boxes are written in javascript.
You might try looking into some server-side code.
from what i know, an iframe with designMode = 'On'; works as an editable area where you can insert whatever tickles your fancy.
i haven't tried it myself, so i can't recommend it, but it looks like something you might find useful
That definitely looks like an option. However, how could I make it so that the user could type a message just like a textarea? If that can be solved then that idea really seems to be perfect. Thanks for that!
Why is that only a one browser solution? I really only need it to be a two browser solution...IE and Firefox. It's just for a little personal site. If that won't work in both browsers, do you have any better suggestions? Thanks, to you both!
You might look at how other WYSIWYG (what you see is what you get) editors handle this issue. Most of them either recreate a container element and toggle between allowing the rendered source to be viewed and a regular text component showing the source...or they use an iframe (or similar concept) with much the same effect.
What do you mean by WYSIWYG editors? Do you mean like Dreamweaver and HomeSite? I'm not using any editors. I used to make websites professionally, but I used freelance JavaScript writers for that. Now I'm just doing a little personal site for my mom.
Anyway, is there anyway to put a transparent object directly over a textarea (and I mean like the textarea is basically a background for the object) so that the text typed in the textarea is printed on the object in realtime? I think someone mentioned a similar idea in another thread a few days ago. Is that something that can be done to simulate a textarea containing an image? Thanks!
You are looking for a Rich Text Editor. A google search will turn up plenty of examples (TinyMCE springs to mind). They normally use an iFrame to display the content. Some, like TinyMCE I think, work with JavaScript disabled by defaulting to a textarea, others just fail completely if JavaScript is disabled.
Great wit and madness are near allied, and fine a line their bounds divide.
Bookmarks