« first day (2187 days earlier)      last day (2987 days later) » 

10:03
EventSource doesn't sound too bad ... would Source do the same thing ? (full name is UI\Source)
@ChrisBeckett may be helpful: gist.github.com/DaveRandom/c87c5e2549287d8a8c4f9e676a510679 - tl;dr I think you can do most of the legwork here in SQL
also, what would the method name be there ?
Is it worth testing type hinted methods for the correct reaction? E.g. testing a non bool input on defined method foo(bool $input) to see if it throws a TypeError?
Just in case the implementation changes for whatever reason at a future point
10:05
it would break a million tests in php-src before yours
@DaveRandom That example will only bring back 4 slots right?
@ChrisBeckett gist updated with a couple of fixes
@ChrisBeckett No it would bring back any matching slots for all children, it would probably need some post -processing, but it will get you all matching available time slots
obviously I've made a lot of assumptions about how your DB is laid out
the multiple endTime thing is because I've assumed PDO/mysql
@DaveRandom I'll have a quick try of this and see what I get back :)
which doesn't let you re-use named params
also time is a proper headfuck
are Source and handler bad class and method names ?
I hate wasting time on words for humans, so an okay from any human means I can carry on ...
10:10
@JoeWatkins E_MISSING_CONTEXT
The class name Source on it's own sucks, but a namespace might solve that
31 mins ago, by Joe Watkins
class Button implements SomeEventInterface {
    public function handleEvent() {

    }
}
@DaveRandom UI\Source
Source of what?
What am I getting from it?
events?
yeah I know ...
Source is the thing e.g. clicked?
EventSource is fine
DataSource is semi-fine
10:12
so many words though
so EventSource and handler then ?
Also handler is not a good method name, a method is a verb, not a noun
EventEmitter, unless the button is actually reacting to an event
@DaveRandom I'm getting errors in mysql with the ":"'s they're showing as unexpected characters
@ChrisBeckett they are named parameters to a parameterised query in PDO
if you are using mysqli they need to be converted to ?
and go through all that binding garbage
10:14
omg
@DaveRandom I'm using mysql
not mysqli
@ChrisBeckett really quite important that you stop doing that right now
maybe I should forget about the interface altogether ... and just have Button::onClick, Radio::onToggle and so on ...
other ui's (swing/.net) are doing closer to that ...
@DaveRandom not my choice, the company I work for all their work is in mysql not mysqli
this is better, right ?
what if a control comes along that has two events
none of them do yet, not at the libui layer, but they might come ... there are controls with more than one event ...
also, mouse/key events ... which look supported
10:16
@JoeWatkins tbh I think that because PHP doesn't have actual events, on(string $name, callable $callback) is the way to go
yeah well ... callables are a bit of a shit ...
@JoeWatkins I would rather look at JS I think
@DaveRandom - I've got all the meetings and i've got the children. Can I not create a method to work out what i need?
And yes I am sorry for suggesting it
The alternatives are all horrid
@ChrisBeckett You can, but an RDBMS has the tools for doing this kind of relational work built in
10:18
using callables now, but it's not very nice, closures are not good for repeated invocation
@DaveRandom Ahhh I see. Would you possible give me little help on where to start for the method if I was not going to use RDBMS?
@JoeWatkins Well then the alternative is to inject a ButtonEventHandler into the button. ButtonEventHandler is an interface with handleClick(), handleMouseDown() etc. It's horrid in many ways.
@DaveRandom As I think in my original message where I posted the method I created, I was heading towards what I needed. I just need little help to adapt it to further what I need
I think I'll defer to pro's and just forget the interface chris ... nobody is doing that ...
@JoeWatkins amphp does it for the exact reason you just said (closures suck for repeated invocation)
10:22
@DaveRandom You cannot spell BDSM without mysql
@ChrisBeckett Essentially you just need to implement the logic that's in that SQL
moment
Strange question, if you're interacting with an API and it returns a failure (e.g. structure level - invalid syntax, or business logic level - address not found) should the SDK handle that by throwing an exception for all kinds of rejections (with specific exception types), or just return a result which indicates the request failed.
API rejections should kind of be expected, so I don't really think it would warrant exceptions, maybe schema/data errors should throw one.
@JoeWatkins your alternative to that is to inject EventHandler which just has handleEvent(string $name, ...$otherArgs)
$openButton = new class($window, "Open File", $openEntry) extends Button {

	public function __construct(Window $window, string $text, Entry $entry) {
		parent::__construct($text);

		$this->window = $window;
		$this->entry = $entry;
	}

	public function onClick() {
		$this->entry->setText(
			$this->window->open());
	}
};
@Sean If you know what can go wrong it's nice to have proper exceptions
10:24
this is so fucking horrible
@JoeWatkins This is precisely what you do not want
You can always extend some base exception if you want to catch them all somewhere higher up the chain
UI controls need to be observable, you don't want to have to inject half of your application into every fucking control
yeah fuck that, I'll just stick with onWhatever(callable)
but it's so bad ... and leaks ... they are probably pluggable, but it's still horrible ... but less horrible than that^
@JoeWatkins The thing is, any sane application will not be passing closures, they will be passing method refs
10:26
@JoeWatkins Can't you just emit events?
refs ... you mean arrays ... that's not really better ...
that means lookups ...
come to think about it. EventSource is probably not a good name since the Event is not the Source. The UIControl is the source of the event. Technically not even that, since the source is the human that clicked the UIControl.
Target?
I have a headache ... I just wanted two words ...
10:28
Naming is hard
I usually get by, by not thinking about it very much ...
Just cobble something together and let people dick around and yell at you
@JoeWatkins Indeed, but I suspect that the other way around (i.e. the huge IoC violation) would only be deferring that problem anyway. You'd end up with loads of people just injecting external handlers
I would rather be bound by dependencies that were injected than to lexical scope, how is it any better to use() your dependences ... I don't see a remarkable difference ...
@JoeWatkins That's the point, you don't do that. You use other objects and method refs.
The dependencies are held by an object responsible for dispatching UI events to them
The control is not responsible for dispatching it's own events
and sometimes multiple dispatchers listen to a single control/event
10:32
Holy shit. Samsung officially stopped production of the exploding notes
That's one way to burn through money :P
Anonymous
their replacement note explodes too \o/
That's old news
Anonymous
shut up.
They actually stopped production now
Like fuck that entire product we are going to take our losses and never look back stopped
That's kinda huge
Anonymous
my Tim must be celebrating
10:34
Yeah I think so too
Yeah read it. Totally surprising
guys
a qurestion
Who invented Semicolon?
l mean this ;
10:38
Probably the Sumers or something like that
> The first printed semicolon was the work of the Italian printer Aldus Manutius the Elder in 1494.[3] Manutius established the practice of using the semicolon to separate words of opposed meaning and to allow a rapid change in direction in connecting interdependent statements.[4] Ben Jonson was the first notable English writer to use the semicolon systematically. The modern uses of the semicolon relate either to the listing of items or to the linking of related clauses.
4
Q: Why ; is called semicolon and what is its history?

