Avatar of smfmetro10
smfmetro10
Flag for United States of America

asked on 

how do you check for two parameters with jquery

Hi,

I'm trying to check the url for either "ID_xxxxx" or "CON_ID_xxxxxx"

The "x" is either a five or six figure number

This is what I have so far. Thanks for the help!

<script type="text/javascript">
        $(document).ready(function () {
            if(window.location.href.indexOf("ID" || "CON") > -1)
            {
                 alert("found it");
            }
			
        });
    </script>

Open in new window

JavaScript

Avatar of undefined
Last Comment
smfmetro10

8/22/2022 - Mon