« first day (611 days earlier)      last day (4323 days later) » 

@Esailija can you help me with regex? :x
 
wut :P
 
I just want to get the string inside the brackets
some { string } heh just get "string"
 
can you give me example
ok
/\{\s*([^}]*?)\s*\}/ should do it
 
!!/regex "some { string }" {([\s\w]+)}
@Zirak { string }, ` string `
 
9:11 AM
@Imdad looks interesting, but I usually wait a few years until the critical mass can access it
 
!!> var re = /\{\s*([^}]*?)\s*\}/; re.exec( "some { string } heh");
ok why doesn't the bot do anything
 
!!> var re = /\{\s*([^}]*?)\s*\}/; re.exec( "some { string } heh");
 
One sec, tabs fucked
 
@Esailija [object Array] ["{ string }","string"]
 
9:14 AM
Well, I can't see anything I type, but it should run :P Also, there's already a command to do regex stuff
!!/help regex
 
@Zirak regex: No info is available
 
!!> var re = /\{\s*([^}]*?)\s*\}/; re.exec( "some { string baby: yeah; } heh");
 
@Zirak regex: Executes a regex against text input. /regex text regex [flags]
@FlorianMargaine ["{ string baby: yeah; }","string baby: yeah;"]
 
@FlorianMargaine [object Array] ["{ string baby: yeah; }","string baby: yeah;"]
 
ok, thanks
I'll never get the regexes -_-
new RegExp( '{\s*([^}]*?)\s*}' ) // is the same, right?
what's the [^}] for?
 
9:17 AM
matches not a }
[^abc] matches not an a, or a b, or a c
 
hi guys. I am javascript begginer and want to know what is good way of learning javascript. um.. actually.. what is good way of learning web technologies? i read one jsp book but only thing i can do is pathethic localhost8080.
 
@SehoLee bit.ly/jsnoob
@BillyMoon thanks
 
thx florian i will check this
 
use firefox, with firebug, do all the tutorials on w3schools, read about different frameworks, and try out a few framework libraries (jQuery, ExtJS, backboneJS)
 
w3schools is a bad resource
They make you to use setTimeout('string containing code')
and write PHP code with SQL injection holes
 
9:20 AM
however, I know of no other noob-friendly resource.
 
@ThiefMaster yes.. I'm proof to that. I don't know shit in JS.. All thanks to W3Schools
 
