0

I want to catch this 'id' on "update.html" file in variable which I could use. I am using "electron".

a.href = "user.js?id ="+ element.id;
Barmar
  • 669,327
  • 51
  • 454
  • 560
Sharjeel shahid
  • 117
  • 1
  • 1
  • 9

1 Answers1

0
<script>
    function getparams(url) {
        var queryString = url ? url.split('?')[1] : window.location.search.slice(1);
        var id = queryString.split('=')[1];
    }
    getparams();
</script>
M. Prokhorov
  • 3,697
  • 24
  • 35
Sharjeel shahid
  • 117
  • 1
  • 1
  • 9