|
 |
asp_web_howto thread: Help with Include Files
Message #1 by anhdo@a... on Wed, 10 Apr 2002 15:04:10
|
|
Is there any way to skip an include file in ASP if it is not loading
properly and load the rest of the page normally?
I have an include file on the homepage of my web site www.acce.org,
<!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
to stall when the include is not working properly.
Newsnap.inc pulls information from another site and loads it onto our
homepage. The problem is that the newsnap.inc file is down often, which
in turn causes our entire homepage to stall. When the file is not loading
properly I would prefer that the ASP page skip it and try to load the
include again only when the refresh button is pushed.
Does anyone have any suggestions?
Thanks,
Anh Do
ACCE
anhdo@a...
Message #2 by "TomMallard" <mallard@s...> on Wed, 10 Apr 2002 07:05:16 -0700
|
|
Put the call to the remote resource into a timeout function and if it times
out, then skip loading it.
tom mallard
seattle
-----Original Message-----
From: anhdo@a... [mailto:anhdo@a...]
Sent: Wednesday, April 10, 2002 3:04 PM
To: ASP Web HowTo
Subject: [asp_web_howto] Help with Include Files
Is there any way to skip an include file in ASP if it is not loading
properly and load the rest of the page normally?
I have an include file on the homepage of my web site www.acce.org,
<!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
to stall when the include is not working properly.
Newsnap.inc pulls information from another site and loads it onto our
homepage. The problem is that the newsnap.inc file is down often, which
in turn causes our entire homepage to stall. When the file is not loading
properly I would prefer that the ASP page skip it and try to load the
include again only when the refresh button is pushed.
Does anyone have any suggestions?
Thanks,
Anh Do
ACCE
anhdo@a...
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
Message #3 by "Craig Flannigan" <ckf@k...> on Wed, 10 Apr 2002 15:04:03 +0100
|
|
Can you not write some error trapping into the Include file.
Why is it not always working properly? Can you not detect this with code?
The dirty way to do it is to place an "On Error Resume Next" but this then
applies to the whole homepage and not just the Include.
You're best trying to find out how to trap the errors that occur in
newzsnap.inc.
-----Original Message-----
From: anhdo@a... [mailto:anhdo@a...]
Sent: 10 April 2002 15:04
To: ASP Web HowTo
Subject: [asp_web_howto] Help with Include Files
Is there any way to skip an include file in ASP if it is not loading
properly and load the rest of the page normally?
I have an include file on the homepage of my web site www.acce.org,
<!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
to stall when the include is not working properly.
Newsnap.inc pulls information from another site and loads it onto our
homepage. The problem is that the newsnap.inc file is down often, which
in turn causes our entire homepage to stall. When the file is not loading
properly I would prefer that the ASP page skip it and try to load the
include again only when the refresh button is pushed.
Does anyone have any suggestions?
Thanks,
Anh Do
ACCE
anhdo@a...
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service on behalf of
Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service on behalf of Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
Message #4 by "Alex Shiell, ITS, EB, SE" <alex.shiell@s...> on Wed, 10 Apr 2002 15:07:11 +0100
|
|
You need to think more carefull about what you're saying... the file is not
"down", but a process within it is causing the page to slow down. You need
to examine the code in the include file to make it more robust. Find the
piece of code that is causing the problem, e.g. the bit that requests
information from another site, and rewrite it so that if there is no
response within an acceptable time limit or an error, the rest of the code
can continue to execute.
-----Original Message-----
From: anhdo@a... [mailto:anhdo@a...]
Sent: 10 April 2002 16:04
To: ASP Web HowTo
Subject: [asp_web_howto] Help with Include Files
Is there any way to skip an include file in ASP if it is not loading
properly and load the rest of the page normally?
I have an include file on the homepage of my web site www.acce.org,
<!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
to stall when the include is not working properly.
Newsnap.inc pulls information from another site and loads it onto our
homepage. The problem is that the newsnap.inc file is down often, which
in turn causes our entire homepage to stall. When the file is not loading
properly I would prefer that the ASP page skip it and try to load the
include again only when the refresh button is pushed.
Does anyone have any suggestions?
Thanks,
Anh Do
ACCE
anhdo@a...
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
________________________________________________________________________
Scottish Enterprise Network
http://www.scottish-enterprise.com
Headquarters Address & Contact Numbers
150 Broomielaw
5 Atlantic Quay
Glasgow
G2 8LU.
Tel: +44 (0) 141 248 2700.
Fax: +44 (0)141 221 3217
This message is sent in confidence for the addressee only.
It may contain legally privileged information. The contents are not to
be disclosed to anyone other than the addressee. Unauthorised recipients
are requested to preserve this confidentiality and to advise the sender
immediately of any error in transmission.
Message #5 by "Do, Anh" <Anhdo@a...> on Wed, 10 Apr 2002 10:09:23 -0400
|
|
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_001_01C1E099.50A010D0
Content-Type: text/plain
It is not my code. We pay for this service so the include was developed by the Newzsnap people. It works to pull national and
local news articles from their database to display on our page. Thanks for the help. I will write to the developers of
newzsnap.inc and ask them to modify their code.
Anh
> -----Original Message-----
> From: Craig Flannigan [SMTP:ckf@k...]
> Sent: Wednesday, April 10, 2002 10:04 AM
> To: ASP Web HowTo
> Subject: [asp_web_howto] RE: Help with Include Files
>
> Can you not write some error trapping into the Include file.
>
> Why is it not always working properly? Can you not detect this with code?
>
> The dirty way to do it is to place an "On Error Resume Next" but this then
> applies to the whole homepage and not just the Include.
>
> You're best trying to find out how to trap the errors that occur in
> newzsnap.inc.
>
>
>
>
> -----Original Message-----
> From: anhdo@a... [mailto:anhdo@a...]
> Sent: 10 April 2002 15:04
> To: ASP Web HowTo
> Subject: [asp_web_howto] Help with Include Files
>
>
> Is there any way to skip an include file in ASP if it is not loading
> properly and load the rest of the page normally?
>
> I have an include file on the homepage of my web site www.acce.org,
> <!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
> to stall when the include is not working properly.
>
> Newsnap.inc pulls information from another site and loads it onto our
> homepage. The problem is that the newsnap.inc file is down often, which
> in turn causes our entire homepage to stall. When the file is not loading
> properly I would prefer that the ASP page skip it and try to load the
> include again only when the refresh button is pushed.
>
> Does anyone have any suggestions?
>
> Thanks,
> Anh Do
> ACCE
> anhdo@a...
>
> ---
>
> Improve your web design skills with these new books from Glasshaus.
>
> Usable Web Menus
> http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
> r-20
> Constructing Accessible Web Sites
> http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
> r-20
> Practical JavaScript for the Usable Web
> http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
> r-20
>
> _____________________________________________________________________
> This message has been checked for all known viruses by Star Internet
> delivered through the MessageLabs Virus Scanning Service on behalf of
> Kingfield Heath Ltd. For further information visit
> http://www.star.net.uk/stats.asp
>
>
> _____________________________________________________________________
> This message has been checked for all known viruses by Star Internet
> delivered through the MessageLabs Virus Scanning Service on behalf of Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
>
>
> ---
>
> Improve your web design skills with these new books from Glasshaus.
>
> Usable Web Menus
> http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
> r-20
> Constructing Accessible Web Sites
> http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
> r-20
> Practical JavaScript for the Usable Web
> http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
> r-20
Message #6 by "Tim Morford" <tmorford@n...> on Wed, 10 Apr 2002 10:06:48 -0400
|
|
I know the software you are talking about, I helped them get there SQL
server back up late one night, What I would do with out seeing the include
file is possable a response.flush or cache the information for the day, I
think they do nigtly updates of there information, Or Dump them and use
XMLHTTP.
Tim Morford
http://www.aspalliance.com/tmorford
-----Original Message-----
From: anhdo@a... [mailto:anhdo@a...]
Sent: Wednesday, April 10, 2002 3:04 PM
To: ASP Web HowTo
Subject: [asp_web_howto] Help with Include Files
Is there any way to skip an include file in ASP if it is not loading
properly and load the rest of the page normally?
I have an include file on the homepage of my web site www.acce.org,
<!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
to stall when the include is not working properly.
Newsnap.inc pulls information from another site and loads it onto our
homepage. The problem is that the newsnap.inc file is down often, which
in turn causes our entire homepage to stall. When the file is not loading
properly I would prefer that the ASP page skip it and try to load the
include again only when the refresh button is pushed.
Does anyone have any suggestions?
Thanks,
Anh Do
ACCE
anhdo@a...
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
Message #7 by "Craig Flannigan" <ckf@k...> on Wed, 10 Apr 2002 15:14:53 +0100
|
|
This is a multi-part message in MIME format.
------=_NextPart_000_0036_01C1E0A2.77D55D00
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
RE: [asp_web_howto] RE: Help with Include FilesEither that, or you could
write a program which extracts the info into a local file and include that
instead.
Or, could you use an IFRAME to insert it? That way your whole page loads
instantly and the IFrame is treated as another page and will either load or
not in it's own time.
Is that possible on your site to use an IFrame?
-----Original Message-----
From: Do, Anh [mailto:Anhdo@a...]
Sent: 10 April 2002 15:09
To: ASP Web HowTo
Subject: [asp_web_howto] RE: Help with Include Files
It is not my code. We pay for this service so the include was developed
by the Newzsnap people. It works to pull national and local news articles
from their database to display on our page. Thanks for the help. I will
write to the developers of newzsnap.inc and ask them to modify their code.
Anh
-----Original Message-----
From: Craig Flannigan [SMTP:ckf@k...]
Sent: Wednesday, April 10, 2002 10:04 AM
To: ASP Web HowTo
Subject: [asp_web_howto] RE: Help with Include Files
Can you not write some error trapping into the Include file.
Why is it not always working properly? Can you not detect this with
code?
The dirty way to do it is to place an "On Error Resume Next" but this
then
applies to the whole homepage and not just the Include.
You're best trying to find out how to trap the errors that occur in
newzsnap.inc.
-----Original Message-----
From: anhdo@a... [mailto:anhdo@a...]
Sent: 10 April 2002 15:04
To: ASP Web HowTo
Subject: [asp_web_howto] Help with Include Files
Is there any way to skip an include file in ASP if it is not loading
properly and load the rest of the page normally?
I have an include file on the homepage of my web site www.acce.org,
<!--#include virtual="/includes/newzsnap.inc"--> that is causing the
page
to stall when the include is not working properly.
Newsnap.inc pulls information from another site and loads it onto our
homepage. The problem is that the newsnap.inc file is down often, which
in turn causes our entire homepage to stall. When the file is not
loading
properly I would prefer that the ASP page skip it and try to load the
include again only when the refresh button is pushed.
Does anyone have any suggestions?
Thanks,
Anh Do
ACCE
anhdo@a...
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service on behalf of
Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service on behalf of
Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
---
Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20
Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20
Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20
--- Improve your web design skills with these new books from Glasshaus.
Usable Web Menus
http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
r-20 Constructing Accessible Web Sites
http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
r-20 Practical JavaScript for the Usable Web
http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
r-20 ---
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service on behalf of
Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service on behalf of Kingfield Heath Ltd. For further information visit
http://www.star.net.uk/stats.asp
Message #8 by "Do, Anh" <Anhdo@a...> on Wed, 10 Apr 2002 10:15:53 -0400
|
|
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_001_01C1E09A.39729300
Content-Type: text/plain
Here is the code to the include file. How would I modify the code so that if it is not working in a certain amount of time, then to
have it skipped our time out on my homepage.
____________________
<%
' NEWZSNAP CLIENT - ASP VERSION
'feedId = Request( "feedId" )
feedId = 1544
refresher = date( )
refresherMinutes = datePart( "n", refresher )
refresher = dateAdd( "n", -( refresherMinutes mod 5 ), refresher )
epoch = dateSerial( 1970, 1, 1 )
set ctrl = Server.createObject( "SOFTWING.ASPtear" )
newzsnap = ctrl.retrieve( "http://www.lobbynet.com/ppc_center_deliver/" & _
"deliver_articles.asp", 2, _
"searchId=" & feedId & "&" & _
"forceReload=" & dateDiff( "s", epoch, _
refresher ), _
"", "" )
set ctrl = Nothing
%>
<!-- The following actually displays the NewzSnap content. Embed in HTML! -->
<%= newzsnap %>
<BR>
____________________
> -----Original Message-----
> From: Tim Morford [SMTP:tmorford@n...]
> Sent: Wednesday, April 10, 2002 10:07 AM
> To: ASP Web HowTo
> Subject: [asp_web_howto] RE: Help with Include Files
>
> I know the software you are talking about, I helped them get there SQL
> server back up late one night, What I would do with out seeing the include
> file is possable a response.flush or cache the information for the day, I
> think they do nigtly updates of there information, Or Dump them and use
> XMLHTTP.
>
> Tim Morford
> http://www.aspalliance.com/tmorford
>
> -----Original Message-----
> From: anhdo@a... [mailto:anhdo@a...]
> Sent: Wednesday, April 10, 2002 3:04 PM
> To: ASP Web HowTo
> Subject: [asp_web_howto] Help with Include Files
>
>
> Is there any way to skip an include file in ASP if it is not loading
> properly and load the rest of the page normally?
>
> I have an include file on the homepage of my web site www.acce.org,
> <!--#include virtual="/includes/newzsnap.inc"--> that is causing the page
> to stall when the include is not working properly.
>
> Newsnap.inc pulls information from another site and loads it onto our
> homepage. The problem is that the newsnap.inc file is down often, which
> in turn causes our entire homepage to stall. When the file is not loading
> properly I would prefer that the ASP page skip it and try to load the
> include again only when the refresh button is pushed.
>
> Does anyone have any suggestions?
>
> Thanks,
> Anh Do
> ACCE
> anhdo@a...
>
> ---
>
> Improve your web design skills with these new books from Glasshaus.
>
> Usable Web Menus
> http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
> r-20
> Constructing Accessible Web Sites
> http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
> r-20
> Practical JavaScript for the Usable Web
> http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
> r-20
>
>
>
> ---
>
> Improve your web design skills with these new books from Glasshaus.
>
> Usable Web Menus
> http://www.amazon.com/exec/obidos/ASIN/1904151027/ref=nosim/theprogramme
> r-20
> Constructing Accessible Web Sites
> http://www.amazon.com/exec/obidos/ASIN/1904151000/ref=nosim/theprogramme
> r-20
> Practical JavaScript for the Usable Web
> http://www.amazon.com/exec/obidos/ASIN/1904151051/ref=nosim/theprogramme
> r-20
Message #9 by "Tim Morford" <tmorford@n...> on Wed, 10 Apr 2002 10:41:08 -0400
|
|
This is a multi-part message in MIME format.
------=_NextPart_000_0032_01C1E07C.39085B20
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: 7bit
RE: [asp_web_howto] RE: Help with Include Filesyou can do a
Server.scriptTimeout something like
<%
' NEWZSNAP CLIENT - ASP VERSION
'feedId = Request( "feedId" )
On Error Resusme Next
Server.ScriptTimeOut = 5 ' seconds
feedId = 1544
refresher = date( )
refresherMinutes = datePart( "n", refresher )
refresher = dateAdd( "n", -( refresherMinutes mod 5 ), refresher )
epoch = dateSerial( 1970, 1, 1 )
set ctrl = Server.createObject( "SOFTWING.ASPtear" )
newzsnap = ctrl.retrieve( "http://www.lobbynet.com/ppc_center_deliver/" &
_
"deliver_articles.asp", 2,
_
"searchId=" & feedId & "&" &
_
"forceReload=" & dateDiff( "s", epoch,
_
refresher ),
_
"", "" )
set ctrl = Nothing
%>
<!-- The following actually displays the NewzSnap content. Embed in
HTML! -->
<%= newzsnap %>
<BR>
Tim Morford
http://www.aspalliance.com/tmorford
-----Original Message-----
From: Do, Anh [mailto:Anhdo@a...]
Sent: Wednesday, April 10, 2002 10:16 AM
To: ASP Web HowTo
Subject: [asp_web_howto] RE: Help with Include Files
Here is the code to the include file. How would I modify the code so that
if it is not working in a certain amount of time, then to have it skipped
our time out on my homepage.
____________________
<%
' NEWZSNAP CLIENT - ASP VERSION
'feedId = Request( "feedId" )
feedId = 1544
refresher = date( )
refresherMinutes = datePart( "n", refresher )
refresher = dateAdd( "n", -( refresherMinutes mod 5 ), refresher )
epoch = dateSerial( 1970, 1, 1 )
set ctrl = Server.createObject( "SOFTWING.ASPtear" )
newzsnap = ctrl.retrieve( "http://www.lobbynet.com/ppc_center_deliver/"
& _
"deliver_articles.asp", 2,
_
"searchId=" & feedId & "&" &
_
"forceReload=" & dateDiff( "s", epoch,
_
refresher ),
_
"", "" )
set ctrl = Nothing
%>
<!-- The following actually displays the NewzSnap content. Embed in
HTML! -->
<%= newzsnap %>
<BR>
____________________
|
|
 |