I want to find out, how can i see if there's any character/string after a specific string part from a string. My question sounds ambiguous but here's my real example:
I can have 2 urls : http://domain/classAdd?itemId=1123123 or http://domain/classAdd?ItemId=
I want to put a condition in HTML regarding the url, to have specific header on my site. How can i check if the url has a itemId or not?
At moment i'm getting only :location.indexOf('classAdd?itemId=') == -1
I tried to verify the length but doesn't work. I searched a lot but i didn't find anything to answer my question, only how to get Specific string from a string. My Id is dynamic and the substring won't work
Thank you guys.