Pager = how do i disable the display of the text next/previous/first/last

Pager = how do i disable the display of the text next/previous/first/last

pingcrosbypingcrosby Posts: 29Questions: 4Answers: 1

I dont want any text to appear - just images for the pagination control

In the datatables settings object if I set first/last/previous/next to "" or null. And just use css to display images it displays nothing.

This is what I am trying to achieve..can you point me in the correct direction - am i doing this the correct way.

What i want to achieve

Datatables settings object :-

   pagingType: "full_numbers",
   language:  {
       paginate: {
           first: " ",
           last: " ",
           next: " ",
           previous: " "
       }
   },
       .paginate_button.next  {        
             background: rgba(0, 0, 0, 0) url("./next1.gif") no-repeat scroll right center;
        }
        .paginate_button.next.disabled  {        
             background: rgba(0, 0, 0, 0) url("./next0.gif") no-repeat scroll right center !important;
        }

        .paginate_button.first  {        
             background: rgba(0, 0, 0, 0) url("first1.gif") no-repeat scroll right center;
        }

        .paginate_button.first.disabled  {        
             background: rgba(0, 0, 0, 0) url("first0.gif") no-repeat scroll right center !important;
        }

        .paginate_button.last  {        
             background: rgba(0, 0, 0, 0) url("last1.gif") no-repeat scroll right center;
        }

        .paginate_button.last.disabled  {        
             background: rgba(0, 0, 0, 0) url("last0.gif") no-repeat scroll right center !important;
        }

       .paginate_button.previous  {          
             background: rgba(0, 0, 0, 0) url("prev1.gif") no-repeat scroll right center;
        }
   .paginate_button.previous.disabled  {          
         background: rgba(0, 0, 0, 0) url("prev0.gif") no-repeat scroll right center !important;
    }

Replies

  • tangerinetangerine Posts: 3,365Questions: 39Answers: 395

    Why choose the "full_numbers" option in the first place, if it's not what you want?

    Alternative pagination is available:
    http://datatables.net/examples/basic_init/alt_pagination.html

  • pingcrosbypingcrosby Posts: 29Questions: 4Answers: 1

    Unfortunately none of the options available are suitable.

    I picked that as it seemed the closest option to what i want

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

    There is actually a bug in DataTables if you set the language strings for the paging buttons to be an empty string. Try the 1.10.8-dev nightly which fixes that issue.

    Allan

This discussion has been closed.