Ask a Question related to ASP, Design and Development.

  1. #1

    Default Function Question

    Hi!

    Is there a considerable degredidation in speed if I where to include an
    ASP page into every other ASP page that would contain all the functions
    for the site?

    This seems an easier route to update functions that are used more than
    once instead of copying code around.

    ¿¿¿
    Andrew

    * * * Sent via DevBuilder [url]http://www.devbuilder.org[/url] * * *
    Developer Resources for High End Developers.
    Andrew Durstewitz Guest

  2. Similar Questions and Discussions

    1. IIF function question
      I'm studying for my ColdFusionMX exam using Ben Forta's study guide. There is quite a bit of errata in the book, including code that simply doesn't...
    2. Simple AS function question
      Why will this not work home_btn.onRollOver = setInterval(delayAction,2000,home); function delayAction (framename:String) var name:String =...
    3. PHP function question
      When writing a function that takes in a variable number of parameters and processing it using func_get_args or a similar technique, I'm assuming...
    4. utf8_decode function question
      Hi folks, I read in a security note that something known as a cross-site scripting attacker can use utf8 encoding and that you could decode data to...
    5. Question: ConnectToDatabase function
      Thanks! I wasn't sure if the Try code would continue or not if an exception was "caught". Now I know it doesn't. "Marina" <mzlatkina@hotmail.com>...
  3. #2

    Default Re: Function Question

    Andrew Durstewitz wrote on 19 aug 2003 in
    microsoft.public.inetserver.asp.general:
    > Is there a considerable degredidation in speed if I where to include an
    > ASP page into every other ASP page that would contain all the functions
    > for the site?
    If you mean an include file: no.

    [depending on the meaning of "considerable degradation"]


    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
    Evertjan. Guest

  4. #3

    Default Re: Function Question

    Andrew Durstewitz wrote:
    > Is there a considerable degredidation in speed if I where to include
    > an ASP page into every other ASP page that would contain all the
    > functions for the site?
    no - it's a minor consideration except on a server which is already
    operating at or very near it's limit.
    > This seems an easier route to update functions that are used more than
    > once instead of copying code around.
    indeed it is ;o)

    --
    William Tasso - [url]http://WilliamTasso.com[/url]


    William Tasso Guest

  5. #4

    Default Re: Function Question

    I do mean an include file.

    * * * Sent via DevBuilder [url]http://www.devbuilder.org[/url] * * *
    Developer Resources for High End Developers.
    Andrew Durstewitz Guest

  6. #5

    Default Re: Function Question

    Since the functions won't run unless called doesn't that mean that the
    degredation will be very low?

    * * * Sent via DevBuilder [url]http://www.devbuilder.org[/url] * * *
    Developer Resources for High End Developers.
    Andrew Durstewitz Guest

  7. #6

    Default Re: Function Question

    I've personally not ran into any problems with including large include
    files in all my ASP pages.

    I have severall that I include into all files and they add up to about
    400k of files

    A little tip

    Keep you include files with the extension of ".asp" and NOT ".inc" put
    your include files into a sub folder eg /inc

    I use the following 3 for my main include folders
    /inc - most files
    /inc/js - all .js files here
    /inc/class - my ASP class files here

    hth.
    Al


    On 19 Aug 2003 15:49:03 GMT, Andrew Durstewitz
    <adurstew@devbuilder.org> wrote:
    >Since the functions won't run unless called doesn't that mean that the
    >degredation will be very low?
    >
    >* * * Sent via DevBuilder [url]http://www.devbuilder.org[/url] * * *
    >Developer Resources for High End Developers.
    Harag Guest

  8. #7

    Default function question

    I'm reading thru a book, and it had this sample code



    <html>

    <head>

    <title>Listing 6.3</title>

    </head>

    <body>

    <?php

    function printBR( $txt ) {

    print ("$txt<br>\n");

    }

    printBR(" This is a line");

    printBR("This is a new line");

    printBR("This is yet another line");

    ?>

    </body>

    </html>



    My question is I understand why there is a variable in the parentheses, (the
    argument) which is $txt, but what is it doing in the function code, print
    ("$txt<br>\n");



    Does it pass the data say for example " This is a line" into $txt, and then
    within the function it uses print $txt, I just want to make sure I
    understand the bases of functions as I learn.



    Thanks,

    Mark


    NJ Termite Guest

  9. #8

    Default Re: function question

    NJ Termite wrote:
    > I'm reading thru a book, and it had this sample code
    >
    >
    > <html>
    > <head>
    > <title>Listing 6.3</title>
    > </head>
    > <body>
    > <?php
    > function printBR( $txt ) {
    > print ("$txt<br>\n");
    > }
    > printBR(" This is a line");
    > printBR("This is a new line");
    > printBR("This is yet another line");
    > ?>
    > </body>
    > </html>
    >
    >
    > My question is I understand why there is a variable in the parentheses, (the
    > argument) which is $txt, but what is it doing in the function code, print
    > ("$txt<br>\n");
    >
    > Does it pass the data say for example " This is a line" into $txt, and then
    > within the function it uses print $txt, I just want to make sure I
    > understand the bases of functions as I learn.
    >
    > Thanks,
    >
    > Mark
    >
    The function printBR take one argument as input-data, $txt. In other
    words if you would like to call the function it needs an argument within
    that call. Let us say that you want to make it write "Hello World", then
    you would call the function like this:

    <?php
    printBR("Hello World");
    ?>

    As you can see inside the printBR it uses the standard print function to
    write the input-data ($txt) followed by a thml-tag for linebrake,
    followed by a new line.

    Hope this will answer your question.

    Cheers,
    Xenovoyance
    Xenovoyance Guest

  10. #9

    Default function question

    Hello group,

    I'm trying to develop a proof of concept webservice which asynchronously
    calls a function in a DLL. The function raises an event when it is finished,
    and works when used as part of a windows form. When I try to hook up the
    webservice to the event and call the WS, the CPU goes to 100% and I have to
    restart the WWW service.

    Does anyone have an idea as to how this can be done ... and if not,
    directions to a tall bridge would come in handy.

    Thanks in advance,
    Tim Gallivan
    I know I'm a great teacher because when I give a lesson, the person never
    comes back.


    Tim Gallivan Guest

  11. #10

    Default Re: function question

    Sorry for the cross-post, but no one had answered in
    microsoft.public.dotnet.framework.webservices

    --
    Tim Gallivan
    I know I'm a great teacher because when I give a lesson, the person never
    comes back.

    "Tim Gallivan" <nospampleasetim.gallivan@edu.gov.on.ca> wrote in message
    news:%23agMeCRiEHA.2448@TK2MSFTNGP12.phx.gbl...
    > Hello group,
    >
    > I'm trying to develop a proof of concept webservice which asynchronously
    > calls a function in a DLL. The function raises an event when it is
    finished,
    > and works when used as part of a windows form. When I try to hook up the
    > webservice to the event and call the WS, the CPU goes to 100% and I have
    to
    > restart the WWW service.
    >
    > Does anyone have an idea as to how this can be done ... and if not,
    > directions to a tall bridge would come in handy.
    >
    > Thanks in advance,
    > Tim Gallivan
    > I know I'm a great teacher because when I give a lesson, the person never
    > comes back.
    >
    >

    Tim Gallivan 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