PHP and IFRAME


#1

I have this image let’s say 500 by 500. It’s a background effect I used so I can’t really slice it. Well I thought I could include a iframe in there somehow and work with php. Or if php can do it also that’s fine.

Matta


#2

IFRAME is nothing to do with PHP. It is part of HTML. The W3C site provides an explanation of how it works.


Simon Jessey | Keystone Websites
Save $97 on yearly plans with promo code [color=#CC0000]SCJESSEY97[/color]


#3

I know that. Let me reword it. What can I do like IFRAME, but in PHP. I wanna have a scroll bar enabled 462 width and 250 height with the text in the middle?

Matta


#4

Absolutely nothing. PHP is a server-side scripting language, not a markup language. PHP offers no structural or behavioral assistance of the type you are looking for.


Simon Jessey | Keystone Websites
Save $97 on yearly plans with promo code [color=#CC0000]SCJESSEY97[/color]


#5

You can of course use PHP to print html code, including iframes. I’m sensing though that you don’t really have much PHP experiences. Try googling for some tutorials to get yourself going.


#6

Well I found what I was looking for. I put the code below in my stylecheet.css:

DIV.scrollbar {
width: 215px;
height: 210px;
position: absolute;
overflow:auto;
}

Than I put this for my page:

<?php if (isset($_GET['page']) && file_exists("{$_SERVER['DOCUMENT_ROOT']}/includes/{$_GET['page']}.html")) { include("{$_SERVER['DOCUMENT_ROOT']}/includes/{$_GET['page']}.html"); } else {$number=5; include("{$_SERVER['DOCUMENT_ROOT']}/test2.php"); } ?>

It gets my pages just fine. Thanks for the help though

Matta


#7

Thanks for following up with that. It always helps to see what people had in mind.

Wholly


#8

You probably want to use some input validation