Ugh, people seriously flag "one sec, tabs fucked" as offensive?!
And one of the problems with W3s is that some people actually like them. A few guys from my university actively suggested it to learn for an XML exam. Even after being told how bad the site is "because it helped them pass the exam"
Actually, the XML part might be pretty ok (don't know that), but by recommending it other people might use the worse parts of it..
 
@ThiefMaster did you make the moderator-position or are elections still running?
 
Still running. Otherwise I wouldn't post about flags here.
But that one was displayed in the regular "vote on flag" queue in the chat.
(probably for 10k+ users, and the displayed flags are anonymous)
It's basically some kind of pre-filtering where you can choose if the flag is correct/wrong/dontknow. Probably saves the mods some work by filtering out flags that are not really helpful
 
@ThiefMaster I think that w3schools is a great introduction to complete newbies, who are not interested in nuances of the language (why not to use eval, variable scoping, double equals giving erratic comparisons) but are trying to get a feel for the language as although it is not comprehensive, it has a lot of content, and lots of nice try it yourself examples which allow you to jump right into the code
 
9:27 AM
agree ^
 
The problem is that those newbies are then going to write horrible code. And post code like this here on SO.
 
The problem is that those newbies don't know that, and think that that's the language.
 
Yeah.. actually that's one of the reasons why I suggest people to use jQuery as beginners. No matter what you think about it - when searching for jQuery code you weed out most of the IE3/NS4-compatible stuff people wrote 10 years ago.
 
@FlorianMargaine Seems like you are not the only one, I have not seen another suggestion in this thread yet...
 
jQuery is easy to understand compared to JS.. so yeah for a noob like myself jQuery is heaven..
 
9:35 AM
@ShyamK for many issues, jQuery spares you the pain of knowing about stuff you can happily live the rest of your life without, for example cross browser ajax functions. jQuery however, is still javascript, so having a better knowledge of javascript will naturally allow you to write better jQuery.
 
cross-browser ajax function is not really a PITA to write
that's like the easiest part of jquery :p
although they do more than that and allow deferred stuff (for example)
the worst part is rather about the DOM.
 
@BillyMoon for a noob jquery is enough.. then when he wants to grow.. learn more.. he will most definitely have to learn JS
jquery is mostly used to hide and show stuff.. get simple values.. mostly stuff like that (basically)..
by noobs (myself)
form validations and stuff too since there are already so many plugins(I don't know how else to describe them) that already available.. so just copy and implement
 
Anyone know any good tutorials for extjs?
does extjs have a future? what about jqgrid?
 
have you guys consider include jquery library in external javascript file? is it impossible include $.function in .js file?
 
9:49 AM
I know a good tutorial about extjs: don't use it
@SehoLee always include jquery from the google ajax cdn
 
haha..
 
seriously though
 
why? is it that bad?
 
I tried out extjs
it's cool and all, you get some nice code on one side
the generated code is horrible and really bloated though
it's usable if you want something app-only really app
like a desktop app that you use in the browser
 
@FlorianMargaine i am a bit busy now :3 :3 , i am with my gf :3 so i will answer that later :-D
and i know what hes asking for ^_^
 
9:52 AM
oh :p
have fun
and don't forget the condoms.
 
app only? hmm.. k then
@FlorianMargaine lol
 
what? it's true
 
@FlorianMargaine you used jqgrid? what is your review on it?
 
didn't use it
 
any idea whether its good or bad? from friends or associates maybe
 
9:59 AM
from what this room says, it's bad
but this room likes to reinvent the wheel, so I don't know
 
ya.. k. guess I'll ask somewhere else for a second opinion..
 
1
Q: How to remove Div elements in javascript using their id?

user1463324I only know their respective ids and don't know specifically about their parent nodes....Plz Help.

why jquery when there's no tag ;(
 
:-)
@FlorianMargaine i wont let her go through such pain , atleast this early :-)
@FlorianMargaine you wanted a community wiki about node.js , you got it (x
 
the node.js answer its gonna take a lil while to type the answer i am typing btw
 
10:11 AM
oh ^^
favoriting then :D
 
:-)
hes basically asked whut the heck is node.js and why the heck are there 3 libraries being used there :-)
 
yeah, he asked the workflow used
 
hell idk the exact workflow either :-| its just a confusion of lifetime :-/
btw thats the documentation of libev :-D
 
lol
assert (("sorry, no epoll, no sex"
 
Any opinions on codecademy.com as a good place to start learning javascript?
 
10:15 AM
it's okay
 
yeah codecademy is fun
 
Siri Mode :: You don't realise the best place to start learning javascript ? And keep this under your pillow while you learn javascript. or any other web-language https://developer.mozilla.org/en-US/
@BillyMoon
 
you get a feeling of the language, though the lessons can get boring pretty fast
 
fuck SO, my most upvoted answers are really easy... stackoverflow.com/users/851498/florian-margaine
 
LOL
codeacademy has a german version now
"Lerne zu codieren"
 
10:17 AM
stackoverflow.com/a/11080630/851498 one upvote for badge pls :D
@GNi33 atchum
 
i guess they translated it using google translator
 
you got two
 
@FlorianMargaine there you go
 
thanks
hm
no badge though :|
 
10:18 AM
if you dont want to use javascript because parent nodes then you should use jquery — shareef 13 mins ago
 
I thought there was one when you reached 10 upvotes on a question
 
what ?!!?!?!?!?!?!??!?!?!?!??!?!?!?!?!?!??!?!?!??!?!?!?!!??!!???????????????!!?!?!
 
depends on if you've been the first to answer
@Abhishek hahaha
 
@GNi33 I was
 
parentNode is so ugly, i'm just gonna insert a lot of code to keep it out
"mainly oracle and JSP"
hmmm...
@FlorianMargaine oh, he needs to accept it for your badge
 
10:21 AM
oh :-)
 
For justice!
0
A: Using indexOf method to find value in a 2D array

Florian MargaineUse some iterator function. Modern browsers way: var arr = array.filter( function( el ) { return !!~el.indexOf( 56 ); } ); console.log( arr ); // [3, 56] console.log( arr[ 0 ] ); // "3" Legacy browsers way, using jQuery: var arr = $.filter( array, function() { return !!~$.inArray( 56...

 
oh, okay
 
ah, took a while :)
 
