HTML - Smilies In Guestbook
Hi all,
I am making GuestBook for my website. I made it with smilies where user can click on smilie and tag for it added in the textbox of message. I wonder how can we show smilie image instead of its tag. Like you can add smilie image in text box with message in Yahoo or Hotmail. Thanks in advance. Similar TutorialsI found an old thread about this but it seems no one was there. I am also new at this so forgive me if I posted in the wrong place. I am using a javascript to replace my smiley characters with a smiley image in comments. The first comment will show all the images. The remaining comments just show smiley characters. Here is the code Code: var smilies = new Array(); smilies[';)'] = 'smileys/wink.gif'; smilies[':)'] = 'smileys/smile.gif'; smilies[':('] = 'smileys/mad.gif'; function showSmilies(){ foo = document.getElementById('div').innerHTML; for ( x in smilies ) { _search = x.replace( /\(/g, '\\(' ); _search = _search.replace( /\)/g, '\\)' ); _search = _search.replace( /\[/g, '\\[' ); _search = _search.replace( /\]/g, '\\]' ); search = new RegExp( _search, "g" ); foo = foo.replace( search, function(found){ return '<img src="'+smilies[found]+'" />'; }); } document.getElementById('div').innerHTML = foo; } if(window.addEventListener){ window.addEventListener('load',showSmilies,false); } else { if(window.attachEvent){ window.attachEvent('onload',showSmilies); } } I have tried changing document.getElementById('div').innerHTML to document.getElementsByTagName('body')[0] It will replace everything on my page and it will also display smileys with a code and link with them. All I need it to do is display smileys in my "div" with the comments. This is also just an add on to my site. Thanks i am looking for a good guestbook to use for my website: i am looking for the following features. all these are not vital but will be preferred. good design no ads, (if there are any they should be text links) place where i can add my own text and links to other pages on my website easy to use as most of my visitors will be computer novices is there any such guestbook out there. Hey guys. I'm a bit new to HTML. So I know the basics but I'm trying to make a unique guestbook. I want to let a visitor of my website type in their name, and then comments on the site or whatever they want to write. The thing is though, I want to make it so it sends it to my e-mail after they put their name and comments, either that or I want it somewhere on my website on another page or something. I also want it to transfer the visitor to a different page that thanks them for signing the guestbook (which i've already made) after they click the submit button. All I really have so far is this: <form> Name: <input type="text" name="name"> <br> Comments: <input type="text" name="comments"> </form> Thanks guys! Hi, I have been working on my new website and i'm wanting to add a guestbook, i've got the HTML, all looks fine on my website. I'm just having problems when i try to post onto the guestbook. I think it has something to do with this bit: <FORM METHOD=POST ACTION=""> Where i have "action" i added /guestbook.html. But when i pressed post it was taking me to the guestbook.html page which is blank. I just want new posts going on the page where the guestbook is. Heres the Code, if someone can edit it for me please. <!--GUESTBOOK--> <HR><B>Barry <A HREF=mailto:sdsm>baza06@msn.com </A></B> <P>Just testing <HR><B>Barry <A HREF=mailto:sdsm>baza06@msn.com </A></B> <P>Just testing <!--POINTER--> <!--everything after this is standard and unchanging. --> <HR> <center>Post a response: <BR> <FORM METHOD=POST ACTION=""> Name: <INPUT TYPE="text" NAME="name" SIZE=25 MAXLENGTH=25> <BR> Email: <INPUT TYPE="text" NAME="address" SIZE=30 MAXLENGTH=30> <BR> Text: <BR> <TEXTAREA ROWS=5 COLS=65 NAME="body"> </TEXTAREA> <BR> <INPUT TYPE=submit VALUE="POST"> <INPUT TYPE=reset VALUE="CLEAR"> </FORM></center> <HR> I'm in a nonprofit org that has an events page & a job posting page. We're currently using an old guestbook format that is getting spam on a daily basis. I'm looking to replace it w/ a more secure forum or something which would require posters to sign-up or something (in hopes of preventing spammers). I'm looking for recommendations for something EASY to setup. Sorry if this is in the wrong forum...wasn't sure where to post this! Thanks in advance, Shelly Hi - I want to create a guestbook that is incorporated into my webpage here Are there any easy to install guestbooks that can be embedded into the page with a captcha. I don't mind paying for a simple one... Have scoured the net but can't seem to find what I'm looking for. Best Mas I am building a website for a class and I need the ability to post comments. I need to take in name, address, all the usual stuff, their comments and then post it back for everyone to read. The catch is that my site will mainly be being viewed offline. I will have it online, but that isnt part of the requirements. I need some sort of extremely simple form/posting method that doesnt require anything to be running server-side. I have decent knowledge of html, but zero knowledge of java scripting, php, mysql, asp, perl, etc. I have downloaded some guestbook generators and looked at some other examples, but all of them seem to require something running server side. I say seem because I really dont know. I dont need any security or anti spam or spell check or anything like that, just something really simple. It is getting down to crunch time, so any help would be appreciated. If you need anything on my end please let me know. I am recieving email notifications on this post, but if you want to IM me at phemmin and get some interactive discussion going, that would be great. I probably wont be around until tomorrow afternoon. Also, I am using frames, dont know if that will matter any. |