jquery get search parameter
$.urlParam = function (name) {
var results = new RegExp('[\?&]' + name + '=([^&#]*)')
.exec(window.location.search);
return (results !== null) ? results[1] || 0 : false;
}
console.log($.urlParam('action')); //edit
Also in JavaScript:
- self invoking function javascript es6
- como criar uma modal jquery
- javascript loop nested object
- react merge two objects
- href javascript void
- check if value is a string javascript
- Array Helpers
- fetch api based on id nodejs and mongodb
- regular expression flags
- postfix date javascript
- javascript date get current date
- get an html img tag from a string
- jquery ajax
- jquery to hide a div
- hoisting in javascript
- jquery don't empty specific form field after submit
- js promiseStatus
- running scripts is disabled on this system react js
- p5js click on button
- send audio with socket io node js
- javascript get the last element of json
- angular build production
- alpinejs examples stackoverflow
- js object contain key