caxekisSemi- is a Latin prefix meaning "half" and colon is another punctuation. Should I therefore say that semicolon is a halved colon?

hi guys may i know what are the types of joins will support in mysql.
!!google joins mysql documentation
Search for "joins mysql documentation" (https://www.google.com/search?q=joins+mysql+documentation&lr=lang_en)
• MySQL :: MySQL 5.7 Reference Manual :: 14.2.9.2 J… - MySQL supports the following JOIN syntaxes for the table_references part of SELECT statements and m… (http://dev.mysql.com/doc/en/join.html)
• MySQL :: MySQL 5.7 Reference Manual :: 9.2.1.9 LE… - MySQL implements an A LEFT JOIN B join_condition as follows: Table B is set to depend on table A an… (http://dev.mysql.com/doc/en/left-join-optimization.html)
Thanks @Gordon
10:43
it seems algol was the first to use semicolon as a terminator
thank you @Gordon @Jeeves
@abdul You're welcome!
2
@Jeeves please learn these two dad jokes: twitter.com/codepo8/status/785594644180537344 /cc @Fabor
@Gordon
sorry iam poor in english
can you give me only the name
from the link you sent
Anonymous
10:54
@HamreenAhmad Aldus Manutius
@PeeHaa and @thepeoplenotheretoday Thanks for your help yesterday
defuse encryption works like a charm
@HamreenAhmad huh? I don't understand.
@JayIsTooCommon the Elder
Anonymous
nah I'm young
@JayIsTooCommon and naive and need the money?
Anonymous
damn right
10:56
go ahead. best time of your life.
actually, that's a lie :D
Anonymous
:D
Anonymous
I'm a fan of this 404
I wonder how many portal players saw the cake and/or its recipe
@Ekin the cake is a lie
11:03
thanks @JayIsTooCommon
@Gordon is it :-)
\o
@Valentincognito \o/
@Ekin a recipe of a cake is not a cake!
Anonymous
> Reacting to the news, investors wiped $13.2bn (£10.7bn) off Samsung Electronics' market value
Anonymous
11:13
sheet
yeah, samsung (SSNLF) was $1600 last week (on nasdaq). it is now $1300, currently
so ... yesterday I was convinced it is November already
I also managed to convince others
@Gordon well, there are a few glitches in portal 1
though it seems the cake is still a lie since everything goes through it
Anonymous
11:37
@PeeHaa They're compatible with the third world!! applausestore.com/book-the-grand-tour-rotterdam
Yeah. They have been here before
Anonymous
1 hour ago, by JayIsTooCommon
shut up.
:P
Just get it over already. I want to torrent the show nooooow
Anonymous
I hope it's gooood
why all IT security consultants are so mad? any guess?
11:45
@JayIsTooCommon Yeah same. They better not cock this one up
Anonymous
@PeeHaa I doubt they will but ya know, umerica
Anonymous
!!wotd
bailiwick: a person's area of skill, knowledge, authority, or work.
11:59
fun fact: I was just offered a job in London, but declined due to "family, brexit, salary".
what was the real reason ?
that is the real reason
well, and me being happy with my current job
105
Q: Physically locating the server

MichaelI've got a CentOS server somewhere in the building; I can login into it remotely and VNC, etc. Now I've got to physically move it, and for that I need to physically locate the machine among the lookalikes around the office. What can I do remotely to make the machine visibly or audibly identify i...

did the change the link color? It looks darker.
Dunno
12:01
ah, its SF not SO
lol
"sorry wife, I can't clean the house because brexit"
it sorta sounds like that ...
oh oh, you'd get getting paid in gbp I suppose ...
@JoeWatkins I cannot relocate when wife doesnt agree. I will not relocate to a country that doesnt want foreigners and I wont work for 60k GBP, especially not in a city that is among the most expensive in the world.
yeah, don't do that ... I learned a long time ago to get paid in usd ...
hence family, brexit, salary
12:05
didn't think about currency ...
60k is crap also
@Gordon 60k for London? Did they offer a comfortable spot under a bridge? Do the kids get to fish on the Thames?
hehe
I dunno about don't want foreigners ...
@JoeWatkins 52% said so, heh
no, they didn't ...
Anonymous
@JoeWatkins well that's depressing
12:07
any country that doesn't take the likes of @Gordon, or any of us, is just harming itself, I don't think anybody voted for that ... at all ...
Yeah, sorry, they indeed didn't directly say that :)
@Ocramius to be honest, I've never seen much better salaries advertised. Not in London, nor elsewhere in the UK. I heard from the Britons in here that more is possible but I've never seen it in job ads.
the best pay is in the valley, I think it will always be that way ...
@Gordon when I was working in Bristol, I was getting ~600GBP/day, probably highest paid contractor in the building tho
that makes it ~160K/year, if you work a full year, but that's not what you get when contracting
salaries are always less than short term contracts/freelance stuff though ... by a whole bunch ...
12:09
@JoeWatkins I also dont want to be put on some sort of list or get my employer shamed because they hired me :)
that's not going to happen ...
I don't agree with what they want to do, but it isn't that ...
Anybody uses that windows subsytem?
I'm extremely uncomfortable with the uk being viewed as backward ...
My tails always return an error
> tail: unknown systemfiletype 0x53464846...
@JoeWatkins after having lived there for 9 months, it kinda is all backwards, eh
@JoeWatkins I know it's not all of you, if that helps with anything
what you're really saying there, is that it's only the people who voted to leave that are backward ...
there is this assumption that if you voted to leave, you done it for dishonourable reasons ...
Anonymous
^
Jeeves' exceptions are scary, 40 layers in the stack lol
the uk doesn't work for me the way it is ...
12:20
@JoeWatkins I am mainly saying that I don't think the UK as a whole, which would include you, is hostile to foreigners or pro-brexit. I only tried to make you feel less uncomfortable.
just to be absolutely clear, I voted to leave, I am pro brexit ... and you just made an assumption, again, that this is a bad thing ...
I do believe it is a bad thing. I made that very clear when the vote was on.
but you believe it's a bad thing because you assume that it was done for bad reasons ... you can only see bad reasons ...
I tried to follow/understand the arguments of the pro group, but I don't share their opinion
@Gordon actually, when I tried to discuss this with you, you refused to read an article that summarised my position because you rejected it as being nonsense. That's .....not exactly trying to understand.
12:29
I rejected the article because of that particular author. I did read many many more articles in various newspapers (german, british and american) to get different POVs though. Pro didn't convince me.
Doesn't have to convince you. Just was meant to show that people had different view points and that trying to shame people for voting a particular way is not a nice thing to do.
I've no doubt that a number of people voted to leave because they thought we were going to kick all the brown people out, but I've also no doubt that they are a minuscule minority ...
@Danack I am not shaming anyone.
there will be no other opportunity to affect real change in my lifetime, general elections come and go, political parties change and nothing changes, not for me, I still struggle, it wasn't that long ago I was homeless ... I won't be able to afford to own my own home for maybe another decade, and I might never finish paying for it ... what I was voting for was change, real change ... not a perfect world outside of the eu, but for a lot of people, it can't actually get any worse ...
@Gordon I dont think majority in people who voted pro-brexit did it because of immigration
oh .. sorry, looks like Joe already said that
12:48
it's well understood that we'll have to reconstruct our economy outside of the eu, it is the economy that keeps those of us that are down, down ... anything has to be better than what we have now, where a couple on minimum wage don't earn enough to feed one child (below avg) without handouts from govt, where they can't afford rent without handouts ... I consider myself rather lucky, I earn much better than most ... the day to day of living like that gets you down
they were given an opportunity to smash everything to pieces and rebuild it, and they took it ... without thinking at all about foreigners ...
... and the students went all hysteric
:D
that couple, they will never afford their own home, and research says they don't have enough savings in the bank to cover one months rent, so it's safe to assume they live on a knife edge .... that's a huge huge number of people, and they really don't care about the colour of your skin, or the country of your birth ... they care about how to feed their child on 20 bucks a week ...
Do we actually say please fill 'in' or 'out' this field ?
:o
TBH, I think the correct answer would be "neither"
Shoot
12:57
I am not a native speaker (dont trust me)
Hmm
okay
@tereško I think you fill in a field, but fill out a form. but not a native speaker either.
1
Q: "Fill in" or "enter" the text fields

DalamberIn the documentation file I am working on right now, I have to inform user about filling some optional and mandatory text fields. Which verb better describes the "putting some text in the field" - "fill in" or "enter"? Here are two examples: In the newly opened Add Currency window (see Picture...

29
Q: "Fill out a form" or "fill in a form"

aviraldgDoes one fill out a form or does one fill in a form? I've gotten different answers from the people I've asked. Google search results: fill in a form — 14,200,000 fill out a form — 7,000,000

this ^
@Gordon that's what I want to say, but I can't explain why
I don't think I need to be able to explain why, that feels right to me ... it's how I would say it, so it's how I'd write it ...
Anonymous
@JoeWatkins All true, very well put
Anonymous
13:10
pinggss
Oh look. The poor kid just got some internet
Anonymous
back off
where?
whereto?
where to?
Anonymous
lol, ass.
Anonymous
Find rust alternative please btw kthxbye
13:12
I thought you were on it?
Anonymous
I'm not good at making decisions
Ugh you're a pussy
Anonymous
<3
@JayIsTooCommon I will only never stop complaining to you if it turns out to suck :P
Anonymous
\o/ :D
Anonymous
13:19
!!remind @PeeHaa find rust alternatives in 5h
Reminder set.
ugh
@JayIsTooCommon Pings still don't work though ;-)
Anonymous
> HELP ME PLEASE. I'M LOSING A GOOD JOB opportunity
Anonymous
13:20
@PeeHaa expect a formal complaint
hands up if you have an imacbook thing ?
Don't forgot to ping @Ekin in the ticket :P
@JayIsTooCommon Also [email protected]
I'm going mad trying to translate verbs from first person to third
... without nlp tools ... don't ask why
@Ekin Oh lol. Yeah that sounds like fun :P
@JoeWatkins o/
got 5 minutes ?
13:22
Does it involve said macbook?
it does
Sorry :(. Not home atm
ah np
I should really get my hands on an ibookmac thing ...
but then I'd have to learn about macs ... so actually I'm not doing that ... I'll just wait ...
I hate working on the thing
they're all pretty terrible aren't they, even top of the range ?
13:25
Some people really like them for some reason. But me not so much no
I've only had hands on them in computer stores ... even really expensive ones have like quad core cpus, I don't get that ...
what exactly are you paying for if it's not ... computer ...
Yeah. They should probably build some new machines. But why would they when people are still paying good money for those old things
@JoeWatkins it sounds like something that should be bundled with 'mac nuggets'
can any of us that aren't on osx run osx in a vm ?
I'm wondering if it's actually possible ... with no wierd problems like mice not working, or it being really slow, or graphics breaking ... like any other os basically ...
or is it still a work-in-progress sort of thing
Anonymous
I used to a while a go on windows and it worked pretty well
13:31
I've got it to run before, but painfully slowly with broken graphics ... but that was the best I ever done, after a few days of fucking about, and even getting a new graphics card ...
why do they need to make it so difficult
Anonymous
Why do you want to anyway?
so I can test stuff
today ui, but all the time this comes up ... bob has a server machine somewhere, but I always forget where, and I dunno if it's powered up ...
Anonymous
@JoeWatkins ah. I can't remember what I used to do it :(
we're supposed to test php there also ... I don't think either of us are :s
Could somebody help me with this?

It seems to check the $ignore array correctly but still allowing same $key + $value into the array. It should check to see if there already a $key and $value if there is then don't add to array

$alreadySelectedMeetingID = array(
    array ("meeting_id" => "1812")
);

$pupils = array("parent" => array( array ("pupil_name" => "Daniel", "pupil_id" => "5", "pupil_grade" => "87"),
    array ("pupil_name" => "Daniel", "pupil_id" => "5", "pupil_grade" => "86"),
    array ("pupil_name" => "Callum", "pupil_id" => "6", "pupil_grade" => "87")
13:37
@JoeWatkins I tried it once and failed, but that was probably just me
ako
ako
hi there
can anyone help me with this question
0
Q: form validation using laravel framework

akoi'm using laravel 5.2 i have a form contains two fields , one for email address and the other for mobile number , for user to sign up into the site , one of these two fields ( mobile number or email address ) is required to be filled but not both of them ( both of them are not required ), how can...

we dont do laravel in here
ako
ako
@tereško i'll try
Anonymous
13:39
@PeeHaa Is voting irregularities just a posh way of saying bad Q's?
Nope. I flagged OP for actual sock puppet upvotes
Anonymous
Oh, look at you
It was pretty clear though :P
And yes I would have done a proper job in 1940 - 1945
Anonymous
ergh laravel, that's horrible stackoverflow.com/a/39978589/4781925
13:41
@JayIsTooCommon meh. that's not that bad
Anonymous
It's like you, in code form.
Just don't look further :)
@PeeHaa what would your job be, the Annihilator?
Anonymous
2 days ago, by JayIsTooCommon
Pickle tickler
3
hehehehe
13:51
lol
0
Q: Stop key and value being added to array when they're already in array

Chris BeckettInside my getNearestMeeting method it seems to allow array with the same key and same value. I'm wanting to check to see if there is key already and meeting_id value. As you see down below that the result from my code so far returns two keys == 6 and they have the same meeting_id == 1812. What ...

SplObjectStorage instead of arrays perhaps?
14:37
function in_array_r($array, $key, $val) { doesn't need to loop
@Sean what do you mean?
It's meant to check if a given key / value pair exist in any of the second level arrays right?
Yes correct
@Sean but don't i need to loop through the array to check the second level array?
3v4l.org/K8I9n for error checking
though array_column might not be supported in your PHP version
In which case update to something that hasn't been dead for a year
14:45
@Sean what php version is it in?
5.5+, 7+
lololol
-4
Q: Khan Academy Challenge : Create a solar system

JKohlplease help me with following task: use Javascript to create a div with createElement, give it the class planet, a nice background color and add it to body. <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <title>Challenge: Create a solar system</title> <style> ...

As if the title wasn't funny enough
Lol
@Sean i'm on 5.4 in work :(
@Sean any other way of checking the second level array?
if (key($item) == $key && isset($item[$key]) && $item[$key]["meeting_id"] == $val) this line is suspicious
key($item) == $key I don't understand why that's there
Right, let me just look at what this is trying to do.
14:51
I'm passing through key and I'm checking if the second level item key is matching that key
because to me that if statement is pretty much guaranteed to return false
so it's never going to accurately tell you if the array contains a given key/value pair
Ahhh right
Wes
Wes
damn i slept all day
@Sean -> 3v4l.org/2vHY6
That's an example of my stuff
It's allowing duplicates of meeting_id and the key
So it's showing key == 5 multiple times and that has the same meeting_id == 1812

« first day (2187 days earlier)      last day (2987 days later) »