webiq / webiq.pagewize.client
Pagewize client; for theme development
Requires
- guzzlehttp/guzzle: ^6.1
- intervention/image: ^2.3
- intervention/imagecache: ^2.3
- smarty/smarty: ^v4.0.0
Requires (Dev)
None
Suggests
None
Provides
None
Conflicts
None
Replaces
None
README
This library can be used for those who develop Pagewize theme's.
Setup
The setup is quite simple:
- Download composer:
curl -sS https://getcomposer.org/installer | php - type
php composer.phar install, all dependencies are setup - Create a
config.phpfile in the root fo the directory, please checkoutconfig.sample.phpas sample
Getting started
Make sure you're web server maps all the requests to the index.php file in the root of the directory. We have attached a .htaccess file in the root
of the project. If you use nginx read the online documentation.
The PagewizeClient will always return the data for a homepage. This is the page that belongs to the / url. From any other request the $_SERVER['REQUEST_URI'] (slug) is passed to the client and will return the content that matches that slug.
Template files are stored in the /tpl folder.
Submit comments
To submit comments we recommend to point the form for submitting comments to the same url as the post. Use these variables as inut names: $_POST['name'], $_POST['email'], $_POST['comment'], $_POST['parentCommentId']. The post id is extracted from the $variables array that is filled when executing the request.