VB syntax for response.addheader

I host automatic redirects on my classic ASP (vb) page. I want to call url from a variable (url2) and hardcoding. you just need to know what the correct syntax is. this is my current code:

Response.AddHeader("REFRESH","10;URL=url2")
+3
source share
2 answers

In ASP-Classic / VBScipt: -

Response.AddHeader "Refresh", "10;url=" & strUrl

You do not use () when calling methods from which you do not accept the return value.

+2
source

The update header is not officially standardized. This means that each browser can implement it differently. I would recommend using a normal HTTP crawl as shown below:

Response.AddHeader "Refresh", "10; url=" & url2

[Edited to reflect new information from the poster]

, , , , ASP.NET - .

+1

Source: https://habr.com/ru/post/1716207/


All Articles