28Jul/090
How to ask user’s name and say welcome on your website
->
Here is how you can ask user's name and say welcome on your website.
Put the code below within your site's source code. If you dont know how to implement this code into your site, please goto how to implement the code to your website
Code:
<!-- this script is from www.manycodes.com --> <!-- Start of Hello Visitor JavaScript--> <!-- DESCRIPTION: This will ask the user for his/her name, then tell them WELCOME. INSTRUCTIONS: Place this script below the BODY tag, before you start the content of your page. FUNCTIONALITY: Works in both Netscape and IE. --> <SCRIPT LANGUAGE="JavaScript"> //Modified by CoffeeCup Software //This code is Copyright (c) 1998 CoffeeCup Software //All rights reserved. License is granted to a single user to //reuse this code on a personal or business Web Site. <!-- { var name = prompt ('Your name',''); var color = prompt ('Color name',''); document.write("<CENTER><FONT FACE=ARIAdL,VERDANA COLOR="+color+" SIZE=5>Welcome To Web Designer "+name+".</FONT><HR NOSHADE WIDTH=450></CENTER><P>") } //--> </SCRIPT> <!-- End of Hello Visitor JavaScript --> <font face="Tahoma"><a target="_blank" href="http://www.manycodes.com/category/java/javascript-codes/"><span style="font-size: 8pt; text-decoration: none">JavaScript Free Code</span></a></font>