On Monday, April 1, 2002, at 01:49  PM, Patrick Hartnett wrote:

> So any use of header("Location=...") automatically does what amounts to 
> a target="_top"?  If so, then ignore this entire post, cuz that answers 
> the question.  If not, does anyone know how to force a target="_top" 
> when using header("Location=...")?

Why not just create an anchor ID at the top of the page, and then make 
the header argument point to that?  This will work on more browsers than 
"_top" anyway.  Like so:

// this is the HTML page you want to point to
<!DOCTYPE xhtml PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
<html xmlns="http://www.w3.org/1999/xhtml";>
   <!-- other head info goes in here -->
<a id="topofpage" />

<!-- other content of page goes here -->

// and this is your PHP code
header('Location: http://www.domain.com/testpage.php#topofpage');




Erik Price
Web Developer Temp
Media Lab, H.H. Brown

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to