<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1020037" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1020037</link>
    <description></description>
    <language>en</language>
          <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122168</link>
    <description> &lt;p&gt;Last update from me on this subject.  I started putting the DOCUMENT_ROOT method of calling my header on every page.  It worked fine everywhere until I got to my photo album area (&quot;Gallery&quot;).  For some unknown reason DOCUMENT_ROOT won&#039;t work here, but the &#039;full path&#039; method does.  So that seems to be the best solution for avoiding errors.  (I guess)&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://www.webmaster-forums.net/misc/smileys/wink.png&quot; title=&quot;Wink&quot; alt=&quot;Wink&quot; class=&quot;smiley-content&quot; /&gt;&lt;/p&gt;
 </description>
     <pubDate>Mon, 23 Dec 2002 16:23:38 +0000</pubDate>
 <dc:creator>fifeclub</dc:creator>
 <guid isPermaLink="false">comment 1122168 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122160</link>
    <description> &lt;blockquote class=&quot;bb-quote-body&quot;&gt;&lt;p&gt;Quote: &lt;em&gt;From &lt;a href=&quot;http://www.php.net/manual/en/function.include.php&quot; class=&quot;bb-url&quot;&gt;PHP.net&lt;/a&gt;&lt;/em&gt;&lt;br /&gt;
&lt;strong&gt;The documentation below also applies to require(). The two constructs are identical in every way except how they handle failure. include() produces a Warning while require()  results in a Fatal Error. In other words, use require() if you want a missing file to halt processing of the page. include() does not behave this way, the script will continue regardless.&lt;/strong&gt; &lt;/p&gt;&lt;/blockquote&gt;
 </description>
     <pubDate>Mon, 23 Dec 2002 07:18:49 +0000</pubDate>
 <dc:creator>Abhishek Reddy</dc:creator>
 <guid isPermaLink="false">comment 1122160 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122159</link>
    <description> &lt;blockquote class=&quot;bb-quote-body&quot;&gt;&lt;p&gt;Quote: &lt;em&gt;Originally posted by fifeclub &lt;/em&gt;&lt;br /&gt;
&lt;strong&gt;Is there an advantage/disadvantage to using require instead of include? &lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;yeah, i&#039;ve been wondering that my self, I usually use the require instead if include - I just didn&#039;t want to make a new thread about it...&lt;/p&gt;
 </description>
     <pubDate>Mon, 23 Dec 2002 06:43:57 +0000</pubDate>
 <dc:creator>Renegade</dc:creator>
 <guid isPermaLink="false">comment 1122159 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122158</link>
    <description> &lt;p&gt;Thanks everybody.  What I ended up doing was taking everybody&#039;s suggestions and a ton of examples from php.net and I tested all of them.  Out of 12 testpages, I got 3 methods to work (call the other page and properly pass the variable to that other page).  One way was using the ../ but I found that it could be dependant on how many folders down you were so that left two ways:&lt;/p&gt;
&lt;p&gt;1)  include(&quot;$DOCUMENT_ROOT/includes/header.php&quot;);&lt;br /&gt;
            (and a &#039;require&#039; version of this document_root method)&lt;br /&gt;
2)  include &quot;/home/mikesus/public_html/includes/header.php&quot;;&lt;br /&gt;
            (which is just using the full path name)&lt;/p&gt;
&lt;p&gt;&lt;img src=&quot;https://www.webmaster-forums.net/misc/smileys/smile.png&quot; title=&quot;Smiling&quot; alt=&quot;Smiling&quot; class=&quot;smiley-content&quot; /&gt; &lt;/p&gt;
&lt;p&gt;One final question though.  An alternate &#039;cousin&#039; of the document_root method worked but used &quot;require&quot; instead of &quot;include&quot;.&lt;br /&gt;
( require($DOCUMENT_ROOT . &quot;/includes/header2.php&quot;); )&lt;br /&gt;
Is there an advantage/disadvantage to using require instead of include?&lt;/p&gt;
 </description>
     <pubDate>Mon, 23 Dec 2002 04:17:15 +0000</pubDate>
 <dc:creator>fifeclub</dc:creator>
 <guid isPermaLink="false">comment 1122158 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122157</link>
    <description> &lt;p&gt;heh, I meant for fifeclub to look around. &lt;img src=&quot;https://www.webmaster-forums.net/misc/smileys/wink.png&quot; title=&quot;Wink&quot; alt=&quot;Wink&quot; class=&quot;smiley-content&quot; /&gt;&lt;/p&gt;
 </description>
     <pubDate>Mon, 23 Dec 2002 02:43:35 +0000</pubDate>
 <dc:creator>Suzanne</dc:creator>
 <guid isPermaLink="false">comment 1122157 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122156</link>
    <description> &lt;blockquote class=&quot;bb-quote-body&quot;&gt;&lt;p&gt;Quote: &lt;em&gt;Originally posted by Suzanne &lt;/em&gt;&lt;br /&gt;
