Learning ASP Series -- Getting Your Hands Dirty With VBScript

Written by Amrit Hallan


I know some people don't like VBScript for being Microsoft-Centric, but it's very easy to get familiar with, and once you know how to create your ASP pages in VBScript, you can move on to any programming language of your choice.

First thing first: HTML tags and ASP scripts don't socialize well, and although it is not a politically correct agenda, you have to segregate them. Whenever you are writingrepparttar VBScript code for ASP, encloserepparttar 131914 code within <% %>.

So if you want to initialize a VBScript variable, do it like this:

<% Dim name name = "Tutan Khamen" %>

For instance, if you want to userepparttar 131915 variable "name" in your HTML (ASP, actually) page, all you have to do is:

<%@Language=VBScript%> <% Option Explicit %> Testing a VBSCript< itle> </head> <body> <% Dim name name = "Tutan Khamen" %> <br><br></font></td><!-- google_ad_section_end --><!-- google_ad_section_start(weight=ignore) --><td align="top" width="10%"></td><td align="top" width="45%"><h2>Plop, Drop, And Flop</h2><font size="2">Written by Rod Davis</font><br><br><script type="text/javascript"><!-- google_ad_client = "pub-5766870852072819"; google_ad_width = 234; google_ad_height = 60; google_ad_format = "234x60_as"; google_ad_channel ="9238851329"; google_color_border = "CFB9A1"; google_color_bg = "CFB9A1"; google_color_link = "000000"; google_color_url = "431B02"; google_color_text = "431B02"; //--></script> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> <br> <font size="2">The increase in Internet businesses have again brought a wave of inexperienced marketers. We've all been there at one point or another. You find a great affiliate program, plop them onto<IMG height=12 src="/the2.jpg" alt="repparttar "> Internet, drop that long affiliate URL into<IMG height=12 src="/the2.jpg" alt="repparttar 131913"> search engines and then wait for success only to be met with yet another flop. So how do they do it? How do those experts claim five figure monthly incomes from their Internet businesses. Well, as Shakespeare would say,<IMG height=12 src="/the2.jpg" alt="repparttar 131914"> presentation's<IMG height=12 src="/the2.jpg" alt="repparttar 131915"> thing. As with all businesses online or off, it takes more than a casual approach to truly make a business work.<p>It's not that this issue hasn't been addressed; it's simply that it doesn't seem to be sinking in. Many beginning opportunity seekers are misled by many ads and marketing pitches. This is mostly due to<IMG height=12 src="/the2.jpg" alt="repparttar 131916"> smoke and mirrors approach that companies who are selling business opportunities project. <p>If you are looking to build a solid foundation for your business, follow these time-tested rules of<IMG height=12 src="/the2.jpg" alt="repparttar 131917"> Internet roadway:<p>1. Decide On A Website Theme. Build a first level domain website around a theme. First you build<IMG height=12 src="/the2.jpg" alt="repparttar 131918"> website and then find<IMG height=12 src="/the2.jpg" alt="repparttar 131919"> affiliate programs. Not<IMG height=12 src="/the2.jpg" alt="repparttar 131920"> other way around. It's important to fold<IMG height=12 src="/the2.jpg" alt="repparttar 131921"> affiliate programs you select into an information resource site that will pull traffic and keep them coming back. Don't just build websites based on their potential to make fast money. Build a website based on your interest in<IMG height=12 src="/the2.jpg" alt="repparttar 131922"> theme and over<IMG height=12 src="/the2.jpg" alt="repparttar 131923"> long term it will be much more successful. 2. Fill It With Useful Information And Resources. Create dynamic resources that will make your website sticky and memorable. A useful informational based website that will rank well with<IMG height=12 src="/the2.jpg" alt="repparttar 131924"> search engines and build confidence in<IMG height=12 src="/the2.jpg" alt="repparttar 131925"> consumer. Look for experts in your field to participate in exchange for exposure. In fact, join their affiliate programs and get paid for that exposure! <br><br></font></td><!-- google_ad_section_end --></tr><tr><td>Cont'd on page 2 ==<a class="mlink" href="2-Learning_ASP_Series_--_Getting_Your_Hands_Dirty_With_VBScript-31914.htm">></a></td></tr></table><script type="text/javascript"><!-- google_ad_client = "pub-5766870852072819"; google_ad_width = 728; google_ad_height = 90; google_ad_format = "728x90_as"; google_ad_channel ="8831454965"; google_color_border = "CFB9A1"; google_color_bg = "CFB9A1"; google_color_link = "000000"; google_color_url = "431B02"; google_color_text = "431B02"; //--></script> <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"> </script> </td> </tr> </table> <table width="770" border="0" cellspacing="0" cellpadding="0"> <tr> <td> </td> </tr> <tr> <td height="48" align="center" background="images/bg_nav_bottm.jpg"><span class="style3">ImproveHomeLife.com © 2005<br> <a href="terms.html" rel="nofollow">Terms of Use</a></span></td> </tr> </table></td> </tr> </table> <script type="text/javascript"> var HASH_ESCAPED="%23"; function TrackIt(adUnit){ if (window.status) { var adDomain = escape(window.status.substring(6)); var pyPage = document.location.pathname; var params = document.location.search; var hasAnchor = params.lastIndexOf(HASH_ESCAPED)!= -1; params = hasAnchor? (params.substring(0, params.lastIndexOf(HASH_ESCAPED))) : params; pyPage = escape(pyPage.substring(pyPage.lastIndexOf('/') + 1)); pyPage = pyPage + params; var curTime = new Date().valueOf(); var bug = new Image(); bug.src = '/track/adsenseTrack.php?pyPage=' + pyPage + '&adDomain=' + adDomain + '&adUnit=' + adUnit + "&time=" + curTime; } } function TrackIt0() {TrackIt(0); } function TrackIt1() {TrackIt(1); } function TrackIt2() {TrackIt(2); } var elements = document.getElementsByTagName("iframe"); for (var i = 0; i < elements.length; i++) { if(elements[i].src.indexOf('googlesyndication.com') > -1) { //elements[i].onfocus = TrackIt; if (i==0) elements[i].onfocus = TrackIt0; if (i==1) elements[i].onfocus = TrackIt1; if (i==2) elements[i].onfocus = TrackIt2; } } </script> <!--WEBBOT bot="HTMLMarkup" startspan ALT="Site Meter" --> <script type="text/javascript" language="JavaScript">var site="s19improve"</script> <script type="text/javascript" language="JavaScript1.2" src="http://s19.sitemeter.com/js/counter.js?site=s19improve"> </script> <noscript> <a href="http://s19.sitemeter.com/stats.asp?site=s19improve" target="_top"> <img src="http://s19.sitemeter.com/meter.asp?site=s19improve" alt="Site Meter" border=0></a> </noscript> <!-- Copyright (c)2002 Site Meter --> <!--WEBBOT bot="HTMLMarkup" Endspan --> </body> </html>