generating html
am 06.08.2007 13:13:57 von soc
(Further to "24hrs static content".....many thanks)
Currently our web site is pulling all pages from a database, dependent on
querystrings.
I wish to set up different system:
index.asp lists a selection of links to pages, but instead of
href="/page.asp?a=10&b=20"
the link will be
href="/10/20.html"
This html page will not be present when the link is used for the first time,
so goes to custom 404.
404.asp extract the querystring from the page name and directory, generates
the html and creates the 20.html page.
Then it redirects to 20.html.
Future users will go to a html page with no need for database access.
I'm having difficulty generating the html, I'm testing the code below. Am i
on the correct track?
Thanks.
MSXML3.dll error '80072ee7'
The server name or address could not be resolved
/404.asp, line 27 (...xmlHttp.Send "")
<%
Response.Expires = -1
URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
xmlHttp.Open "Get", URLToRSS, false
xmlHttp.Send ""
strHTML = xmlHttp.ResponseText
Set fstemp = server.CreateObject("Scripting.FileSystemObject")
Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
filetemp.Write(strHTML)
filetemp.Close
set filetemp = nothing
set xmlHttp = nothing
response.Redirect("somepage.html")
%>
Re: generating html
am 06.08.2007 13:39:47 von exjxw.hannivoort
SOC wrote on 06 aug 2007 in microsoft.public.inetserver.asp.db:
[.......]
>
> MSXML3.dll error '80072ee7'
>
> The server name or address could not be resolved
>
> /404.asp, line 27 (...xmlHttp.Send "")
>
> <%
> Response.Expires = -1
> URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
> xmlHttp.Open "Get", URLToRSS, false
> xmlHttp.Send ""
So the url does not exist or is inaccessable from the server.
The below is not part of the problem, and is not even executed, meseems.
Retest the url,
and then make a testpage, a simple test.asp, not containing the below,
but the %>.
> strHTML = xmlHttp.ResponseText
> Set fstemp = server.CreateObject("Scripting.FileSystemObject")
> Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
> filetemp.Write(strHTML)
> filetemp.Close
> set filetemp = nothing
> set xmlHttp = nothing
> response.Redirect("somepage.html")
> %>
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Re: generating html
am 06.08.2007 17:01:17 von zxc1
I have been able to create a web page using filesystemobject, but I can't
generate content using msxml:
Response.Expires = -1
URLToRSS=http://www.abc123.xyz.com
Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
xmlHttp.Open "Get", URLToRSS, false
xmlHttp.Send () (....line27)
The following error is returned.
MSXML3.dll error '80072ee7'
The server name or address could not be resolved
/404.asp, line 27
Thanks.
"Evertjan." wrote in message
news:Xns99848AFC8903Ceejj99@194.109.133.242...
> SOC wrote on 06 aug 2007 in microsoft.public.inetserver.asp.db:
>
> [.......]
>
>>
>> MSXML3.dll error '80072ee7'
>>
>> The server name or address could not be resolved
>>
>> /404.asp, line 27 (...xmlHttp.Send "")
>>
>> <%
>> Response.Expires = -1
>> URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
>> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
>> xmlHttp.Open "Get", URLToRSS, false
>> xmlHttp.Send ""
>
> So the url does not exist or is inaccessable from the server.
>
> The below is not part of the problem, and is not even executed, meseems.
>
> Retest the url,
> and then make a testpage, a simple test.asp, not containing the below,
> but the %>.
>
>
>> strHTML = xmlHttp.ResponseText
>> Set fstemp = server.CreateObject("Scripting.FileSystemObject")
>> Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
>> filetemp.Write(strHTML)
>> filetemp.Close
>> set filetemp = nothing
>> set xmlHttp = nothing
>> response.Redirect("somepage.html")
>> %>
>
>
>
> --
> Evertjan.
> The Netherlands.
> (Please change the x'es to dots in my emailaddress)
Re: generating html
am 06.08.2007 17:28:35 von soc
Apologies, reading an earlier post on this subject, I have noticed that the
web cannot be browsed from this server, and therefore content cannot be
generated from the web.
Thanks Soc.
"SOC" wrote in message
news:OuKgnrB2HHA.2064@TK2MSFTNGP03.phx.gbl...
> (Further to "24hrs static content".....many thanks)
> Currently our web site is pulling all pages from a database, dependent on
> querystrings.
>
> I wish to set up different system:
>
> index.asp lists a selection of links to pages, but instead of
> href="/page.asp?a=10&b=20"
> the link will be
> href="/10/20.html"
>
> This html page will not be present when the link is used for the first
> time, so goes to custom 404.
>
> 404.asp extract the querystring from the page name and directory,
> generates the html and creates the 20.html page.
> Then it redirects to 20.html.
> Future users will go to a html page with no need for database access.
>
> I'm having difficulty generating the html, I'm testing the code below. Am
> i on the correct track?
> Thanks.
>
>
> MSXML3.dll error '80072ee7'
>
> The server name or address could not be resolved
>
> /404.asp, line 27 (...xmlHttp.Send "")
>
> <%
> Response.Expires = -1
> URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
> xmlHttp.Open "Get", URLToRSS, false
> xmlHttp.Send ""
> strHTML = xmlHttp.ResponseText
> Set fstemp = server.CreateObject("Scripting.FileSystemObject")
> Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
> filetemp.Write(strHTML)
> filetemp.Close
> set filetemp = nothing
> set xmlHttp = nothing
> response.Redirect("somepage.html")
> %>
>
>
>
Re: generating html
am 06.08.2007 17:29:52 von soc
Apologies, having read an earlier post on this subject, I have noticed that
the
web cannot be browsed from this server, and therefore content cannot be
generated from the web.
Thanks Soc.
"SOC" wrote in message
news:OuKgnrB2HHA.2064@TK2MSFTNGP03.phx.gbl...
> (Further to "24hrs static content".....many thanks)
> Currently our web site is pulling all pages from a database, dependent on
> querystrings.
>
> I wish to set up different system:
>
> index.asp lists a selection of links to pages, but instead of
> href="/page.asp?a=10&b=20"
> the link will be
> href="/10/20.html"
>
> This html page will not be present when the link is used for the first
> time, so goes to custom 404.
>
> 404.asp extract the querystring from the page name and directory,
> generates the html and creates the 20.html page.
> Then it redirects to 20.html.
> Future users will go to a html page with no need for database access.
>
> I'm having difficulty generating the html, I'm testing the code below. Am
> i on the correct track?
> Thanks.
>
>
> MSXML3.dll error '80072ee7'
>
> The server name or address could not be resolved
>
> /404.asp, line 27 (...xmlHttp.Send "")
>
> <%
> Response.Expires = -1
> URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
> xmlHttp.Open "Get", URLToRSS, false
> xmlHttp.Send ""
> strHTML = xmlHttp.ResponseText
> Set fstemp = server.CreateObject("Scripting.FileSystemObject")
> Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
> filetemp.Write(strHTML)
> filetemp.Close
> set filetemp = nothing
> set xmlHttp = nothing
> response.Redirect("somepage.html")
> %>
>
>
>
Re: generating html
am 06.08.2007 17:34:06 von exjxw.hannivoort
Sean O'Connor wrote on 06 aug 2007 in
microsoft.public.inetserver.asp.db:
> "Evertjan." wrote in message
> news:Xns99848AFC8903Ceejj99@194.109.133.242...
>> SOC wrote on 06 aug 2007 in microsoft.public.inetserver.asp.db:
>>
>> [.......]
>>
>>>
>>> MSXML3.dll error '80072ee7'
>>>
>>> The server name or address could not be resolved
>>>
>>> /404.asp, line 27 (...xmlHttp.Send "")
>>>
>>> <%
>>> Response.Expires = -1
>>> URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
>>> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
>>> xmlHttp.Open "Get", URLToRSS, false
>>> xmlHttp.Send ""
>>
>> So the url does not exist or is inaccessable from the server.
>>
>> The below is not part of the problem, and is not even executed,
>> meseems.
>>
>> Retest the url,
>> and then make a testpage, a simple test.asp, not containing the
>> below, but the %>.
>>
>>
>>> strHTML = xmlHttp.ResponseText
>>> Set fstemp = server.CreateObject("Scripting.FileSystemObject")
>>> Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
>>> filetemp.Write(strHTML)
>>> filetemp.Close
>>> set filetemp = nothing
>>> set xmlHttp = nothing
>>> response.Redirect("somepage.html")
>>> %>
[Please do not toppost on usenet]
> I have been able to create a web page using filesystemobject, but I
> can't generate content using msxml:
>
> Response.Expires = -1
> URLToRSS=http://www.abc123.xyz.com
Forgetting the quotes is unforgivable in vbs!!!
[while allowed in jscript]
> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
Try:
"MSXML2.ServerXMLHTTP"
> xmlHttp.Open "Get", URLToRSS, false
> xmlHttp.Send () (....line27)
>
> The following error is returned.
>
> MSXML3.dll error '80072ee7'
>
> The server name or address could not be resolved
>
> /404.asp, line 27
[advice: do not use 404.asp for testing!]
This works fine overhere:
<%
Response.Expires = -1
URLToRSS="http://www.google.com/"
Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP")
xmlHttp.Open "Get", URLToRSS, false
xmlHttp.Send ()
response.write xmlHttp.ResponseText
%>
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Re: generating html
am 06.08.2007 17:36:08 von exjxw.hannivoort
Evertjan. wrote on 06 aug 2007 in microsoft.public.inetserver.asp.db:
> Sean O'Connor wrote on 06 aug 2007 in
>> "Evertjan." wrote in message
>>> SOC wrote on 06 aug 2007 in microsoft.public.inetserver.asp.db:
Why do you change your name in one and the same thread, Sean?
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Re: generating html
am 06.08.2007 17:38:44 von exjxw.hannivoort
SOC wrote on 06 aug 2007 in microsoft.public.inetserver.asp.db:
> Apologies, reading an earlier post on this subject, I have noticed
> that the web cannot be browsed from this server, and therefore content
> cannot be generated from the web.
>
Sean,
please first try correct code,
before you decide your server is the culprit.
<%
Response.Expires = -1
URLToRSS="http://www.google.com/"
Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP")
xmlHttp.Open "Get", URLToRSS, false
xmlHttp.Send ()
response.write xmlHttp.ResponseText
%>
--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Re: generating html
am 07.08.2007 10:59:25 von zxc1
Thanks Evertjan,
It works on a different machine.
Soc.
"SOC" wrote in message
news:uUCOx6D2HHA.5160@TK2MSFTNGP05.phx.gbl...
> Apologies, having read an earlier post on this subject, I have noticed
> that the
> web cannot be browsed from this server, and therefore content cannot be
> generated from the web.
> Thanks Soc.
>
> "SOC" wrote in message
> news:OuKgnrB2HHA.2064@TK2MSFTNGP03.phx.gbl...
>> (Further to "24hrs static content".....many thanks)
>> Currently our web site is pulling all pages from a database, dependent on
>> querystrings.
>>
>> I wish to set up different system:
>>
>> index.asp lists a selection of links to pages, but instead of
>> href="/page.asp?a=10&b=20"
>> the link will be
>> href="/10/20.html"
>>
>> This html page will not be present when the link is used for the first
>> time, so goes to custom 404.
>>
>> 404.asp extract the querystring from the page name and directory,
>> generates the html and creates the 20.html page.
>> Then it redirects to 20.html.
>> Future users will go to a html page with no need for database access.
>>
>> I'm having difficulty generating the html, I'm testing the code below. Am
>> i on the correct track?
>> Thanks.
>>
>>
>> MSXML3.dll error '80072ee7'
>>
>> The server name or address could not be resolved
>>
>> /404.asp, line 27 (...xmlHttp.Send "")
>>
>> <%
>> Response.Expires = -1
>> URLToRSS = http://www.abcde12345xyz.com:99/anindex.html
>> Set xmlHttp = Server.CreateObject("MSXML2.ServerXMLHTTP3.0")
>> xmlHttp.Open "Get", URLToRSS, false
>> xmlHttp.Send ""
>> strHTML = xmlHttp.ResponseText
>> Set fstemp = server.CreateObject("Scripting.FileSystemObject")
>> Set filetemp = fstemp.CreateTextFile("somepage.htm", true,true)
>> filetemp.Write(strHTML)
>> filetemp.Close
>> set filetemp = nothing
>> set xmlHttp = nothing
>> response.Redirect("somepage.html")
>> %>
>>
>>
>>
>
>
>