Exforsys

Free Training

Basic ASP Example - A simple Clock

This is a discussion on Basic ASP Example - A simple Clock within the ASP forums, part of the Programming Talk category; <% ' This simple asp page will display the current date/time ' First we declare (Dim) a string variable strGreeting, ...

Go Back   Exforsys > Programming Talk > ASP

Exforsys.com

  #1 (permalink)  
Old 04-29-2006, 07:59 AM
Senior Member
 
Join Date: Apr 2006
Posts: 126
Ricky is on a distinguished road
Basic ASP Example - A simple Clock

<%
' This simple asp page will display the current date/time
' First we declare (Dim) a string variable strGreeting, which will hold the value / text "Hello, today is"
' and also a VB function now()
' Classic ASP page allows ASP code to be mixed with HTML code.
' strGreeting is displayed in HTML
' To run this asp page, you need to have IIS installed on your machine, and you can copy this file to
' your local drive (eg, C:\Inetpub\wwwroot\). Open your default browser, and type in http://localhost/aspExample.asp

Dim strGreeting
strGreeting = "Hello, today is " & now()
%>
<html>
<head>
<title>ASP Example</title>
</head>
<body>
<%=strGreeting%>
</body>
</html>
__________________
My name is Rick and I'm a Exforsysoholic! (Is that even a word lol)
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 01-30-2007, 06:47 PM
Junior Member
 
Join Date: Apr 2006
Posts: 7
Lucy is on a distinguished road
very simple and nice sample code
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 02-07-2007, 03:37 PM
Member
 
Join Date: May 2006
Posts: 38
zsk_00 is on a distinguished road
does <%=strGreeting%> work or you need <% ?strGreeting%>

where ? is for print
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads

Thread Thread Starter Forum Replies Last Post
CCIE SEC lab study material! cciecrazy CISCO Certification 2 04-27-2006 08:04 PM
Visual Basic : Discovering Visual Basic .NET: Working with Variables techguru Visual Basic Tutorials 0 08-29-2005 08:27 AM
Visual Basic : Make the Transition from Traditional Visual Basic Error Handling to the Object-Oriented Model in .NET techguru Visual Basic Tutorials 0 08-29-2005 06:27 AM
Visual Basic : Discover a Series of Fortunate Event Handlers in Visual Basic techguru Visual Basic Tutorials 0 08-28-2005 04:26 PM
Visual Basic : Get a Lean, Mean Dev Machine with the Express Editions of Visual Basic and SQL Server 2005 techguru Visual Basic Tutorials 0 08-28-2005 06:26 AM


All times are GMT -4. The time now is 09:26 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.0
Copyright 2004 - 2009 Exforsys Inc. All rights reserved.