« first day (1934 days earlier)      last day (3028 days later) » 

9:00 AM
I'm not sure I'll ever have the guts to buy anything but IPS, I just know the quality of a IPS panel so I'm properly gonna stick with it.
 
@tereško it looks really nice, decent graphics and engaging back story
 
posted on February 01, 2016 by nlecointre

/* by Tom */

 
@Epodax actually the PVA/MVA is newer tech than IPS (I got MVA screen myself)
 
Maybe so, but doesn't that just increase the cost even more then? :P
 
does any one remember Time Commando??
https://www.youtube.com/watch?v=nSTD2I8kWRM
 
9:06 AM
@tereško which is currently more expensive than 4k :(
 
@Leigh depends. The 4K panels that can only do 30Hz are quite cheap .. sure
@SamIbraheem lol no
 
@tereško you should totally check it out
 
it looks like ass
 
@tereško forget the graphics, the game play is awesome
 
@tereško Obviously I don't know how it compares to LV prices but a 4K 60Hz here is around £350, and an ultrawide curved is around £700
 
9:12 AM
you guys what do we mean by a 60HZ or 30HZ screens?
 
@Leigh the one I bought was a bit over £550
 
@SamIbraheem refresh rate
 
@Leigh is it enough to look it to judge a screen?
 
if you know what to look for
 
A screen needs minimum 60HZ. (At least in my opinion)
 
9:16 AM
@SamIbraheem On 30Hz, you will notice lag during mouse moving etc.
 
@Leigh if you pay attention, you can notice that stuttering on 60Hz too .. but it's not so painful at least
 
@Leigh can system information on win7 tell the refresh rate?
 
@SamIbraheem It should do
 
Morng
 
no, system information will not usually show you the refresh rate
 
9:20 AM
Pretty sure when I was using windows I could see the refresh rate under "display" somewhere
 
technically you could see it in monitor's settings, but that's almost always set to "auto"
 
@Danack when you say you don't like the "interface" suffix, does this apply to other terms, such as "dispatcher" or "aggregate" suffix as well, or is it just the reserved words, such as "interface", "trait" or "abbstract"?
 
laptop screens are almost always 60Hz (with some exception running at 75Hz)
 
> Current Status: Departed Processing Center
Oh boyy it's coming :D
Morning 11-ers
 
@Sean what did you order?
 
9:24 AM
PHP 6 Certified Hoodie :V
 
lol :D
I will have to get that one
 
@SamIbraheem Most graphic drivers will show you what refresh rate it's running
 
@ErikLandvall do you write class AccountClass { .. ?
I suspect you don't (unless you are using Yii 1.x) .. now just apply the same logic to other symbols
 
9:29 AM
\o
 
'nin
 
@tereško This is the argument against "interface" and "traits" and so on, this argument I understand. The question now is if this applies when using different suffix depending on the application layer, such as: "dispatcher", "validator" or "aggragate" and so on ..
 
@ErikLandvall that's what the namespaces are fore :D
 
I would agree for \Acme\Validators\CreditCard. Not sure about Aggregate. I don't see why this would be an interesting part of anything. Dispatcher can definitely better be suffixed imo.
 
I am not entirely sure when one would use "aggregate" as a suffix
 
9:35 AM
@tereško that's what I do now, I don't like it however.. I prefer to have the component in one package and use virtual folders for organizing the layers.. but sense I can't, I do it like s, but with the suffix (haven't done the transfer yet, not sure if I will either)
 
@Sean from where did you ordered that is it available in extra large :P
 
Why is aggregate a bad suffix ? .. well I guess it's the core functionality of that module .. is this the argument maybe?
 
@tereško I don't use Interface etc, but I do use Aggregate or Composite, because that's what is is in a business or domain sense
Interface isn't anything in a business context
 
@ErikLandvall why is aggregate or composite a useful piece of information at all?
 
@ErikLandvall because instead of AppleBreadAggregate I would call it Pie
 
9:37 AM
@AnmolRaghuvanshiVersion1.0 Right over here :p
 
@Gordon no, I ment just the suffix part.
 
@ErikLandvall yes, why is that a useful piece of information to put in a class name?
 
Wes
with aggregate you mean aggregate root? the name is misleading, because the aggregate is the whole group of classes
 
if you have "aggregate" as suffix, it would mean that the rest of the name is describing the parts and not the greater whole
 
9:39 AM
@Wes, still learning this, but I'm sure you right thathis is what I ment
@tereško at the same time, I would look for an aggregate when I wanna look at how to use the module, so if it's suffixed, it's very clear I belive
 
@ErikLandvall yes, but only when you are looking at technical details over domain details
 
aw deer .. the religion of DDD
 
@Gordon Not following what side of the argument you are on.
 
@Wes yes I seen that, reading the book now, why the questions are coming up I guess :D
 
Wes
9:42 AM
naming a class Aggregate is wrong, you could name a namespace "Aggregate" but not a class
 
@ErikLandvall in general I am for leaving out technical information in class names and using domain language instead.
 
@Wes it shouldnt even be a namespace
 
Wes
@tereško notice the "could" :P
 
Alright, thanks, I believe it was answered. I see why it shouldn't be in the namespace neither..
 
I make things easy and name all my classes after people in here.
 
9:43 AM
it's the CherryChocolateBreadAggregate VS Cake naming question
 
@Wes Agreed, we're not talking about Aggregate root. However, I name things SomethingAggregate to mean a group of, or an aggregation of. This is perfectly acceptible
 
@tereško CherryChocolateBread is much more descriptive than Cake though
 
The interface would be Cake
 
bread? remind me to never let any of you bake
 
@Jimbo why not just Something? what additional information does it convey to suffix it with that technical information that its an aggregate?
 
9:45 AM
@Jimbo the interface would be Edible
 
@PaulCrovella banana bread is tasty. try it ;)
 
