Modify action names for route collections in Symfony?

Posted by James Skidmore on Stack Overflow See other posts from Stack Overflow or by James Skidmore
Published on 2009-05-30T21:06:38Z Indexed on 2010/05/11 4:04 UTC
Read the original article Hit count: 315

Filed under:
|

When creating an sfPropelRouteCollection, how can I edit the action names that the collection will generate?

For example:

# Routing for "product" CRUD
product:
  class:              sfPropelRouteCollection
  options:
    model:            Product
    module:           product
    actions:          [new, create, edit, update, delete]

How can I change the actual action that is called for any of the new/create/edit/update/delete methods? I'd like for them to call "ajaxNew," "ajaxCreate," etc. so the URL would look something like "product/ajaxNew", or the action for "update" would be "ajaxUpdate".

Let me know if I need to clarify further. Thanks.

© Stack Overflow or respective owner

Related posts about php

Related posts about symfony