Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Datatables pagination characters "<<" and "<" not displaying correctly in IE and Safari

I'm using the DataTables jQuery plugin and am having issues with the First and Previous pagination links displaying correctly in IE and Safari (Firefox and Opera work).

"<<" and "<" display as "<" and "".

$(document).ready(function () {
     oTable = $('#fileList').dataTable({
            "bJQueryUI": true,
            "sPaginationType": "full_numbers",
            "oLanguage": 
            {
                "sSearch": "Search all columns:",
                "oPaginate": 
                {
                    "sNext": '>',
                    "sLast": '>>',
                    "sFirst": '<<',
                    "sPrevious": '<'
                }
            }
});

I have attempted to escape '\<\<' to no avail.

Any ideas?

like image 576
Jaaromy Zierse Avatar asked May 14 '10 00:05

Jaaromy Zierse


2 Answers

Use the character entity references &lt; and &gt; for < and >respectively.

You might also want to know about &amp; too which is used to display &.

like image 60
Mark Byers Avatar answered Oct 22 '22 08:10

Mark Byers


These are the correct character entities to use in your case.

For < and > use &lt; and &gt;

For << and >> use &laquo; and &raquo;

like image 4
Brian Wigginton Avatar answered Oct 22 '22 08:10

Brian Wigginton