Title: microcoder's Replies | WordPress.org

---

# microcoder

  [  ](https://wordpress.org/support/users/microcoder/)

 *   [Profile](https://wordpress.org/support/users/microcoder/)
 *   [Topics Started](https://wordpress.org/support/users/microcoder/topics/)
 *   [Replies Created](https://wordpress.org/support/users/microcoder/replies/)
 *   [Reviews Written](https://wordpress.org/support/users/microcoder/reviews/)
 *   [Topics Replied To](https://wordpress.org/support/users/microcoder/replied-to/)
 *   [Engagements](https://wordpress.org/support/users/microcoder/engagements/)
 *   [Favorites](https://wordpress.org/support/users/microcoder/favorites/)

 Search replies:

## Forum Replies Created

Viewing 5 replies - 1 through 5 (of 5 total)

 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Search with Typesense] REST API updates not visible](https://wordpress.org/support/topic/rest-api-updates-not-visible/)
 *  Thread Starter [microcoder](https://wordpress.org/support/users/microcoder/)
 * (@microcoder)
 * [3 years, 1 month ago](https://wordpress.org/support/topic/rest-api-updates-not-visible/#post-16688628)
 * Actually I’m using Search with Typesense (not Typesense for WooCommerce).
 * I did not need the WooCommerce-functionality so I’m fine with this free plugin.
   Typesense for WooCommerce seemed unnecessary as my site is kind of custom and
   has no use of the WooCommerce-functionality (frontend) from the paid plugin.
 * But if my problem is solved in Typesense for WooCommerce, that could be interesting
   to start using the plugin.
 * After some investigation I found that my problems are the following:
    1. When I’m updating only the post image with the REST API the “wp_after_insert_post”
       is not triggered => no update in Typesense.
    2. When I’m creating a new post with the REST API => The post category is not found
       when I’m using the “cm_typesense_data_before_entry” hook. And because of that
       the post will not show up when I’m filtering on that category.
 * Maybe this is out of scope of this support as it’s kind of custom. I just wanted
   to check if someone had a similar problem and knew a solution.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Search with Typesense] “&” are displayed as “&”](https://wordpress.org/support/topic/are-displayed-as/)
 *  Thread Starter [microcoder](https://wordpress.org/support/users/microcoder/)
 * (@microcoder)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/are-displayed-as/#post-16546107)
 * Due to my previous reply I checked how this is handled in the plugin and found
   this:
 * _/includes/Main/TypesenseAPI.php:167_
 *     ```wp-block-code
       $category_names[] = html_entity_decode( $category->name );
       ```
   
 * That confirms my previous reply and is the reason why it renders properly for
   the default category data ($formatted_data[‘category’]).
 * Case closed.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Search with Typesense] “&” are displayed as “&”](https://wordpress.org/support/topic/are-displayed-as/)
 *  Thread Starter [microcoder](https://wordpress.org/support/users/microcoder/)
 * (@microcoder)
 * [3 years, 2 months ago](https://wordpress.org/support/topic/are-displayed-as/#post-16546087)
 * Thanks for the response [@digamberpradhan](https://wordpress.org/support/users/digamberpradhan/),
 * I did a fresh install with the standard theme to see if I got the same problem.
   I inserted a string “Foo & foo” into $formatted_data in the hook _cm\_typesense\
   _data\_before\_entry_ and it rendered properly.
 * I did some more investigation and found out that when I’m using get_the_terms()
   or get_the_title() the returning string is encoded. 
 * Because of that, I tried to run the _wp\_specialchars\_decode()_ function on 
   my resulting values, like:
 *     ```wp-block-code
       $formatted_data['custom_value'] = wp_specialchars_decode(get_the_title($d));
       ```
   
 * and then it works (proper rendering). Yay!
 * Thanks for helping me out.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Search with Typesense] “&” are displayed as “&”](https://wordpress.org/support/topic/are-displayed-as/)
 *  Thread Starter [microcoder](https://wordpress.org/support/users/microcoder/)
 * (@microcoder)
 * [3 years, 3 months ago](https://wordpress.org/support/topic/are-displayed-as/#post-16496878)
 * Update: 
   I realized I could run the post titles through the _.unescape() function(
   edit the template). Then the titles will be displayed correctly.
 * Now I just need to figure out how I can run the unescaping for the filter values.
 *   Forum: [Plugins](https://wordpress.org/support/forum/plugins-and-hacks/)
    In
   reply to: [[Search with Typesense] Possible to filter on facets?](https://wordpress.org/support/topic/possible-to-filter-on-facets/)
 *  Thread Starter [microcoder](https://wordpress.org/support/users/microcoder/)
 * (@microcoder)
 * [3 years, 4 months ago](https://wordpress.org/support/topic/possible-to-filter-on-facets/#post-16429976)
 * Hello [@digamberpradhan](https://wordpress.org/support/users/digamberpradhan/),
 * I wrote a script based on your code and it seems to work. 
   Thank you for the 
   code example and your explanation.
 * Thank you!

Viewing 5 replies - 1 through 5 (of 5 total)