Results 1 to 4 of 4

Thread: require_once

  1. #1

    Thread Starter
    Addicted Member nota141's Avatar
    Join Date
    Feb 2000
    Location
    The place down there under everyone else.
    Posts
    224

    require_once

    i was wondering what effect this would have

    -----------------------
    file1.php

    require_once(file2.pinc);
    require_once(file3.pinc);
    some code

    -----------------------
    file2.pinc

    require_once(file3.pinc);
    some code

    -----------------------
    file3.pinc

    some code
    On Error wake up and try again ;-)
    ___________________________
    ICQ # 65392645
    email - [email protected]

    Visual Studio 6 ent with SP5 Running on XP with an AMD 1.2 ThunderBird with 512 MB RAM And a 120GB primary HDD (very sweet)

  2. #2
    scoutt
    Guest
    well, you ain't really requiring once are you.

    you require file3.pinc in the file1.php then again in file2.pinc when you require file2.pinc in file1.php.

    well that is confusing. I wouldn't do it that way.

  3. #3

    Thread Starter
    Addicted Member nota141's Avatar
    Join Date
    Feb 2000
    Location
    The place down there under everyone else.
    Posts
    224
    just to clarfiy file1.php can use file3.pinc if file2.pinc requires it.

    (only just learning php)
    On Error wake up and try again ;-)
    ___________________________
    ICQ # 65392645
    email - [email protected]

    Visual Studio 6 ent with SP5 Running on XP with an AMD 1.2 ThunderBird with 512 MB RAM And a 120GB primary HDD (very sweet)

  4. #4
    scoutt
    Guest
    but why do that if you you are already requiring file3.pinc in file1.php

    require file3.pinc in file1.php.

    no need to include it in file2.pinc if you are already including it in file1.php.

Posting Permissions

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



Click Here to Expand Forum to Full Width