10:34 AM
just to know whether my answer has some obvious drawback I'm not seeing :|
 
btw
 
@Abhishek waiting for your answer ffs
 
i am typing and putting all what i have read about node in there
 
btw how do we look :-/ //her question..
lol
 
10:41 AM
fine fine :D
 
she looks fine, you look ugly
:D
j/k :p
 
i am ugly :D
 
hah, you should see me
there's a reason for my stupid avatar :P
 
yeah, there's a reason why I have mine too
I'm just so beautiful
2
....
:p
 
haha :D
good self esteem is important ;)
 
10:47 AM
Florian looks good enough to be miss universe ;-) ;-)
@Abhishek @GNi33 i wish u can star
 
:P
 
o/
@FlorianMargaine i hope you don't mind bro :-(
 
11:17 AM
i hate bugfixing
 
Florain felt bad :-/
 
hhh
11:44 AM
I hope you finish this here because your answer contains at least one error [1]. I am trying to debug it, xhr.send(...) needs a string not object.

[1] http://stackoverflow.com/a/11078935/164148
(I get DOM 11 error when executing it in the browser apparently coming before the point)
Yes it comes with the lines:

var xhr = new XMLHttpRequest();
xhr.setRequestHeader( 'Content-Type', 'application/json' );
-
Earlier I tried to add the Documention here about XMLHttpRequest but for some reason someone cancelled the edit. There is something wrong.
XMLHttpRequest() is undefined, no idea what it should be -- anyway still investigating...
 
can you make a client side "login with twitter" button like you can with facebook?
 
@Esailija o/
 
apparently not
:x
 
why not? i've already seen a lot of those
 
with facebook, they give you the connect.js and pretty much handle everything
so you just add the button and add event listener when someone logs in and get their id
with twitter you apparently need to make server side code plus the login screens error handling etc etc sigh
 
12:01 PM
@Abhishek nah, I just went to eat :p I don't mind
 
oh, okay
 
I hate SO not letting me post the answer says invalid domain :-|
0
A: Nodejs Event Loop

Abhishek@Tamil i have been personally reading the source code node.js & v8 , I went into similar problem like you when i attempted to understand node.js architecture in order to write native modules. What i am posting here is my understanding of node.js and this might be a bit off track aswell . L...

Not very polished but with a beautiful distraction i couldnt think much now can i ?
 
@Abhishek mind if I correct grammar/spelling mistakes?
some parts are hard to understand :|
 
sure bro
my grammer sucks
 
how is your english grammar florian
 
12:05 PM
@Esailija quite good when writing down stuff
 
I will write more on that
 
@Abhishek: In (1) you are talking about libev but called it libuv
 
@ThiefMaster nope
libev , libuv , libeio are 3 different librarires
 
Yes, I realize that.
Check your answer again.
 
libeio+libev+libares = (libuv)80%
 
12:06 PM
> Libuv is the event Loop which actually runs interally in node.js to perform simple event loop operations its written originally for *nix systems.What lib uv performs under them is provide a simple yet optimized event loop for the process to run on. You can read more about libev here.
 
