?
Solved

Jquery Data table pagination not working ?

Posted on 2016-11-08
12
Medium Priority
?
611 Views
Last Modified: 2016-11-14
Hi Experts ,

We have used Jquery data table . Previously its working fine . But now Pagination has stopped working and no error on console and other things are working fine . Please see the attached screenshot . And i have checked the Table structure and placed the same table in another page is working . Any guess on this Experts


Thanks in Advance
0
Comment
Question by:karthik80c
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 6
  • 6
12 Comments
 
LVL 58

Expert Comment

by:Julian Hansen
ID: 41878365
No screenshot - no code - no link.

Strong are we with the force ... but not that strong.
0
 

Author Comment

by:karthik80c
ID: 41879966
oh sorry buddy . Please see the screenshot and below is the code for jquery table we have added


$(document).ready(function () {
            
            var item = document.getElementById('view');

            if (item != "undefined") {
                oTable = $('#view').DataTable({
                    'aoColumnDefs': [{
                        'bSortable': false,
                        'aTargets': [1] /* 1st one, start by the right */
                    }]
                });
            }
            
          

        });

Open in new window

Capture.PNG
0
 
LVL 58

Expert Comment

by:Julian Hansen
ID: 41881958
What is the problem - the table seems to render correctly - or are you unable to click through to other pages?
0
Get 15 Days FREE Full-Featured Trial

Benefit from a mission critical IT monitoring with Monitis Premium or get it FREE for your entry level monitoring needs.
-Over 200,000 users
-More than 300,000 websites monitored
-Used in 197 countries
-Recommended by 98% of users

 

Author Comment

by:karthik80c
ID: 41881959
Hi Julian

 table renders correctly . but the pagination not working and no errors on console
0
 
LVL 58

Expert Comment

by:Julian Hansen
ID: 41882029
When you say pagination is not working
a) Do the pages not change when you click the pagination buttons
b) The pages change but show the wrong data

Is there a link we can look at?
0
 

Author Comment

by:karthik80c
ID: 41883377
Sorry to reply u lately Julian .Yes Julian the page is not changing when we click the button and we don't have any link rite now . Its the dynamic table and i copy the same html generated from it and check with other html page and its working fine . Any clue on this Julian
0
 
LVL 58

Expert Comment

by:Julian Hansen
ID: 41883400
When you say dynamic - dynamic on the server or dynamic on the client?

Is the table being built dynamically on the client - if so it might be you are binding to the table before it is built.
0
 

Author Comment

by:karthik80c
ID: 41883457
Hi Julian ,

Its dynamic on server side  using asp.net
0
 
LVL 58

Accepted Solution

by:
Julian Hansen earned 2000 total points
ID: 41883487
Then I don't understand because from the browser perspective it is static. The browser has no way of knowing if content was generated by a script or a static page. When it arrives in the browser it is a static page irrespective of origin.

If you say the same html works in a static page then you need to compare the difference between that page and the generated html (view page source) on the broken page.
1
 

Author Comment

by:karthik80c
ID: 41883610
Ok Julian thanks for the help
0
 

Author Comment

by:karthik80c
ID: 41886064
Hi Julian ,

 i was tried with the Jquery table library with cdn link instead of local and pagination started working and thanks buddy
0
 
LVL 58

Expert Comment

by:Julian Hansen
ID: 41886106
You are welcome.
0

Featured Post

Why Off-Site Backups Are The Only Way To Go

You are probably backing up your data—but how and where? Ransomware is on the rise and there are variants that specifically target backups. Read on to discover why off-site is the way to go.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction A frequently asked question goes something like this:  "I am running a long process in the background and I want to alert my client when the process finishes.  How can I send a message to the browser?"  Unfortunately, the short answer…
Nothing in an HTTP request can be trusted, including HTTP headers and form data.  A form token is a tool that can be used to guard against request forgeries (CSRF).  This article shows an improved approach to form tokens, making it more difficult to…
The viewer will learn how to dynamically set the form action using jQuery.
The viewer will learn the basics of jQuery, including how to invoke it on a web page. Reference your jQuery libraries: (CODE) Include your new external js/jQuery file: (CODE) Write your first lines of code to setup your site for jQuery.: (CODE)
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question