skip to Main Content

How do I combine javascript variables into a object – Jquery ajax

I need to combine all variables in one object: $.get("https://www.virginmegastore.ae/en/gaming/playstation/playstation-games/sonic-forces---ps4/p/714792", function (data) { var productNamePost=$("[name='productNamePost']").val(); var productCodePost=$("[name='productCodePost']").val(); var bg = $('.pdp_image-carousel-image.js-zoomImage-mobile').css('background-image'); var productPrice=$(".price__container > .price__value > .price__number").text(); var url = window.location.href; console.log(url); }); Sorry the question was unclear,i was need…

VIEW QUESTION

how to filter json data for different key value and creating a new json element using that key values without hard coding data – Jquery ajax

<table> <tr> <th>Net Weight</th> <th>Net Weight Count</th> <th>Difference Average</th> </tr> <tr> <td>5</td> <td>20</td> <td>120</td> </tr> <tr> <td>3</td> <td>3</td> <td>30</td> </tr> <tr> <td>52</td> <td>1</td> <td>123</td> </tr> </table> I have a json data in which i want to filter these data according…

VIEW QUESTION
Back To Top
Search