X-Git-Url: https://git.cweiske.de/phancap.git/blobdiff_plain/62875bdbecc633496c712bc2fc5e0ef8f54733e3..09ad15fd2ed08bbfb4ed4d70ff21f774387aa204:/www/index.php diff --git a/www/index.php b/www/index.php index 6eff33c..d2580be 100644 --- a/www/index.php +++ b/www/index.php @@ -1,4 +1,157 @@ + * @copyright 2014 Christian Weiske + * @license http://www.gnu.org/licenses/agpl.html GNU AGPL v3 + * @link http://cweiske.de/phancap.htm + */ +namespace phancap; +header('HTTP/1.0 500 Internal Server Error'); +if (file_exists(__DIR__ . '/../src/phancap/Autoloader.php')) { + include_once __DIR__ . '/../src/phancap/Autoloader.php'; + Autoloader::register(); +} else { + include_once 'phancap/Autoloader.php'; +} +header('HTTP/1.0 200 OK'); +$options = new Options(); +$config = new Config(); +try { + $config->load(); + $options->setConfig($config); +} catch (\Exception $e) { +} ?> + + + + + phancap + + + + + + + +
+
+
+
+ + + +
+
+

+ Web service to create website screenshots. +

+ +
+
+ +
+
Create screenshot
+
+ access === false) { ?> +
API is disabled
+ access !== true) { ?> +
API requires authentication
+ +
+
+ + +
+ +
+
+
+ +
+
+ + +

Tools

+ + + +

API

+

+ The API is accessible at get.php. +

+ +
+
+ Available URL parameters +
+ + + + + + + + + + +options as $name => $option) { + echo '' + . '' + . '' + . '' + . '' + . ''; +} +?> + +
NameDescriptionTypeDefault
' . $name . '' . htmlspecialchars($option['title']) . '' + . ( + is_array($option['type']) + ? ('One of: ' . implode(', ', $option['type']) . '') + : str_replace('skip', ' ', $option['type']) + ) + . ' ' . $option['default'] . '
+
+

+ Ages can be given as ISO 8601 duration specification, for example: +

+
+
P1Y
1 year
+
P2W
2 weeks
+
P1D
1 day
+
PT4H
4 hours
+
+ +
+
+
+ + + + +