Wes
@Jimbo ok but Aggregate usually means a different thing in programming
Collection should be used, and in that case it would be fine
 
@PaulCrovella english is not my first language .. do you really expect me to know bakers terminology?
 
Anyway, at a company where we are taking our first attempt at structured code, I believe naming things with the suffixes is prefererad so everyone clearly can see what parts belong to what layer (for teaching purposes). But will keep it in mind when it's time to refactor or develop new modules..
 
Basically any object that has other objects as collaborators is an aggregate. If I'd apply that as a suffix, most of my classes would be suffixed.
 
9:47 AM
@Gordon it's lovely, but that doesn't make it cake
 
Wes
what gordon said ^
 
@tereško Okay if there's an abstract class it would be Cake
 
granted .. I should have named it ChocolateCake
then again, I almost never use abstract classes these days
 
@Gordon ValidatorComposite is an example. It's an object comprising of multiple validators - you could say it's almost like a bounded context
That clearly defines what it contains and what it is
 
@Jimbo yes, I can see the reasoning, though you could just name it MultipleValidator, too
 
9:49 AM
@Gordon MultipleValidator isn't as nice in English imho. Maybe that's all it is then just opinion :-)
 
@Gordon or maybe Validationator
 
Mother vs MotherHumanFemaleAdultMatriarchNotKangaroo
3
 
or you could just name it Validators, because it holds many Validators
Validators implements Validator makes it quite clear that it must be a composite pattern
 
