Title: Custom Attribute handler
Last modified: August 22, 2016

---

# Custom Attribute handler

 *  Resolved [abailey](https://wordpress.org/support/users/abailey/)
 * (@abailey)
 * [11 years, 1 month ago](https://wordpress.org/support/topic/custom-attribute-handler/)
 * When you encode the Custom Attributes from Event Manager you use.
 *     ```
       json_encode(
         iconv(
           mb_detect_encoding( $custom_att, mb_detect_order(), TRUE ),
             "UTF-8", $custom_att
       )
       ```
   
 * But I’m finding that this phrase
    `mb_detect_encoding( $custom_att, mb_detect_order(),
   TRUE )`
 * always return null. So it doesn’t work. If I just pass the string then the attribute
   data is there so somethings wrong in mb_detect.
 * I’ve confirmed the mb_detect_encoding function exists. According to the manual
   it should return a string or FALSE. Istead it returns null.
 * But on a more general note. Why don’t you add support for a second namespace 
   to expand the fields that can be included?? This is the standard way of extending
   XML.
 * For example I need to pass the “location_id” from event manager in the places
   section. I add a namespace.
 * <ess xmlns:nf=”[http://eventmangerpro.com&#8221](http://eventmangerpro.com&#8221);….
   >
 * And then I can add in <Places>
 * <nf:location_id>1234567</nf:location_id>
 * Strategic placement of filter hooks would make this easy to do.
 * [https://wordpress.org/plugins/events-manager-ess/](https://wordpress.org/plugins/events-manager-ess/)

The topic ‘Custom Attribute handler’ is closed to new replies.

 * ![](https://s.w.org/plugins/geopattern-icon/events-manager-ess_e0e0e1.svg)
 * [Events Manager ESS](https://wordpress.org/plugins/events-manager-ess/)
 * [Support Threads](https://wordpress.org/support/plugin/events-manager-ess/)
 * [Active Topics](https://wordpress.org/support/plugin/events-manager-ess/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/events-manager-ess/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/events-manager-ess/reviews/)

 * 0 replies
 * 1 participant
 * Last reply from: [abailey](https://wordpress.org/support/users/abailey/)
 * Last activity: [11 years, 1 month ago](https://wordpress.org/support/topic/custom-attribute-handler/)
 * Status: resolved