« first day (872 days earlier)      last day (4300 days later) » 

15:00
@R.MartinhoFernandes We have the same lambdas. With explicit import of locals that it
@rdlowrey Is use for capturing locals for closures?
user895378
@R.MartinhoFernandes yes.
@R.MartinhoFernandes btw, does C++ do this binding for the lambas?
Yes. [varFromCurrentScope]() { ... }.
Or [&varFromCurrentScope]() { ... } for capturing by reference.
user895378
Also, as of PHP5.4 the $this variable is automatically bound inside closures so you can do ...
user895378
15:01
function() { $this->foo(); }
user895378
Which is helpful if you want to be lazy and not spend years creating the perfect interface ... you can just pass around closures to provide specific, directed access to otherwise private/protected object functionality.
function() use ($this as $that) { } =D=D
You need to [this] to bind this in C++.
The most effective stances to take when dealing with a democratic system (SE) is to strike and protest. We should rally up as many people to strike as possible until they increase the vote limit to at least 100. But that's just me being crazy.
user895378
@Jack Except you still can't access non-public members and methods with that (prior to 5.4, I mean)
15:03
@Jack happy that didn't make it in ^^
But the biggest annoyance is that you don't get any type deduction whatsoever.
@NikiC Yeah, that would have been fun a walking disaster.
@R.MartinhoFernandes and from what I understood that was just an erring on the behalf of the committee?
@ircmaxell c'mon, admit it ... you just know everyone wants that syntax :)
15:05
/me doesn't
@crypticツ I'm up for that
The further we get from true closures, the more I will dislike it
Or at least I remember something about them not having type deduction because it interferes with concepts but it turned out that it didn't after all. Was there something like that?
Fatal error: Cannot redeclare colour_sku() (previously declared in /domains/x/http/SizeCalc.php:531) in /domains/x/http/SizeCalc.php on line 531
anyone ever gotten this?
@Jimbo yeah two people!! =oD
15:06
@NikiC Oh, I wouldn't call it "erring". It was mostly about caution. There is another big feature they want to introduce (concepts), and superb lambdas kind of interfered with those, so they included what could be included safely, instead of tying their hands forever.
@NikiC Yeah, that's it.
@Hiroto Nope, I never use colour_sku() :)
it's my function
@Hiroto Fatal error: unknown noun "colour". Did you mean "color"?
2
@crypticツ I might as well help then!
user895378
lol
15:07
oh you
@R.MartinhoFernandes so will you get the type deduction in 14?
I am not entirely sure. I mean, it's 2013 already...
yeah, time's going fast ^^
After the next meeting (April, I guess) we'll have a better picture of what we get or not.
And today is the 6th...
15:08
@NikiC: you should have been in Sara's HipHop talk. Really was quite good...
user895378
Plus the C++ conclave still has to address the business of electing a new Pope ... so much to do ...
That means I can close the non-scalar RFC and merge the patch :)
@ircmaxell what was it about?
@rdlowrey Wait, Bjarne is dead?
:)
user895378
15:09
hehe
@NikiC HipHop
@ircmaxell and is there a vid / slides?
:-P
haven't seen slides
@ircmaxell yeah I got that much ^^ I mean what in particular
HipHop is that PHP-to-C++ thing they use at Facebook?
15:10
like was it about implementation or usage or whatever?
Or am I misremembering?
@R.MartinhoFernandes yes
@R.MartinhoFernandes no
Ok, confused now.
15:10
HipHop used to be a PHP-C++ cross-compiler type thing
hasn't been for over a year
hasn't been?
now it's a dedicated VM with a tracing JIT compiler
Ok. What is it now, then?
@ircmaxell Ah, ok, thanks.
@ircmaxell btw, do they have 5.3 support by now?
This error is definitely trolling me
15:12
@NikiC partially
i'm getting "cannot redeclare" on any function i define now
they are working on namespaces and other parts
@ircmaxell 5.3 as in namespaces
@Hiroto double-include
They are working on parity this year
not even including it, maxwell
i'm hunting, now
user895378
15:13
Is it just me or is it terrifying that the facebook codebase has been written essentially in < 5.3 for all these years?
user895378
That sounds awful.
There was something before 5.3?
@ircmaxell ahh, i moved a brace
'twas in this horrible horrible while loop the last guy made
user895378
Apparently anything you write in < 5.3 has no choice but to become an evil self-contained thing that murders privacy.
refactoring, ho!
15:15
@rdlowrey That's probably exactly what my boss would want >:D
I have updated this jsfiddle 427 times! jsfiddle.net/L8su2/427
in Das Lounge<C++>, 35 secs ago, by Scott W
ready to strike on the PHP room...
@rdlowrey that sounds aweful? what about the fact that it's mostly a procedural codebase
user895378
Oh my.
@Jack They are "dont care" guys.
15:19
@Jack Sigh.
@NikiC Oh, and apparently, based on their tests, 5.4 cuts down hiphops advantage by a factor of 2... as in from 500% faster to 250% faster...
@R.MartinhoFernandes Hmm? :)
@Hiroto you included the file twice
@ircmaxell yeah, hiphop is pretty slow
In PHP one should be able to get much better numbers. Like 10x faster or more
Guys .. 1 question related to jQuery. I have some element inside multiple levels of divs. And I need to add an overlay over the body and show only that div as focused. I can't seem to pull this of. I can't copy that div because it has binds and ID's and I can't move it outside because other elements position are based on it ?
15:21
I mean, we even give the compiler a lot of type information
Could be made to good use
@Jasper I didnt; i already solved it
@NikiC I was talking to her about PHPPHP (she brought it up during her talk), and I mentioned adding a JIT compiler into it and adding an extension to execute machine code directly, and she basically said "yeah......"
@ircmaxell i agree with the "yeah......"
but but but it's native code....
:)
15:24
:-D
alright, bottle of wine done im going to bed.
Goodnifgt SO.
user895378
bed? lol later.
@ircmaxell Read about the PHP name and how the license governs it yesterday (because some - I think it was @Lusitanian - brought it up here) and just now I realize that PHPPHP may actually not be a name you can use for it...
SCREW YOU APTITUDE
apt-get install vim
no install candidate for vim
vim
try apt-get install vim
@Jasper
try yum install vim =D
@Jack I wish...
@Jasper nope
@ircmaxell It's the name that makes sense and I don't think anyone will really mind, but the license does prohibit using PHP in the name of a derived product
just suppressed the errors
PHPPHP is not derived from PHP, as such it can use the name
15:36
Ah, the only reason I installed ubuntu: sudo apt-get install hiphop-php
What you can't do for example is fork PHP, add some stuff and the release it as "PHP-next" or something :)
How about PHP++? .... awwww ;(
@NikiC cool idea, wait. someone already did it
@Gordon Cool. Let's sue him :P
@NikiC But can a php developer create a php clone without it being derived product?
15:38
@Jasper Yes, why not? I understand "derived" to mean derived from the source code
@iroegbu How is that javascript?
@NikiC exactly, considering a court ruling has said that APIs are not subject to copyrightability
random fun fact. I am currently butt naked wearing nothing but a FIG … proposal printed on a sheet of paper
but obv IANAL so I can't say for certain what it means
@NikiC dont say IANAL when I am butt naked
15:41
@Gordon I would suggest using FIG proposals for wiping your butt instead ;)
@dragon112 sorry, about that
@Gordon Stop saying you're butt naked when you're butt naked.
it's not
I did that yesterday, just updated it
btw, morning
15:42
@NikiC If I'm not mistaken, you don't need to actually copy the source to make a derived work. As such, if one's intricate knowledge of the php source code influences the development of a php copy enough, it is a derived work. This would be similar to making a film adaptation of a book (as I see it)
@Jasper You got a point there
Is there any app like this one: stackapps.com/questions/3081/… that can notify me about new questions in selected tags?
Just wanted to point out that that if this ever gets to court, I'm afraid @ircmaxell's case wouldn't hold up (and so getting permission from [email protected] might be a smart thing to do). That said, IANAL as well and I don't think it will ever get to court.

