Web Analytics Made Easy -
StatCounter Action based on connectivity - CodingForum

Announcement

Collapse
No announcement yet.

Action based on connectivity

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Action based on connectivity

    By default the site is using dynamic navigation.

    What I need:

    If for whatever reason database connection is not available - display static menu (which would only have links to static pages), instead of having entire site go down with sql error message.
    I know that I know nothing

  • #2
    hmmm, try this,
    place this on top of ur asp page

    Code:
    <%
    On Error resume Next
    %>
    then use this code.

    Code:
    <%
    If Err.Number <> 0 then
    
    'static navigation bar
    
    else
    
    'dynamic navigation bar
    
    Error.Clear
    End If
    %>
    i dont know if this will work but give it a go and let us know how it went
    Last edited by Baleric; Oct 2, 2006, 05:19 AM.

    Comment

    Working...
    X