« first day (1296 days earlier)      last day (3655 days later) » 

12:00 AM
Like, wayyyyy out.
 
lol... i will eventually!! dont get me wrong!...
 
@KirstyHarris a lady wouldn't mingle with that sort of stuff...
 
by branch we mean a branch on a different tree
 
Fuck it. Burn the forest. Find a new one.
 
lol... thanks for the compliment CS :P
 
12:01 AM
Terraform a new planet.
 
That'd be sweet.
@Fabien Did you get a load of the black magic I posted?
 
@KirstyHarris , i may only be a fraction talented , in comparing to Dan Lugg, but even i stay away from it.
As i also do not do that , because i like the interaction with some community's .. at the end it is best to make it all by yourself.
 
IN RUSSIA, DEPENDENCY INJECTS YOU
7
 
@DanLugg wtf. How did you even get there?
 
i am trying @HenryW im all self taught... i get asked to do a favour and get dragged in to a crap theme to sort by someone who cant code lol
 
12:03 AM
Whatcha mean jelly bean? (I'm not in Russia if that's what you mean)
@Fabien I wonder if that approach has any value though.
I've seen it used for AOP, among other magic like eval'ing proxies on the fly.
Anyway, more beer.
 
heh
 
@DanLugg you scare me lol
i dunno what to say or think
 
well how good is this coder! this agency! his coding doesnt work with newest wordpress... fantastic!
 
was just thinking of moving to the fridge
 
ping @HamZa and @Ocramius
 
12:10 AM
sup
 
ack @crypticツ
 
@DanLugg you know I wrote github.com/Ocramius/LazyProperty for that, rait? :)
 
@Ocramius You wrote some unit tests for my stack-csp repo. I've transfered the repo to Simon and he wants to change license from MIT to public domain, would you be ok with that?
 
what is "public domain"?
No, I want it to stay under MIT
otherwise, remove the code while porting it
 
utterly free
what's wrong with mit?
 
12:12 AM
indeed
 
I don't know, he wants to change the license
 
mit=mention the name...
basically
 
tell him that to change the license he has to remove all code coming from any of my commits
and re-write it from scratch without copying
 
blah, ok I'll message him and point him to this convo.
I'd rather he not change it at all, don't know his reasoning.
 
Sorry about that, I just believe that moving code under a license that gives no attribution is wrong
unless I got paid for it
 
12:16 AM
not your fault at all. I understand, I feel the same.
 
it's ok for small chunks of code..
 
@CSᵠ as long as all my code is removed from it before the license is changed, I'm fine :)
 
well.... not really, it's debateable (general case, not this)
 
No, it's not debatable. It's something that is accepted because minor contributions are easy to replace, so if someone complains, it can be fixed
it doesn't mean that it is OK to port code, even minor chunks
 
if a bit of code made it possible for a greater thing to exist...
 
12:20 AM
if that happens, it's because the author could not get contacted
@CSᵠ you'd still need to rewrite that bit
 
yes, but it wouldn't necessary make it fair
 
I don't want to be fair to licenses I don't approve :)
 
that;s perfectly ok
@Ocramius so, this is only fine if you agree to it, reworking some functionality to make it completely yours is wrong too!
there are just too many ways you can write something to do the same thing
 
you just need to rewrite it without copying from mine
and yes, it's still a delicate thing
 
Or just leave it as MIT license because why the fark not.
 
12:36 AM
i can't see either why one would want to change from MIT to PD after working over something started by someone else...
 
Also, Simon == phpnoob?
 
@Danack yeah
 
I wonder, would it be so fucking hard for youtube to list the subscriptions the the fucking alphabetical order!
(the thing's I have at 4 AM)
 
@Ocramius lol, I was going for transparency though; autoproxying $this when possible.
 
@DanLugg "autoproxying $this" and "transparency" in the same sentence
hmmm.....
 
12:47 AM
@tereško I've wondered the same thing. I don't even go by the name anymore, but rather the channel photo/icon
 
they have been trying to the everything they possibly can to stop people from using subscriptions , i guess
a year or so ago, the "landing page" was the subscription feed
 
@tereško There are 3 little dots in a column (on the desktop version) clicking that will allow you to select alphabetical.
 
now it is the "what to watch" page ... other otherwise known as "some retarded crap somebody else in my country favorited"
 
If people use subscriptions then they primarily stick to them, thus reducing visits to random videos. Google wants people to get lost on the site =oP
more views more monies!
 
anyway, time to put on some podcast and go to sleep
 
12:52 AM
Good point. s/transparency/magic/
 
It's like bullshit thing RayWilliamJohnson did, instead of having 3-5 video reviews in one video, he broke it up into 1 video review in 3-5 seperate videos. Just to inflate views, dick move, made me unsub.
 
I always thought he was a first class douche.
Mind you, I haven't watched much of his material, nor read much about him.
So, snap judgement, but meh.
 
Hmm
110k of json data about what a php app is doing internally... acceptable or madness? :)
 
