asp-classic

Can't set Response object in ASP Classic

时光总嘲笑我的痴心妄想 提交于 2019-12-11 05:24:46
问题 This line: set Response = nothing Fails with the error "Microsoft VBScript runtime error '800a01b6' Object doesn't support this property or method: 'Response' " Now, I can think of any number of reasons why the engine might not want to let me do such a seemingly silly thing, but I'm not sure how a missing method could be stopping me. EDIT: Here is an example of what I'd like to do with this. class ResponseBufferEphemeron private real_response_ private buffer_ private sub class_initialize set

ADODB.Connection (0x800A0E78)

天涯浪子 提交于 2019-12-11 05:20:00
问题 Original connectionstring whitch working on MSSQL 2000: Provider=SQLOLEDB.1; Persist Security Info=True; User ID=XXXXXXXX; Initial Catalog=IntranetApps; Data Source=MS; Use Procedure for Prepare=1; Auto Translate=True; Packet Size=4096; Workstation ID=datawriter; Password=XXXXXXXX'; New connectionstring which not working on MSSQL 2008: Provider=SQLNCLI10;Server=PR-NB-CIS011\SQLEXPRESS;Database=IntranetApps;Uid=XXXXXXXX;Pwd=XXXXXXXX; I tryed change provider to SQLNCLI10.1, without provider, ..

404 page that displays requested page

不羁岁月 提交于 2019-12-11 05:19:46
问题 I recently migrated a website to a new CMS (Umbraco). A lot of the links have changed, but they can be easily corrected by searching for patters in the url, so I would like to write something that will redirect to the correct page if the old one is not found. That part isn't a problem. How can I obtain the requested URL after the browser is redirected to my custom 404 page. I tried using: request.ServerVariables("HTTP_REFERER") 'sorry i corrected the typo from system to server. But that didn

How to send request from XMLHTTP without waiting for the response?

二次信任 提交于 2019-12-11 05:16:01
问题 pXML= Product_Request set http= server.Createobject("MSXML2.ServerXMLHTTP") http.Open "GET", "http://test.com/Data_Check/Request.asp?XML_File=" & pXML , False http.setRequestHeader "Content-Type", "application/x-www-form-urlencoded" http.send I need to send request with above asp code for the above URL. But i no need response from that server. After sending the request, it waits for the response. How do I write this so that it doesn't block while waiting for the response? 回答1: Change your

Using JavaScript to MergeTwo HTML Rows

故事扮演 提交于 2019-12-11 05:15:22
问题 I'm giving support to a classic asp WEB application, and I came across the need of building a scheduling board that shows, at the headers, the lines and at the rows the time of the scheduling. What I do is: I verify it there is something schedule for today. If there is, I get the starting and ending time of that schedule, and then, for each of them, I call the function that will write the line: DIM todayDate: todayDate = year(now()) & "-" & month(now()) & "-" & day(now()) sql = "SELECT

IIS 7.5 doesn't run *.inc as ASP Classic

怎甘沉沦 提交于 2019-12-11 05:05:24
问题 I'm setting up an ASP Classic website on Win7 x64, I have done the usual trick (Add site as Application to enable global.asa, use Classic pipeline App Pool, Enable 32-bit Applications: True, Load User Profile: False, Enable Parent Paths: True, give Everyone full access to site files, use odbc 32), and the site is up and running for *.asp files. However, I have some files named as *.inc under Includes directory, and IIS doesn't seem to be able to process them. When I try to access http:/

asp consuming a web service, what do do with recordset object?

半腔热情 提交于 2019-12-11 04:59:54
问题 Currently I run an classic (old) ASP webpage with recordset object used directly in bad old spagethi code fasion. I'm thinking of implementing a data layer in asp.net as web serivce to improve manageability. This is also a first step towards upgrading the website to asp.net. The site itself remains ASP for the moment... Can anybody recommend a good way of replacing the recordset object type with a web service compatible type (like an array or something)? What do I replace below with?: set

Export XML to Excel spreadsheet using Javascript/classic-ASP

笑着哭i 提交于 2019-12-11 04:40:02
问题 I'm trying to export XML data from a web page to a spreadsheet using javascript. So far I've just tried the very simple: Sub Export Response.ContentType = "application/vnd.ms-excel" <script> var XML = document.getElementById("xmldata"); window.open(XML); </script> End Sub This tries to open the XML file as an excel spreadsheet, however it doesn't open because it has invalid characters. I've tracked down these characters and the main culprit tends to be the horizontal dash "–". There may be

In asp, how to set boolean values to english?

柔情痞子 提交于 2019-12-11 04:34:36
问题 When I run this: <% www = false response.write www response.write "UPDATE table SET domain='"&www&"' WHERE id=n" %> I get this: false UPDATE table SET domain='Falso' WHERE id=n Notice the 'Falso' word that is in Portuguese instead of English. Is it possible to change the boolean values to English? I have a Windows 2008 / IIS 7 in pt-BR. 回答1: This question was asked just recently here I don't have a good machine to test the following code, which came from a working solution. It forces the

Classic ASP render a template and send variables

假装没事ソ 提交于 2019-12-11 04:30:49
问题 I have a classic ASP page, and I need to create a loop for each row on a table and then create an html document and save it to the hard drive, but I want to create a template so I just send the two variables to the template so I don't have to write the HTML document each time on the loop. This is what I have so far: SQL = "select Title, Article from [ASPTest].[dbo].[articles]" set rs = conn.execute(SQL) arrRecs = rs.GetRows For row = 0 To UBound(arrRecs, 2) 'Rows For col = 0 To UBound(arrRecs