« first day (1444 days earlier)      last day (3507 days later) » 

12:00 AM
(well, apart from Windows where it's C++, but Windows API sucks balls.)
@HamZa btw. that sounds like the type of people which happily will jump on the Hack train…
@HamZa seems you're answering less and less question to not have to enter the 10k club? :-P
 
@bwoebi I'm tired of moderating and answering SO. I finally got rid of this addiction
I tend to visit it a few times a day to check if there's some interesting questions (most of the times there isn't) and then I quit
I tend to hang in chatrooms though
I'm training more btw :D
 
@HamZa uh, I don't moderate, except a question is so bad and I have it open... and answering: there's too often nothing interesting, just as you say.
 
 
2 hours later…
2:14 AM
hello
can you help me with postgres i dont know why dropping off the db came up with an errro
 
2:35 AM
@HamZa Sounds like an unprepared professor, unfortunately. :/
 
2:58 AM
@LeviMorrison good moaning
 
quick qn, do you use a web frontend for git by any chance? as in, for projects not on github, etc. :)
I'm inclined to just use gitweb.
 
Nope.
I just use command line git.
For everything.
 
Oh, it's not to perform any actions on the repo
 
I've used PhpStorm's UI for simple commit stuff but even then I prefer to drop out to CLI.
Everything important has a github mirror anyway, right? :D
 
3:08 AM
We don't have a mirror for those repos, they just get backed up daily.
 
3:46 AM
morning
 
 
2 hours later…
5:56 AM
@bwoebi it causes bugs elsewhere if we allow it
morning
 
Good morning
 
6:20 AM
morning
 
6:31 AM
posted on September 29, 2014 by kbironneau

/* by max */

 
starting monday with segfaults and corrupted heaps is depressing ...
thanks fpm, dick head ..
 
@LeviMorrison He was indeed unprepared. He did admit it
 
7:04 AM
@LeviMorrison Pretty much the same, I'll use PHPStorm for quick commits, maybe even a revert occasionally, but I seem to do most git activity in the terminal these days too
 
7:26 AM
good meurning
 
Hello everyone! Is there anyone here who is experienced working with WebEx API?
 
7:57 AM
mornings
 
moin
 
@Leigh Yeh especially since you can open a terminal right in the same window, I much prefer to know exactly what it's doing. I'd probably use the built-in stuff more if it the descriptions of the GUI options corresponded a bit more closely to the command line opts
Also the fact that github checkouts always set the remote URI to the https variant, and I can't find any settings to make it use ssh by default
 
Goooood morning Vietnam Room 11 :)
 
E_MONDAY
Although, only 4 days to go :-D
 
yay
 
8:05 AM
Does anyone still know what that __toString() is on about?
 
rephrase()
 
The thread on ML
And how can Lester make everything about BIGINT and 64bit on 32bit?
 
I have all of his mails automatically archived in Gmail? so I don't even see them? because he never seems to have anything even remotely useful to say?
 
good call @DaveRandom ?
@Jack because he picks a subject every few months and just tries to make everything about that ?
 
Seems like it :)
 
8:14 AM
Is there any speed up tips to count the number of expected number of result in search/filter(without running query for each filter type)?
 
@Fasilkk If you want the number of matches, the only way you can do it is to actually let the query run fully and count the number of rows. Are you using MySQL?
 
