« first day (915 days earlier)      last day (4258 days later) » 

00:01
Do you bio guys not have standard tools to help you deal with these sorts of extraction problems? Every day or two we get yet another variation on "I need to parse this GATTACA string". I'd think there have to be some already written, debugged and tested tools out there to help you. — Andy Lester Apr 5 at 21:25
@DaveRandom what's wrong with insanely large dams?
@MikeB They don't fit in my back garden.
get a bigger garden
and an insanely thin dam :P
<3 the vision of people posting to fig-standard using the expression "hype frameworks"
I'm so hyped :D
whooohooo!!! what's the new hype @Ocramius ? whooohooo
what's a hype framework?
@MikeB dunno, anything that uses PSR-0 as it looks like :P
which reminds me ... why do the still allow Phil Sturgeon to write posts ?
00:23
@tereško actually voted against having fuel in, but I got bashed just a little bit ^_^
i was referring to this steaming pile of crap: philsturgeon.co.uk/blog/2013/04/is-psr0-shortsighted-or-are-you
tl;dr? :P
i read as much as i could stand it ... i was waiting for food at a cafe
dunno... kinda sick of reading rants on psr-0
they should have called it PSR-7 .. instead everyone from FIG now is invested in defending it, because it is "the first standard", and if someone even suggests that it is crap, it will unravel their whole perception of importance
00:36
@tereško the point is that there's no real need to defend it - what I wonder is that so far I have not seen a practical use case for a different autoloader except go-aop-php, which is black magic
1. case insensitive class names
2. multiple namespaces in same folder
3. multiple folders containing same namespace
4. namespaces that do not match the folders (plural vs singular forms)
@tereško :-X
@tereško I still don't get why that would be useful, but maybe I'm really shortsighted
I mean - if I had to lookup a NS over different dirs I'd be running in circles
and the other ones - that's nitpicking without any real advantage - and again, all this stuff can come with your own autoloader, just common sense tends to drive people to do 1:1 things as of the document, heh
here is an example : you have a project with public site and a CRM system .. it share some parts of the model layer : the shared parts you can put in a separate folder , while leaving the section-specific parts in each apps own directory tree
@tereško never seen a system like that, but where's the problem in creating two sub-namespaces there?
it seems like a much more logical solution to me
My\CRM\Base <- shared stuff My\CRM\CoolPaidStuff <- secret sauce
that's what I'm currently doing with the stuff at work: divide into packages and ship only what was paid
00:44
Hello!
I have a problem. I'm using cURL to get some data from a website. But sometimes it's extremely slow (I'm not sure if it's my host being slow). Normally it would take 1-4 seconds but in some cases it will take 10-70 seconds!
And when it's that slow it will be for a period of time and not only that instant
"I have a problem. I'm using cURL .." ... so you actually have two problems
How come? :o
anyway .. i need to get some sleep
curious, what's wrong with cURL, apart from the horrible API?
00:48
you mean i need another reason ?
What would be better?
I've been recommended to use cURL by everyone
@teresko your punctuation is confusing. 1. seems trivial. 2-4. seem like they could be solved with proper organization
@kaᵠ uhm, usually I'm referred to cURL as soon as I mention using fgc
00:50
@igorw Well . . . I don't need another reason either.
file_get_contents' API is not really any better, and it doesn't support some of the stuff that curl does, such as keepalive.
@igorw what else then? except wget ?
why are you asking me?
@colandus cURL is better for organization and functionality. It's just that the organization is lunacy.
also, do you use wget from within PHP?
00:53
ok guys, really curious now, what else is there besides those 3?
And the official documentation will peeve you
@igorw executed @linux, sometimes yes
@LeviMorrison what alternative do you suggest?
For me the proper tool would depend on the format of returned data
@igorw If it's a script (not a stable or production program) then I just use wget since I'm probably just downloading something.
If I'm adhering to something like REST then I would use Artax.
It's still not stable and probably has a lot of refactoring left.
I'm fine with that since it's a joint effort with @rdlowrey
The cURL API is horrible. I'd rather program do socket programming than deal with PUT in cURL.
It has other unlikeable issues as well, but that one is always unpleasant.
00:59
despite the fact that the term "curl wrapper" gives me knee-jerk reaction, there's lots of thin libs that give you a usable API for it.
Ratchet?
@dyelawn are you referring to the WebSocket server? if so, what about it?
user895378
Yeah ... Artax works perfectly well, but like all code I wrote more than two weeks ago I now hate it and think it's terrible and desperately needs a major overhaul.
@LeviMorrison Artax has no (programming related) entry in wikipedia
user895378
lol I would be surprised if it did.
01:02
@rdlowrey
duh! :P
ty @igorw
SO chat, aka "google as a service"
user895378
Not to mention I've learned so much about socket programming in general over the last couple of months that I didn't know when I wrote Artax.
user895378
Who knows what nonsense is lurking in that codebase.
@rdlowrey what could possibly go wrong? who knows? who cares! deploy to production.
2
user895378
lol yeah it works just fine, but I do think it's an overengineered pile of crap and I won't really refer anyone to it until I have a chance to completely rewrite it :)
@igorw Already done.
Albeit it is a very small and hardly important piece of our system.
:]
user895378
I've been using it for a while without problems as well ...
user895378
I just hate the overcomplicated API
01:05
what do you mean? just create a new ClientBuilder and build a client with an implementation of the Mediator interface
user895378
exactly ... OOP wanking at its finest
at least it's better than liboauth (oauthlib? whatever)
/me hides
I'd say that Artax isn't over-engineered to the point that it's unbearable to use.
Just more than needed.
user895378
Nah I mean it works but ... whatever ... needs to be rewritten.
> Ok that's it. I'm done with this PRS [sic] stuff. I'm switching to all javascript cause I don't even have to use semi-colons there
01:09
@LeviMorrison please don't mention semi-colons!
@LeviMorrison you're not using AMD? then your code sucks
user895378
hehe there is like 1% of me that's worried everyone (including me) who isn't using node.js to program in js on client and server side might be making a huge mistake.
I just had a horrible day debugging my code.... Just to find out I had added a semi-colon on my if-statement
@rdlowrey Wow. A whole 1%?
user895378
The benefits of using the same language at both ends can't be overstated, and node works well.
01:11
Oh definitely. It's one reason I'm excited about Dart.
user895378
I mean, I've spent the last three months replicating what node does in PHP and even though it works well and just as fast, I'm still stuck with the fact that I can't use PHP to work on the client side.
user895378
Dartisans of the world, unite!
I think once JS has normal classes and scoping that are promised then Node.js would look very attractive.
node.js works really well for certain responsibilities in my products that are heavily client-initiated. Mission critical, format heavy things are still handled in php and ruby. None of the js mvc libs are close to ready
<- off, nn
user895378
01:13
@Ocramius later
user895378
Not having a usable preexisting mvc framework is certainly not a deterrent to me ...
Clearly I'm not as ninja as some
@rdlowrey we just need someone to make PHP compile to LLVM, then we can emscripten it.
user895378
@igorw That would be sweet. And I think Jeff Atwood would make a mess in his pants on the spot if people started writing client-side PHP.
3
user895378
Which would probably make the whole endeavor worthwhile.
01:15
definitely
Like 18 months ago someone in this room said something along the lines of, "smarter people have already solved these problems, use their solutions". I stopped trying to learn anything other than frameworks ever since. // sarcasm
I don't know enough about PHP internals or LLVM to make it happen
user895378
Yeah me neither. Will just have to dream of some mythical PHP savior to come along and do that ...
@dyelawn ^ watch that, it's The Mother of All Demos
@igorw Compilation to LLVM has been done. It's not really production worthy, though.
Lots of things would break being in a browser, such as anything related to IO.
01:17
@dyelawn it will give you a new perspective on "smarter people have already solved these problems"
@igorw that's really long. Are you just trying to get me to go away for 1:40?
@dyelawn no, you should definitely watch it. not now, but at some point in your life, you should.
IMO this is branching, choosing a branch gets you further on that path without the other (infinite) possibilities at the roots
Now at the top of my continuing education list.
I'd really like to see something that got php on orgmode.org/worg/org-contrib/babel/languages.html
01:35
@NullCatPonyDogUnicornDragonAndOtherCreaturesPointer stackoverflow.com/questions/16010257/…
02:21
woah, that was scary
I thought I just bricked one of my GPUs
or the mobo
screens went to jibberish, and then a reboot stuck on a bios code (0_)
but after doing a bit of key jamming, I got it to boot ok, then rebooted a few times without incident
Yep, time for a new machine :)
#bitcoin
Say, it would probably be the epitome of foolishness to ask here, but are there any android devs here? :)
@baba this guy posted it in twitter. He is the best. twitter.com/ryanqnorth
02:30
Hi there, i want to ask about
<form method="post" action="check.php">
<select name="website_string">
<option value="" selected="selected"></option>
<option VALUE="abc"> ABC</option>
<option VALUE="def"> def</option>
<option VALUE="hij"> hij</option>
</select>
<INPUT TYPE="submit" name="submit" />
</form>
@igorw I love that
can i remove the input type submit and when the select the option it will automatically submitted
@JosuaMarcelChrisano You could add onchange="this.form.submit();" on your <select> perhaps? :)
@ircmaxell it makes me question everything I know, and everything we do today.
02:40
still cannot @Jack
@JosuaMarcelChrisano "Still cannot" is not an error message.
@Jack its working, but after the form submitted how to get the value from that select? and make the selected value is selected
@kaᵠ unacceptable! =oP
@crypticツ ??? why
02:56
tl;dr; =oD
This always blows me away: http://www.youtube.com/watch?v=yJDv-zdhzMY 45 years ago. 15 years before the mouse was in mass production... What's wrong with us?
ok, off to bed now. 'night
@kaᵠ no it's good. Post it here
@crypticツ ty, used positive language in the end after filling reader's brain with no no no... no
@crypticツ done.
gawd, Hiroto again?
03:06
ei?
Oh wait, it's somewhat constructive :)
really... all those "Please* are stupid
you mean checking if string is 'array()' ?
Your regex email is too slim, you should use the one in this answerka ᵠ 40 secs ago
@kaᵠ How about this one? stackoverflow.com/questions/201323/…
03:17
@Jack yea, but that's not ugly at all :D
I especially like the "It's easy in perl 5.10 or newer:" comment above
nice lecture if you haven't read it
Yep, quite nice :)
@kaᵠ I did some slight modifications to it so less words, also used the short URLs gist.github.com/KyraD/5178756
@crypticツ OH NO !!!!!!!!!!1 another please ???? please don't !
I tried so hard to word it around that
03:23
lol ok
will remove please, or should I change it to "Bitch pleeease, mysql_* function..."
@crypticツ no need to shorten the urls, actually if they fit the 500chr limit it's best to leave the original
@kaᵠ reason used short URL is in case someone wants to put more text in comment they have more chars
you can't guess where you're redirected from a short url, a proper one will be clicke by who wants to be educated
@crypticツ also i crafted the removed link specially as connect has nothing to do with remove, but with the special #warning (nonexistant on the site) will make sense when the user will see the red box (subltle :D)
@crypticツ is there a meme with 'Bitch please... / mysql ?' maybe it could be used ? :P
@kaᵠ there is no anchor #warning I think you meant to use this URL php.net/manual/en/…
@crypticツ exactly ! just wanted a fake anchor that says warning for whoever reads the link
03:32
@crypticツ That should rather read "Y U NO Use PDO or MySQLi?!"
@Jack++
where's that meme generator you guys use?
I never use one, I always act memes out in person :)
:)))))))))))
!
@crypticツ that ^^ ! and include it with all your answers on mysql_* posts
03:40
@kaᵠ I'm stalking you on github, don't mind me O_o
!!!!!!!!!!11 grrr
@kaᵠ Y U never use image URI that ends with .jpg? there ya go :)
"One does not simply deprecate mysql_* functions"
because damn generator diodn't gimme one straight away
c'mon
!!!!!!!!!!11
lmao
@crypticツ stalk away, now sure what you have to slatk about there but go ahead...
03:58
@Jack just taken up Jabba / Android stuff?
@kaᵠ It's missing the "I dare you ... I double dare you mofo!"
@kaᵠ As long as I stay inside the realm of JavaScript I don't have to deal with Java shit like this.
do we have to say "officially deprecated"? I mean would it ever be unofficially deprecated?
I got tired so I'm going to unofficially deprecate preg_* functions
official here means that you can read about it from an authoritative source :)
@crypticツ actually it's not 'official' till the 5.5 stable release but it's officially deprecated :D
@crypticツ you gonna do what with preg ?
I'm deprecating it in favor of ereg(), bringing it back old-school!
04:05
@kaᵠ She will use only strstr() and strchr() functions to do matching :)
dafuq?
@crypticツ So you're unofficially undeprecating ereg huh? nice :)
lol
I miss the good old days when I didn't have to use delimiters and modifiers.
youtube's search is stupid, like it wasn't a product of google...
04:09
@kaᵠ =o)
I love the new powers the RegEx god bestowed upon me, o hail RegEx !
@crypticツ yeah.. so that's what i mean. triple enforce negation. statement sentence. use of official as a power word. end nice and slow with benefit for the user in mind...
off to bed, goodnight everybuddy!
gnight
04:58
hi friends..
I have a variable of type object
If i give var_dump($variable)
its printing only the variables in that object(class)
how about functions?
I also want the functions to be displayed..
are functions not a part of the object?
whats wrong with var_dump?
I gave echo get_class_methods($some);
its just displaying "Array"
@udaysagar did you click that link?
@udaysagar how do you 'print' an array? what should that function return?
yes, got it!
05:08
how can i know what a particular function returns(type) along with the function names?
@udaysagar short answer... you don't.
ok..
so, you say that there is no way to predict the return type unless we go into the function definition itself. Am I right ka?
well no
05:40
@udaysagar , stars are for the messages that are useful for EVERYONE and have meaning without the context
okay, alrite.
i ll be careful next time.
06:10
.. i guess this is not what people expected to hear
1
Q: Most MVC-strict php framework

