We use cookies to improve your experience. No personal information is gathered and we don't serve ads. Cookies Policy.

ExpressionEngine Logo ExpressionEngine
Features Pricing Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University
Log In or Sign Up
Log In Sign Up
ExpressionEngine Logo
Features Pro new Support Find A Developer
Partners Upgrades
Blog Add-Ons Learn
Docs Forums University Blog
  • Home
  • Forums

New extension: Tag Sync (for the Solspace Tag module)

Development and Programming

Derek Hogue's avatar
Derek Hogue
316 posts
15 years ago
Derek Hogue's avatar Derek Hogue

I love the Tag module, but the fact that EE search results don’t include Tag tags is always a pain. Using the Tag search results isn’t much of an option (who wants two separate sets of results?) I did come across a couple of options, but neither really fit the bill.

Tag Sync is an extension that works alongside the Solspace Tag module to automatically keep a custom text field synchronized with each entry’s tags, therefore making your tags searchable via the EE Search module.

Usage

After uploading and activating the extension, visit Tag Sync’s extension settings screen. For each relevant weblog, choose the custom text field you’d like tags synced to. (Make sure this custom field is searchable, and I’d suggest you keep it hidden by default.) Once saved, the chosen field will be updated with current Tag data whenever an entry is published or updated.

You can also run a full synchronization of tags to your custom field by using the link provided on the extension settings screen for each weblog. This is useful if you already have a bunch of tagged entries when you install the extension, and for periodic refreshes (i.e. when tags have been altered or merged using the Tag Manager, or if tags have been submitted via the public tag form, as these actions will not automatically update your custom fields).

(Note that if you have a whole tonne of entries in the weblog you’re syncing, this process could possibly timeout if you have a not-so-powerful server. I tested the sync process with a few hundred entries and it didn’t blink. I’d love to hear reports of successes or failures!)

Note that Tag Sync executes one-way synchronization. It will never interfere with the Tag module; it will only take data from the module and insert it into your custom field.

Tag Sync has been tested with ExpressionEngine 1.6.8.

Download it from GitHub

       
wecreateyou's avatar
wecreateyou
86 posts
15 years ago
wecreateyou's avatar wecreateyou

This is bananas D Rock, Thanks!

       
Derek Hogue's avatar
Derek Hogue
316 posts
15 years ago
Derek Hogue's avatar Derek Hogue

Just updated Tag Sync to version 1.0.1, which (thanks to some advice from Paul Burdick) is way more efficient, and uses batching for the full weblog/tag sync, so you shouldn’t have to worry when syncing even the largest weblogs.

       
Jarred's avatar
Jarred
14 posts
15 years ago
Jarred's avatar Jarred

Amazing, thank you.

       
Dylan Smith/Context Design's avatar
Dylan Smith/Context Design
346 posts
15 years ago
Dylan Smith/Context Design's avatar Dylan Smith/Context Design

Great idea - thanks!

       
mhulse's avatar
mhulse
329 posts
15 years ago
mhulse's avatar mhulse
Great idea - thanks!

This ROX! Thank you!!!!!

       
Danny T.'s avatar
Danny T.
426 posts
15 years ago
Danny T.'s avatar Danny T.

D-Rock,

I think this is a fantastic idea and is exactly what I need. I was wondering if you’ve any plans to make it synchronized the other way around as well from custom field into Solspace Tag? I like the function of Simple Tags, but like the added power of Solspace Tag, so hopefully this will help out quite a bit. =)

       
Derek Hogue's avatar
Derek Hogue
316 posts
15 years ago
Derek Hogue's avatar Derek Hogue

Hey Danny - glad this will work for you.

Tag already has the functionality you mention built-in, called “harvest”. http://www.solspace.com/docs/detail/tag_control_panel/#harvest

       
Danny T.'s avatar
Danny T.
426 posts
15 years ago
Danny T.'s avatar Danny T.

D-Rock,

Forgive me if I’m incorrect, but doesn’t harvest only allow one to batch process tags to input into Solspace Tag rather than it constantly monitor and sync automatically?

       
Derek Hogue's avatar
Derek Hogue
316 posts
15 years ago
Derek Hogue's avatar Derek Hogue

You are correct. I thought you were looking to migrate from Simple Tags? Not sure why you’d want to use a text field for tag input to the Tag module when there’s the Tag tab?

       
Danny T.'s avatar
Danny T.
426 posts
15 years ago
Danny T.'s avatar Danny T.

Thanks for the quick response D-Rock. I had the use because I was hoping to have SAEF users submit tags as well. Upon a second look though, it seems as though I can use a form field named “tag_f” to do what I’m looking for. Thanks!

       
Doug E's avatar
Doug E
98 posts
15 years ago
Doug E's avatar Doug E

Is there a way to have a list of tags show up in the advanced search options? I’d like to allow users to select what tags they want to include in their searches alongside the categories and other criteria.

       
Derek Hogue's avatar
Derek Hogue
316 posts
15 years ago
Derek Hogue's avatar Derek Hogue
Is there a way to have a list of tags show up in the advanced search options?

Not with this extension. You’d need to write a whole new search module, as the EE search module has no hooks.

A little birdie told me that Tag search will be coming to Solspace’s Super Search module at some point.

       
Doug E's avatar
Doug E
98 posts
15 years ago
Doug E's avatar Doug E

thanks, just installed and got it working in no time. Very simple and effective! Much appreciated.

       

Reply

Sign In To Reply

ExpressionEngine Home Features Pro Contact Version Support
Learn Docs University Forums
Resources Support Add-Ons Partners Blog
Privacy Terms Trademark Use License

Packet Tide owns and develops ExpressionEngine. © Packet Tide, All Rights Reserved.