Sephr


Member since 01/16/2009

Name: Elijah Grey

Website: http://eligrey.com/

4 snippets

1298 profile views

3 Comment(s) Posted

View their favorites

Profile

Achievement

first submission:submitting first snipplet

Sephr's Recent Snippets



« Prev 1 Next »
Use this to extract an HTML5 origin from a URI. $1 is the origin. The square brackets are there to support IPv6 addresses. Example: var html5OriginRegex = /^([\w-]+:\/*\[?[\w\.:-]+\]?(?::\d+)?).*/; "http://www.google.com:42/foo/bar/...
0 457 posted 15 years ago by Sephr
ErrorConstructor produces error constructors that behave the same way as the seven native error constructors. Usage: `ErrorConstructor([constructorName])` *If no constructorName is specified, the default of `Error.prototype.name` is used* Us...
1 525 posted 15 years ago by Sephr
object.forEach ========= *Requires JavaScript 1.8* `void object.forEach(function callback(item, value)[, thisObject])`
0 539 posted 15 years ago by Sephr
Get Function Name ============ This will only return (a string) if the object passed to getFunctionName is a function or an "object" function from IE. The function does not rely on function.name if present as it can't always be trusted. Examp...
0 513 posted 15 years ago by Sephr
« Prev 1 Next »