I need help extracting the value of a specific parameter from a list of URLs.
Here are some examples:
http://example.com/#!/dp/dp.php?g=4346&h=fd34&kl=45fgh&bl=nmkh
http://example.com/#!/dp/dp.php?h=fd34&g=4346&kl=45fgh&bl=nmkh
http://example.com/#!/dp/dp.php?h=fd34&kl=45fgh&g=4346&bl=nmkh
http://example.com/#!/dp/dp.php?h=fd34&kl=45fgh&bl=nmkh&g=4346
I am looking to use JavaScript (regex) to extract the value associated with the g
parameter.
Any assistance on how to achieve this would be greatly appreciated!