OZONE Asylum
Forums
DHTML/Javascript
Drum roll - twenty liners rules discussion
This page's ID:
29904
Search
QuickChanges
Forums
FAQ
Archives
Register
Edit Post
Who can edit a post?
The poster and administrators may edit a post. The poster can only edit it for a short while after the initial post.
Your User Name:
Your Password:
Login Options:
Remember Me On This Computer
Your Text:
Insert Slimies »
Insert UBB Code »
Close
Last Tag
|
All Tags
UBB Help
Funny, I was going to bring up that chaining of function calls through the shortcut evaluation operators. Yes, I think we should only count it as one line, because it would be ridiculous to make so intricate rules that you actually prevent this atrocity from being counted as a single line while still making sensible one liners using the shortcut evaluators count as only one line. It opens up for some potential exploitation of the rules, yes, but I can't recall the rules dealing with it any better earlier. Anyway, I think there's some things that aren't worth detailing, where it's better to simply go by a case-by-case discussion. Another example is this:[code]var a=[null,'param1,param2,param3','alert(param1);alert(param2);alert(param3);return function(){return [param1,param2,param3];}'], s=Function.prototype.call.apply(Function,a)('This','is','madness!')().join(' ');[/code]It's a two liner, right? One line is an array initiator, one line is a complex series of function calls. If we really want to deal with that, we have to special case function calls like [b]eval[/b], [b]Function[/b], [b]setTimeout[/b], [b]setInterval[/b]. There's also numerous ways of getting the same effects using events, the DOM, URIs etc. -- var Liorean = { abode: "[sigrotate][url]http://liorean.web-graphics.com/[/url]|[url]http://codingforums.com/[/url]|[url]http://web-graphics.com/[/url][/sigrotate]", profile: "[url]http://codingforums.com/member.php?u=5798[/url]"};
Loading...
Options:
Enable Slimies
Enable Linkwords
« Backwards
—
Onwards »