Home > Software engineering >  Using JQuery to get multiple pages from the same url
Using JQuery to get multiple pages from the same url

Time:02-10

Please help I am a very young padawan to javascript. I also haven't used any code in years. This just a snippet of the code but where I believe the problem is. Currently my code works but I noticed yesterday afternoon once the URL I am pulling from has a second page I lose all the data from the second page. How can I make sure that i pull the data from all pages?

function getTable() {
    var url = "https://mywebsite.com/data/mydatabase?a=API&token&datbaseid&jsa=1"
    if(typeof getTable.entries == 'undefined') {
        getTable.entries = 0;
    } 
    if (navigator.onLine) {
        //Retrieves array from database api at url defined above
        $.getScript(url, function() {
            if(qdb_numrows > 0) {   
                var hour = getHour();
                //Check for new entries
                if(getTable.entries == parseInt(qdb_numrows)) {

CodePudding user response:

  •  Tags:  
  • Related