Like, tracing data, or config?
 
contains stack traces, triggered events, a copy of the app config
etc
planning to build an angular app around it
 
1:00 AM
Well, depending on the longevity of the file, 110k could be ... small.
It's relative no?
 
what do you mean?
 
I mean, if the file in question is modified (and grows) with time, then 110k isn't that big, depending on the age of the file; it's relative to the age.
 
oh, no, every request has its own file
 
Oh.
Meh, even then.
 
basically, every application dispatch produces a mini-dump of a load of stuff
 
1:01 AM
So, it's like a snapshot of the application?
 
right
 
Ah okay. Well, that's not bad.
 
And it's probably hugely useful.
Can you reinitialize the application to a given state?
 
that's my plan, yeah
 
1:02 AM
That'd be fucking awesome.
That'd be one hell of a graph to build though.
 
oh, and it contains the composer.lock too :O
lol, forgot about that
 
lol
var_export() should be able to handle recursion.
 
hmm, no, I can't really serialize the app state
because closure scope
 
Right, right.
 
but my aim is producing a tool where I (freelancer) can basically get an idea of where the customer fucked up
 
1:04 AM
If closures were serializable, you could theoretically recreate a version of var_export that handles recursion.
 
yeah, there is super_closure, but it can't serialize the scope
 
Yea, super closure is poo.
Frankly, it's broken because of the dependency on line numbers.
 
can't do much about that :\
 
If PHP supported file byte-offsets for constructs (such as $reflectionFunction->getStartByte()) you could totally do it though.
 
I guess "don't write stupid stuff" would be the best advice there
 
1:06 AM
^^ Yea, but where's the fun in that?
 
:P
 
Seriously though, I think reflection should support byte offsets
You could seek to wherever, and start reading.
I dunno how fundamentally that'd change the engine though. The token struct (or whatever) would need to change.
But being able to save and restore an application to a given state... that's pretty damn wicked.
@rdlowrey could possibly benefit from that with his HTTP server.
If it comes all but crashing down he could restore the state.
 
well
one particular thing I could need is reading stuff around constants :P
 
As in redefining them?
 
nah, I mainly needed to support annotations on those
but that's probably not related with the cursor
 
1:10 AM
lol, I was just writing an annotation component.
Now I'm dicking around with proxy madness.
 
heh
I'm waiting for HHVM's Closure::bind() to go on with mine...
 
They don't support it yet?
 
