Skip to content

mantas/acts_as_slugable

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is a slight modified copy of http://code.dunae.ca/acts_as_slugable/. It uses rails .parameterize instead of custom functions.

Installation:

./script/plugin install git://github.com/mantas/acts_as_slugable.git

Usage:

=== With scope

  class Page < ActiveRecord::Base
    acts_as_slugable :source_column => :title, :target_column => :url_slug, :scope => :parent
  end

=== Without scope

  class Post < ActiveRecord::Base
    acts_as_slugable :source_column => :title, :target_column => :url_slug
  end

== Credits

Parameterizing changed to Rails' parameterize by Mantas Masalskis (http://idev.lt), 2009 July

Created by Alex Dunae (http://dunae.ca/), 2006-07, though it takes a village to raise a plugin:

Thanks to Andrew White (http://pixeltrix.co.uk/) for fixing a conflict with <tt>acts_as_list</tt>.

Thanks to Philip Hallstrom (http://pjkh.com/) for pointing out some redundant code.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages