Sublime directory Surf the web anonymous Pagerank Monitor


Different results for Iframe and php include

RealEstateAdvertis
Sun 25 March 2007, 06:16 am GMT +0200
I'm trying to figure why a script I wrote is working in an IFrame but won't work as a php include.

The script is in one coded file. The user selects from the directory and the selection results in the page being submitted to itself. I built it as a form and the values needed for the second display are carried via hidden inputs in the form.

Each selection option is a select button through the following two lines of code -
$next_menu_url = "<input type='submit' class='btn' $mouseover value='$cat_name' name='B1'>";
$display_block{$actual_page} = $display_block{$actual_page}."<td ALIGN='CENTER'><font FACE='Small Fonts' SIZE='1'>$next_menu_url</font></td>";

Then the form starts with these lines

<form enctype="multipart/form-data" action"<?php print $PHP_SELF ?>" method="POST">
<input type="hidden" name="Action" value="SaveList">

and after the form is submitted to itself I check for the $Action vale with
}elseIf(isset($Action)){

That code is not picking up any value in $Action. if viewing the page with a include statement but is picked up if viewing the page through an Iframe.




Those values are carried fine in an IFrame but if I access the same page with php include the values aren't carried.

Perhaps it may make it clearer if I say the display page is created on website A (as a php script) from the db of site A. It is called from any number of remote websites (syndicate style). When called as an iframe it works fine if as a php include it doesn't.


I don't know if that is ennough info for anyone to know what the problem is.





olaf
Sun 25 March 2007, 10:38 am GMT +0200
include = server side
iframe = client side html

these are two different things and are not related to each other

RealEstateAdvertis
Mon 26 March 2007, 03:07 am GMT +0200
ahhh ok. Just like with java script and php. That explains it! There is no easy tweak then - I have to rewrite it for php. Thanks Olaf - you just saved me a useless debugging attempt.

Archive for SMF v1.00 by N.P. Valid XHTML 1.0 Transitional