Professional Web Applications Themes

Fitting the asp code in a page inside the asp code in a template - Macromedia Dreamweaver

I'm adding code in a template which connects to the only database and also closes the connection. Every page in the site uses the template and most of the pages in the site access the database. So I can strip out the database connection set up and closing out of each page because it will be in the template. But the sequence has to be correct when the template is applied to the page: template code connects to database; page code uses database; template code closes database connection. How do I make sure when I add the code to the ...

  1. #1

    Default Fitting the asp code in a page inside the asp code in a template

    I'm adding code in a template which connects to the only database and also closes the connection.

    Every page in the site uses the template and most of the pages in the site access the database. So I can strip out the database connection set up and closing out of each page because it will be in the template.

    But the sequence has to be correct when the template is applied to the page: template code connects to database; page code uses database; template code closes database connection.

    How do I make sure when I add the code to the template and update the pages that the code is in this order?






    rogerwithnell webforumsuser@macromedia.com Guest

  2. #2

    Default Re: Fitting the asp code in a page inside the asp code in a template

    How many editable regions does your template have?

    --
    Murray --- ICQ 71997575
    Team Macromedia Volunteer for Dreamweaver MX
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    [url]news://forums.macromedia.com/macromedia.dreamweaver[/url] - THE BEST WAY TO GET
    ANSWERS
    ==================
    [url]http://www.dreamweavermx-templates.com[/url] - Template Triage!
    [url]http://www.projectseven.com/go[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.DreamweaverFAQ.com[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.macromedia.com/support/search/[/url] - Macromedia (MM) Technotes
    ==================

    "rogerwithnell" <webforumsusermacromedia.com> wrote in message
    news:bf4k0o$r5p$1forums.macromedia.com...
    > I'm adding code in a template which connects to the only database and also
    closes the connection.
    >
    > Every page in the site uses the template and most of the pages in the site
    access the database. So I can strip out the database connection set up and
    closing out of each page because it will be in the template.
    >
    > But the sequence has to be correct when the template is applied to the
    page: template code connects to database; page code uses database; template
    code closes database connection.
    >
    > How do I make sure when I add the code to the template and update the
    pages that the code is in this order?
    >
    >
    >
    >
    >
    >

    Murray *TMM* Guest

  3. #3

    Default Re: Fitting the asp code in a page inside the asp code in a template

    The template has two editable regions.


    rogerwithnell webforumsuser@macromedia.com Guest

  4. #4

    Default Re: Fitting the asp code in a page inside the asp code in a template

    roger:

    Then you are likely to have a problem applying that template to pages since
    you must put all the page's content into a single editable region.

    A better way is to spawn a new page from the template, and copy and paste
    from the existing page to the new page before saving the new page over the
    old one. This way you get to place material in each editable region as
    desired.

    --
    Murray --- ICQ 71997575
    Team Macromedia Volunteer for Dreamweaver MX
    (If you *MUST* email me, don't LAUGH when you do so!)
    ==================
    [url]news://forums.macromedia.com/macromedia.dreamweaver[/url] - THE BEST WAY TO GET
    ANSWERS
    ==================
    [url]http://www.dreamweavermx-templates.com[/url] - Template Triage!
    [url]http://www.projectseven.com/go[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.DreamweaverFAQ.com[/url] - DW FAQs, Tutorials & Resources
    [url]http://www.macromedia.com/support/search/[/url] - Macromedia (MM) Technotes
    ==================

    "rogerwithnell" <webforumsusermacromedia.com> wrote in message
    news:bf5nf7$egl$1forums.macromedia.com...
    > The template has two editable regions.
    >
    >

    Murray *TMM* Guest

Similar Threads

  1. ASP Code inside Templates
    By Shmooter in forum Dreamweaver AppDev
    Replies: 4
    Last Post: April 5th, 01:26 AM
  2. Passing code/data from code-behind to ASPX page
    By A. Atienza in forum ASP.NET Data Grid Control
    Replies: 1
    Last Post: December 8th, 06:29 PM
  3. passing code inside function
    By Marcos Rebelo in forum PERL Beginners
    Replies: 4
    Last Post: December 9th, 01:14 PM
  4. Can you use Keyword {Next} for isPastCuePoint()? [code inside]
    By Jeff in forum Macromedia Director Basics
    Replies: 3
    Last Post: November 4th, 09:45 PM
  5. Replies: 0
    Last Post: July 11th, 06:27 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not 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