Blog for web designers

Create an AJAX call

Simple jauery ajax call var eventsParam = { “url”: url, “data”: { limit: config.size, page: config.page++, }, “method”: “GET” }; $.ajax(eventsParam).done(function (res) { if(res.status == “success”) { console.log(res) } else { console.log(res) } }).error(function(err) {…Continue Reading

Compare identical array

How to compare identical array var userOrder = [“sort_one”,”sort_two”,”sort_three”,”sort_four”,”sort_five”]; var correctOrder = [“sort_one”,”sort_two”,”sort_three”,”sort_four”,”sort_five”]; function arraysEqual(arr1, arr2) { if(arr1.length !== arr2.length) return false; for(var i = arr1.length; i–;) { if(arr1[i] !== arr2[i]) return false; } return…Continue Reading

Update cordova android

How to update cordova android npm install -g cordova cd my_project cordova platform remove android cordova platform add android@7.1.0 To add it explicitly cordova platform add android@7.1.0 Reference link