Thread: Site recognition
Results 1 to 6 of 6
04-17-2003, 12:35 PM #1
I have two different sites, each with different style sheets. They both link to one specific page. When a user opens the specific page, it should be loaded using the style sheet from the page of which he came!
In other words, how is it possible for the page to see from which site the user came?
I have heard that something like <a href”…..”?”TOKEN”>, where TOKEN is the sites ‘code’, should send this TOKEN with the link ????
04-17-2003, 12:56 PM #2
Welcome to the forums Braco
Sounds to me, if you want to serve up a different(yet the same) page depending on where the user came from, you are wanting to "cloak". I have never done this nor taken the time to learn, simply for the fact that Google and I have a wonderful relationship and I do not want to mess that up
There are reasons to cloak that are fine, sadly most use it to spam the engines. Though sites do cloak for reasons that are not to spam, you are asking google and others to figure out your intentions, not a situation most would want to place themselves in.
04-17-2003, 01:07 PM #3
Cloaking I don't know?!?!
All I want to do is a few 'if ..then ....' sentences.
Like this: IF ‘previous page = A’ THEN ‘use A’s style sheet’
IF ‘previous page = B’ THEN ‘use B’s style sheet’
And so on…….
ps. Go Spurs !!
04-17-2003, 01:11 PM #4
Slap me, bad day
If you are looking at the previous page that is fine, if you are looking at the user themselves(user-agent) that is cloaking.
I will move this to the scripts forum and somebody will help you out I am sure.
ps: ALL the way
04-17-2003, 03:03 PM #5
You didn't mention which scripting you wanted to use, but here is a PHP scripplet to check for HTTP_REFERER.
echo '<link rel="stylesheet" type="text/css" href="http://my_domain.com/styles/my_css_1.css">';
echo '<link rel="stylesheet" type="text/css" href="http://my_domain.com/styles/my_css_2.css">';
echo '<link rel="stylesheet" type="text/css" href="http://my_domain.com/styles/my_css_3.css">';
Last edited by sonofmidi; 04-17-2003 at 03:11 PM.
04-21-2003, 01:55 PM #6
I was looking for a JS instead, but thanks anyway ;-)