error_reporting(E_ALL) Shawn -- Shawn Wilson [email]shawn@glassgiant.com[/email] [url]http://www.glassgiant.com[/url] [allowsmilie] => 1 [showsignature] => 0 [ipaddress] => [iconid] => 0 [visible] => 1 [attach] => 0 [infraction] => 0 [reportthreadid] => 0 [isusenetpost] => 1 [msgid] => <3FCF384E.95C575F8@glassgiant.com> [ref] => [htmlstate] => on_nl2br [postusername] => Shawn Wilson [ip] => shawn@glassgian [isdeleted] => 0 [usergroupid] => [membergroupids] => [displaygroupid] => [password] => [passworddate] => [email] => [styleid] => [parentemail] => [homepage] => [icq] => [aim] => [yahoo] => [msn] => [skype] => [showvbcode] => [showbirthday] => [usertitle] => [customtitle] => [joindate] => [daysprune] => [lastvisit] => [lastactivity] => [lastpost] => [lastpostid] => [posts] => [reputation] => [reputationlevelid] => [timezoneoffset] => [pmpopup] => [avatarid] => [avatarrevision] => [profilepicrevision] => [sigpicrevision] => [options] => [akvbghsfs_optionsfield] => [birthday] => [birthday_search] => [maxposts] => [startofweek] => [referrerid] => [languageid] => [emailstamp] => [threadedmode] => [autosubscribe] => [pmtotal] => [pmunread] => [salt] => [ipoints] => [infractions] => [warnings] => [infractiongroupids] => [infractiongroupid] => [adminoptions] => [profilevisits] => [friendcount] => [friendreqcount] => [vmunreadcount] => [vmmoderatedcount] => [socgroupinvitecount] => [socgroupreqcount] => [pcunreadcount] => [pcmoderatedcount] => [gmmoderatedcount] => [assetposthash] => [fbuserid] => [fbjoindate] => [fbname] => [logintype] => [fbaccesstoken] => [newrepcount] => [vbseo_likes_in] => [vbseo_likes_out] => [vbseo_likes_unread] => [temp] => [field1] => [field2] => [field3] => [field4] => [field5] => [subfolders] => [pmfolders] => [buddylist] => [ignorelist] => [signature] => [searchprefs] => [rank] => [icontitle] => [iconpath] => [avatarpath] => [hascustomavatar] => 0 [avatardateline] => [avwidth] => [avheight] => [edit_userid] => [edit_username] => [edit_dateline] => [edit_reason] => [hashistory] => [pagetext_html] => [hasimages] => [signatureparsed] => [sighasimages] => [sigpic] => [sigpicdateline] => [sigpicwidth] => [sigpicheight] => [postcount] => 3 [islastshown] => 1 [isfirstshown] => [attachments] => [allattachments] => ) --> including files in other directories - PHP Development

including files in other directories - PHP Development

I have some code running on windows on my local machine that uses the jpgraph image library. I include the jpgraph libs using include ("C:\Programming\php\jpgraph-1.14\src\jpgraph.php"); I am trying to get this code to run on my web host's unix server, with no luck. I put the folder (jpgraph) containing all the jpgraph libs in the same directory as my php code. I have tried all of the following: include ("/jpgraph/jpgraph-1.14/src/jpgraph.php"); //(relative path) include ("jpgraph/jpgraph-1.14/src/jpgraph.php"); //(relative path without leading slash) include ("/usr/www/users/mysite/jpgraph/jpgraph-1.14/src/jpgraph.php"); //(absolute path) include("http://www.mysite.com/jpgraph/jpgraph1.14/src/jpgraph.php"); //(url) include ("http://" . $_SERVER['HTTP_HOST'] . "/" . dirname($_SERVER['PHP_SELF']) . "/" . "jpgraph/jpgraph-1.14/src/jpgraph.php"); None of these ...

  1. #1

    Default including files in other directories

    I have some code running on windows on my local machine that uses the
    jpgraph image library. I include the jpgraph libs using

    include ("C:\Programming\php\jpgraph-1.14\src\jpgraph.php");

    I am trying to get this code to run on my web host's unix server, with
    no luck.
    I put the folder (jpgraph) containing all the jpgraph libs in the same
    directory as my php code. I have tried all of the following:

    include ("/jpgraph/jpgraph-1.14/src/jpgraph.php"); //(relative
    path)

    include ("jpgraph/jpgraph-1.14/src/jpgraph.php"); //(relative
    path without leading slash)

    include ("/usr/www/users/mysite/jpgraph/jpgraph-1.14/src/jpgraph.php");
    //(absolute path)

    include("http://www.mysite.com/jpgraph/jpgraph1.14/src/jpgraph.php");
    //(url)

    include ("http://" . $_SERVER['HTTP_HOST']
    . "/" . dirname($_SERVER['PHP_SELF'])
    . "/" . "jpgraph/jpgraph-1.14/src/jpgraph.php");

    None of these have worked. Does anyone know the proper technique to
    include files in other directories when using Unix or Linux? Keeping
    all php files in the same directory is not feasible.

    Thanks,

    Esoos
    ebobnar Guest

  2. #2

    Default Re: including files in other directories

    ebobnar <ebobnar74> wrote or quoted:
    > include ("jpgraph/jpgraph-1.14/src/jpgraph.php"); //(relative
    > path without leading slash)
    That should normally work.
    --
    __________
    |im |yler [url]http://timtyler.org/[/url] [email]timtt1lock.org[/email] Remove lock to reply.
    Tim Tyler Guest

  3. #3

    Default Re: including files in other directories

    ebobnar wrote:
    >
    > I have some code running on windows on my local machine that uses the
    > jpgraph image library. I include the jpgraph libs using
    >
    > include ("C:\Programming\php\jpgraph-1.14\src\jpgraph.php");
    >
    > I am trying to get this code to run on my web host's unix server, with
    > no luck.
    > I put the folder (jpgraph) containing all the jpgraph libs in the same
    > directory as my php code. I have tried all of the following:
    > include ("jpgraph/jpgraph-1.14/src/jpgraph.php"); //(relative
    > path without leading slash)
    This should work (or the absolute path). You also have to make sure the owner
    of the PHP files have permission to access the directory and the libraries.
    What are the permissions set to on the directory and files? What error are you
    getting? --> error_reporting(E_ALL)

    Shawn
    --
    Shawn Wilson
    [email]shawnglassgiant.com[/email]
    [url]http://www.glassgiant.com[/url]
    Shawn Wilson Guest

Similar Threads

  1. Including files with a control
    By Ryan in forum ASP.NET Building Controls
    Replies: 1
    Last Post: August 20th, 07:01 PM
  2. Upload files and directories
    By Lone Wolf in forum PERL Beginners
    Replies: 4
    Last Post: January 22nd, 05:18 PM
  3. Purging old files from directories
    By Verdon Vaillancourt in forum PHP Development
    Replies: 3
    Last Post: August 4th, 06:43 PM
  4. [PHP] Purging old files from directories
    By Verdon Vaillancourt in forum PHP Development
    Replies: 0
    Last Post: August 1st, 02:10 PM
  5. IE can't display Sun ftp files and directories
    By Alan in forum Sun Solaris
    Replies: 4
    Last Post: June 30th, 05:50 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