&lt;strong&gt;Right, and Dean&#039;s solution was to make $DOCUMENT_ROOT a smaller variable for multiple uses. &lt;/strong&gt;&lt;/p&gt;&lt;/blockquote&gt;
&lt;p&gt;Yeah, I guess if I would have clicked on that link and looked around. Using $DOCUMENT_ROOT is a quick and dirty approach. A better solution generally is creating at least two variables. One that is the Root or whichever directory you want to be root and another variable for the system path (i.e. /home/username/directory). The second variable is useful for calling stuff that is in directories under the www directory which means that they won&#039;t show up over the web. A good place to stick usernames and passwords for databases.&lt;/p&gt;
 </description>
     <pubDate>Mon, 23 Dec 2002 02:28:10 +0000</pubDate>
 <dc:creator>mairving</dc:creator>
 <guid isPermaLink="false">comment 1122156 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122143</link>
    <description> &lt;p&gt;Right, and Dean&#039;s solution was to make $DOCUMENT_ROOT a smaller variable for multiple uses.&lt;/p&gt;
 </description>
     <pubDate>Sun, 22 Dec 2002 16:10:37 +0000</pubDate>
 <dc:creator>Suzanne</dc:creator>
 <guid isPermaLink="false">comment 1122143 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122140</link>
    <description> &lt;p&gt;Try using this:&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;&lt;span style=&quot;color: #000000&quot;&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;&amp;lt;?php&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;include(\&lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&quot;&lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;$DOCUMENT_ROOT&lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;/test.php\&quot;);&lt;br /&gt;?&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/div&gt;&lt;br /&gt;
This will bring up the file to your public_html directory which would translate to &lt;a href=&quot;http://yoursite.com/test.php&quot; class=&quot;bb-url&quot;&gt;http://yoursite.com/test.php&lt;/a&gt;&lt;/p&gt;
 </description>
     <pubDate>Sun, 22 Dec 2002 12:44:39 +0000</pubDate>
 <dc:creator>mairving</dc:creator>
 <guid isPermaLink="false">comment 1122140 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122138</link>
    <description> &lt;p&gt;&lt;strong&gt;/&lt;/strong&gt; = root directory (in PHP it&#039;s the server&#039;s root dir, but in HTML it&#039;s your domain&#039;s root dir)&lt;br /&gt;
&lt;strong&gt;./&lt;/strong&gt; = same directory&lt;br /&gt;
&lt;strong&gt;../&lt;/strong&gt; = One directory back&lt;br /&gt;
&lt;strong&gt;../../&lt;/strong&gt; = Two directories back&lt;/p&gt;
&lt;p&gt;If you can&#039;t get it to work, then write us the FULL URL where your PHP script is, and also where is the file you&#039;re trying to include. This way it will be a lot easier for us to help you.&lt;/p&gt;
 </description>
     <pubDate>Sun, 22 Dec 2002 08:08:15 +0000</pubDate>
 <dc:creator>zollet</dc:creator>
 <guid isPermaLink="false">comment 1122138 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/not-using-full-url#comment-1122132</link>
    <description> &lt;p&gt;if ../ didnt work, try ../../ or even ../../foldername/&lt;/p&gt;
&lt;p&gt;it all depends where the folders are and from where your starting from. example using a folder 2 back, 1 over is different if the calling files is in a upper directory than the lower one&lt;br /&gt;
Take a quick peek at [url=http://ezhtml.net/ezgraphics.html]here[/ur] for a directory tree example (third way down)&lt;/p&gt;
 </description>
     <pubDate>Sun, 22 Dec 2002 06:09:07 +0000</pubDate>
 <dc:creator>Busy</dc:creator>
 <guid isPermaLink="false">comment 1122132 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
