[PHP] Get page height?
Hi, I was wondering if it would be possible to get the page height using php? The reason I would like to do this is so that I can include a link to the top of the page if the page is long enough, but not to display it for very short pages (where it would not be needed:) Cheers for your help, Donald Accessible Computers, competitive prices on all computer related items including Hardware, Software, Consumables and Custom Built PCs http://www.AccessibleComputers.co.uk personal website: http://www.donaldrnoble.f2s.com -- 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] Get page height?
the screen dimensions are not sent to the server, a sniffer is a handy thing, you will be able to see all the headers, and see that one is not in there. plus to compound the fact, javascript might be able to get this data (cant confirm) but javascript will only know what the dimensions are, after the page is loaded. you could get the data from javascript and use a header_redirect to give php that data. sorry I dont have a code snippit. -- Chris Lee [EMAIL PROTECTED] DRN [EMAIL PROTECTED] wrote in message 9dv0a8$4gd$[EMAIL PROTECTED]">news:9dv0a8$4gd$[EMAIL PROTECTED]... Hi, I was wondering if it would be possible to get the page height using php? The reason I would like to do this is so that I can include a link to the top of the page if the page is long enough, but not to display it for very short pages (where it would not be needed:) Cheers for your help, Donald Accessible Computers, competitive prices on all computer related items including Hardware, Software, Consumables and Custom Built PCs http://www.AccessibleComputers.co.uk personal website: http://www.donaldrnoble.f2s.com -- 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] -- 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] Get page height?
DRN [EMAIL PROTECTED] Hi, I was wondering if it would be possible to get the page height using php? This solution is sloppy but in theory it works. I would lean towards using an fopen() to read the bytes of the page on the server, then based on bytes have your script decide what to do. Chris Lee [EMAIL PROTECTED] plus to compound the fact, JavaScript might be able to get this data (cant confirm) but JavaScript will only know what the dimensions are, after the page is loaded. you could get the data from JavaScript and use a header_redirect to give php that data. sorry I don't have a code snippet. JavaScript (AFAIK) can only tell the dimensions of the window/frame the page is being drawn in. Nathan Cook [EMAIL PROTECTED] -- 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]