$v = new Validators (I have never created a pluralised object before, because it doesn't read like English) or $v = new ValidatorComposite
That's a thought - pluralised objects
 
@Jimbo you obviously havent had the pleasure of working with ActiveRecord
 
9:52 AM
^ I use plural names for collections only
 
@Jimbo though in all fairness, CompositeValidator and CompositeLogger sounds okay, too. I wouldn't object to that as much as I would object to FooAggregate or FooInterface
 
they sound ok, but when I think about, what they would describe, my "code smell detection" kicks in
 
they're not very funny names is my only criticism, software should be funny, above all else ...
 
@JoeWatkins then someone would probably find it offensive some time down the road ... and you would be dis-invited from a conference for discriminating against multiple systems
 
@tereško I did and learned quickly how shit that is
 
9:58 AM
-1
Q: i create a running total type of summary is sum but the result is incorrect it count the number of line need help please

Edwardi create a running total in crystal report visual studio 2012 type of data field (double) type of summary (sum ) but the result is incorrect it count the number of line instead of total every amount need help please

should be closed?
 
@Gordon The distinction between aggregation and composition needs to be made. I know the difference in a DB context, but not in a natural language one
To me, composite (composed of) means multiple objects coming to gather to make one, and aggregate means multiple whole objects together
 
@Jimbo in that case, omit that detail
 
So with that in mind, I would have said it was a ValidatorAggregate, as it was just a bunch of validators
 
I can see why someone would want to indicate the Composite design pattern, but not the general concept of composition and aggregation
Also, the difference between Composition and Aggregation is mainly about ownership and lifecycles. It's possible to have classes that utilize both, so would you name them FooCompositeAggregate then?
 
omg, I hadn't thought of this being a thing: addons.mozilla.org/en-US/firefox/addon/video-blocker
I will able to get rid of all the fucking WatchMojo shit in my recommendation-list
 
10:09 AM
@JoeWatkins I like to think you suffix all your classes with NotKangaroo... unless of course they happen to be kangaroos, in which case a suffix is simply omitted
 
I always thought multiple objects is ___Collection, ___Aggregate if it is an object that proxies the calls to each of them and ___Composite would be the object that has it's own behavior?
 
@PaulCrovella you mean to say, you don't ??
 
In computer science, object composition (not to be confused with function composition) is a way to combine simple objects or data types into more complex ones. Compositions are a critical building block of many basic data structures, including the tagged union, the linked list, and the binary tree, as well as the object used in object-oriented programming. == Details == In a programming language, when objects are typed, types can often be divided into composite and noncomposite types, and composition can be regarded as a relationship between types: an object of a composite type (e.g. car) "has...
> Aggregation differs from ordinary composition in that it does not imply ownership. In composition, when the owning object is destroyed, so are the contained objects. In aggregation, this is not necessarily true. For example, a university owns various departments (e.g., chemistry), and each department has a number of professors. If the university closes, the departments will no longer exist, but the professors in those departments will continue to exist.
 
This is bringing back flashbacks of university UML diagrams.
 
@JoeWatkins I'm from California so kangaroos aren't much of an issue. Instead I use NotOnFire, except in summer when the state burns down - then it's omitted
 
10:15 AM
but they don't continue to exist as chemistry professors at said university .. metaphor is hard ...
 
@JoeWatkins yes, but they would continue to exist as people, which is probably what is meant there
and they'd still hold their professor degree
and you could inject them into another department at another university
actually, they could be part-time professors at multiple universities
 
but I think I'll adopt NotKangaroo for future open source work, as a step toward better internationalization
 
what about Wallabees?
 
nobody cares about your wallabees, gordon
 
@PaulCrovella I'm from the UK ... everyone should be worried about kangaroos, they can be two meters high, have feet more than a foot long, have more strength in their tail than most humans have in their body ... oh and they like to box ...
 
10:21 AM
@Gordon isn't that what happens when you create objects with defined behavior who have multiple children, when they cease to exist, they children cease to exist too, but collections & aggregates still leave their children intact as your logic is maintained in them, not in their parent?
 
Raj
is openssl_digest($pass, 'sha512') sufficient for security ??
 
@Gordon I can't think of a better one ... it's not super clear imo though ...
 
@Sean triggered
 
Raj
so nay alternatives?
 
@Gordon as if the object is standalone or not
 
10:22 AM
@J7mbo use Laravel\Maths; Maths::round($number);
 
@SergeyTelshevsky yes
 
@Jimbo Life is … mysterious.
 
@Jimbo I am too scared to google whether this is actually a thing
 
@Gordon i was brave, thankfully it doesn't exist
 
(which is a lib built to be used with Laravel…)
 
10:24 AM
> /**
* The SolutionEngineInterface implementation.
*
* @var \Flare\Math\SolutionEngineInterface
*/
protected $solutionEngine;
/**
* The ExecutionEngineInterface implementation.
*
* @var \Flare\Math\ExecutionEngineInterface
*/
protected $executionEngine;
That's some abstraction :D
 
@Jimbo I like the collision of issues filed under #phproblems: philippines, php, acidity...
 
@Jimbo well … but it still does what you need :-P
 
@JoeWatkins I would love a t-shirt with the best quotes from my favourite people in PHP land. You would be on there with your tweet :P
 
</troll>
 
Joe has a tweet?
 
10:27 AM
@J7mbo dude, use jQuery ... PHP sucks ass ...
2
 
Oh
Dissapoint ;(
 
y? :(
 
I was hoping for something more epic I guess, you raised my hopes, and then dashed them
I do quite fancy one of those hoodies though
 
one of the teachers at my kids school got it (the joke) ...
 
I was thinking, Joe's tweet somewhere on there, Teresko has plenty of good ones
Anthony about leaving the community
And that Laravel on one the right
Ahh when I retire I know already I will have happy memories :-)
 
10:32 AM
@Jimbo haha, ~45 years to go :D
 
lol
 
Actually, retirement age will probably be 80 by the time you get there.
 
I can't imagine I'll retire ...
 
@Leigh Good thing I actually enjoy this stuff then
 
!!rfcs
 
I'm not enjoying at the moment to be honest. Need to find a way to spice it up again
 
Votes are looking very positive!
 
Thanks
 
10:44 AM
@Jeeves bot fail
 
@tereško Damn that's cool
 
@salathe ?
 
the invalid strings one isn't in voting
 
Or a @kelunik fail :)
Will look into it somewhere this week
 
@PeeHaa o.O "Implemented"
 
10:50 AM
Yeah both are a bit wonky I guess :P
 
@PeeHaa I don't use it. But I opened an issue for it already there.
 
\o/
 
@JoeWatkins may need to plan my dir structure better. common has to include ../ds.h because that's where my globals are. And everything includes common.
 
which globals ?
 
10:54 AM
Any globals. But at this stage just the compare func ones
 
ah so module globals ... you can extern them ...
 
Should work with recent commit I think. Not a proper solution though.
It's midnight and I haven't gone home yet.. time for some tea then zz.
 
I'll have a look ...
okay cool, nn :)
 
