[PHP] Fussy logic...

2001-08-16 Thread Tribun

Moin!

Has anybody already thought about the problematic conditional on adding an
automatic BACK Link?

It seems to be very easy... just Link to basename($HTTP_REFERER);

BUT if you CLICK on this Link, and come to a prior site, the BACK-Link THERE
appears NOT to the PAGE, witch was prior this, but is linked to the Site you
come from...
so the link should better be called FORWARD.

Do U C the problem???

;)

Has someone an idea to solve it?


Sincerely yours,
Patrick Lehnen (alias: Tribun)



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Fussy logic...

2001-08-16 Thread Renze Munnik

On Thu, Aug 16, 2001 at 10:01:36AM +0200, Tribun wrote:
 Moin!
 
 Has anybody already thought about the problematic conditional on adding an
 automatic BACK Link?
 
 It seems to be very easy... just Link to basename($HTTP_REFERER);
 
 BUT if you CLICK on this Link, and come to a prior site, the BACK-Link THERE
 appears NOT to the PAGE, witch was prior this, but is linked to the Site you
 come from...
 so the link should better be called FORWARD.
 
 Do U C the problem???
 
 ;)
 
 Has someone an idea to solve it?
 
 
 Sincerely yours,
 Patrick Lehnen (alias: Tribun)


Patrick,

It's pretty obvious that after using it once it becomes a forward
link because the HTTP_REFERER is the page you last came from. And
after using the back-button once, the last page was the 'next'. The
HTTP_REFERER isn't some kind of history-list.
If you realy want to go Back, why not use:
JS: history.back(...);

That way you really use the history-list of the browser. So after
using it once, it's still a Back-button instead of a Forward-button.

Besides that, using the $HTTP_REFERER isn't really something to rely
on. $HTTP_REFERER doesn't always have to be set. In that case you
can't go either Back nor Forward.

-- 

* RzE:

-- 
-- Renze Munnik
-- DataLink BV
--
-- E: [EMAIL PROTECTED]
-- W: +31 23 5326162
-- F: +31 23 5322144
-- M: +31 6 21811143
-- H: +31 23 5516190
--
-- Stationsplein 82
-- 2011 LM  HAARLEM
--
-- http://www.datalink.nl
-- 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Fussy logic...

2001-08-16 Thread Tribun

yapp.

I know the JS-function, but I was curious if someone knows an beautifuller
solution.

something neater ;)


Renze Munnik [EMAIL PROTECTED] schrieb im Newsbeitrag
[EMAIL PROTECTED]">news:[EMAIL PROTECTED]...
 On Thu, Aug 16, 2001 at 10:01:36AM +0200, Tribun wrote:
  Moin!
 
  Has anybody already thought about the problematic conditional on adding
an
  automatic BACK Link?
 
  It seems to be very easy... just Link to basename($HTTP_REFERER);
 
  BUT if you CLICK on this Link, and come to a prior site, the BACK-Link
THERE
  appears NOT to the PAGE, witch was prior this, but is linked to the Site
you
  come from...
  so the link should better be called FORWARD.
 
  Do U C the problem???
 
  ;)
 
  Has someone an idea to solve it?
 
 
  Sincerely yours,
  Patrick Lehnen (alias: Tribun)


 Patrick,

 It's pretty obvious that after using it once it becomes a forward
 link because the HTTP_REFERER is the page you last came from. And
 after using the back-button once, the last page was the 'next'. The
 HTTP_REFERER isn't some kind of history-list.
 If you realy want to go Back, why not use:
 JS: history.back(...);

 That way you really use the history-list of the browser. So after
 using it once, it's still a Back-button instead of a Forward-button.

 Besides that, using the $HTTP_REFERER isn't really something to rely
 on. $HTTP_REFERER doesn't always have to be set. In that case you
 can't go either Back nor Forward.

 --

 * RzE:

 -- 
 -- Renze Munnik
 -- DataLink BV
 --
 -- E: [EMAIL PROTECTED]
 -- W: +31 23 5326162
 -- F: +31 23 5322144
 -- M: +31 6 21811143
 -- H: +31 23 5516190
 --
 -- Stationsplein 82
 -- 2011 LM  HAARLEM
 --
 -- http://www.datalink.nl
 -- 



-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP] Fussy logic...

2001-08-16 Thread Renze Munnik

On Thu, Aug 16, 2001 at 10:38:56AM +0200, Tribun wrote:
 yapp.
 
 I know the JS-function, but I was curious if someone knows an beautifuller
 solution.
 
 something neater ;)


Okay... Well... then you should store the history yourself (eg. in a
session or db). But then again... the $HTTP_REFERER isn't something
to rely on. So then you'll need to store the current page in the
history session/db. That way you always have the correct URL because
it's the URL of the page the user is using. How much can go wrong
with that?
I think that's the best way. Actually I think it's even (a lot)
better then the JS solution I mentioned.

-- 

* RzE:

-- 
-- Renze Munnik
-- DataLink BV
--
-- E: [EMAIL PROTECTED]
-- W: +31 23 5326162
-- F: +31 23 5322144
-- M: +31 6 21811143
-- H: +31 23 5516190
--
-- Stationsplein 82
-- 2011 LM  HAARLEM
--
-- http://www.datalink.nl
-- 

-- 
PHP General Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]