| Author |
Message |
makama80 Hangin' Around

Joined: Feb 20, 2007 Posts: 32
|
Posted:
Sun Mar 18, 2007 10:18 am |
|
I am using the following IFRAME (code below) in my 8.0 site. Due to the known security issues I am porting to RN 2.10. But: the IFRAME code used in 8.0 does not work in RN 2.10. It produces a blank page. Also the code mentioned in the HOWTO on PHPNUKE.ORG does not work (anymore?)
Anybody any clues? I commented out the theme, for obvious reasons. It will also work without.
Here's my code:
| Code: |
<?
if (!eregi("modules.php", $_SERVER['PHP_SELF'])) {
die ("You can't access this file directly...");
}
if(!IsSet($mainfile)) { include ("mainfile.php"); }
$index=0;
//$theme="Helius";
$go_to_address1="http://www.actuelewaterdata.nl/cgi-bin/measurements/MUN1.Hm0?template=golfperfreqtemp";
$go_to_address=rawurldecode($go_to_address1);
include("header.php");
echo "<center><h3>Voor de wrakduikertjes onder ons:</h3></center>";
echo "<center><h4>De actuele golfhoogte bij de munitiestortplaats.</h4></center>";
// echo "<center><h4>Bron: Rijkswaterstaat</h4></center>";
echo "<!frame SRC=\"".$go_to_address."\" width=\"100%\" height=\"420\"
framespacing=0 frameborder=no border=0 scrolling=auto></!frame>";
//
//
//
$go_to_address2="http://www.actuelewaterdata.nl/cgi-bin/measurements/MUN1.Hmax?template=golfperfreqtemp";
$go_to_address=rawurldecode($go_to_address2);
echo "<!frame SRC=\"".$go_to_address."\" width=\"100%\" height=\"460\"
framespacing=0 frameborder=no border=0 scrolling=auto></!frame>";
//
OpenTable();
echo "<br><center>Gebruik van deze gegevens is voor eigen risico!</center><br>";
CloseTable();
include("footer.php");
die;
?>
|
|
|
|
|
 |
hitwalker Sells PC To Pay For Divorce

Joined: Posts: 5661
|
Posted:
Sun Mar 18, 2007 10:47 am |
|
then we leave it up to raven ...  |
|
|
|
 |
Raven Site Admin/Owner

Joined: Aug 27, 2002 Posts: 16987 Location: Kansas
|
Posted:
Sun Mar 18, 2007 11:28 am |
|
Note from Raven: I have inserted your code as requested. I modified the iframe tags to !frame to have NukeSentinel ignore it.
To all: For future reference, if you receive a scripting block and don't understand why, first of all, read what's on the screen that's displayed. It tells you the most common causes. Then, if that doesn't solve your issue, examine the /includes/nukesentinel.php code. Somewhere around line 276, depending on your version, you will see a // Check Filters comment. From line 276 down to line 343, again depending on your version, are most all of the word/code that we block. If the text you are tryin to post contain those words or tags you will need to alter them somehow as I have done with the iframe tags here. |
|
|
|
 |
makama80 Hangin' Around

Joined: Feb 20, 2007 Posts: 32
|
Posted:
Mon Mar 19, 2007 2:25 am |
|
Thanks for posting my code. I promise to do better reading in the future.
For now, I have resolved my problem by using this blank module:
I have inserted the code from the previous iframe module, and this is how it's working at the moment:
| Code: |
<?php
if (!stristr($_SERVER['SCRIPT_NAME'], "modules.php")) {
die ("You can't access this file directly...");
}
require_once("mainfile.php");
$module_name = basename(dirname(__FILE__));
$pagetitle = "- $module_name";
$index = 0; // 0 = No Right Blocks | 1 = Show Right Blocks!
include("header.php");
global $user;
if(!is_array($user)) {
$user_get = base64_decode($user);
$user_get = explode(":", $user_get);
$user_name = "$user_get[1]";
} else {
$user_name = $user[1];
}
OpenTable();
echo "<table width=\"100%\" border=\"0\" align=\"center\"><tr><td align=\"center\">";
$go_to_address1="http://www.actuelewaterdata.nl/cgi-bin/measurements/MUN1.Hm0?template=golfperfreqtemp";
$go_to_address=rawurldecode($go_to_address1);
echo "<center><h3>Voor de wrakduikertjes onder ons:</h3></center>";
echo "<center><h4>De actuele golfhoogte bij de munitiestortplaats.</h4></center>";
echo "<!frame SRC=\"".$go_to_address."\" width=\"100%\" height=\"420\"
framespacing=0 frameborder=no border=0 scrolling=auto></!frame>";
$go_to_address2="http://www.actuelewaterdata.nl/cgi-bin/measurements/MUN1.Hmax?template=golfperfreqtemp";
$go_to_address=rawurldecode($go_to_address2);
echo "<!frame SRC=\"".$go_to_address."\" width=\"100%\" height=\"460\"
framespacing=0 frameborder=no border=0 scrolling=auto></!frame>";
echo "</td></tr></table>";
CloseTable();
include("footer.php");
?>
|
Regards,
Martijn |
|
|
|
 |
Raven Site Admin/Owner

Joined: Aug 27, 2002 Posts: 16987 Location: Kansas
|
Posted:
Mon Mar 19, 2007 8:22 am |
|
Do you run PHP as an Apache module or as a stand alone CGI? |
|
|
|
 |
makama80 Hangin' Around

Joined: Feb 20, 2007 Posts: 32
|
Posted:
Tue Mar 20, 2007 3:10 pm |
|
I am running it as an Apache module. |
|
|
|
 |
Raven Site Admin/Owner

Joined: Aug 27, 2002 Posts: 16987 Location: Kansas
|
Posted:
Tue Mar 20, 2007 5:23 pm |
|
| klaafstra99 wrote: | | I am running it as an Apache module. |
You should not have that issue with running PHP as an Apache module. That should only occur if you were running it as CGI, unless you configuration is disallowing PHP_SELF which some do. |
|
|
|
 |
|
|
|
|