<?xml version="1.0" encoding="utf-8" ?><rss version="2.0" xml:base="https://www.webmaster-forums.net/crss/node/1043895" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title></title>
    <link>https://www.webmaster-forums.net/crss/node/1043895</link>
    <description></description>
    <language>en</language>
          <item>
    <title>Hello me-c and welcome to</title>
    <link>https://www.webmaster-forums.net/webmasters-corner/using-hidden-links#comment-1241834</link>
    <description> &lt;p&gt;Hello me-c and welcome to the forums! &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;If you don&#039;t see anything in his pages&#039; source file than it could be coming from a php script(or other server side script) or from a .htaccess file on his server.&lt;/p&gt;
&lt;p&gt;If you don&#039;t want his referred links to show your site you could use php code similar to this.&lt;/p&gt;
&lt;p&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;$referred_from &lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;= &lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;$_SERVER&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;[ &lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&#039;HTTP_REFERER&#039;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;];&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;$blocked_sites &lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;= array(&lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&quot;site1&quot;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;, &lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&quot;site2&quot;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;, &lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&quot;site3&quot;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;, &lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&quot;and so on&quot;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;);&lt;br /&gt;&lt;br /&gt;if(&lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;in_array&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;(&lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;$referred_from&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;, &lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;$blocked_sites&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;))&lt;br /&gt;{&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; echo &lt;/span&gt;&lt;span style=&quot;color: #DD0000&quot;&gt;&quot;You can not view my site, sorry&quot;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;;&lt;br /&gt;}&lt;br /&gt;else&lt;br /&gt;{&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: #FF8000&quot;&gt;//code for showing the page on the site&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: #007700&quot;&gt;}&lt;br /&gt;&lt;/span&gt;&lt;span style=&quot;color: #0000BB&quot;&gt;?&amp;gt;&lt;/span&gt;&lt;/span&gt;&lt;/code&gt;&lt;/div&gt;&lt;/p&gt;
&lt;p&gt;Now I will go over the code for you.&lt;br /&gt;
&lt;strong&gt;The first part&lt;/strong&gt;&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;&amp;lt;?php&lt;br /&gt;$referred_from = $_SERVER[ &amp;#039;HTTP_REFERER&amp;#039;];&lt;/code&gt;&lt;/div&gt;&lt;br /&gt;
The first line signals the start of the php code to be executed. The second line gets the referral link from your web server&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The second part&lt;/strong&gt;&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;$blocked_sites = array(&amp;quot;site1&amp;quot;, &amp;quot;site2&amp;quot;, &amp;quot;site3&amp;quot;, &amp;quot;and so on&amp;quot;);&lt;/code&gt;&lt;/div&gt;&lt;br /&gt;
This line is where you will put all of the sites you would like to deny access to your site from.  The array function will create an array with the values that you put in. The current array would contain the values site1, site2, site3, and &quot;and so on&quot; all in the same array.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The third part&lt;/strong&gt;&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;if(in_array($referred_from, $blocked_sites))&lt;br /&gt;{&lt;br /&gt;	 echo &amp;quot;You can not view my site, sorry.&amp;quot;;&lt;br /&gt;}&lt;/code&gt;&lt;/div&gt;&lt;br /&gt;
This part checks to see if the referral url is in the array of blocked sites. If it is in the list the person on the other end will get the message &quot;You can not view my site, sorry.&quot;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;The fourth and final part&lt;/strong&gt;&lt;br /&gt;
&lt;div class=&quot;codeblock&quot;&gt;&lt;code&gt;else&lt;br /&gt;{&lt;br /&gt;&lt;br /&gt;//code for showing the page on the site&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;?&amp;gt;&lt;/code&gt;&lt;/div&gt;&lt;br /&gt;
This sends the user who hasn&#039;t been redirected from a blocked site to your site. add your own site&#039;s code between the { and } or echo a redirect in html.  The ?&amp;gt; at the end will end the code and the php script.&lt;/p&gt;
&lt;p&gt;If you don&#039;t know anything about php you can learn from &lt;a href=&quot;http://w3schools.com/php&quot;&gt;here.&lt;/a&gt;&lt;br /&gt;
I hope this helps with your problem.&lt;/p&gt;
 </description>
     <pubDate>Thu, 21 May 2009 01:43:17 +0000</pubDate>
 <dc:creator>cmoyer</dc:creator>
 <guid isPermaLink="false">comment 1241834 at https://www.webmaster-forums.net</guid>
  </item>
  </channel>
</rss>