Yes, im using mysql..
Im aware of running of 100s of query for my filter. To get expected result count..:(
 
@Fasilkk Are you trying to paginate the results?
So basically, you want to just get a set of, say, 30 results, but know how many matches there are in total?
 
Yes, Paginate + filter based on many fields.. (categories, price etc)
 
Assuming you want to work with your existing technologies rather than start messing around with new things (I personally would recommend solr for stuff like this but it's non-trivial to set it up) you can use SQL_CALC_FOUND_ROWS for the first query, cache the total number of matching rows (you don't want to do it every time) and that's about as efficient as you can get
It basically means that the first query for a given filter will have to do a full table scan
so the first query will be relatively slow
But then for subsequent pages you only have to get the results for that page
 
8:22 AM
Hm. ok, i have to do in this way. Please let me know, if anyone know any tutorial of better way.
Thanks @DaveRandom
Il do in the way you suggested..
 
As I say, I would recommend solr for search stuff (that's what it's for) but it's not simple to get it set up and working reliably with current data
I would suggest you make it work with mysql first - afaik that ^^ is the best way to do it with mysql only - and then look at other technologies
 
ok.. ok.
 
@Fabien When it first aired, but not since. I read the book as well, can't remember a huge amount about it - was OK from what I remember, was ages ago though.
That was like 15 years ago or something
It was while I was still at school, I remember that
 
Morning.
 
Oooh @Leri has a shiny new avatar?
 
8:34 AM
posted on September 29, 2014 by kbironneau

/* by Gnaarf */

 
@DaveRandom Yes, new for this chat.
 
You should clean under your finger nails more
:-P
 
@DaveRandom lol tell that to the hand owner (I have doubts, she'll kill you, because spent 2 hours to make those nails). :P
 
Maybe it's the low-res, but it just looks like dirt under finger nails.
@FlorianMargaine w. t. a. f.
 
@DaveRandom In original image it was cyan.
Anyways, will change avatar soon, as long as we quit everything. :Ь
Has anyone already implemented async tcp and/or udp application layer using alert or libuv? /me looks @rdlowrey, @DaveRandom
 
8:44 AM
@Leri What do you mean by "application layer"?
i.e. what interface are you looking for?
 
interface Handler {
      public function onConnected(Peer $peer);
      public function onDisconnected(Peer $peer);
      public function onRead(/*byte[]*/ $data, Peer $peer);
      public function onSent(/*byte[]*/ $data, Peer $peer);
}

interface Peer {
     public function isConnected();
     public function send(/*byte[]*/ $data);
     public function disconnect();
}
@DaveRandom something like that. ^
 
@Leri OK so an OO stream, basically. There isn't currently anything like that because a) there's an implicit, fairly sizeable perf hit, unfortunately and b) we've found that a one-size-fits-all impl actually doesn't generally fit-all. What are you actually doing?
 
Trying to port some of my .net servers (because it's mix of C# and IL) to php.
I'd like to port simple stuff and therefore increase performance of heavy stuff.
 
Honestly, for production applications, it's probably better in .net (best for maint would actually probably be C++ targeting a specific *nix platform)
 
8:53 AM
@DaveRandom I don't see exactly where is performance hit if using libuv. Exactly what might hang?
 
@Leri It's more the internal fcall/memory overhead. What kind of concurrency volume do you need to support, is the real question
bear in mind that most of rdlowrey's stuff is all about squeezing every last drop of perf out of PHP, it's possible (likely) those problems aren't relevant to you
 
@DaveRandom Pretty high (for php) around 100-200 active connections (1-2 packets/s).
 
Oh that's peanuts
You probably won't have any issues then
I guess we could do with something like that (the OO streams stuff)
 
0
Q: Is it possible to create a new controller and view in jomsocial getting blank page?

user2848901I am having a hard time figuring out how the exactly the routing works in JomSocial. Does anyone know how to create a new controller and corresponding model and view

 
Ugh, got that dry mouth feeling from using mouthwash. Like my teeth are made of rubber.
 
9:06 AM
People who are not going to PHPNW: ping me if you have any ideas for a easy-ish "just for fun" challenge that requires some coding to solve
9
 
@DaveRandom Great, I'll start implementing it. At least it will be great for prototyping.
 
@DaveRandom Build a hot or not for the people of PHPNW. Hack the phpnw website to get all the profiles and ultimately end up in a disciplinary meeting for your behavior.
 
/me needs some more free time
Or simply delete the Internetz. -.-
 
@Fabien You mean @DaveRandom may lose his license to practice PHP over that? :)
 
@DaveRandom Wait, you're going to PHPNW right
 
9:11 AM
But he'll go on to create a social network site that'll earn him billions off of others peoples data.
 
good mornings
Ah! @Jimbo I totally for got to ping you over the weekend... There's probably a problem with methods too... seems broken
 
Your face is broken
What's up with it?
 
and you have this
 
Yeah, I decided that I didn't like having a whole ConfigLoader thing when all you need to do is Yaml::parse()
 
I can't make method: POST to work
 
9:20 AM
@iroegbu Did you set the ROUTE method to 'POST' ?
 
yep
 
@iroegbu Have you altered anything else? Setting the method to post definitely works for me... You can get the POST variables sent through by asking for Request in the method signature and then: $request->request->get('id')
 
hit me on the head with a big stick!!!
I wrote "methods: POST"
@Jimbo it's all good
 
9:38 AM
@Jimbo Yes...?
 
@DaveRandom Good good, just wondered what the challenge was for
@iroegbu You can see at the end of Application.php where it does the method stuff
Should be able to see what those methods to, I just chained them together
 
@Jimbo @Ja͢ck @Fabien Basically this year's version of docnet.nu/blog/2012/10/17/…
 
@DaveRandom Shit, they gave away a new MBP?
Let's fix this and go halves on the prize ;)
 
Yeh, and last year as well I think
@Jimbo Hence the reason I stated people not going to PHPNW :-P
 
Nob
 
9:42 AM
Also, not sure how you can go halves on an MBP
Also I don't actually want one...
 
@DaveRandom Sell it
 
Java is wank
 
Also, Something to do with regex for the question?
 
@Jimbo Yeh that's a possibility...
 
Hi Guys
 
10:02 AM
@Jimbo Did you resolve your cactus issue? :P
 
I believe he's scheduled for an extraction operation early next week.
 
PDD - Panic Driven Development
 
morning
 
@Jimbo Usually abbreviated to just "D"
@PeeHaa sup dawg
 
@DaveRandom haha :-P
 
10:08 AM
@DaveRandom I'm taking this week off so not much :P
 
Your boss is such an awesome guy
 
Yeah sometimes he sure is nice :D
 
@PeeHaa You should totally buy him a gift, from what I hear he'd appreciate a case of beer
 
@DaveRandom hehehehe
 
10:23 AM
I have it on good authority @PeeHaa is sleeping with his boss though.
4
 
10:34 AM
Please edit and improve stackoverflow.com/a/26097764/1348195 Trying to guard it against repwhores.
 
@BenjaminGruenbaum s/loosely based on/a subset of/ ?
 
@DaveRandom it's not a subset though.
 
In what way? All JSON is valid JS literals, not all JS literals are valid JSON, isn't that the definition of a subset?
 
@DaveRandom no, they're not.
 
?
What is valid JSON but not valid JS?
 
10:38 AM
Unicode stuff
 
What, bare newlines are valid in JSON strings?
Never knew that...
That seems like a hole in the JSON spec, that shouldn't be valid
 
It's usually circumvented by encoding those unicode whitespace characters
At least that's what PHP does
 
Oh wait no, it's only U+2028-9
 
To make sure that ignorant people who think they can safely include JSON into JS code don't end up with bad surprises
 
@DaveRandom it's more like a hole in the JS spec, and it's not the only case.
@NikiC haha, that's hilarious.
 
10:42 AM
It should work like that anyway, but what you going to do
 
The newline thing makes JSON a hypocritical spec.
You can't argue that you don't support all floating point numbers because JS doesn't have (safe) NaN/Infs and then go ahead and introduce incompatible strings...
 
Crockford's mantra: "because fuck you, that's why"
 
hi all
 
Yes, that's the feeling I got
 
@DaveRandom lol
 
11:03 AM
Is it possible to track what the last line of a PHP script run was? I'm trying to investigate why a legacy symfony app is whitescreening on an exception......
 
@Danack use a debugger?
 
@BenjaminGruenbaum That's usually my line...
 
Doesn't PHPDBG have process record and replay?
 
@Danack Do you not get a stack trace logged anywhere?
 
No...that's the issue.
somethings just doing exit();
 
11:12 AM
Could be that PHP is segfaulting or something then, in which case the Apache logs should at least tell you that this is the issue
Also @Danack 3v4l.org/AnUb7
 
thanks.
 
gdi
 
@BenjaminGruenbaum it can record executed oplines, but what do you mean with replay?
 
@bwoebi replay a program's execution
 
@BenjaminGruenbaum you mean what changes to what and where?
 
11:24 AM
@bwoebi record a program's execution and play it step by step.
 
Currently not. You can set watchpoints but not on the symbol tables (except on the global one)
Would be maybe a great idea to implement... Might you add some phpdbg issue for recording symtable changes alongside with oplog? (I can't now, being on phone)
 
That'd be swell
 
so uh... re: Juliens mail.. wat?
 
@BenjaminGruenbaum then please open an issue there, I'll look what I can do then.
 
2 hours ago, by DaveRandom
Java is wank
srsly
@Leigh You mean Actually, some php.net machines have been compromised and prevent us from releasing 5.6.1. ?
I have no idea...
 
11:39 AM
@BenjaminGruenbaum: Link you've provided doesn't say anything about null being a separate type, also Array is a composite type and yes, it yields to an object as I mentioned in my answer. Read this: msdn.microsoft.com/en-us/library/ie/7wkd9z69(v=vs.94).aspxSurya 10 mins ago
I want to punch him in the nuts :/
 
"The Null type has exactly one value, called null."
That's just like, an opinion, man.
 
I'm not a part of your system, my dad is not a phone.
 
@BenjaminGruenbaum s/nutoriously/notoriously/
 
ty
don't want to nutor w3schools, or maybe I do :D
 
I'm not sure that would be enough tbh, it needs killing and incinerating. Give it the Japanese Knotweed treatment.
 
11:52 AM
I have 4 projects opened: 2 .net tcp based server, 1 aspx project and 1 as3 project. And my salary barely is 500 EUR per month. fml.
 
I think you need a new job...
Ugh, what the actual shit Java, I've now upped the memory limit to the point where I could not give it any more without killing essential operating system processes (which it preallocs in one huge block at program init) and it still keeps throwing OOM exceptions
What the program is doing: copying some files from a USB disk to a network drive
 
@DaveRandom Or salary raise. I've been talking about this for 2 weeks now with management and they try to avoid this talk as much as they can. Also today I heard that they want to get developer with higher salary. This means, either they want to replace me or demote me. In both cases I leave. :-)
 
@DaveRandom Yes, Java grabs as much memory as it can when it starts up. Sounds like you need to run something like yourkit.com/download/index.jsp to view what objects are still in memory...it's probably an actual leak somewhere.
 
@Danack It's not my program, it's catacombae.org/hfsexplorer, which seems to be the only free way to do this
There's a couple of freeware *nix packages but they both seem to 100% the cpu not far into the process
 
"Buy a mac"?
 
12:00 PM
Literally the only thing I need to do is copy the data off a USB HDD onto another data store with a sane filesystem
(also ideally I want to do this remotely)
 
Not free
oh, free
 
hi all
 
Only works for Win8+ though
 
i need a "little" help :)
 
12:02 PM
Host where it's currently connected is Win7
I think I'll just labour through with this, it's a pita but it is doable and once it's done, it's done
 
anyone could help with php/PDO/MySql a bit please?
 
I'm copying the data to an ext4 partition, which is much easier to deal with in this respect
@Julo0sS Please ask a question rather than asking for help before you've asked a question ;-)
 
lol
ok
^^
I have a pdo query :
$get = $db->prepare("SELECT Y(geo_position) FROM geo_table WHERE geo_id = $id");
geo_position is a POINT
then i do this
 
@DaveRandom Install win8 :)
 
