INT213Lab1

INT213Lab1 - \Seneca College of Applied Arts and Technology...

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
\\\\\\Seneca College of Applied Arts and Technology INT213 – Active Server Pages Lab 1 This lab will introduce you to the practical concept and usage of Variables , within your ASP scripts. In addition we will look at Data Types, joining Strings and outputting your scripts. Your lecture demonstrated these concepts and now you will use them in some simple scripts. Outputing Information – Response.write In VBScript the method used to output information is the Response.write object . By default all output is sent starting at the top-left corner of the screen. Formatting with this command is usually done in concert with HTML. Lab 2 will deal with in greater detail. Here is an example: Open notepad (or any other editor) and type the script exactly as shown. Name the file: Myfirstscript.asp Save the file to: c:\inetpub\wwwroot (This assumes you are using the C: drive.) <% Response.write “I am taking INT213” Response.write ”I am not sure about this programming stuff” %> After saving, open your Browser and on the address box type http://127.0.0.1/ Myfirstscript.asp Questions 1) Do you see the output?_______yes_________ 2) How is it formatted? I am taking INT213I am not sure about this programming stuff ______________________________________________________ Let’s change the script so the formatting is different. You can modify the previous script example. <% Response.write”I am not sure about this programming stuff.” %> Question: 1) How is the output different? I am taking INT213. “I am not sure about this programming stuff” start from the second line 1
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
The character is used to join strings together and the HTML break tag sends output to a NEWLINE . Variables Before you continue, it will be useful for you to, once again, review the rules for using Variables with VBScript. Rules Variables must begin with a letter, not an underscore or a number They cannot have more than 255 characters They cannot contain a period (full stop) , a space or a dash You can use an underscore, but not as the first character Case sensitivity is not important. The variable ‘test’ is the same as ‘TEST’ Complete the following. Circle the variables that you feel are not valid variable names. (refer to the rules)
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 01/27/2011 for the course INT 213 taught by Professor Tim during the Fall '10 term at Seneca.

Page1 / 8

INT213Lab1 - \Seneca College of Applied Arts and Technology...

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online