@PeeHaa Andrea fail probably, did you just remove it from wiki.php.net/rfcs, @salathe? Can't view the diff, wiki is too slow and gives up with WSOD.
 
Thanks for your help @JoeWatkins #krakjoeForPresident2016
 
10:57 AM
@JoeWatkins it's nine circles… nine …
 
@JoeWatkins is this real?
 
@bwoebi woops :D
 
Hello im new to SO and probably an average PHP programmer. I have one question, do not know if this is the best place to post it. I am wondering what is the main reason that people want to make a webserver written in PHP? If anyone willing to explain why, i would love to know. I find it a good idea, just because its in PHP, so the whole app would run in PHP. is there any other reason ? thanks in advance
 
@JoeWatkins You're not the only one to make this mistake … don't know why…
 
^^ question for you :)
 
11:00 AM
@thgs masochism, mostly
 
i have heard that answer before
 
@thgs well, ultimately, that's the point. and better performance because less context switches/no request cycle restarts [fyi: I'm co-author of github.com/amphp/aerys ]
 
Yes @bwoebi that is one of my examples, the other one will be ReactPHP webserver. I saw you are posting here so I thought of asking and maybe you were willing to explain. Thanks :)
 
@SergeyTelshevsky change for the sake of changing something
 
@thgs and well, everything else like an (IMO) cleaner request/response API etc. is a bonus on top of that.
 
11:06 AM
@bwoebi 7 heavens, 7 deadly sins, 7 virtues... easy to forget about a couple circles of hell
 
