Help! I need to incldue php files from another directory

Discussion in 'PHP' started by buckmajor, Mar 22, 2009.

  1. #1
    Hi there

    I have been searching around for days and have been trying to use the php include which I am familiar with but have found no solution to my problem.
    I have 2 links here
    'My Web link'

    'My Photo link'

    I want to add a php include from 'My Photo link' to 'My Web link' within the body content. I also have 'My Photo link' in a directory located on 'My Web link' called 'Logogallery' but can not get it to work which is the reason why I uploaded the files to a subdomain 'My Photo link'.

    This is not easy for me to explain but do forgive me if I have not made myself clear enough for anyone to understand.

    Would surely appreciate your help.
    CHEERS :)
     
    buckmajor, Mar 22, 2009 IP
  2. mehdi

    mehdi Peon

    Messages:
    258
    Likes Received:
    12
    Best Answers:
    0
    Trophy Points:
    0
    #2
    Hello, you can try including from Absolute Directory.
    like if your subdomain called "test"
    you can try
    
    <?php
    include("/home/myusername/public_html/test/index.php");
    ?>
    
    Hope it helps.
    PHP:
     
    mehdi, Mar 22, 2009 IP