nope :(
it breaks too many invariants in the JIT
 
dafuq? That's poo.
Oh
 
I wrote a patch for it, but it worked only without JIT enabled
 
1:13 AM
What happens when it's enabled?
 
I couldn't care less, but that's the sell point of that thing
 
What can't it do?
 
it just crashes iirc
 
Oh okay.
I'm working on an RFC for function prototype definitions; sometimes called delegates.
So rather than Closure or callable, you'd be able to typehint against them.
 
like proto = callable(Foo $foo) : Bar?
then function (Foo $foo) : Bar { return new Bar; } can be used where you type-hinted proto?
 
1:16 AM
Pretty much, I think.
prototype FooBarPrototype (Foo $foo, Bar $bar);

function acceptsFooBarPrototype(FooBarPrototype $callable) {
	$callable(new Foo, new Bar);
}

acceptsFooBarPrototype(function (Foo $foo, Bar $bar) { }); // all good

acceptsFooBarPrototype(function (Qux $qux, Zip $zip) { }); // fail
The second one fails the type check because the signature is different.
 
I like that, but what's the difference with an invokable object?
ah, nvm
 
Yea, invokables would work too; __invoke would just need to match the prototype.
I'm thinking they, like functions, can live in global and class scope.
function acceptsGlobalPrototype(GlobalPrototype $p) { }
function acceptsClassScopePrototype(\My\Namespace\SomeClass::ClassScopePrototype $p) { }
Subject to visibility modifiers, etc.
 
Yeah, I'm not sure if I'd prefer an interface at that point
and implementing it
 
^^ but you can't typecheck a closure against an interface.
 
though GO does that (ircmaxell suggested such an RFC, no?)
yeah, but I wouldn't use closures there
 
1:19 AM
That's structural typing (IIRC) and a bit different
That's like assertions about the behaviors and state of an object.
Without doing so via a named container (interface)
I think the prototype idea might be cool though; it could easily support return types as part of the check, and if we ever get generics that'd be fucking incredible.
 
well
 
class SomeClass<T>
{
	public prototype SomePrototype(T $arg);

	public function doSomething(self::SomePrototype $callable, T $arg)
	{
		$callable($arg);
	}
}
 
I don't see a difference with your impl tbh
except that one allows multiple methods
IIRC, Closure implements __invoke internally, so any interface defining __invoke could be used
 
^^ Yes it does.
The point was to make assertions on anonymous callbacks.
Basically, defining the implied contract outside of, without explicit reference to, the anonymous function.
They're quite powerful in application; maybe they wouldn't be as powerful in PHP as statically typed languages, but still.
They help you define expectations, without resorting to E_FATAL out of nowhere.
 
Yeah, what I mean is that the two RFCs match if instead of having a dedicated prototype syntax you'd have the usual interface stuff
 
1:27 AM
Hmm. So repurposing interfaces with respect to __invoke as you described.
Wait, can you do that now?
Nah, you'd still need explicit reference to the interface in question.
 
right
 
Yea, I'm going for implicit satisfaction of the "interface", or prototype or whatever.
 
but if PHP used the signature of Closure (which is something like public static function bind(); public function bindTo(); public function __invoke();) then that's it
 
So, it'd just need to do a 1-to-1 on __invoke (internally)
Maybe I'm not understanding.
 
well, your prototypes could work both for closures and other objects
with any signature
maybe I'm pushing it a bit far ;-)
 
1:35 AM
The way I foresee it; the parameters expected for an invocation (defined by __invoke for an invokable type, stored in the aether for closures, etc.) are checked against the parameter list defined by the prototype. Just a 1-to-1. If they match, satisfied. If they don't, E_FATAL with a descriptive message.
Each of the "invokable" types will probably need to handle this check slightly differently on an implementation level, but because PHP.
 
correct
 
That's it.
 
yeah, well, all other invokables resolve to methods
or functions
hmm, yeah, function sucks :X
 
1:48 AM
Super proxies would work if we could get around interfaces.
As in, if we could somehow force PHP to allow a non-implementing type to pass a check.
 
"Super proxies"?
 
lol, yea.
^^ non technical term.
I mean, proxies that envelop the lifetime of the object entirely.
And all objects they touch.
 
@DanLugg it can be done easily :D
it just is a bit ugly
 
What, on-the-fly eval?
I hate that shit.
 
lol
yeah, but that's how I roll
 
1:50 AM
Every AOP package does it that way.
 
lol
I sent that to my girlfriend yesterday; she lol'd.
 
and I copied it in boom :D
this monster can do it :D
 
Point being, intercepting the autoload to generate a class proxy is poo.
 
no, I don't do that in the autoloader
but yes, it needs eventual eval at runtime if you didn't cache the proxies
 
1:52 AM
Fuck, if only __call was magic for "Don't worry bro, I satisfy all interfaces"
Either way, that's pretty nifty.
Gotta the woman is complaining about me drinking and computing all day.
Check ya later dood.
 
 
2 hours later…
3:40 AM
Hi...
 
3:53 AM
hi,
 
4:23 AM
stackoverflow.com/a/3126175/168868 -- completely rewrote my "classic" answer on escaping / validation order of operations.
 
5:12 AM
@crypticツ if you pinged me because of that regex, I don't care if the license changed.
Morning
 
5:39 AM
hi,
 
@Muhammad hi
 
its strange, gives mysql error.
 
@Muhammad lol, an error?
 
this error, You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '²Ü¥zÈ^z×,' at line 5
but I have no query on this file.
 
@Muhammad well I need some code to work with.
 
5:42 AM
ok
hi all, can anyone look into this strange error?
 
I am having IIS 7 and wamp server in my system. I need to work on XAMPP. I have installed it. But I am unable to access PHPMyAdmin and other things. How to find which port XAMPP is working?
 
@Muhammad again, you need to show some code in a pastebin. We can't guess, there's definitely a query going on there. Unless you have echo'd that error message
 
@Muhammad I had the same error while I work
Please wait
I will recollect those things
 
@gunaseelan is apache of xampp running on the same port as the apache from wamp/iis?
 
5:46 AM
@Muhammad are you using a free hosting provider?
 
use htmlspecialchars function while insert the content
 
@HamZa no its on godaddy
 
also while retrieving the value we need to check
 
@Muhammad are you using some htaccess magic?
 
yes
 
5:47 AM
@Muhammad maybe you're rewriting style.css ...
 
@hamZa here is: RewriteRule ^([-@./#&+\w\s]*)/([-@./#&+\w\s]*)$ /details_post.php?id=$2 [NC,L]
@HamZa only for one file /details_post.php, not for stylesheet.css
 
@Muhammad do you have a rewritecond ?
 
@Muhammad check the content type
the db may have different content type
Please check it with htmlspecialchars
 
@gunaseelan @HamZa here is the whole .htaccess pastebin.com/6EGRVkBL
 
@Muhammad there's your problem
 
5:51 AM
@gunaseelan how to check the db content type?
@HamZa what?
 
@Muhammad add these 2 rewrite conditions:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([-@./#&+\w\s]*)/([-@./#&+\w\s]*)$ /details_post.php?id=$2 [NC,L]
 
Any sample data that can never be parsed with RegEx?
 
it means if the requested thing isn't a file nor a directory then apply the rewriterule
 
@HamZa ok, let me check
 
@shiplu.mokadd.im /.*/ could match everything
 
5:54 AM
The reason I am asking, I am taking tutorial class on regex and my students seem to parse anything with regEx.
@HamZa I am looking for data not pattern.
 
@shiplu.mokadd.im Well you said "data that can't be parsed" and I told you this simple pattern will match anything
Sooooo, define can't be parsed
 
@HamZa Great, thanks it works.
 
I know irregular language is not parsable with regex. Any good example for regular data.
@HamZa you are mixing parsing with matching.
 
@shiplu.mokadd.im well, you're asking the wrong dude since I do match irregular language :D
 
i will be back in 10 mins
sorry for the trouble
 
5:57 AM
@Muhammad welcome
@shiplu.mokadd.im something like this if your students aren't advanced users of regex "test, test1, test2 (some, data), test3", tell them you want ["test", "test1", "test2 (some, data)", "test3"] as output
but if they are resorting to SO, then it's another story...
 
like ["test", "test1", "test2 [some, data]", "test3"] ?
 
Hmmm, my idea was to split on "," but not those that are enclosed between brackets
@shiplu.mokadd.im this problem that I encountered earlier stackoverflow.com/questions/23376145/… which normally requires a parser
 
The idea is to show that not everything is parsable with regular expression.
For example recursive data.
Like (2+3+(2+3*(2+3+(2+3))))
 
@shiplu.mokadd.im what engine are you letting the students use?
 
Any!
But its the regex they should use, no programming language construct.
like function, loop, etc
 
6:05 AM
@shiplu.mokadd.im what's your expected output of that expression?
 
@Muhammad Have you find the solution
?
 
@shiplu.mokadd.im Anyways, I think the ultimate and most "real" example would be to parse HTML. You ask them to parse a certain div with class = "test", you will show them what could go wrong. Say for example you have: http://pastebin.com/Q7Pns0WN .
The things that could go wrong:
1- instead of double quotes, there's single quotes. No worries, we could use ("|') and \1
2- spacing class = ".." instead of class="..", could be solved by adding \s*
3- Nested divs, could be solved using recurisve patterns
@gunaseelan yeah, he needed some rewritecond stuff
 
6:22 AM
thanks @HamZa
 
np
 
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^([-@./#&+\w\s]*)/([-@./#&+\w\s]*)$ /details_post.php?id=$2 [NC,L]
please explain this
 
32 mins ago, by HamZa
it means if the requested thing isn't a file nor a directory then apply the rewriterule
 
thanks
 
6:38 AM
@shiplu.mokadd.im Also see this stackoverflow.com/questions/20082476/… (check the comments, I lost some rep there lol)
 
6:51 AM
if you want to do something useful with all this regex, I require a message parser for irc and am too lazy to write it ...
 
@HamZa Thanks a lot for the problem set.
 
@JoeWatkins specs? deadline? repo? language?
@shiplu.mokadd.im welcome
 
!) RFC1459 2) none, will explain 3) DatingVIP/IRC 4) PHP
there's no deadline because what I have is working for what we need, the messages appear to come in two (at least) forms from the server, the user messages we want to process are easily parsable, but to have events like onJoin and make use of user lists and what not we require to be able to parse server messages reliably too ...
 
@HamZa About 7, do you think its possible with look ahead assertion with non-fixed length pattern support?
 
current code makes mistakes...
bit bodgy ...
 
6:56 AM
@shiplu.mokadd.im 7 easy since we need to use </div\s*> instead of </div> (most people forget this though)
 
Okay, my mistake I thought you meant 7 when you say "Now if any of your students ..."
 
@shiplu.mokadd.im I meant that if any student were to think about all those 7 situations, they are most likely knowing what they are doing using regex. Make sure they don't use SO :P
@JoeWatkins Saved the conversation link, I will think about it
 
ta, much appreciated ;)
 
7:11 AM
Is it efficient to use readfile() to display an image?
And should i use Output Buffer?
 
7:58 AM
0
A: php 5.5 memory leak when using "continue 2" inside two foreach loops?

Joe WatkinsWAIT !! You should not disable opcache: as well as caching, opcache performs optimization. Optimization means that opcache changes the compiled opcodes. I am certain that it is the case that tuning optimization will show you where the bug is introduced, this will mean you can create a bug repo...

morning @hakre
/me grumbles about shitty answers being accepted ...
 
MorninggningroM
 
nin
 
/me cleans up php tags again :)
 
