Aria-label wrong with the new 2.14 version.

Aria-label wrong with the new 2.14 version.

DamianStolarekDamianStolarek Posts: 5Questions: 1Answers: 0

Hello,
I am very happy with the datatables plugin.
Now it's time to migrate my tables from 1.* to 2.* version. Most parts works fine now.
I found a problem with the aria-label here:

__ g.attr("aria-label", i ? o.ariaTitle + t.api.i18n("oAria.orderable" + l) : o.ariaTitle),__

In my case I get "Nameundefined" instead of "Name" as column name.
t.api.i18n("oAria.orderable" + l) is in my configuration undefined.

It's my 1.x datatables initialisation:

$(obj).find('table.dataTable').dataTable({
    "aaSorting": [[ 0, "asc" ]],
    "sPaginationType": "full_numbers",
    "aoColumns":[
        null,
        null,
        { "bSearchable": false, "bSortable": false },
        { "sType": "string" },
        null,
        { "bSearchable": false, "bSortable": false }
    ]
});

Any suggestions are welcome :-)
Best regards
Damian

Answers

  • allanallan Posts: 63,691Questions: 1Answers: 10,500 Site admin

    I'm not seeing that in this example which uses the configuration you posted.

    Can you link to a page or update my example to demonstrate the issue so I can patch DataTables if it needs to be?

    Thanks,
    Allan

  • DamianStolarekDamianStolarek Posts: 5Questions: 1Answers: 0

    Hello Allan,
    thank you very much for your fast response and the fantastic example. The problem was my language file.
    It has the old structure without:

    "oAria": {
    "orderable": ": Activate to sort",
    "orderableReverse": ": Activate to invert sorting",
    "orderableRemove": ": Activate to remove sorting",
    ....

    ariaType was after loading the language strings undefined.

    Now it works again :-)

    Thanks and have a nice day.
    Best regards
    Damian

  • allanallan Posts: 63,691Questions: 1Answers: 10,500 Site admin

    Hi Damian,

    Super - many thanks for letting me know.

    Allan

Sign In or Register to comment.