• Resolved Nobody777

    (@nobody777)


    Hello Tobias,

    I am experiencing challenges sorting columns in my table if the text in the cell contains a special character such as an ampersand.

    For example, I have my tablepress filter set to allow the user to sort the table by selecting a drop-down item for Office Name.

    http://paragon.pacmls.com/nrds-idx-user-and-office-codes/

    Here’s is the short code I am using for the page:

    [table id=1 datatables_tabletools=”true” datatables_columnfilterwidgets=”true” datatables_columnfilterwidgets_exclude_columns=”1,2,3,4,6,7,8″ /]

    Column 5 is the “Office Name”

    I can view any other office from the list, so long as there is no ampersand in the office name.

    Is there a way to fix this (without changing & to “and”)?

    Thanks,
    Dave

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author TobiasBg

    (@tobiasbg)

    Hi Dave,

    thanks for your question, and sorry for the trouble.

    I see what you mean. This is indeed a bug in the JS code of the ColumnFilterWidgets script. Unfortunatley, as this code was not developed by me, I’m not aware of a way to fix it 🙁
    The problem with ampersands is that they are encoded as & internally, and that causes problems here.
    I can only suggest to replace it for now 🙁

    Regards,
    Tobias

    Thread Starter Nobody777

    (@nobody777)

    Thanks my friend. I figured it was something like that. Appreciate your time and assistance. Have an awesome weekend!!!

    Plugin Author TobiasBg

    (@tobiasbg)

    Hi,

    sure, no problem! I hope that it will be fixed one day in the JS code.
    I will of course update the Extension then!

    Regards,
    Tobias

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Sorting Columns Containing Ampersands’ is closed to new replies.