I am trying to validate a text string as a date before processing it, however both of the regex i have tried are throwing syntax errors and I can't see why. ... |
I'm staring blank on this error, so I hope someone here can point out where I go wrong.
This function should replace a parameter's value in a querystring with a new value:
function ...
|
I am working on a AJAX/PHP chatroom and am currently stuck on the regex to detect if a user has send a PM & then work out who it is too ... |
In javascript you can match regular expression with regex(string) syntax.
However the syntax isn't very used as far as I know, anybody know why?
|
I'm reading a js file at here, on the very top of this js file you can find the following lines:
var
gsAgent=navigator.userAgent.toLowerCase(),
gsAppVer=navigator.appVersion.toLowerCase(),
gsAppName=navigator.appName.toLowerCase(),
gbIsOpera=gsAgent.indexOf("opera")>-1,
gbIsKHTML=gsAgent.indexOf("khtml")>-1
||gsAgent.indexOf("konqueror")>-1||gsAgent.indexOf("applewebkit")>-1,
gbIsSafari=gsAgent.indexOf("applewebkit")>-1,
gbIsIE=(gsAgent.indexOf("compatible")>-1&&!gbIsOpera)
||gsAgent.indexOf("msie")>-1,
gbIsTT=gbIsIE?(gsAppVer.indexOf("tencenttraveler")!=-1?1:0):0,
gbIsFF=gsAgent.indexOf("gecko")>-1&&!gbIsKHTML,
gbIsNS=!gbIsIE&&!gbIsOpera&&!gbIsKHTML&&(gsAgent.indexOf("mozilla")==0)
&&(gsAppName=="netscape"),
gbIsAgentErr=!(gbIsOpera||gbIsKHTML||gbIsSafari||gbIsIE||gbIsTT
||gbIsFF||gbIsNS),
gbIsWin=gsAgent.inde
|
I have an input textbox that runs a js function on the keyup event to match for a valid string (domain name pattern match, the regex was found on here). ... |
I would like to extract the individual elements of a composite webkit transformation in Javascript. For example:
var act_transform = element.style.webkitTransform
gives me:
scale(0.6) translate(0px, 2236px) rotate(12deg)
What is good human readable, but terrible to ... |
|
John Resig wrote a nifty Class function, swanky. I'm trying to figure out what is going on, and have pretty much everything figured out except a single line:
fnTest = /xyz/.test(function () ...
|
I have created the following Regular Expression in C# to extract tokens from a string in the format {token}. I developed the regex in C# and confirmed that it works.
// c#
var ...
|
I have a regex that I'm trying use to validate against strings.
Trying to catch anything that is not: Upper Case alpha, Number, -, /, does not contain spaces and must be ... |
I have the following code as part of my email validation script. I'd like to learn more about the variable reg but don't know how to find relevant information because I ... |
Something very strange.
var body="Received: from ([195.000.000.0])\r\nReceived: from ([77.000.000.000]) by (6.0.000.000)"
var lastMath="";
var subExp = "[\\[\\(](\\d+\\.\\d+\\.\\d+\\.\\d+)[\\]\\)]"
var re = new RegExp("Received\\: from.*?"+subExp +".*", "mg");
var re1 = new RegExp(subExp , ...
|
I've got this regular expression for validating phone numbers
^(\+?|(\(\+?[0-9]{1,3}\))|)([ 0-9.//-]|\([ 0-9.//-]+\))+((x|X|((e|E)(x|X)(t|T)))([ 0-9.//-]|\([ 0-9.//-]+\)))?$
I dugged it out from my C#/vb library and now i want to translate it into javascript. But it ... |
I'm writing C# code to parse JavaScript into tokens, and my knowledge of JavaScript is not 100%.
One thing that threw me is that JavaScript regular expressions are not enclosed in quotes. ... |
So there have been plenty of questions, and filtering through a few, I still dont know how to go about this...
Pattern for:
- Alphabets ONLY, no case sensitivity, no limit on character count ...
|
I'll try to better explain myself ;-).
I'm using RegexBuddy to try to find the solution.
The target is JavaScript in a Konfabulator widget.
The string I need to parse is :
|
Can you explain the semantics of following regex? Especially, what ?: and () means?
/(?:^|:|,)(?:\s*\[)+/g
Thanks.
|
I have a variable patt with a dynamic numerical value
var patt = "%"+number+":";
What is the regex syntax for using it in the test() method?
I have been using this format
var patt=/testing/g;
var ...
|
|
|