@PaulCrovella Well, actually, I couldn't have told you how many heavens, deadly sins or virtues there are ;-D
 
@bwoebi as i said, i feel its the right way to do it. also it helps me with one of my small business projects as i have to implement an app that will substitute another glashfish app. if that webserver was ready for production, i would make a PHP-only solution
 
@tereško well I don't see this change a problem, I could even agree that it'll remove the possibility for all custom extensions like .inc & other stuff, but the argumentation, the argumentation is......
 
@SergeyTelshevsky someone really wants a @php.net email
 
@thgs Oh, the webserver is already pretty stable, it's just a few TODOs for completeness missing until an 1.0 ;-) Feel free to use it!
 
MGE
11:10 AM
Hello everybody, Im trying this query:
SELECT purchases.purchaseid as purchaseid, purchases.email AS email, purchases.addedfields AS addedfields, events.id as eventid,events.name AS eventname,purchases.tickets AS tickets,SUM((SELECT SUM(amount)
                    FROM codes WHERE codes.purchase = purchases.purchaseid)) as amount,purchases.currency AS currency, purchases.timestamp AS saledate,purchases.payment_type AS paymenttype,purchases.payment_info AS paymentinfo,events.name AS eventname FROM events INNER JOIN purchases ON events.id=purchases.eventid WHERE purchases.property=3 AND purchases.status=1 ORDER BY purchases.id DESC
the problem is that when it can't find any record in the db, it returns all fields as NULL so the rowCount is 1 instead of 0
 
11:29 AM
@kelunik yeah I moved it back to under discussion
 
public function abs($number){
    return abs($number);
}
Really?
 
@Jimbo what's that from?
Laravel?
 
I guess that's the way to do it if you want an OO abs
 
11:34 AM
"for Laravel 4" I'll take it
 
I don't think shoving something into a class method makes it OO ;)
 
Well it'd be $obj->abs(5) vs abs(5)
 
Because the added dependency there is worth it
 
The first being object oriented, right? ;)
 
$num->abs() would be
 
11:36 AM
xxx: you lack abstraction in your code
yyy:
4 mins ago, by Jimbo
public function abs($number){
    return abs($number);
}
here's a goodie from one of our juniors:
private static function a( &$s, $d )
{
    $s .= $d;
}
 
junior or intern?
 
junior.
 
so you're hiring then?
 
holy shit!
I had forgotten how to use my own "workflow"
 
@rtheunissen go to bed ...
 
11:51 AM
I made a coffee.
 
@Jimbo this is why you are NOT supposed to post shitty code here
noobs take it seriously
 
@tereško Trying to decide if I should be happy that there are so many shit devs, as I get the good jobs, or if I should put the effort in when they're not willing to learn (I guess that's your problem too :P)
 
so true
 
@AnmolRaghuvanshiVersion1.0 send them an email, that you are willing (for a negotiable price) to fix their homepage
 
11:55 AM
done that :D
prev dev charged huge amount for that website
 
@rtheunissen we have a build ...
have to rebuild php to get composer working, which takes a million years on windows ...
 
\o/ for the tests?
 
yeah
 
@AnmolRaghuvanshiVersion1.0 some of the links are worth than others: threadzindia.com/index.php?route=account/account
also, be warned, it smells like CodeIgniter
 
12:00 PM
opencart shit :p he told me
 
i dare say that might be worse
 
@SergeyTelshevsky might be justified depending on context…
 
@bwoebi overthinking
he just said he doesn't like how $x .= 'string'; syntax looks
 
lolwat
 
12:05 PM
Does += look better to him?
 
my favorite was and still is this little gem
function noob($string) { return echo $string; }
and the guy who wrote it asked me why $mail[] = noob("700 chars of html css sql and javascript mixed on line"); doesnt work
 
does JS work at all in mails?^^
 
if you've got a really really shitty mail client, sure
 
it was never used for sending mail. he just did it "in case"
 
