Results 1 to 3 of 3

Thread: PHP Screen Size / IFRAME Help

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Feb 2002
    Location
    Allen, Texas
    Posts
    125

    PHP Screen Size / IFRAME Help

    I have a quick question. I have a webpage that I normally do an INCLUDE to include another webpage. However I am unable to INCLUDE another PHP page.

    So somone suggested to me that I use IFRAME to pull the page in. This works good however I am wondering what avenue to take on this. Is it possible to make the IFRAME the same size as the page that is in it. IE 100%? I tried making the height 100% but it doesnt like it. Any thoughts?

    What about using PHP to get the screen height and then plug that into the height portion of the IFRAME?

    How do I plug something into the IFRAME statement using PHP? Like this.
    <IFRAME Height = <? GET_['Height'] ?> .... (i know the syntax is wrong but you get the idea.

    Thanks

  2. #2
    Frenzied Member ober0330's Avatar
    Join Date
    Dec 2001
    Location
    OH, USA
    Posts
    1,945

    Re: PHP Screen Size / IFRAME Help

    If I had a dime for each.... bah

    *smack* BAD PHP PROGRAMMER!

    PHP is unaware of the user's screen size. It doesn't know or care. You are looking for javascript functionality. Would it even do what you want? Probably not, but you could look into it.

    But tell me, how were you planning to use PHP if you can't do a simple include? Do us all a favor and make a page with nothing but the following:
    PHP Code:
    <?php phpinfo(); ?>
    If that displays correctly, there should be no reason you can't use an include.
    Last edited by ober0330; Jan 18th, 2005 at 10:17 AM.
    format your code!! - [vbcode] [/vbcode]

    ANSWERS CAN BE FOUND HERE!!

    my personal company

  3. #3
    VBA Nutter visualAd's Avatar
    Join Date
    Apr 2002
    Location
    Ickenham, UK
    Posts
    4,906

    Re: PHP Screen Size / IFRAME Help

    Quote Originally Posted by wookie224
    I have a quick question. I have a webpage that I normally do an INCLUDE to include another webpage. However I am unable to INCLUDE another PHP page.

    So somone suggested to me that I use IFRAME to pull the page in. This works good however I am wondering what avenue to take on this. Is it possible to make the IFRAME the same size as the page that is in it. IE 100%? I tried making the height 100% but it doesnt like it. Any thoughts?

    What about using PHP to get the screen height and then plug that into the height portion of the IFRAME?

    How do I plug something into the IFRAME statement using PHP? Like this.
    <IFRAME Height = <? GET_['Height'] ?> .... (i know the syntax is wrong but you get the idea.

    Thanks
    You seem to be confused about client side an server side. Things like the screen resolution and IFRAMEs are client side. You need to use Javascript or CSS.

    To set the height of the iframe you need to set it explicitly, 100% won't work:

    <iframe stlye="height: 500px>

    To include a file in PHP you don't use iframes. You use the include language construct.
    PHP || MySql || Apache || Get Firefox || OpenOffice.org || Click || Slap ILMV || 1337 c0d || GotoMyPc For FREE! Part 1, Part 2

    | PHP Session --> Database Handler * Custom Error Handler * Installing PHP * HTML Form Handler * PHP 5 OOP * Using XML * Ajax * Xslt | VB6 Winsock - HTTP POST / GET * Winsock - HTTP File Upload

    Latest quote: crptcblade - VB6 executables can't be decompiled, only disassembled. And the disassembled code is even less useful than I am.

    Random VisualAd: Blog - Latest Post: When the Internet becomes Electricity!!


    Spread happiness and joy. Rate good posts.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width