ASP Judgment function List and Web page making common skills (2)

Source: Internet
Author: User
function | Web page ASP Web page making tips

1. Access to System time:


<%=now ()%>



2. Access to the IP:

<%=request.servervariables ("Remote_host")%>



3. Access to the system, browser version:

<script>

Window.document.write ("Version:" +navigator.appname+navigator.appversion+ "browser.")

</script>



4. Remove IE Mixing strips:

<body scroll= "No" >

<body style= "Overflow-y:hidden" >



5. Go to the website and jump out of the advertisement:

<script language= "& #106avascript" >

<!--

<!--note change the path to the file-->

(' http://www.******.com ', ', ', ', ' height=200,width=300,top=0,left=30 ');


-->

</script>



6. Random Number:

<%randomize%>

<%= (int (rnd () *n) +1)%>


N is a number that can be changed

7. Move Up code:

<marquee direction= "Up" scrolldelay= "style=" Font-size:
9pt; Color: #FF0000; line-height:150%; Font-style:italic; Font-weight:bold "
Scrollamount= "2" width= "206" height= "207" bgcolor= "#FFFF00" >hhhhhhhhhhhhhhhhhhh</marquee>



8. Automatically close the Web page:

<script language= "& #106avascript" >

<!--

SetTimeout (' Window.close (); ', 10000); Shut down in 60 seconds.

-->

</script>

<p align= "Center" > this page closes automatically after 10 seconds, please note refresh page </p>



9. Random background music:

<%randomize%>

<bgsound src= "mids/<%= (int (rnd () *60) +1)%>.mid" loop= "-1" >


You can modify the number to limit the number of calls, here are 60.

10. Automatically refresh this page:

<script>

<!--
var limit= "0:10"
if (document.images) {

var parselimit=limit.split (":")

Parselimit=parselimit[0]*60+parselimit[1]*1

}

function Beginrefresh () {

if (!document.images)

Return

if (parselimit==1)

Window.location.reload ()

else{

Parselimit-=1

Curmin=math.floor (PARSELIMIT/60)

Cursec=parselimit%60

if (curmin!=0)

curtime=curmin+ "+cursec+" seconds after the brush this page! "

Else

curtime=cursec+ "Seconds later to brush this page!" "

Window.status=curtime

SetTimeout ("Beginrefresh ()", 1000)

}

}
Window.onload=beginrefresh

file& #58//-->

</script>


Leave the page automatically closed after five seconds
<script>

SetTimeout ("Window.close ()", 5000);

</script>

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.