|
|
This work is licensed under a Creative Commons |
PHP is a server-based technology, but it can also act as a client. Using additional packages, a PHP script can request information from other servers. Snoopy is such an example, it implements HTTP and allows users to request resources from Web servers. In addition, Snoopy supports a methods to access these resources. The goal of this lecture is to introduce Snoopy so that it can serve as a foundation for further experiments when implementing Web-based services.
$command = $saxon . ' dret.xml bibquery.xsl author=' . pass_string($formval_author) . ' format=html' ; system ($command) ;
localresources such as databases
glue, not as application platform
<?php
include "../a/3/Snoopy.class.php";
$snoopy = new Snoopy;
$snoopy->fetch("http://www.ischool.berkeley.edu/");
print $snoopy->results;
?>
<?php
include "../a/3/Snoopy.class.php";
$snoopy = new Snoopy;
$snoopy->fetchtext("http://www.ischool.berkeley.edu/");
print $snoopy->results;
?>
andor is not implementedquery?title=XSLT
query?title=Markup
query?fulltext=XDBMS
query?fulltext=xml+modeling
article, book, incollection, inproceedings, manual, misc, proceedings, report, thesisall selects all entry typesquery?type=book
query?type=thesis
start date for the lower bound of the queried entriesend date for the lower bound of the queried entries2006 specifies a year2006-09 specifies a year and a month2006-09-27 specifies a year and a month and a dayquery?end=1950
query?start=2006-09&end=2006-09