@bwoebi nope
hell, most of the HTML4.01 doesnt work in mails
 
12:08 PM
and he named the function noob because he said when he cannot get this simple function right, then he is a noob … at least he had some levels of self reflection
 
there's a whole site dedicated to these gems: http://govnokod.ru/
it's in Russian, but you'll read code so it doesn't matter
 
@tereško actually I have no problem with HTML/CSS in mails … except really shitty mail clients.
 
@SergeyTelshevsky it's not like an indirect branch would be any faster here…
 
12:24 PM
@bwoebi have you found the marketshare stats for various mail clients?
because it's kinda complicated to gauge that
 
no… Just from personal experience what I've seen on others computers
 
not good enough
your immediate circle of acquaintances probably not representative
 
@tereško possibly.
 
Sorry @Andrea we're a bit slow over here... tweakers.net/geek/107731/…
 
@PeeHaa why do you have so many "ij"'s in Dutch … crazy that…
 
12:31 PM
:)
 
@bwoebi they like to make it diffucult, even for us dutch speaking people :P
 
@PeeHaa I know no Dutch… but … "waarmee ze vorig jaar stopte" isn't that saying that she quit PHP dev last year? [which is a bit dated ;-)]
 
Yeah as said we're a bit slow over here :P
 
haha :-P
 
@PaulCrovella 7 minute abs.
 
12:37 PM
@PeeHaa that haar/zijn discussion in comments is amusing me for some reason…
 
Hi guys! Is creating a custom wrapper for jQuery ajax a good thing to do? I have added a question to code review (codereview.stackexchange.com/questions/118517/…) but wanted to know if it s a good thing to do?
 
@SamSwift웃 Could ask in JS room
(this is PHP)
 
@Jimbo, good point, my bad...
 
if you wrap your jQuery with jQuery, it must be good. Can never have enough jQuery.
5
 
@bwoebi :P
@SamSwift웃 don't prepend variables with $ if it is just a string instead of a jquery object
 
12:46 PM
@JoeWatkins finally walking home. Catch you later.
 
@rtheunissen lata
 
@Gordon $($(this).parent()).attr('id')
 
@PeeHaa, I did this to imply avoid conflict with the jQuery objects within the ajax itself...
 
@SamSwift웃 I prefer to use the jQuery widgets to bind some code to a particular bit of a page. Having all the code and data be contained in one place seems easy to reason about. e.g. like this
 
Well don't
:P
 
12:53 PM
whats the best way for facebook sharer with custom parameters, i am struck at same issue; in reference to stackoverflow.com/q/20956229/1158603 & developers.facebook.com/x/bugs/357750474364812
 
@krishna That has an accepted answer......what more could you want?
 
a pony
some ice cream perhaps
 
@Danack but that doesnt say how to share custom image & text with multiple items to share in the same page
 
It says to use this api instead: developers.facebook.com/docs/sharing/reference/share-dialog which indeed might not be capable of doing the same things that the previous "api" did.
 
yeah i just wanna know if there is any hack
 
1:16 PM
@ErikLandvall reply turn into a novel: gist.github.com/Danack/636420a803d7999ee5af short version ¯\_(ツ)_/¯
 
posted on February 01, 2016 by nlecointre

/* by Frankie */

 
Being able to read code > all other priorities.
 
Might start making my code in to novels. War & PHP.
 
@Fabor It was the best of Warning: It is not safe to rely on the system's timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. it was the worst of Warning:...
9
 
1:25 PM
lol
 
1:38 PM
@Danack thanks for the write up (y)
 
@Danack No.
Code being correct > all other priorities.
 
@MadaraUchiha This is ofc not important, it just have to look like it works.. Look at Microsoft, they build a complete company on this principle.
 
@ErikLandvall Nah, they just have a different definition of "correct" than you :D
 
@PaulCrovella And here I thought it was a thinly veiled reference to a manifesto written by Anthony Ferrara about trying to leave internals and being repeatedly drawn back in
 

« first day (1934 days earlier)      last day (3028 days later) »