Javascript examples for jQuery:Selector
Select string after a specific symbol in javascript/Jquery
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <script type="text/javascript" src="https://code.jquery.com/jquery-1.4.2.js"></script> <script type="text/javascript"> $(function(){/*from w w w.ja v a 2s . c o m*/ var haystack = "this is a @moo"; if (haystack.indexOf("@")) { console.log(haystack.substr(haystack.indexOf("@") + 1)); } }); </script> </head> <body> </body> </html>