cvs: pear /RDF/docs/examples custom_test.php
| From: | Lukas Smith | Date: | Tue, 24 May 2005 11:27:16 +0000 |
| Subject: | cvs: pear /RDF/docs/examples custom_test.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-32099@lists.php.net to get a copy of this message | ||
lsmith Tue May 24 07:27:16 2005 EDT
Modified files:
/pear/RDF/docs/examples custom_test.php
Log:
- lets be a good example and use SCRIPT_NAME when PHP_SELF is not needed
http://cvs.php.net/diff.php/pear/RDF/docs/examples/custom_test.php?r1=1.3&r2=1.4&ty=u
Index: pear/RDF/docs/examples/custom_test.php
diff -u pear/RDF/docs/examples/custom_test.php:1.3 pear/RDF/docs/examples/custom_test.php:1.4
--- pear/RDF/docs/examples/custom_test.php:1.3 Tue Dec 28 12:42:02 2004
+++ pear/RDF/docs/examples/custom_test.php Tue May 24 07:27:16 2005
@@ -46,7 +46,7 @@
if (!isset($_POST['submit']) OR (strlen($_POST['RDF']) > 10000)) {
?>
-<form method="post" action="<?php echo
$HTTP_SERVER_VARS['PHP_SELF'];
+<form method="post" action="<?php echo $_SERVER['SCRIPT_NAME'];
?>">
<p>This is an online demo of <a href="http://www.wiwiss.fu-berlin.de/suhl/bizer/rdfapi/index.html">RAP
- RDF API for PHP V0.8</a> . You can paste RDF code into the text field below and choose how
the data should be processed. It's possible to parse, serialize, reify and query the
data.</p>
<p>The size of your RDF code is limited to 10.000 characters, due to resource
restrictions.</p>
@@ -199,7 +199,7 @@
$parser =& new RDF_Parser();
$model =& $parser->generateModel($rdfInput);
// Set the base URI of the model
- $model->setBaseURI("http://www3.wiwiss.fu-berlin.de" .
$HTTP_SERVER_VARS['PHP_SELF'] . "/DemoModel#");
+ $model->setBaseURI("http://www3.wiwiss.fu-berlin.de" .
$_SERVER['SCRIPT_NAME'] . "/DemoModel#");
// Execute query on model if submitted
if ($_POST['query_subject'] != '' OR $_POST['query_predicate'] !=
'' OR $_POST['query_object'] != '') {
$comment_string = "<BR><H3>The following query has been
executed:</H3><BR>";
@@ -279,7 +279,7 @@
echo_string_with_linenumbers($model->toStringIncludingTriples());
} ;
- ?> <center><a href="<?php echo $HTTP_SERVER_VARS['PHP_SELF']
?>"><h2>Go back to input form.</h2></a></center><?php
+ ?> <center><a href="<?php echo $_SERVER['SCRIPT_NAME']
?>"><h2>Go back to input form.</h2></a></center><?php
} // end of "form submitted"
?>