Lounge<C++>

Today we're daydreaming about C++26 reflection
"Dies ist eine Kriegserklärung gegen PHP!" => "This is a declaration of war against PHP!" :)
:O
15:46
@Hast Yes, its called RSS feed :)
@NikiC we'll eat their CPU cycles and make them slow as hell
lol
@Ocramius Well we do that anyway...
@dragon112 we do that with C, not C++ :\
@Ocramius You do have a point there..
15:48
@Ocramius That's why we're all going to run HipHop now and then we can do that with C++ instead of C :D
Anyone using sonar in here? Zis thing is driving me mad...
@Jasper HUH? why wouldn't it hold up?
@ircmaxell Because it gets really icky when it gets to be about proving whether or not your knowledge of PHP influenced the design of PHPPHP enough to be a derived work. And since you are one of the developers of PHP and PHPPHP is a PHP clone (be it one written in PHP) you are at a disadvantage
15:53
@Gordon :D
I just noticed something incredibly funny
totally looks like
:D
@Gordon HAHAHAH It does indeed.
:D
schizophrenia?
@iroegbu is that you? :D :(
15:56
@Gordon I'm going to show you few slides, you need to tell me what you see.
@webarto likely genitals
hahaha
@Jasper Well, I'll take my chances...
@ircmaxell Fair enough
shoot, I didn't put 2+2 together. I can't run PHPPHP on HipHop, as it doesn't support namespaces...
@crypticツ wow... just, wow...
@Gordon what are you implying? /me resembles that remark
im having some problems with mysql installation
16:07
@ircmaxell just what it says :)
the mysql server instance configuration is stuck at the step where its starting the service
i had tried removing the service using sc command
its showed success
on the same machine
but when tried again with instance config the wizard is unable to start the service
i had previously installed wamp and xamp
could any one tell me what's going wrong
@ircmaxell :D
@ircmaxell I had to google what resemble that remark means. i thought you mean resent.
not a problem though. It's not like it's hard to do a quick ns -> non-ns conversion
I put it on Cheezeburger: cheezburger.com/7115972096
16:17
What do these two numbers mean on tags top-users page? joxi.ru/D2w3Udg5CbAjBrW3-ts
@Hast hover over them
lol
thank you :D
I tried bot the tooltip was loading too slow
has anyone ever used the eBay API?
user895378
16:34
Ah, the small things ... it's so nice when your code aligns all by itself:
user895378
const CLOSE_NONE = 0b000;
const CLOSE_RECD = 0b001;
const CLOSE_SENT = 0b010;
const CLOSE_DONE = 0b011;
@rdlowrey indeed it is...
@Jasper the entire thing is WTF
Anonymous
16:41
Hmm..
@ircmaxell Haven't read past that line. The thing is, though, that I know I'm not too well versed in strength of passwords (and moreover password storing) but even so I can read that line and know this is not something that actually has much to do with the strength of the password
user895378
And before anyone says, "you should not have abbreviated RECEIVED to RECD," note that it's purposefully abbreviated because received is a frequently misspelled word resulting in phantom WTF errors ... best to abbreviate in a case like that IMHO.
@Jasper I put a limit on all my password forms...
@rdlowrey RECD? thats short for recorded. Received is RCVD.
@Gordon agree
user895378
16:46
hmm ... you might be right.
@rdlowrey s/might be/are/
@rdlowrey RECD?
Ow lol @Gordon beat me
@ircmaxell You do? Seems I am even less informed than I thought... Wouldn't that actually put a limit on the strength of the password?
user895378
You guys are just jealous of my "creative" abbreviations ;)
@rdlowrey JLUS? ABBRVS?
user895378
16:48
lol -- wish I'd thought of that.
@Jasper I do. But very high (50 characters +)
@ircmaxell What's the advantage of a high maximum over not having a maximum?
mental note to self: pushing the tax reminder one day back is not making it disappear forever. you tried that for 5 days now.
@Jasper just FYI bcrypt will just cut off the password after a certain length ;)
16:51
so guys ... can someone tel me why this fails in IE8 : fiddle.jshell.net/teresko/MBUAs/3/show ?
afaik it was 72 chars, so after that making the pw longer won't give you anything ;)
@NikiC That's a good point.
@tereško Because you're not using jQuery? :P
In official docs I can see that DOMNodelist::item returns DOMNode class. But it really returns the DOMElement object. Is it a mistake in the docs or I missed something?
@Hast Can you show some code?
17:04
@tereško because your are using IE8? :P
that is not helpful
@webarto look at the my answer here: stackoverflow.com/questions/15252770/…
get_object($a) returns DOMElement, and acutally it IS the DOMElement
I noticed this because my IDE doesn't show a correct autocompletion for this var because it says me that $a is an object of DOMNode class...
@Hast yes, the latter is an implemention of the former
17:12
Just booked airfare and hotel for Portland
@Hast w3.org/TR/DOM-Level-3-Core/core.html#ID-844377136 => Return Value : Node : The node at the indexth position in the NodeList, or null if that is not a valid index.
@ircmaxell Are your expenses covered or you have s* load of money? :)
@Gordon yes, clear it now. Thanks.
2
Q: jQuery get value of selected radio button