if($get->execute()){
return $get['Y'];
}
it does NOT work
if i do
return $get
i receive an object...
(i use json encode after that)
how can i "read" the value of Y from my $get object please?
(i also tried $get[0] which is not better...)
 
12:07 PM
is there a way anyone can solve this? stackoverflow.com/questions/26097380/…
 
Hello.
 
@DaveRandom Now that comes as a surprise ;-)
 
@Julo0sS Why are you using prepare?
 
I Know this is bad, but i can't understand PSR's autoloading and namespaces standards.
I Mean PHP-FIG's.
 
@Julo0sS $get is a statement, you are treating it as if it's a row
 
12:10 PM
> Actually, some php.net machines have been compromised and prevent us
from releasing 5.6.1.
wat?!
 
You need to use one of the fetch*() methods
 
@DaveRandom you mean that if i do : foreach($get as $data) it will work?...
 
Anyone can help?
 
@Julo0sS That's one way, yes. Although, you need to make to that the fetch mode is correct for that
But I think the default would let you do that
Will that query only ever return a single row?
If so I personally would use fetchColumn()
 
yes it will return only one row
 
12:13 PM
I don't like to loop over a collection of things if I know the collection only contains one thing
 
@PeeHaa idk, i'm used to do that...
so how would you do?
 