8:13 AM
@JoeWatkins delete it…
 
how ?
 
by asking 20+k users
 
there's none on my sofa ... the misses doesn't use stackoverflow and nor does my friend ...
:D
srsly tho ... dunno how ...
 
@JoeWatkins here in chat I mean
^ @Joe this way...
 
I c
29 secs ago, by bwoebi
http://stackoverflow.com/a/23370954/2153758
^this
 
8:17 AM
lol
A bad idea: removing hard links with rm -r...
 
@RonniSkansing it is with prevent default also not worked, but now i have seen that he never go to my ajax script and now i have the code without any javascript just two forms one submit
 
what?
 
do you remember the problem yesterday but still the same thing, but I doubt even the code to clean up and only the relevant pieces left
 
yea
@averroken did you get it fixed then, else paste the code and lets have a look at it again
 
8:36 AM
reduced to 112 lines i have typed ... where code intervenes I removed
 
http://pastebin.com/9wsCggEF

voila reduced to 72 lines, I do not know if any remained essential but suspect it, I've noticed that he even echoes in isset saving change in php side does not, but when I press submit button press to pop all the fields of the account information (form popup) empty
the first form
 
I do not understand the question.
 
http://pastebin.com/RZXgVXgK

with the form with class company that is the first form when i click on the link opslaan then the popup show that's the form with class reveal-modal but i click in the form reveal modal on the submit button and all the fields are empty by the form company(after sql UPDATE query i think) but i have observed that he not goes to php, my echo echo 'mmm'; does'nt show is that normal while my fields are well empty after submit, or is it possible that the fields of the form company are empty by submit the form reveal modal?
 
