• Resolved odotjulia

    (@odotjulia)


    Hello Tobias,

    when using your “TablePress Extension: Shortcode Filter from GET parameter” the search filter works perfectly fine when coming from another page via a URL like http://domain.com/?table_filter=SearchTerm.

    However, I have trouble with search terms that inlcude characters like – ä ö ü ß (basically German characters for terms like Rheinland-Pfalz or Thüringen). It seems that this post https://wordpress.org/support/topic/filter-table-through-url is helpful. Nevertheless, I must be doing something wrong, when trying to solve it for my purposes.

    Would it be possible to explain a bit further the change that needs to be done in your PHP Extension:
    $filter_term = preg_replace( '#[^a-z0-9]#i', '', $filter_term );

    Furthermore, I understood that the special characters needs to be changed like here http://www.w3schools.com/tags/ref_urlencode.asp from UTF-8. Maybe, it’s not working due to my incorrect PHP changes. However, it would be great, if you could also give an example for an according search term ( for example Thüringen = Th%26%C3%BC%3Bringen).

    I hope, I’m not asking too much and appreciate your support!

    Many thanks, Julia

    https://wordpress.org/plugins/tablepress/

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    thanks for your post, and sorry for the trouble.

    You are right, that line is too strict here. As a quick test, I suggest to simply comment it out, by adding // in front of it:

    // $filter_term = preg_replace( '#[^a-z0-9]#i', '', $filter_term );

    Regards,
    Tobias

    Thread Starter odotjulia

    (@odotjulia)

    Hi Tobias,

    no problem and thanks for your suggestion. However, commenting it out doesn’t do the trick. Actually, it doesn’t change anything. Might there be anything else I should try?

    Thanks for your support.

    Best regards
    Julia

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi Julia,

    can you then maybe play with adding a urldecode() for the filter term, like

    $filter_term = urldecode( $filter_term );

    ?

    Regards,
    Tobias

    Thread Starter odotjulia

    (@odotjulia)

    Hi Tobias,
    I need a bit more then a quick glance and will give you feedback next week. However, thanks already for the suggestion.
    Best, Julia

    Plugin Author Tobias Bäthge

    (@tobiasbg)

    Hi,

    no problem, you are very welcome! 🙂

    Best wishes,
    Tobias

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

The topic ‘URL encoding’ is closed to new replies.