kidonchuI have been trying to wrap my head around MVC pattern for about 6 months.I've read tons of articles, Q&A, and blog posts about MVC and HMVC patterns, but I just simply don't get it 100%. I tried learning MVC by exercising one of widely used PHP MVC framework, CodeIgniter. I've implemented few in...

06:23
@tereško couldn't you explain what does it mean: Views are able to judge several templates?!
How so, then it would break 1:1 relationship or am I completely wrong?
user652649
06:40
good morning
06:55
good mornings!
morning!
What is faster/more preferable: strlen($path) or $path !== "" ?
@hakre the second, and ditch the exact comp if you know you have a string
@kaᵠ why should I ditch the exact comp?
well if you know you have a string in $path, you're gonna compare with another string "", so the types are the same, no need to check for that
07:07
@kaᵠ Well it prevents type-juggling and makes the code more distinct.
Which would be an argument for me to not ditch it.
I normally always prefer strict comparison over non-strict comparison in PHP.
@hakre yeah :) depend on what you have then.
Yeah I have a string and I don't want anything else than a string there ;)
@hakre so you actually want to know that you have a string and if it's emty? that's the comp you need to make there?
@kaᵠ Yes, exactly.
I've just been metricing with only 1000 iterations and the difference is impressive.
I mean for this kind of microptimization shizzle
@hakre consider this also isset($path[0]) it will work on arrays too however but strings HAVE to start at index 0 if they're set
and since isset is a lang construct it's fast
@hakre show me
07:18
1000 Iterations:
 #     Test       Total     Single
