Ask a Question related to Macromedia Dynamic HTML, Design and Development.

  1. #1

    Default Using Snippets

    Hi All,
    Could someone please help me use the redirect snippet. I want to redirect
    users to a page after a certain amount of time.

    Thanks in anticipation,
    Lloyd Codrington [url]https://www.bluespotnetwork.com[/url]

    lloydcodrington Guest

  2. Similar Questions and Discussions

    1. Contribue & Snippets
      We have a dreamweaver template, with a lot of snippets which are used globally across all departments using that template. We want to start using...
    2. css/html snippets?
      Hello, For images on my site, I usually place them in a table with certain border styles and another td for captions. However, now I am building...
    3. snippets in Contribute
      I'd like my contribute users to be able to insert a pre-defined table in their pages (alternsating coloured rows etc.). Contributre does offer...
    4. snippets of php
      I have a fairly large .php page that is 99% html with two teeny tiny snippets of PHP: one near the beginnning of the page, the other near the end. ...
    5. Snippets crashing DW MX
      When I try to insert snippets, I get the following error message: Dreamweaver encounter a fatal exception. Dreamweaver will now terminate. Then...
  3. #2

    Default Re: Using Snippets

    The redirect snippet? Can you show me what its code is?

    --
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    [url]http://www.dreamweavermx-templates.com[/url] - Template Triage!
    [url]http://www.projectseven.com/go[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.dwfaq.com[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.macromedia.com/support/search/[/url] - Macromedia (MM) Technotes
    ==================


    "lloydcodrington" <webforumsuser@macromedia.com> wrote in message
    news:dv4e7n$c4f$1@forums.macromedia.com...
    > Hi All,
    > Could someone please help me use the redirect snippet. I want to redirect
    > users to a page after a certain amount of time.
    >
    > Thanks in anticipation,
    > Lloyd Codrington [url]https://www.bluespotnetwork.com[/url]
    >

    Murray *ACE* Guest

  4. #3

    Default Re: Using Snippets

    Hi Murray,
    The snippet code is attached. Please could you give me an example of how to
    use it and how to incorporate a delay.

    Thanks,
    Lloyd



    function browserRedirect()

    {

    var ns4 = document.layers;

    var ns6 = document.getElementById && !document.all;

    var ie4 = document.all;



    if(ns4) URLStr = "1.html";

    else if(ns6) URLStr = "2.html";

    else if(ie4) URLStr = "3.html";

    else URLStr = "4.html";

    location = URLStr;

    }

    lloydcodrington Guest

  5. #4

    Default Re: Using Snippets

    That's pretty antique code. And, it's a bad idea, too. Not only are you
    doubling, tripling, or quadrupling your effort by redirecting to pages for
    specific browsers, but you are breaking the browser's back button by using
    it, since if the user sees the redirected page, and clicks on the back
    button, they arrive at the redirected page again. A better solution (at
    least one that doesn't break the back button) would be to do a server-side
    redirect.

    But tell me this - what problem are you trying to solve by using that?

    --
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    [url]http://www.dreamweavermx-templates.com[/url] - Template Triage!
    [url]http://www.projectseven.com/go[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.dwfaq.com[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.macromedia.com/support/search/[/url] - Macromedia (MM) Technotes
    ==================


    "lloydcodrington" <lloydcodrington@bluespotnetwork.co.uk> wrote in message
    news:dv6jfc$f39$1@forums.macromedia.com...
    > Hi Murray,
    > The snippet code is attached. Please could you give me an example of how
    > to
    > use it and how to incorporate a delay.
    >
    > Thanks,
    > Lloyd
    >
    >
    >
    > function browserRedirect()
    >
    > {
    >
    > var ns4 = document.layers;
    >
    > var ns6 = document.getElementById && !document.all;
    >
    > var ie4 = document.all;
    >
    >
    >
    > if(ns4) URLStr = "1.html";
    >
    > else if(ns6) URLStr = "2.html";
    >
    > else if(ie4) URLStr = "3.html";
    >
    > else URLStr = "4.html";
    >
    > location = URLStr;
    >
    > }
    >

    Murray *ACE* Guest

  6. #5

    Default Re: How do I use browser redirect snippet

    Hi Murry,
    What I want to do is as follows:
    I have a client and he wants a page on his site that just says hello to his
    site's users. He also wants it to then redirect the user to the home page
    after 5 - 10 seconds.

    The code I sent you earlier was taken directly from the DW8 snippet panel. I
    have no idea how it would have acted.

    Thanks for the assistance,
    Lloyd Codrington

    lloydcodrington Guest

  7. #6

    Default Re: How do I use browser redirect snippet

    <sigh>

    Why does your client want this. How will it be for people who have been to
    the site already 10 times?

    You can do that with the meta refresh tag -

    Position your cursor in the head of the page, and use INSERT | HTML > Head
    Tags > Meta Refresh, and fill in the blanks.

    But you have now broken the back button on the browser (as I described
    earlier).

    --
    Murray --- ICQ 71997575
    Adobe Community Expert
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    [url]http://www.dreamweavermx-templates.com[/url] - Template Triage!
    [url]http://www.projectseven.com/go[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.dwfaq.com[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.macromedia.com/support/search/[/url] - Macromedia (MM) Technotes
    ==================


    "lloydcodrington" <lloydcodrington@bluespotnetwork.co.uk> wrote in message
    news:dv6q4i$oj0$1@forums.macromedia.com...
    > Hi Murry,
    > What I want to do is as follows:
    > I have a client and he wants a page on his site that just says hello to
    > his
    > site's users. He also wants it to then redirect the user to the home page
    > after 5 - 10 seconds.
    >
    > The code I sent you earlier was taken directly from the DW8 snippet panel.
    > I
    > have no idea how it would have acted.
    >
    > Thanks for the assistance,
    > Lloyd Codrington
    >

    Murray *ACE* Guest

  8. #7

    Default Re: How do I use browser redirect snippet

    Murray,
    I have no idea why my client wants to make my life a misery. I did mention
    that people will not want to see the welcome screen after the first time but as
    they say the client is always right. So I get on with it.

    Will try your method. Because the back key only goes back to the welcome page
    I can't see it having much of an effect.

    Thanks,
    Lloyd

    lloydcodrington Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139