Skip to content
This repository was archived by the owner on Aug 16, 2021. It is now read-only.

Releases: aeberdinelli/express-php

Less support

12 Apr 23:49
025f7d0

Choose a tag to compare

Now you can use Less instead of CSS if you want. An example:

use \Express\ExpressLess;

/**
 * Let's say you have a /less folder on your project
 * And you want every request that goes into /css to load the less file within that folder instead
 *
 * In this example /css/global.css will load the compiled version of /less/global.less
 * Same for /css/something.css -> /less/something.less
 */

$less = new ExpressLess($express, array(
	'source'	=> __DIR__.'/less',
	'dest'		=> '/css'
));

// Yes, it's that simple.

Cookies and QueryString support

16 Jul 23:13

Choose a tag to compare

New helpers for cookies:

  • $res->cookie($name, $value, $settings) - sets a cookie
  • $res->clearCookie($name) - removes a cookie
  • $req->cookies - gets the cookies

Querystring now supported:

  • $req->query - contains the querystring params

New helpers for redirections:

  • $res->location($url) - redirects using Location header
  • $res->redirect($url) - redirects using 302 http code
  • $res->redirect($url, true) - redirects using 301 (http permanent redirect code)

Also:

  • Added $res->download($path, $name) - forces the download of a file
  • Added $express->getInfo() - retrieves all the info from the current request
  • App locals now supported in object $express->locals

Added Mustache support

13 Jul 18:53

Choose a tag to compare

Merge pull request #3 from aeberdinelli/mustache-support

Mustache support

v1.0.1

13 Jul 15:48

Choose a tag to compare

Update README and clear repo

Composer ready

13 Jul 15:31

Choose a tag to compare

v1.0

Fix code in README.md