--------------------------------------
 1. Empty Loop:  0.00014 0.0000001371
 2. !== "":      0.00019 0.0000001900
 3. strlen():    0.00113 0.0000011339
 4. isset([0]):  0.00024 0.0000002439
strlen is crap anyway!
empty loop?
@kaᵠ That is the test running without doing anything. It is the value you need to substract from all other values if you want to see it isolated.
Theoretically at least.
@hakre better do at least 1 mil iters
a
so strict comp is incredibly fast, unbelievably fast....
btw... that's the way i do it too :P
I will stick to it.
Well I often did with strlen() in the past, but now I was wondering if.
also.. $var+0 instead of (int)$var
07:21
@kaᵠ There I normally prefer casting. To get the INT.
@hakre when you need to know the count you use strlen, actually i never used it for cheching empty struing... find it counter-intuitive...
yeah.. i was bashed here for that, readability they say..
@kaᵠ Yes readability is very important.
true
That's why I think $path !== "" is nice, because it is readable, too.
but i don't agree for that, anyway
looks like 20 times faster too, but how often do you check for 200+ strings at a time for this to matter that much?
07:25
How much storage do you think is enough for a Linux installation to be reliably used as a local development environment for PHP? (i.e. install PHP, nginx, MySQL/PostgreSQL, an IDE such as PhpStorm, and Chromium browser?)
(Also, which installation should I go with? I still prefer GUI for developing)
@MadaraUchiha what linux? 20gb is enough usually
@MadaraUchiha I like Xubuntu
I currently have Ubuntu on my VM, and it's good, but it doesn't seem tailored for development as much as it tries to be a competitor to Windows.
standard Ubuntu GUI sux (aimed for touchables lately)
ubuntu as a distro is awesome, Xubuntu uses XFCE 'gui' which is lightweight and 'like the old gnome/winXp/etc'
@MadaraUchiha also the 20Gb is a minimum, think about what are you gonna save/work on
actually i'm using close to 12gb now
@kaᵠ I don't know how it goes with Linux, but Windows seems to be spontaneously eating up space slowly by itself, I'm guessing this doesn't happen with Linux?
@Gordon sir need to ask you something
07:34
@SalmanKhan What do you need?
I doubt he'll answer you, he wasn't here for hours
@MadaraUchiha need to ask about SO rules and some favour also..
@SalmanKhan I can help you with SO rules, not sure about the favor, but try :P
@Jocelyn Morning
Also, another question about Linux, @kaᵠ
I'm pretty sure I'm doing it wrong, but here's my workflow ATM
@MadaraUchiha actully my friend's id was blocked before 1 month and after 9 hours it will be unblocked but the prob is his chat account is blocked for 1 year.. account was blocked for serial upvoting and blocked for 1 year but because of benefit of doubt it is subsided to 1 month but chat is still blocked for 1 year..:(
07:37
@SalmanKhan Account ID?
Or link to profile, please?
@hakre actually you need to think about it again, give you the gist in a sec...
reading madara...
@kaᵠ I've downloaded PhpStorm, which was packaged as a tar.gz., I've extracted it (to ~/Programs, I now know it's not the best)
And to activate it, I go to Terminal, to ~/Programs/phpstorm/bin/ and ./phpstorm.sh
How can this workflow be improved?
@MadaraUchiha this never happens in linux (unless you're filling up some logs) linux instalations are timeless, with little maintenance you have a well-oiled machine
I'm sure I can somehow place a shortcut on my desktop, or allow me to run it from terminal with a single command
@kaᵠ That's good to know
@MadaraUchiha you have linux already
07:41
@kaᵠ On a VM, yes.
Ubuntu, Unity gui?
aha
so you want a shortcut on the desktop/'quick launch' ?
I'm considering a dual installation with Windows (Gamer, can't give up Windows just yet), but I want to know stuff before I push through
07:42
@kaᵠ I want an improved workflow! I know that this isn't the normal way of doing things in Linux
well you can create a shortcut, but i forgot how to do it in the damn gnome :P simple google serach and you're there (ubuntu has a very large userbase)
@MadaraUchiha On my linux I created a .desktop file (or how that is called) for it so I have a nice Icon in gnome :)
exactly ^ what he said
@SalmanKhan Who's your friend? Please provide a link to his profile
@MadaraUchiha learning to use the terminal is a must in linux (not using it is only for grandmas)
07:44
@kaᵠ I do know how to use the terminal
@MadaraUchiha : sudo apt-get install guake
However it doesn't seem right to me that I need to activate a specific .sh file on a specific location, just to run a program
I mean, I don't do it for anything else
that's gonna make things a lot easier ! :D just press F12 and have a terminal at yo fingers
@kaᵠ Ubuntu has CTRL+ALT+T, but I guess that's fine too :P
@MadaraUchiha yeah so, there's the desktop icon/quickbar icon for the gui mode
07:46
@MadaraUchiha Hmm, activate? What do you mean by that?
@MadaraUchiha man alias man ln
@Jack Run it, sorry if it wasn't clear
@MadaraUchiha Oh ... sh /path/to/stuff?
Basically what I'm asking, how do I properly install and use PhpStorm in Linux? (For example, Ubuntu)?
Because I have a feeling what I did wasn't 100% correct, and with the distro I'm going to install on the PC (not the VM) I want to do it right
moarning
07:48
Hmm, I don't know what kind of storm that is ;-)
moarning.
@MadaraUchiha Ctrl-Alt-T spawns a new terminal emulator, with guake you have the one started and listening (or doing what you want)
I was surprised to see that this method of determining whether a string holds an integer was not mentioned, until today that is :)
07:51
@hakre gist.github.com/godka/5410970 you need to check how it behaves when the var is not set, or when it's empty too for the test to be real (when it's not set, things break...)
@kaᵠ the var is always set.
It is a function parameter.
then.. you don't know if it's a string or not? @hakre
@kaᵠ wel well well, what is this then? a benchmark? :)
07:52
@kaᵠ I hope so, I will test in the testsuite to break it after I've fixed it ;)
@Jack Oh it was just that I was curious.
@hakre What's the objective?
It's for a general purpose library and I wanted to ensure I use some useful code.
@Jack no preg_match() :(((
@Jack The objective is to fix: pear.php.net/bugs/bug.php?id=19315
@kaᵠ Hmm? To check an int? That answer is also there I believe.
07:54
Test is in: github.com/ktomk/Net_URL2/blob/development/tests/Net/… I now just think about how to fix it.
@Jack i see nico did the preg one
@Jack Yes there is a patch I wrote earlier, just reviewing it.
hello
one doubt in zend php
@Jack cool answer !
@hakre Interesting bug heh ... if it's a string it should be tested with strlen() or !== "".
07:57
@Jack you don't test for an empty string with strlen! it makes sense, but really who does that?
while (strlen($path) && $j++ < 100) { ... what the hack is 100?
@kaᵠ I do :)
eww
so it's an ugly way to obsfucate code, that's what it is
You have strange ideas of what obfuscate means :)
basically wit loops till $path is zero length or $j >=100

« first day (915 days earlier)      last day (4258 days later) »