Title: [Plugin: Twitter Search] Widget IDs
Last modified: August 20, 2016

---

# [Plugin: Twitter Search] Widget IDs

 *  [MikeNGarrett](https://wordpress.org/support/users/mikengarrett/)
 * (@mikengarrett)
 * [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-twitter-search-widget-ids/)
 * This is going to sound crazy.
 * I’m developing a rather large WordPress multisite that’s using Carrington Build.
   
   Twitter Search uses widget ids to cache the results. Carrington Build does all
   kinds of strange things to widgets. One of which is not setting unique ids for
   each widget (don’t ask me… something to do with magic).
 * SO! I’m proposing instead of using the widget id we use the query. I know I know.
   That’s crazy-pants. Hear me out.
 * Doing the query will make queries cross-site cache no matter where they show 
   up and in which widget. It will also solve my problems, but that’s a sideline
   issue.
 * To prevent crazy option names we can get all fancy and hash that shit.
    I’m proposing
   to change line 304 (and other instances of get_option/update_option) to: `$tempJSON
   = get_option(md5(utf8_encode("twitsearch_cache_{$query}")));`
 * Sound like fun?
 * [http://wordpress.org/extend/plugins/twitter-search-for-wp/](http://wordpress.org/extend/plugins/twitter-search-for-wp/)

The topic ‘[Plugin: Twitter Search] Widget IDs’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/twitter-search-for-wp.svg)
 * [Twitter Search](https://wordpress.org/plugins/twitter-search-for-wp/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/twitter-search-for-wp/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/twitter-search-for-wp/)
 * [Active Topics](https://wordpress.org/support/plugin/twitter-search-for-wp/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/twitter-search-for-wp/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/twitter-search-for-wp/reviews/)

## Tags

 * [widgets](https://wordpress.org/support/topic-tag/widgets/)

 * 0 replies
 * 1 participant
 * Last reply from: [MikeNGarrett](https://wordpress.org/support/users/mikengarrett/)
 * Last activity: [13 years, 8 months ago](https://wordpress.org/support/topic/plugin-twitter-search-widget-ids/)
 * Status: not resolved