sfRequestPlugin - 1.0.1

Adds get/set Error functionality back into $request

You are currently browsing
the website for symfony 1

Visit the Symfony2 website


« Back to the Plugins Home

Signin


Forgot your password?
Create an account

Tools

Stats

advanced search
Information Readme Releases Changelog Contribute
Show source

sfRequestPlugin plugin (for Symfony 1.1)

The sfRequestPlugin adds the functionality for setting and retrieving errors in the request object, which was previously in Symfony 1.0 but removed in Symfony versions 1.1 and 1.2

Installation

  • Install the plugin

     $ symfony plugin:install sfRequestPlugin
    
  • Update your factories.yml

     all:
      request:
        class: sfHardenedWebRequest
        param:
          formats:
            txt:  text/plain
            js:   [application/javascript, application/x-javascript, text/javascript]
            css:  text/css
            json: [application/json, application/x-json]
            xml:  [text/xml, application/xml, application/x-xml]
            rdf:  application/rdf+xml
            atom: application/atom+xml
    
  • Clear your cache

     $ symfony cc
    

Usage

See the API documentation relating to errors within sfRequest here : http://www.symfony-project.org/api/1_0/sfRequest

TODO

  • test with Symfony 1.2
  • find a more elegant way of using sfWebRequest without having to include it within the bundle

NOTES

Please send comments, bug reports etc to lee at php.uk.com :)