@Julo0sS Well, the point @PeeHaa is making is that you prepared a query but you still passed a bare variable into the query string instead of using a parameter
 
i really need help for this.. stackoverflow.com/questions/26097380/…
 
@DaveRandom i know, but the "prepare" statement let me forget the quotes things... i don't need to quote anything if i do it this way... am I wrong?
 
@Gokigooooks No need to spam. If somebody is here and wants to help they will
 
12:15 PM
hello guys anyone experienced in drupal 7 hooks ?
 
// wrong
$stmt = $db->prepare("SELECT * FROM foo WHERE col = $val");

// right
$stmt = $db->prepare("SELECT * FROM foo WHERE col = :val");
$stmt->bindParam('val', $val);
 
@DaveRandom @PeeHaa i have to go right now, but i'll be back tomorrow, i do not forget what you've told me now, we will speak about it tomorrow if you have some time. Thanx btw for help! :)
 
np
/me is out for lunch
 
@DaveRandom enjoy
 
Can you guys help?
 
12:20 PM
@iFarbod You didn't ask a question?
 
No, I Think it was my Net problem, that, question is not sent, i think
Can i ask it again?
 
Considering I don't see your previous question you can ask again :)
 
is anyone listening can I ask a question ?
 
Yes everyone is watching..
 