user1114212The problem statement is simple. I need to see if user has selected a radio button from a radio group. Every radio button in the group share same id. The problem is that I don't have control on how the form is generated. Here is the sample code of how a radio button control code looks like: <...

what happens when no answer is selected as the 'correct' answer?
@webarto corporate card
17:15
evening
@ircmaxell that's cool
@Hast DOMNodeList returning various DOMNodes eval.in/12027
@Gordon yes, i have already understood that :)
funny unsecured ip camera feed...--> cryptogasm.com/webcams
@iroegbu the code is wrong by itself, i mean the person is stating he/she know the id's are not unique and don't/can't change it... number one rule should be: respect the goddamn rule
they want a "jquery solution" but don't even know how html works
Woot, I'll have Silver on United by mid-June (with Portland and Amsterdam)... And be part way to gold by the end of the year
17:26
foreach ($rootNode->childNodes as $child) {
    /** @var DOMElement $child */
    echo $child->
}
@Hast this will enable autocomplete in most IDEs. It's ugly though
childnodes should be hinted in the core of the IDE
@ircmaxell the IDE would need to deduce it per method, e.g. it would need to know that getElementsByTagName returns a DOMNodeList containing only DOMElements whereas the interface denotes DOMNode, which is correct, but cannot happen with getElementsByTagName.
@Happyninja here the 'wrong' answer was picked stackoverflow.com/questions/986120/…
@iroegbu how can it happen???
Look at that... the second answer is by far better
17:33
does anyone have good experience with reading xml files with jquery
@Gordon true
:8110144 i would have think of something like this: 	$(':checkbox').change(function(){
		var isChecked = $(this).attr('checked')?true:false;
		switch($(this).attr('name')){
			case '...':
				...
			break;
		}
	});