oh (x
 
such a brilliant naming scheme
 
edited
@Esailija oh you havent seen worse
fixed
and added another video
 
@Abhishek in the first one too : Libev is .... What Lib uv performs...
 
what is so complicated about event loop
why is there so much shit about it
 
12:19 PM
@Esailija try implementing one in C++
you will know
 
does LibreOffice offer any kinda scripting support like Excel has VB?
 
@rlemon yes
 
idk
 
can't remember what it is though, but I used it once
@Abhishek hope you don't mind my edits :p
 
@FlorianMargaine can a lil brother mind an elder brother fixing his errors ?
nope
 
12:22 PM
nah, I mean, I didn't change anything meaningful?
especially this paragraph
> Basically what happens inside the node.js is that v8 loop runs and handles all javascript parts as well as C++ modules [ when they are running in a main thread ( as per official documentation node.js itself is single threaded) ].....
 
when I launch node the process uses 4-7 threads
 
nice question
 
@FlorianMargaine as per official docs a node.js instance runs on a single thread
all tasks help in 1 single thread
while thread-loops occur to perform async task. even i dont understand if that happens why they call it single threaded
but as per docs its single threaded
 
12:31 PM
LOL someone edited his clarfying code away
 
how to change the history? OP added some code, and this guy just removed it and totally changed the question's title
 
hey... i'm a little new to javascript but i need to build this demo page for a client.. its gotta have a feature where you can search for something and it queries the database for near matches.. when you press search, the form is replaced with a loading gif what then loads a <select> with all the results after... once the user selects their result it loads it to another form and the load form is meant to reset, but when you search again it searches for the first search not the last one..
i think its an issue with dynamically placing <inputs> and then reading their value but i don't know a walk around
is it something fairly simple to change or shall i post a question on SA
SO* thanks :)
 
did you send to correct no-cache headers on the server?
 
ahh nope.. let me just check what the code gets at the other end just before the request.. that'll determine wether its a fault at the request or not
thanks
nahh its not that, i think it'll be best if i post a question
thanks for your help though
 
Ali
12:49 PM
heyyyyyyyyyyyyyyy , am back :D
does anyone knows about CredentialCache
more like

request.Credentials = CredentialCache.DefaultCredentials;
 
RT @p01: http://my.opera.com/dragonfly/blog/full-of-resources first iteration of my work on Resource Inspector landed in the Experimental build of Opera Dragonfly
RT @janodvarko: Automate Page Load Performance Testing with Firebug and Selenium! http://bit.ly/LnxnId
 
Ali
what :O
 
500 rank :-)
i would like to thank my mum , dad , uncle , aunt , dog , my first keyboard , my monitor , cpu(s) { Celeron D, Pentium IV , Intel i5 , Amd Althon X2 } , and most importanty @FlorianMargaine my brother :D :D
 
@Ali What makes you think anybody in the JavaScript room would know about System.Net.CredentialsCache?
2
 
:LOL:
@RyanKinal good point bro.
@Ali try C# or .net rooms you may get response there
 
1:00 PM
I thought it was for CORS :/
 
Ali
@RyanKinal its related to authentication so i thought you guys or any of you must been through it
 
@FlorianMargaine what pal ?
 
Ali
and I tried that rooms, they are dead as deadtown :/
 
@Ali you know we know it but not in .net , and ask out on stackoverflow.com
form the question as

"Where to find tutorials of credentials cache / how to best use credential cachee"
 
Ali
@Abhishek I tried looking at google, but hate explanations in formal language :/
 
1:06 PM
@Ali so try to start loving them nobody loves formal language but it needs to be there
i mean try this code
 
Ali
I got all the code, I just dont know what it means, even tho its doing what its suppose to do
 
 var a = new (function(){
                    var foo = 'a';
                    this.getFoo(){
                          return foo;
                    }
    })();
 
the parentheses aren't necessary
 
!!> Array(6).join("Bum ") + " I'm loving it!";
McJavascript
 
1:17 PM
10² - 10² === ( 10 + 10 ) ( 10 - 10 ) ?!
 
since when is 10² === 10+10...
oh florian was faster :D
 
lol
 
0
Q: Automatically login to site

ShansalI want to be able to log in to a site automatically. For that purpose, i save a copy of login page of that site. Then i enter passsword and user name on this copy in advance. There is a login button on this page. So normally, after typing user name and password, i need to click this button to go ...

 
Horribly Written code of the day!
function filter_list(list) {
	var ret = [];
	list.forEach(function(row){
		if( row[1] !== null && ( row[6] || row[7] || row[8] || row[9] || row[10] ) ) {
			ret.push(row);
		}
	});
	return ret;
}