morning
 
Morning
@averroken I am still having a hard time understanding. Maybe we can break it down to just 1 thing at a time.
 
i have this form (the first with class company)

<form action='$_SERVER[PHP_SELF]' method='post' class='company'>
<p>
<label id='IDnaam'>Naam:</label>
<input type='text' id='IDnaam' name='naam' value='$naam' size='25' required />
</p>
<input type='hidden' name='wijzigid' value='$id' />
<br />
<a href='#' data-reveal-id='myModal' data-animation='fade'>OPSLAAN</a>
</form>
 
@averroken There's only one problem: You need to organize your code.
 
@averroken simply hit CTRL + K
 
that is my main form when clicking the <a href="" ....> the 2nd popup form will appear for password verification

That's that:

<form action = "<? php $ _SERVER ['PHP_SELF']?>" method = "post">
<p>
<label> Password: </ label>
<input type="password" id="IDwachtwoordcheck" name="wachtwoordcheck" />
</ p>
<input type='submit' name='opslaanwijzig' value='opslaan' class='opslaan' />
</ form>
and after click on submit with name='opslaanwijzig' all the fields are empty but he doesn't show echo within that: if (filter_input(INPUT_POST, 'opslaanwijzig')){

but does he than the sql update or nut but all the fields are well empty by the basis form
because thats within the if input_post opslaanwijzig
 
clear ?
 
Nothing interesting around. Later.
 
9:23 AM
@averroken =/ no..
 
Morning
 
Morning
 
morning
 
=/ sunday
 
9:40 AM
Hi
 
well .. it's independence day today, so monday is free too
 
@DanLugg There's no dependency injection here in Russia. Only statics, only hardcore
 
=/ I thought it was in a month
 
Morning
 
9:46 AM
morning
 
i send the demo and db and you can test and see
 

« first day (1296 days earlier)      last day (3655 days later) »