to track change
> var isChecked = $(this).attr('checked')?true:false;
jQuery strikes again...
@DaveRandom yeah
but the person wants it
(by which I mean: What's wrong with var isChecked = this.checked;?)
17:40
@DaveRandom :D
@DaveRandom it's not cool enough
lol
Quite apart from the ternary with cond ? true : false
It's too simple.
jquery verbose a lot so by looking at it, nobody can miss the fact it's all about a checkbox
...because other elements have a boolean checked property?
17:42
lol
it could be a ... (looking for a way to promote jquery)
There are two very good reasons to use jQuery: compatibility and speed of development. That's no excuse for writing terrible Javascript though...
@DaveRandom you are right
And with that I'm out of this conversation, it never ends well and everyone knows how I feel about it
people are asking question, asking for jquery solution but they don't even know html
Anonymous
Finally got my tablet. codding PHP
17:44
maybe i'm just assuming
that because someone keep having the same id multiple time and state that they can change it... what the heck
Check out #phpbnl13 official after movie! https://vimeo.com/61129982 starring @grmpyprogrammer @ircmaxell @e3BethT @DragonBe @phpbenelux
Ben
Ben
Does someone have an idea to this: stackoverflow.com/questions/15209567/…
@Happyninja we are supposed to get the value of a radio button
not track change
@iroegbu i was sarcastic. i guess it didn't sleep enough. The value is as stated by @DaveRandom: var isCheched = this.checked; is perfect.
I'm out, later @all
radio buttons don't return true or false as value <input type='radio' id='foo' name='foo' value='bar'> should return 'bar' as value... correct?
@Ben i provided a possible dupe. but if you dont have shell access whatsoever, your options are limited (to use a euphemism). you could create daemon in php to periodically check the folder: stackoverflow.com/search?q=daemon+php
@iroegbu to get the name value --> $(this).attr('name');
no, not the name value
from the 'value' property i mean
$(this).val()
Ben
Ben
@Gordon Thank you!
17:55
@Happyninja hence, $('input:radio[name=theme]:checked').val(); is correct
Hi,
I am using swift mailer.

$plugin = new Swift_Plugins_DecoratorPlugin($replacements);
$mailer = Swift_Mailer::newInstance($transport);
$mailer->registerPlugin($plugin);
$mail_template = file_get_contents('../templates/affiliate-mail.phtml');
$message = Swift_Message::newInstance($subject)->setFrom(array($from => $fromname))->setTo(array( $to => $toname))->setBody($mail_template, 'text/html');

I am getting with mail with out replacing the {some-txt}. How do i parse using swift mail. What i done wrong on this ?
kindly advice
CAM
CAM
at launch2013 in SF
Amazing Networking
@Dinesh You're registering the plugin, but don't seem to ever call it. Does the plugin actually do things automatically? You should double-check.
@Charles Okay let me check
@Charles Finally i am sending mail using $mailer->send($message); THis sends HTML content to mail with out replacing the {text}
My replacement array will be like $replacements = array (
"{heading_text}" => "Your account has been credited with a new order",
"{subject_text}" => " New Order",
"{detail_text}" => "The details are as follows:",
"{detail_content}" => $rep_content,
"{detail_sub_content}" => Notification::$signoff,
);
18:13
Hello.
I'm creating a small framework just for the sake of it and I'm trying to make it as OOP correct as possible. I'm wondering how to implement classes like config which reads a config file and saves its contents into an array. This class should be available throughout the whole application. Codeigniter makes sure that file is read only once by implementing singleton (anti)pattern, other frameworks use some kind of a registry, static classes,... None of these seems like a viable solution. Can someone please help me?
@JanL for the sake of it?
Evening
@PeeHaa hello
@Happyninja Not really "for the sake of it". I'm just making a little hobby project, mostly for learning how frameworks work internally and to improve my OOP programming.
Hey, sup
@JanL There are that many config options that are really needed throughout your entire application
@JanL Indeed all those things look like crap to me
@Happyninja I'm already using it heavily.
I think you should really reconsider the idea that you have that the config needs to be global
@PeeHaa The config class was just an example. The problem is that in some cases framework components should be able to access the same instance of a certain class
@JanL In that case just pass the same instance
18:37
@Jack Had time to look at the comparisons yet?
@PeeHaa Yes, but how?
What do you mean by how? You don't know how to pass arguments?
Anonymous
1
Q: how to stop bcrypt salt from changing everytime for login password

cbenn95I grabbed the code for defining the bcrypt function from http://stackoverflow.com/a/6337021/2115954. The registration of the password works fine, and saves all of the fields to the table in the database. The problem, like that title says, is that the password_login will not work because when it i...

@PeeHaa Of course I do. Controllers are called dynamically, and the loader doesn't 'know' if they need access to a certain object
@JanL Sounds like an architecture problem to me.
18:44
^ that
Do you have a github link somewhere?
@LeviMorrison It most certainly is.
@PeeHaa Nope, I don't use Git yet.
In that case it's pretty hard to tell you where the flaw is, because I'm pretty sure there is
@tereško Are you in yet?
Is it OK I truncate tables that are used in test (prior to test)?
@webarto If you need to test you database stuff I would say yeah

« first day (872 days earlier)      last day (4300 days later) »