• Resolved abailey

    (@abailey)


    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; ….>

    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/

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