Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3

Thread: require_once

  1. #1
    Senior Coder
    Join Date
    May 2005
    Posts
    2,137
    Thanks
    96
    Thanked 72 Times in 72 Posts

    require_once

    When I use the require_once tag, I need it to go back a folder when finding the file to use. But i've tried everything. Here is my coding im using.

    Code:
    require_once('library.php');
    I've tried these as well

    Code:
    require_once('\library.php');
    require_once('..\library.php');
    require_once('\..\library.php');

  • #2
    Super Moderator Inigoesdr's Avatar
    Join Date
    Mar 2007
    Location
    Florida, USA
    Posts
    3,642
    Thanks
    2
    Thanked 405 Times in 397 Posts
    PHP Code:
    require_once('../library.php'); 

  • Users who have thanked Inigoesdr for this post:

    masterofollies (02-29-2008)

  • #3
    Senior Coder
    Join Date
    May 2005
    Posts
    2,137
    Thanks
    96
    Thanked 72 Times in 72 Posts
    It works, thank you man


  •  

    Posting Permissions

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