--- trunk/www/printable.php 2010/03/17 23:46:34 28
+++ trunk/www/printable.php 2010/09/20 18:49:07 131
@@ -6,48 +6,50 @@
";
+if (substr($curPage,0,14) == "printable.php?" ) {
+ //
+ // This means we have a printable.php?xxx.html URL
+ // let's get the xxx.html part
+ //
+ $pageUrlName = substr( $curPage,14,strlen($curPage) );
+ // echo "pageUrlName = $pageUrlName
";
+} else {
+ //
+ // trunk or demo are the local folders used to develop
+ // this file at my own private apache server
+ //
+ $pageUrlName=basename ($_SERVER['HTTP_REFERER']);
+ if ( $pageUrlName == 'clonezilla-sysresccd.hellug.gr' OR $pageUrlName == "localhost" OR $pageUrlName == "demo" OR $pageUrlName == "trunk" ) $pageUrlName='index.html';
+ $eReg="{#.*}";
+ $onlyURL=preg_replace($eReg,"",$pageUrlName);
+ // echo "pageUrlName = $pageUrlName
";
$thePage = getcwd() . '/' . basename ($_SERVER['HTTP_REFERER']);
- $thePage = getcwd() . '/' . $pageUrlName;
}
+$thePage = getcwd() . '/' . $pageUrlName;
+// echo "thePage = $thePage
";
-// echo "$thePage";
+// Read the file into $file
$file = file_get_contents ($thePage);
-$eReg="
" . $copr . "
" . $upd . "