Go Premium for a chance to win a PS4. Enter to Win







Active Server Pages (ASP) is Microsoft’s first server-side engine for dynamic web pages. ASP’s support of the Component Object Model (COM) enables it to access and use compiled libraries such as DLLs. It has been superseded by ASP.NET, but will be supported by Internet Information Services (IIS) through at least 2022.

Share tech news, updates, or what's on your mind.

Sign up to Post

This javascript function uses a variable (newPrice)

I need to include it in the savedata.asp as a variable to be passed like &newPrice=(I dont know how to insert the js newPrice Variable) newPrice is already defined properly, it has a proper value

 if(send && Validate("form[name=forma]")){
  $("form[name=forma]").ajaxSubmit({url: 'savedata.asp?origen=Otro&newid=<%=Request.Cookies("newid")%>&evento=<%=Request.Cookies("evento")%>&referer=<%=referer%>', type: 'post', success: function(){
   $( document ).ready(function() {
	totalPrice += newPrice;

Open in new window

What does it mean to be "Always On"?
What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

How can I make the hidden div with the gif visible on submit at http://www.gseannouncer.com/'

Please note that the page submits to itself.  If I can't make the div visible onsubmit then I understand that I will have to use ajax/jquery.  The key is that I need it to happen as quickly as possible.

Thank you so much!
I have a classic asp page that I want to display a "processing wheel" or similar gif while it is processing.  I would like it to start when the user clicks a button and stop when the submission has completed and the page is fully loaded.  Any help would be much appreciated.
|Dear all,

I am working with MS Access.

I have two tables:

TABLE2 - with the field texts(char)


Table1 - spanish (text 30 chars)

I want find on table2.texts each register placed on Table1.spanish

Examples (that not works):

rs.open "select * from table1, table2 where table1.spanish like '%" & table2.texts & "%' ", con

rs.open "SELECT table1.*, table2.texts FROM table1 INNER JOIN table2   ON table2.texts LIKE ('%" &  table1.spanish & "%') ", con

Example: table2.texts: "Y eso ha sido exactamente lo sucedido en los últimos 10 años con un sector bancario que en 2007 sobrevaloraba tanto su solidez
table1.spanish: "sector bancario"

But these codes not works.

Could someone please place a code that works?

Thanks in advance
Would it be possible to transport a value from a classic ASP string to the user his or her clipboard using pure javascript only?

I've found this example and tried to modify it to work with a hidden form input. But without succes.
For years we have been using the following vb code in a Classic ASP page to retrieve data from a software product.
To boost performance and get away from Classic ASP, I need to ASHX C# equivalent of the following  

    //set h = CreateObject("MSXML2.SERVERXMLHTTP")
    //h.open"POST", "http://localhost/isapi/webapi.dll"  //this is a software provided dll that accepts xml objects and returns xml response objects
    //h.setOption(2) = 4096
    //response.Write("<br><textarea rows=\"20\" cols=\"60\">" + h.responseText + "</textarea>");    
    //for each response in h.responseXml.selectnodes("//Response")
    //response.Write("<br><textarea rows=\"20\" cols=\"60\">" + response.xml + "</textarea>");
Hi, I' need to select a specific node in an xml doc... i have this which gives me everything

For Each xmlNode In objXML.documentElement.selectNodes("Data")

but i need a single node and its related nodes that has a specific value.. please see the xml

for example: I need to select only the Data where Bookcode = NEA-CSOP

Thank you




Open in new window

Hi Experts

I want to generate dates from to day to next year the same day, ie:
13/11/2017 18:57:29
14/11/2017 18:57:29
15/11/2017 18:57:29
16/11/2017 18:57:29

But I want to exclude Fridays and Saturdays

And I want to divide each day by 11 hours starting from 8 AM to 7PM,  and each hour divided by 15 minutes

13/11/2017 08:00:00
13/11/2017 08:15:00
13/11/2017 08:30:00
13/11/2017 08:45:00
13/11/2017 09:00:00
13/11/2017 09:15:00
13/11/2017 09:30:00
etc... until
13/11/2017 : 19:00:00

And then display next day, and so on

Can anyone please help me with the code.
I have an ASP page that displays data pulled from an excel sheet with a named range called "tblData" in the cell of the table where I have a percentage number I want to make it to where if the number is between 1 and 5 then the cell is green. if the umber is between 6 and 8 its yellow, then if its over 8 its red. this is what I have now:

If rs.Fields("2017 Rate") >= 1 OR rs.Fields("2017 Rate") <= 5 then
	Response.Write "<td bgcolor='green' style='width: 301px; height: 21px;' class='auto-style3'>"
Elseif rs.Fields("2017 Rate") >= 6 OR rs.Fields("2017 Rate") <= 8 then
	Response.Write "<td bgcolor='yellow' style'width: 301px; height: 21px;' class='auto-style3'>"
Elseif rs.Fields("2017 Rate") >= 8 then
    Response.Write "<td bgcolor='red' style'width: 301px; height: 21px;' class='auto-style3'>"
End If
<%=rs.fields("2017 Rate")%>

Open in new window

and it just colors all the cells in that column green regardless of the number.
I would like to replace this calendar (http://www.gopherstateevents.com/calendar/calendar.asp) with one that is a little more contemporary.  I use classic asp/sql server.  I am using bootstrap. for layout.

Important Lessons on Recovering from Petya
LVL 11
Important Lessons on Recovering from Petya

In their most recent webinar, Skyport Systems explores ways to isolate and protect critical databases to keep the core of your company safe from harm.

We ran a vulnerability scan and got this alert:  HTTP Security Header Not Detected
Description:  This QID reports the absence of the following HTTP headers according to CWE-693: Protection Mechanism Failure

How can we fix this issue?
We are running the application on IIS7
We had a field which was nvarchar 8000, it was changed to a text field to accomodate more characters.

I currently have the code below to call the Stored Procedure, but the parameter is for 8000 characters, how should I change it to allow the entry of as many characters as the text field allows?


Set UpdateSignature = Server.CreateObject ("ADODB.Command")
UpdateSignature.ActiveConnection = MM_bluedot_STRING
UpdateSignature.CommandText = "UPDATE Userlogin SET Emailsignature = ? WHERE  userid = ?"
UpdateSignature.Parameters.Append UpdateSignature.CreateParameter("MMColParam", 200, 1, 8000, MM_IIF(Request.Form("signature"), Request.Form("signature"), UpdateSignature__MMColParam & ""))
UpdateSignature.Parameters.Append UpdateSignature.CreateParameter("MMColParam2", 3, 1, 4, MM_IIF(Session("Userid"), Session("Userid"), UpdateSignature__MMColParam2 & ""))
UpdateSignature.CommandType = 1
UpdateSignature.CommandTimeout = 0
UpdateSignature.Prepared = true


Open in new window

Something else that may be relevant is that this field is intended to save the user's signature block, if they add an image (their logo) then the HTML editor converts it into characters and this is where 8000 characters don't seem to be enough.
I am not sure if because we are including an image I may need to use a different type of data for the user, otherwise I guess text fiedl will work.
I have an ASP classic application that sends emails, I currently use an old extension for Dreaweaver to generate the code that sends emails. Its like a wizard, you fill out the necessary information and the extension creates the code.
Unfortunately the latest versions of Dreamweaver do not support this extension anymore.

I am looking for some sort of template/code/plugin I can use to replace the old code, something more modern I guess.

The current extension allows me to specify the following:

1.  SMTP server details (CDOSYS)
2. Subject
3. Recipients (to/cc/bcc, this can be a list that comes from a result of a recordset)
4. Attached documents (Also from the results of a recordset, could be more than one attachment)
5. HTML for the body of the email

Anything to replace this extension must include the above at least.

Any suggestions are greatly appreciated.
I have a news table with a related keywords table.

So on each news page I just want to be able to list the top 3 related news items ordered by the most matching keywords. I'm just not sure how to best query this?

So there are three tables:

News table

Keywords table

News :: Keywords table
Hi Experts,

I'm trying to automate a script that sends a daily email to registered users - my script is below - I want Task Scheduler to run the script, however in testing in CMD I get the following error -

Microsoft VBscript Runtime Error Variable is undefined : 'Server'

Here's my code -

Option Explicit

' FileName="Connection_odbc_conn_dsn.htm"
' Type="ADO" 
' DesigntimeType="ADO"
' HTTP="false"
' Catalog=""
' Schema=""
MM_SITE_STRING = "Provider= SQLOLEDB; Data Source=,1433; Database=DBASE;uid=USER;pwd=XXXXX;"
' create recordset of email recipients - this runs a SP on the Server

Set cmdAlertRecipientList = Server.CreateObject ("ADODB.Command")
cmdAlertRecipientList.ActiveConnection = MM_SITE_STRING
cmdAlertRecipientList.CommandText = "dbo.SITEDailyJobsbyEmailRecipientList"
cmdAlertRecipientList.CommandType = 4
cmdAlertRecipientList.CommandTimeout = 0
cmdAlertRecipientList.Prepared = true
set AlertRecipientList = cmdAlertRecipientList.Execute
AlertRecipientList_numRows = 0

If not AlertRecipientList.eof then
arrAlertRecipientList = AlertRecipientList.GetRows()
End if 

AlertRecipientList.Close() 'Clean Up
Set AlertRecipientList = Nothing 'Clean Up
Set cmdAlertRecipientList = Nothing 'Clean Up

'Loop through recordset to get ID for each recipient 

If IsArray(arrAlertRecipientList) AND UBound(arrAlertRecipientList,2) >= 0 Then

'Now for each record a subroutine i.e for each record do something.

Open in new window

I need to put a function on my emails where we can track the initial link that is being clicked.  The way I currently do this is to put a small php/asp script onto the website and add the script onto the hyperlink - something like this:


When the script runs, it takes the user to the relevant page (PID) and sends an email with the ID number to a designated email address (that can then be processed). This function is going to be used by several companies, so I need to minimise what I ask them to do when setting things up.  

Historically the companies that have used an early version of this function have been fine with adding a small php/asp script to their site and setting up a mailbox.

Ultimately, the marketing guys just need the ID, whereas the Tech guys need to be happy (security, ease of implementation etc.). So, is this a good way to do it - or is there a better method?  

Hi whats the best, quickest and easiest way to style positive (blue) and negative (red) numbers in an asp page. Code is below and I'm using a CSS include to style stuff... Thanks

table {
    border-collapse: collapse;
    width: 100%;

	background-color: #87C5FF
		font-family:Gotham, "Helvetica Neue", Helvetica, Arial, sans-serif;
    text-align: left;
    padding: 9px;
td {
	font-family:Gotham, "Helvetica Neue", Helvetica, Arial, sans-serif;
    text-align: left;
    padding: 9px;
	font-family:Gotham, "Helvetica Neue", Helvetica, Arial, sans-serif;
	background-color: #eef6ff
	font-family:Gotham, "Helvetica Neue", Helvetica, Arial, sans-serif;
	background-color: #ffffff

Open in new window

   Set objXML = Server.CreateObject("MSXML2.DOMDocument.3.0")
   objXML.async = False
	objXML.Load (Server.MapPath("book/NWP-MV.xml"))
'select each node in the data
	For Each xmlNode In objXML.documentElement.selectNodes("Data")

		'strTitle = xmlProduct.selectSingleNode("EnsembleID").text

     xIssue = xIssue & xmlNode.selectSingleNode("Issue").text & ","
	 xEnsembleID = xEnsembleID & xmlNode.selectSingleNode("EnsembleID").text & "," 
    ' xBookCode = xBookCode & xmlNode.selectSingleNode("BookCode").text  & ","        
     xStatistics = xStatistics & xmlNode.selectSingleNode("LongBLPTicker").text & ","
	 xStubPos = xStubPos & xmlNode.selectSingleNode("StubPos").text 

Open in new window


I inherited an ASP classic website. I need to provide authentication to specific directories in the website via user id and password.

I need some pointers of how this can be done.

Note: The site does not use Active Directory.

Much thanks for any pointers you are able to give.
David Bach
Hi all,
I have a page that sends out text messages to various clients. One of my pages send out to two different clients with different content in each text message. My text message provider uses an API which I access using an oXMLHTTP GET request. I want to somehow reuse this on the page as it works. But the second text message never goes through. Any thoughts? It's probably dead obvious, but I just can't see it. This is my code:
Function GetTextFromUrl(url)

  Dim strStatusTest
  Set oXMLHTTP = CreateObject("MSXML2.ServerXMLHTTP.3.0")

  oXMLHTTP.Open "GET", url, True
  If oXMLHTTP.Status = 200 Then

    GetTextFromUrl = oXMLHTTP.responseText

  End If

End Function

Dim sResult : sResult = GetTextFromUrl("https://myprovider.com/rest/mtsms?token=A_SECRET!&message=Your+case+with+case+number+" + Id + "+was+updated!+http://" + link + "show.asp?ID=" + ID + "&recipients.0.msisdn=" + string+ "&sender=" + sender + "&label=" + reciever + "")

response.write sResult

Open in new window

Free Tool: Port Scanner
LVL 11
Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Does anyone know what the syntax should ber for the line  :

xsort = request.QueryString("sort")
 objRs.Sort =  xsort "DESC"

For i = 0 To uBound(aEnsembleID) 
			objRs.Fields("EnsembleID") = aEnsembleID(i)
			objRs.Fields("BookCode") = aBookCode(i)
			objRs.Fields("Issue") = aIssue(i)
			objRs.Fields("Statistics") = aStatistics(i)
			xsort = request.QueryString("sort")
 				objRs.Sort =  xsort "DESC"
 ''response.write xsort
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <th><a href="https://nwds.nimco.com.hk/test.asp?sort=EnsembleID">aEnsembleID</a></th>
  <th><a href="https://nwds.nimco.com.hk/test.asp?sort=BookCode">aBookCode</a></th>
  <th><a href="https://nwds.nimco.com.hk/test.asp?sort=Issue">aIssue</a></th>
  <th><a href="https://nwds.nimco.com.hk/test.asp?sort=Statistics">aStatistics</a></th>
  do while not objRs.eof%>
      <td><%Response.write objRs("EnsembleID")%></td>
      <td><%Response.write objRs("BookCode")%></td>
      <td><%Response.write objRs("Issue")%></td>
      <td><%Response.write objRs("Statistics")%></td>

Open in new window

I have a stored procedure that updates a record.
I need to add code so that it only runs IF the parameter passed has a value

The parameter is:  request.querystring("marriageidspouse")

If the parameter does existing run the SP code, something like:

IF request.querystring("marriageidspouse") <> NULL THEN 



Open in new window

What would the correct syntax be?

Sometimes the part of the URL passes no value like:  marriageidspouse=

I am using classic ASP
Both websites are on the same network, one is an intranet, one is an internet. We want to display some content (XML) from the Intranet site on the Internet site. Can the internet site serve content from the Intranet site if it's given permissions. Any suggestions?
We have a script that opens a pop up window, the pop up shows the URL which includes certain parameters.
Is there a way to hide the URL bar in a pop up window?   I am using ASP Classic
in asp web applicaiton i am storing in a session variable on a button lick as below :
session("TEST") = "ABC"

in there anyway in javascript to read this session variable?
Thank you
I have a table that gets populated from a database.  Using ASP classic.  
I am trying to have the user click on one of the rows, and then open a new web page with more data based on what they clicked.
So far I have this:
response.write "<td><input type='submit' name='postData' value='" & rsObjPlumDetail.Fields(1) & "'></input></td> "

Open in new window

This is in a Do while not loop. and in a form with an action="url".   Tried adding a method='post', but that did not help.
So every line in the table now has the system number looking like a button, or a link.

and here is a bigger picture of the code
<form action="URL" method="post">
Do while not rsObjPlumDetail.EOF
Response.Write "<TR class='row'>" 

response.write "<td><input type='submit' name='postData' value='" & rsObjPlumDetail.Fields(1) & "'></input></td> "

Open in new window

I also tried the <a href> instead of button, with a hidden input after it.

at the bottom of the page, I have a separate form that I can just type in the number from the table and that works. but I want to delete this second form.






Active Server Pages (ASP) is Microsoft’s first server-side engine for dynamic web pages. ASP’s support of the Component Object Model (COM) enables it to access and use compiled libraries such as DLLs. It has been superseded by ASP.NET, but will be supported by Internet Information Services (IIS) through at least 2022.