/ Published in: JavaScript
Expand |
Embed | Plain Text
Copy this code and paste it in your HTML
function is_json(a) { if (!a || a.toString() === "") return !1; try { return $.parseJSON(a.toString()) } catch (b) { return !1 } } // Requires jQuery Library to parse json string.