<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1036324" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1036324</link>
    <description></description>
    <language>en</language>
          <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/absolute-and-relative-linking#comment-1209339</link>
    <description> &lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;That will be why then...&lt;/p&gt;
&lt;p&gt;If the url was:&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://www.yourdomain.com&quot; class=&quot;bb-url&quot;&gt;http://www.yourdomain.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;/ would go to the root which is the domain,&lt;/p&gt;
&lt;p&gt;However when using:&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://111.222.333.444/~yourdomain.com&quot; class=&quot;bb-url&quot;&gt;http://111.222.333.444/~yourdomain.com&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;The tilde (~) basically skips all the middle parts. Your actual path is probably something like:&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://111.222.333.444/home/sites/yourdomain.com/&quot; class=&quot;bb-url&quot;&gt;http://111.222.333.444/home/sites/yourdomain.com/&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;So the / goes to the root of the IP which is of course, not where the files are.&lt;/p&gt;
&lt;p&gt;Easiest solution is to edit your local hosts file (using netinfo manager I think) on your mac to make &lt;a href=&quot;http://www.yourdomain.com&quot; class=&quot;bb-url&quot;&gt;yourdomain.com&lt;/a&gt; resolve to the IP of your server until you can actually put the new site live. Then for you the site will resolve to the new server, but for everyone else the site will resolve to the old one.&lt;/p&gt;
&lt;p&gt;&lt;a href=&quot;http://www.apple.com/server/pdfs/UnderstandingUsingNetInfo.pdf&quot; class=&quot;bb-url&quot;&gt;This document&lt;/a&gt; should help you with configuring netinfo manager:&lt;/p&gt;
 </description>
     <pubDate>Mon, 23 Oct 2006 17:37:26 +0000</pubDate>
 <dc:creator>andy206uk</dc:creator>
 <guid isPermaLink="false">comment 1209339 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/absolute-and-relative-linking#comment-1209290</link>
    <description> &lt;p&gt;OK, to follow up on this... there is no problem using links formatted with a leading slash when on a live domain. My problem was caused by using IP/~user to reach a cpanel site which has no live domain pointed to it. If each domain had its own IP this may not have been a problem.&lt;/p&gt;
 </description>
     <pubDate>Sun, 22 Oct 2006 17:49:51 +0000</pubDate>
 <dc:creator>K12RS</dc:creator>
 <guid isPermaLink="false">comment 1209290 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/absolute-and-relative-linking#comment-1209097</link>
    <description> &lt;p&gt;Greg,&lt;br /&gt;
Thank you. This is a cpanel setup on a VPS that allows hosting multiple domains. All the domains on the VPS share the an IP and cpanel sorts out the calls based on actual domain or user. Another factor is that the domain I&#039;m working on is not active so I&#039;m using &quot;IP/~user&quot; to access the site. So I guess I need to put the site on an active domain to finish testing because even the relative links within public_html aren&#039;t working properly. But I do appreciate knowing that it &quot;should&quot; work and will continue to pursue it.&lt;br /&gt;
Thanks again,&lt;br /&gt;
John&lt;/p&gt;
&lt;blockquote class=&quot;bb-quote-body&quot;&gt;&lt;p&gt;&lt;strong&gt;Greg K;209092 wrote:&lt;/strong&gt; The leading slash SHOULD tell it to go to the root of the domain (or ip address), the browser has no knowlege of the file structure of the server, so it can only go off of the domain.&lt;/p&gt;
&lt;p&gt;If you have &lt;a href=&quot;http://www.domain.com/images/file.jpg&quot; class=&quot;bb-url&quot;&gt;domain.com/images/file.jpg&lt;/a&gt; as where your files are, any file under &lt;a href=&quot;http://www.domain.com&quot; class=&quot;bb-url&quot;&gt;domain.com&lt;/a&gt; that calls /image/file.jpg should access it fine.&lt;/p&gt;
&lt;p&gt;However, if you have &lt;a href=&quot;http://www.domain.com/username/images/file.jpg&quot; class=&quot;bb-url&quot;&gt;domain.com/username/images/file.jpg&lt;/a&gt; , and you consider your main site to be &lt;a href=&quot;http://www.domain.com/username&quot; class=&quot;bb-url&quot;&gt;domain.com/username&lt;/a&gt; then you will have to change all your links to be  /username/images/file.jpg   This is the only thing I could think of that may be wrong, and many free hosts use a setup like this.&lt;/p&gt;
&lt;p&gt;-Greg&lt;/p&gt;&lt;/blockquote&gt;
 </description>
     <pubDate>Thu, 19 Oct 2006 21:50:06 +0000</pubDate>
 <dc:creator>K12RS</dc:creator>
 <guid isPermaLink="false">comment 1209097 at https://www.webmaster-forums.net</guid>
  </item>
  <item>
    <title></title>
    <link>https://www.webmaster-forums.net/html-css-and-javascript/absolute-and-relative-linking#comment-1209092</link>
    <description> &lt;p&gt;The leading slash SHOULD tell it to go to the root of the domain (or ip address), the browser has no knowlege of the file structure of the server, so it can only go off of the domain.&lt;/p&gt;
&lt;p&gt;If you have &lt;a href=&quot;http://www.domain.com/images/file.jpg&quot; class=&quot;bb-url&quot;&gt;domain.com/images/file.jpg&lt;/a&gt; as where your files are, any file under &lt;a href=&quot;http://www.domain.com&quot; class=&quot;bb-url&quot;&gt;domain.com&lt;/a&gt; that calls /image/file.jpg should access it fine.&lt;/p&gt;
&lt;p&gt;However, if you have &lt;a href=&quot;http://www.domain.com/username/images/file.jpg&quot; class=&quot;bb-url&quot;&gt;domain.com/username/images/file.jpg&lt;/a&gt; , and you consider your main site to be &lt;a href=&quot;http://www.domain.com/username&quot; class=&quot;bb-url&quot;&gt;domain.com/username&lt;/a&gt; then you will have to change all your links to be  /username/images/file.jpg   This is the only thing I could think of that may be wrong, and many free hosts use a setup like this.&lt;/p&gt;
&lt;p&gt;-Greg&lt;/p&gt;
 </description>
     <pubDate>Thu, 19 Oct 2006 20:06:27 +0000</pubDate>
 <dc:creator>Greg K</dc:creator>
 <guid isPermaLink="false">comment 1209092 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
