EE 1
EE 2
Freebie
Developer
3rd Party (Free)
Download
Compatibility
- LG Addon Updater
- Multi Site Manager
- Stand Alone Entry Form
Requirements
- jQuery for the Control Panel
Tags
Take control of your URLs — define segments that you want EE to ignore completely. Use 'freebie' segments to trigger template behavior, build dynamic archives inside Structure, or just build special URLs for analytics purposes. Freebie allows you to use segments in powerful, flexible ways without the hassle of dealing with strict URL parsing (like Structure's).
Here’s a quick rundown of Freebie features — read the full docs over on Github. if you have any questions or have better ideas about documenting Freebie, email me or open an issue. Thanks!
Define segments you want EE to ignore
If you set “preview” as a Freebie segment, EE will parse blog/entry-5/preview as if it was just blog/entry-5
Access parsed or original segments
Example URI: /blog/preview/post-5/comments/
Example setting: “preview|comments”
{segment_1} will return “blog,” and {segment_2} will return “post-5”, because these are the ‘true’ segments EE is parsing.
{freebie_1} will return “blog”, but {freebie_2} wil return “preview” — these are the original segments, saved as freebie variables.
Set a ‘break’ segment
Example URI: /blog/2010/12/5/comments/
Example break: “blog”
EE will parse this uri as blog, and give you the remaining segments as freebie_x variables. This is super-useful in Structure, when you want to use extra segments to achieve certain behavior, but don’t want Structure to choke when it tries to find corresponding pages.
Ignore numeric segments
Not for the faint of heart! This setting tells EE to stop parsing all segments that are strictly numeric, like “12”, “2010”, etc. This will break a lot of dynamic weblog functionality (like archives), but give you the flexibility you need to rebuild the functionality yourself, or even use it inside Structure.
Break on category URL indicator
If you set this option, Freebie will automatically ignore your category URL indicator and any segments past it.
Match any segment
Want to trigger “print” behavior no matter WHERE the /print/ segment is added? The {exp:freebie:any name=“segment_name”} tag will return either “true” or “false” when it matches any segment with the supplied name. This allows you to throw useful segments on the end of all your URIs without worrying about their position.
Download Freebie
| EE Version | Downloads | Add-On Version | Release Date |
|---|---|---|---|
| 2.+ | Download |
Hooks Used
If the add-on is an extension, and ties into ExpressionEngine's core files, it will use ExpressionEngine hooks. We are listing any hooks the add-on uses for developers to have an easier time locating other add-ons that they can reference for their own work.
This entry was last updated November 16, 2011, 5:48 am.
Disclaimer: Information about ExpressionEngine add-ons is provided as a service to you, the user, and every member of the ExpressionEngine community. Devot:ee is not responsible if you hose, mangle, wreck, or otherwise destroy your EE website by installing an add-on that you found out about at this site, regardless of its rating, Favorites status, commercial or free status, or general popularity. Caveat EEmptor!


5 Reviews:
Tony Geer 05.15.11
Brilliant addon with lots of creative uses from a great developer.
One thing to note – this won’t work with the include method of removing index.php if you plan on using a freebie segment as your first segment in the URL, you’ll have to use the exclude method instead.
Ryan Battles 03.11.11
Great simple way to provide success messages for forms, and preview pages for entries using Structure. The two addons are inseparable.
Chuck Norton 11.02.10
This extension is so freaking powerful. 180 has essentially built a recent website around Structure/Freebie functionality.
Thanks for this Addon!!
Doug Avery 09.14.10
I talked with Chad and we concluded that yes, LowSeg2Cat won’t work with Freebie – the matched segments are actually being removed from EE’s internal segment array.
Instead, try using category_id with the {freebie_x} variables:
http://devot-ee.com/add-ons/categor
Chad Crowell 09.12.10
Note: This disables Low segcat in some situations. If you turn on “break on category indicator” so Structure won’t see the /category/blah segments, and try to use {segment_3_category_id} to get the cat_id of blah, it won’t work, that I can tell so far.