Login   Register  
PHP Classes
elePHPant
Icontem

File: ifobtest.php

Recommend this page to a friend!
Stumble It! Stumble It! Bookmark in del.icio.us Bookmark in del.icio.us
  Classes of Michael A. Peters  >  CSP Filter  >  ifobtest.php  >  Download  
File: ifobtest.php
Role: Auxiliary script
Content type: text/plain
Description: Example iframe/object
Class: CSP Filter
Filter HTML based on Content Security Policy
Author: By
Last change:
Date: 2009-03-21 00:50
Size: 630 bytes
 

Contents

Class file image Download
<?php
if (isset($_GET['type'])) {
   
$foo strtolower($_GET['type']);
   } else {
   
$foo "iframe";
   }
if (
strcmp($foo,"object") == 0) {
   
$type "object";
   } else {
   
$type "iframe";
   }
?>
<html>
<head>
<title>foo</title></head>
<body>
<h1>This is an <?php echo(ucfirst($type));?></h1>
<p>
It looks like you are viewing this page via <a href="README.html" target="_top">README.html</a>, hence you see the contents of an <?php echo($type);?>. If viewing this page via <a href="index.php" target="_top">index.php</a> you should see the children of the <?php echo($type);?> node, not this paragraph.</p>
</body></html>