12:24 PM
Don't ask to ask. Just ask. If somebody is here and wants to help they will help. Just don't spam your question.
 
The problem is that i can't understand PSR's Autoloading standards and Namespacing standards.
 
can I post a link to my question here ?
 
try gardening as a hobby instead ?
 
@iFarbod ok and what is the specific question?
@tereško Don't underestimate growing pot! :)
 
@PeeHaa ok .. beekeeping then
 
12:27 PM
Can you give me a good source to understand them?
 
1
Q: Search autocomplete in drupal 7 using hook_form_alter

H_altThis is the module that I have created. It is supposed to make a views exposed form which is used as a block on the homepage turn into an autocomplete form using hook_form_alter. The code is not showing any kind of error but it is not working. Is there a problem with the $form_id ? Can some one p...

 
@iFarbod What in specific don't you understand?
 
can someone kindly help thanks
 
@PeeHaa idk how to say
@PeeHaa didn't understood namespaces at all. i'm building a CMS, OOP.
 
@iFarbod slowly .. preferably with some dignity
 
12:29 PM
@tereško What?
 
@iFarbod Did you read the manual pages about namespaces?
 
Yep, can't understand them.
 
Have you tried wth code?
 
did you try the Indian translation ?
 
I'm not Indian.
 
12:30 PM
@iFarbod What happens if you build an application with a class called Foo and you include a library I wrote which also contains a class called Foo?
 
@iFarbod Try using composer as it'll help you learn the principles. Install it and setup a bunch of classes in multiple dirs. Then use composer to autoload the directory.
 
OK, Going to install Composer.
 
eval.in/199890 @iFarbod
 
@PeeHaa Yes, I Think we should use namespaces here, but idk how.
 
12:38 PM
@PeeHaa i saw other popular apps declare namespaces in another ways, for example, using use keyword.
 
@H_alt "The code is not showing any kind of error but it is not working" -> have you debugged it in anyway, tried to isolate the bug..?
 
@iFarbod use does not declare namespaces
It "imports" them
 
@PeeHaa i mean importing
Sorry.
Like Java's import
 
Nope not like java's import
 
?
 
12:40 PM
IIRC java actually does an import
 
ok, Java doesn't matter now for me, just i want to understand the autoloading, and how to organize my libraries for them.
Sorry for really bad English.
 
Technically you don't need namespaces at all for autoloading
 
For PSR's, i want to follow those standards.
 
You are trying to drive a car before you are able to start a car. That is not going to happen
Forget about psr
 
Should i start coding without PSR?
 
12:44 PM
0
Q: how to fetch data from API URL in php?

ramanI am totally new in PHP and i want to get data from a API URl. I am using the following code. i am not getting what is the error and how can resolve to get the data. please help me. <?php exit; // REMOVE this line to run the script // this token is used to authenticate your API request. // You ...

please help me
 
@raman is the client_secret a secret?
 
@RonniSkansing yes it was ;)
 
Shit happens
@raman sure they should be a space after token?
 
Other than getting a timemachine and punching the appropriate person before they do it, if I have a site that has in it's CSS:
form {
	width: 659px;
	border:1px solid #b6b7b8;
    //Lots of other stuff
}
Is there anyway to add a class to a form that 'resets' the css rules?
to avoid having the generic form style applied to all forms?
 
12:51 PM
!important time!
 
@Danack form.class {width: auto; border: none; }?
Or are other elements also screwed up?
 
Actually yeh, the specificity of a class should override the generic form selector
 
Basically the site assumes that one form will take up one 'box' with an outline. I want to have one 'box' with outline that contains two forms.
But not like that....
 
Why does that even need to be a <form>?
 
12:55 PM
Symfony 1.4
 
form[class] {
 
...aaaaand I'm out
 

« first day (1444 days earlier)      last day (3507 days later) »