var tbl = document.getElementById('tbl'),
	thead = tbl.getElementsByTagName('thead')[0],
	tbody = tbl.getElementsByTagName('tbody')[0],
	data = filter_list(list);

	var headers = data.shift(),
		hels = document.createDocumentFragment();
	headers.forEach(function(cell) {
		var th = document.createElement('th');
 
@rlemon I think we've seen more horrible
 
1:23 PM
@Zirak his picture kinda looks like Florian
@DieVarDump but it's likely the most horrible code I will write today
 
@rlemon totally, I thought it was one of my answers
but I answer test related questions instead :p stackoverflow.com/a/11083859/851498
 
@rlemon You can do worse. Just try
 
Accountant: "Hey, I have this export and I want to print it as a table"
Me: "Use Excel, it's already a CSV file"
Accountant: "But I want <list of reasonable but totally pointless criteria>"
Me: "You can do that in Excel"
Accountant: "But I don't know how, can you!"
Me: "FFS I don't have excel..... but Excel does c and p HTML tables nice... Idea!"
 
Ali
I am the accountant
 
I am Gog
 
1:28 PM
I am tired
What's Gog ?
 
so ppl now get upvotes for just fucking copypasting OP's code?
1
A: php oops constructor : unexpected behaviour

VettelSYou're using the wrong class name? $jobName = 'Dummy Job'; $obj_pi = new A($jobName);

SIGH
fuck me
also, pls don't flag for language ^^
 
Gog and Magog ( Gog u-Magog; ') are names that appear primarily in various Jewish, Christian and Muslim scriptures, as well as numerous subsequent references in other works. Their context can be either genealogical (as Magog in Genesis 10:2) or eschatological and apocalyptic, as in Ezekiel and Revelation. They are sometimes individuals, sometimes peoples, and sometimes geographic regions. The passages from Ezekiel and Revelation in particular have attracted attention due to their prophetic descriptions of conflicts said to occur near the "End times". Etymology The etymology of both the ...
 
since when it's an acceptable answer to say "Your code is fine" :X
also lol at everyone wondering who downvoted
would he get that error if he was calling a non-existing class? sigh Downvote rampage incoming — Esailija 25 mins ago
 
You're too nervous today
 
yes, I'm filled with rage
 
1:37 PM
Have a break
Have a kitkat
 
I tested your code and it works fine as is... see here Please if there are still errors on your end post more code or a complete example. All of the answers saying this should be comments guys, this is clearly only part of the issue so your answers are pointless!rlemon 9 secs ago
 
it's like some question where the code in the question is missing a ", but the OP says the code does this and that, then you get 6 answers that you are missing a " but the code wouldn't even run if that was the case
 
@Esailija problem is why are there like 5 answers saying "your code is fine" when the obvious situation here is there is something else wrong we need to help the OP figure out.
 
yeah ask for clarification or close vote
 
like every answer to that question should have been a comment.
if that
 
1:42 PM
f***
is it possible to store in my git console my github username ?
 
lavishbootstrap.com that is kinda cool
 
heloooooooo geeeeeeeeeeeeeks
 
yes it is
 
who hates jquery like me ?????????
 
interesting, you love pure javascript but use .NET
good bye
 
1:49 PM
do you hate it because it is currently out performing your own js framework/library?
I see that a lot..
now we can all look like facebook instead of twitter! \o/
 
is that a joke
also I would believe there has to be some kind of copyright issue
 
I'm actually thinking of using it :P make your fb apps look nice in fb itself.
I can fb my fb while looking at my fb from within my fb like fb app .... built with fb bootstrap.
 
don't worry, be appy
 
0
Q: Can this javascript with jquery be improved?

Tom JenkinsonI recently started learning jquery and javascript and put this together for the site I work on here. /* * Manages the error report popups * * written by Tom Jenkinson */ jQuery(document).ready(function($) { var bottomTableReport = { timer: null, init: function() {...

 
1:59 PM
oh dear god
 

« first day (611 days earlier)      last day (4323 days later) »