« first day (1076 days earlier)      last day (3858 days later) » 

12:07 AM
Ah namespace city.
Umm is the psr for ucwords or lowercase?
on folders
 
@Fabien The composer (and most other autoloaders) try to open the directory with the same case that the namespace was spelt with - so you can do MyNaMeSpAcE\SoMeClAsS if you want.
but dont.
 
Aye, so I guess it doesn't matter.
but consistency is appreciated.
 
s/appreciated/required
The autoloader can't open the directory if it has a different case, on Linux - I guess it might work on Windows.
 
@Danack if I am extending baseController (now called Controller to match the folder) from Controller/Admin/Index.php it breaks when I extend it.
it tries to load /srv/www/lamephp.com/src/application/Controller/Admin/Controller.php
 
have you done either 'use Controller\Controller' ?
or 'extends \Controller\Controller' ? - oops typo.
The explanation is that because it's in a different namespace you have to tell PHP what namespace it is in. Before you had everything in the global namespace, so it worked without specifying the namespace.
 
12:15 AM
Ah cool cheers. never used "use"
 
@Danack Worked with SF Security before?
 
@Jack I do not know what that even means - so no.
 
It means the this :)
 
Thanks @Danack & @cspray You'll be added to the list.
http://admin.lamephp.co.uk/
http://lamephp.co.uk/
 
They declare a UserInterface that should implement, amongst others, ->eraseCredentials() but somehow that never gets called =(
 
SLEEEEP nite boyz
 
@Danack I can read source code too, but $result there is that of TokenInterface::eraseCredentials() :)
    public function testEraseCredentials()
    {
        $user = new User('fabien', 'superpass');
        $user->eraseCredentials();
        $this->assertEquals('superpass', $user->getPassword());
    }
I mean, that test case doesn't even make sense to me.
Why have such a method and expect it to do nothing at all?
 
That does look a little funny. I guess would expect eraseCredentials() to actually, ya know, erase the credentials
 
@Jack Well - i have no idea either. I guess that's one reason why I don't use an security module that has 50 classes in it.
 
That's a different story altogether :)
 
12:30 AM
@Jack And $user->getPassword() is just doing $user->password - it's not referencing anything else at all...
 
@Danack I don't see how that matters at all, but my take on this was that it would be possible to nullify the password before persisting it.
 
I guess.
 
Yeah, that's okay :)
Probably doesn't even matter here, but it irks me not knowing why :)
 
morning
 
Howdy
 
12:39 AM
morning @tereško
Isn't it a weird hour for you?
 
did some shifting of internal clock
 
Finally! youtube.com/watch?v=q7U2aVUAqPI A killer squirrel horror movie...been waiting years for one.
 
So my controller folder looks like
--/ Controller
--/ Admin
---- Index.php (extends Controller.php)
-- Controller.php

In order to use the __construct() of Controller what should I be using?
parent::__construct(); kk
 
1:01 AM
.. that's not how I would do it
 
Go on...
 
@tereško If you do decide to show me how you'd do it please tag my name as I am off to bed so I can review in the morning.
Night all :)
 
1:17 AM
So I have a website(www.noahhuppert.com) and I don't really know were to put color. My design seams be fine but its really lacking color and for this design I haven't the foggiest were to put color. Any ideas?
 
1:30 AM
@NoahHuppert the background?
 
@crypticツ Ya. The lack of it. What would you recomend?
 
@NoahHuppert pink
 
@crypticツ ...
Ill try graphics designers
 
lol ... there is no Ruby room in SO, and the "rails room" has 5 people
 
what's the best way to free a blind DotNet COM object?
 
2:37 AM
@tereško funny, and sad...
 
/me has no idea how to deal with .NET
 
no worries, you haven't lost anything
 
omg I'm so sick of my VPS, @tereško who do you use again?
 
Tilaa
 
@JoeWatkins I'm still not 100% sure about anonymous classes in general, but at least it's shaping up and you are covering several cases.
I think that the cases where anonymous classes are useful may be better solved with other things, but I don't know that. It's like a programming hunch, you know?
 
2:54 AM
@crypticツ where do you have it?
 
@crypticツ So you didn't like atlantic afterall, eh?
 
@LeviMorrison they keep having problems with their nodes. I mean I;ve got a 100% refund for the entire month, but even after they transferred my servers to the new nodes they setup still having issues.
 
Hm.
Sounds quite bothersome.
 
it's a new company so they have yet to get their shit together
I would really like someone who has VPS but also offers mailservers, since I don't want to have to manage those.
 
3:00 AM
What does anonymous classes offer over a named class?
 
Ease :)
 
@Orangepill Exactly what it's name implies: anonymity.
 
But what do you gain with that?
 
That is, currently, the important question.
I can use it to make 'hidden' classes. This is useful when I need a class for the inner-workings of another class but don't want it to be public.
 
It gives a new way to express yourself in the language.
 
3:02 AM
Are the symbols freed when the instance goes out of scope?
 
I am not sure on the technical details.
 
@Orangepill It's just an instance in the back.
So it behaves much like one.
 
Hey, is anyone good in css?
 
@EliteGamer I am sure a lot of people are.
 
Yea, haha. I used to think that PHP programmers used twitter boostrap for all there prototypes
well, i have a question. I have 4 li's in a ul
how do i get the last li to extend the rest of the ul?
i have tried using them as tables, but got nowhere
 
3:05 AM
emmm ... did I read the topic wrong ?
 
topic ?
 
>So I have a form on the front end. I use jQuery to collect and send the data to collect.php.
I want collect.php to send the to another site in the following **format ?fname=tom&phone=3434343** .

How do I simply send the data that is sent to collect.php to this other site?7
 
ah, well, yea, but i was just wondering
 

HTML / CSS / WebDesign

This room is now defunct. RIP.
 
@tereško I do not think it is possible. For Same-orgin
 
3:06 AM
o.0"
 
empty
In computing, the same-origin policy is an important security concept for a number of browser-side programming languages, such as JavaScript. The policy permits scripts running on pages originating from the same site – a combination of scheme, hostname, and port number Same-origin policy also applies to XMLHttpRequest and to robots.txt. This mechanism bears a particular significance for modern web applications that extensively depend on HTTP cookies to maintain authenticated user sessions, as servers act based on the HTTP cookie information to reveal sensitive information or take st...
 
This question is about cURL/sockets , right ?
 
Yeah, I guess so. That's how I would read it.
 
I can kinda understand if you had a long running service that needed to potentially access lot of classes why, for memory reasons, you wouldn't want a lot of definitions hanging around in the symbol table.
 
0
Q: redirect GET data to another site with PHP

JulianSo I have a form on the front end. I use jQuery to collect and send the data to collect.php. I want collect.php to send the to another site in the following format ?fname=tom&phone=3434343 . How do I simply send the data that is sent to collect.php to this other site?

 
m59
3:08 AM
What's a good collection name for "logging in" with a rest api?
I've seen it recommended api/sessions
 
so why only answers that contain jquery are not downvoted ..
 
m59
but that sounds a little bit counter-intuitive
 
@m59 what do you have there?
 
m59
@CSᵠ huh?
 
3:22 AM
sessions fits quite well
 
m59
oh
 
asking what methods you have there
 
m59
I guess I meant that you're not so much worried with a session so much as authentication/authorization
 
@tereško Y u no use http_build_query()?
 
m59
You know, a session doesn't necessarily mean "logged in"
 
3:23 AM
indeed
not logged in is also a state
 
m59
api/logins maybe sounds closer
 
@Jack dunno .. stupid, i guess
 
:)
 
@m59 better maybe
 
I keep confusing it with http_build_url(), which is a PECL thing
 
user652649
3:27 AM
morning
 
Oh, that's mike's extension.
 
@Wes morning
 
user652649
hey @NullPoiиteя i resolved already, was a netbeans question :P thank you anyway
 
@Wes yours welcome ...:D
 
user652649
@LeviMorrison add border:0 to the <img> logo
 
user652649
3:32 AM
@LeviMorrison even adding border:0 there's a 1px gap between documentation and the separator imgur.com/L0IeBqH,KSQqf9c#1
 
I just got a lead on a side job that would involve developing a feed logistics mobile app for a hog farmer... this may be interesting.
 
yeah .. or it can turn into a spectacular disaster
 
@Orangepill nice!!! getting dirty... ohh yea baby
 
@teresko yeah... it's probably not going to be worth it.
 
so... do Java docs suck?
 
3:45 AM
@CSᵠ it's not that Java docs sucks, it's .. emm ... just not designed for humans
 
@tereško I thought you weren't human?
 
shh
 
@tereško (rofl)
compile that with the fact Java is not designed for computers and you have an awesome package
 
m59
@CSᵠ so, api/sessions is best :)
 
@m59 go with logins if you don't care about guest/anon
 
m59
3:49 AM
It IS vague in a sense, but it makes sense when you consider what you're posting to it
You're aren't sending a vague post request. you send a specific one that refers to an authenticated or "logged in" session
so, it makes sense that way
 
It is as minimum idiotic. No offense. For the first, curl is platform-dependic. — davidkonrad 4 mins ago
emm .. what ?
was he dropped at birth ?
 
boom
 
because you have linuxserver — davidkonrad 25 secs ago
 
@tereško yup.. seems so, or drunk
 
What's "platform-dependic"? lol
 
4:01 AM
@Jack of course some sort of appendix on a platter
 
small people with wamp is lost to this question and socalled solution, just saying - delete my own (correct) answer now — davidkonrad 1 min ago
 
He has the amazing gift of embarrassing himself.
 
4:20 AM
At least I know when to tuck my tail between my legs and run away.
 
"And I hope the extent of how much you have embarrassed yourself will not be lost on you" - you bet. I still dare you to show 1 installation in the whole world, which run on windows and where you can include cURL. Are you running windows and have cURL? — davidkonrad 2 mins ago
 
@Wes I hate IE. I hate it. Why can't it just be nice?
 
ircmaxell stated that silex/pimple's ioc container is not a true dic because the factories are not container aware. What exactly does he mean by that?
 
user652649
lol, ie9+ isn't that bad :P
 
isn't that good either
 
m59
4:32 AM
why am I able to use classes before they are defined?
 
@m59 because the entire file is parsed before it's evaluated.
 
m59
sweet.
 
@Orangepill well .. the DI containers are supposed to be used in factories. Or any other context where you create an object. Instead the silex/pimple thing is injected in a class, where the class then pull what it need from the service locator
You might also notice how hard is to actually find examples where DICs are used in an applications
 
@teresko but if I pass in the dic into the factory method (via use) and resolve the dependencies inside the factory would that be transforming it into a dic
 
they don't have any facilities to do the resolving
Pimple simply is a glorified reigistry with lazy initialization
 
4:40 AM
so it fails at autowiring complex dependencies.
 
it fails autowiring any dependencies
Fabien Potencier has a habit of using wrong names for wrong things
.. then again, it lately has become default M.O. for all the people who are even remotely associated to FIG
 
I get it now... do you know of a true DIC implementation I could use as reference to see it done the right way?
 
Does fabpot actually refer to Pimple as DIC?
 
@Orangepill IIRC , @rdlowrey has a decent one
follow-up on the "prove it" guy:
There is the possibility that I am not uptodate. That cURL have evolved and now is functioning on windows also. I have not been uptodate with that, simply because I dont use cURL. But I know the programming behind curl was nor appliccable to windows in the first place, because it was some generic unix routines that were bundled. — davidkonrad 1 min ago
 
@teresko thank you... his stuff is generally pretty easy to follow as well.
 
4:49 AM
here is one thing you have to consider:
if you are using interfaces instead of concrete classes to define the class's dependencies, DIC will be of very limited use to you
 
> my flag: "post needs comments cleanup." answer: declined
and then the mod cleaned up the comment feed
sigh
 
@teresko that pretty much blows.
 
@CSᵠ that's how @AndrewBarber operates
 
@tereško wtf..!?
 
you flag an answer, he will decline the flag and close the topic
standard M.O. for him
 
4:52 AM
checking to see if i voted for him...
 
@Orangepill you could say that SOLID practices and use of DIC are conflicting
 
@tereško davidkonrad is frustrated person IMO.
 
Just ignorant.
 
nope, been neutral for him
 
Ahh found it, here he got -1, may be because of that reason he is frustrated.
 
4:57 AM
no, I gave him -1 because he's ignorant
 
morning detective @YogeshSuthar
he didn't impress me at all, neither disturb
 
@CSᵠ more-ning
 
@teresko I'm thinking wiring up my own dependencies within the factory would suck less then sacrificing abstract dependencies. What's your opinion?
 
mornin mornin what a nyc mornin
 
I'm currently sticking with factories
 
5:03 AM
did u get a hike ? @Mr.Alien
 
@YogeshSuthar nope, auto no-reply mails does work, just sent a no reply mail to the company and they issued the cheque in a day
 
@Mr.Alien means?
 
good mornings :)
 
@Orangepill It's not a container, but it does do DI 'right' github.com/rdlowrey/Auryn - warning, may cause you to re-write all of your code.
 
@YogeshSuthar was asking for money due since 2 weeks, they didn't paid, sent 1 mail using php, with a from header set to no-reply@site.com saying this is auto generated mail, payment due rs blah blah by date blah should be paid by blah blah date, failing that will result in termination of your system, and they sent the cheque very next day :p
 
5:08 AM
@Mr.Alien lolzzz that was a nice trick.
using php for own use.
 
@Danack That was teresko's suggestion as well.... reading through the code now
 
@YogeshSuthar haha yes ;)
 
hi every one
 
anyone using EuroDNS here ?
 
does any one know how to display all the images from a single post as a thumbnail in the Facebook share button?
 
5:11 AM
is it just me or their page is completely fucked after the latest redesign ?
 
we hate facebook
 
@Mr.Alien : ha ha ha.. LOL
 
user895378
5:24 AM
@Orangepill ... @tereško is right: DICs -- regardless of the implementation quality -- start becoming a hassle and lose their effectiveness if you use SOLID principles and interface typehints. They can work with non-concrete types but it just turns into a lot of extra "meta" definitions and just doesn't feel quite right.
 
user895378
You can us DICs to good effect but it seems like there should be a better way to do it. I'm not sure what that method is, but I don't think DICs themselves are a cure-all.
 
@rdlowrey I'm was starting to arrive at that as eventuality as well... the auto-wiring magic may not be worth the hoops that you have to jump through to get there in a sane way.
 
user895378
Yeah -- I spent a good deal of time working on mine and it's useful in places, but I still feel the same way about it as I do about frameworks: if you know how to do it yourself you'll most likely be better off to do that.
 
@rdlowrey So you're saying "Don't use someone elses dic? It's better to roll your own."
/nailed it
 
user895378
Nooooo
 
5:37 AM
Well .. there is one particular case where it seems to me that DI container might be a good solution - the wiring of MVC-like components. In particular - initializing the controller as view instances, because both of those need services (concrete classes) as dependencies.
But outside of this use-case, I'm drawing a blank.
 
@rdlowrey just wanted to say your code is very readable
 
user895378
I'm saying that inversion of control is not a complicated thing -- just pass in the dependencies you need. A DIC starts to be useful when you won't to try and abstract out a large bootstrap process.
 
@Orangepill .. it might have something to do with this chat-room nagging about every smallest detail
 
user895378
@Orangepill thanks -- it's mostly because I have a small brain and if I don't do it that way I'll be screwed in a few weeks when I come back to make changes.
 
well whatever the reason the results are beautiful.
 
user895378
5:42 AM
And TBH, @tereško has had a greater positive effect on the quality of my code than any book I've read :)
 
thank you
 
Well I'm going to tap out... I got an early morning tomorrow.
 
user895378
(fear of) Criticism is often the best teacher
 
user895378
Same -- catch you guys in the A.M.
 
If anyone wants to have a good laugh, than you can read the comments here
 
5:45 AM
hmm ... should I spend 10$ for X games or not. It's still up for next 12 hours. Damn.
 
I really appreciate teresko's blatant honesty and opinions.
4
 
5:57 AM
@rdlowrey It's not that DICs were designed as a cure-all but I think to help apply inversion of control that is to move the creation of objects out of the places where they are consumed. We had a similar discussion among peers lately and someone even questioned dependency injection as a whole but I didn't fully grasp the argument because it was all too chatty.
 
Was it after a few beers? :)
 
I wonder, what was the suggested alternative for dependency injection
 
Heroin, the ultimate dependency injection.
11
 
user895378
^^ Don't say things like that. Sometimes people like myself (and@PeeHaa) show up hammered and think it sounds like a good idea.
 
@Jack not beers, but right direction :D
it also was a theoretical discussion.
 
6:07 AM
@rdlowrey But it is a good idea :)
 
user895378
Sold!
 
user895378
Now I just need to find a good "injection container"
 
@rdlowrey Updated your git branch, and yay, all tests passing :)
It would be nice to be able to test the x509 validation separately.
Like, without having to actually make a connection to anywhere.
Just for testing really. I don't think it will have a real-world benefit.
 
user895378
I would like to converse intelligently on that point but I'm afraid I'm in the post-alcohol pre-sleep phase. In the words of the Magic 8-Ball ... "Outlook hazy"
 
@tereško English
 
6:13 AM
Right, postponed :)
 
user895378
Remind me in a few hours though and maybe I can figure something out.
 
@Mr.Alien are you doing this just to hurt me ?
 
Yes :p
This was awesome but no get successfull
 
Yea, he is a south indian, they keep big moustache
 
6:23 AM
AFAIK, there is similar practice in Turkey too
the mustache is perceived as symbol of wisdom and manliness
 
It's better than having a wizard beard, but is still itchy.
 
... in west it is perceived as symbol of male porn-stars from 80's
 
yea, same here, kings used to have big ones, new generations hardly have.. even my dad has good moustache
 
@tereško You watched porn from the 80's? o_0
3
 
rofl
 
6:26 AM
@Jack it's quite hilarious =D
 
even I've seen, mmmm blonde hair, rich red lipsticks..
 
I can imagine heh
 
no, you cannot
 
@tereško I grew up in the eighties :)
 
Morning.
 
moin
 
morning, @JoeWatkins
Who writes C/C++ regularly, which IDE do you use/recommend on linux?
 
6:53 AM
kdevelop ?
 
vim
 
@Leri I do ... no ide tho
also, what's wrong with eclipse, why does nobody want to use eclipse anymore ?
 
I find it slow tbh.
 
aren't you really asking does anybody know of an ide that is not eclipse ...
 
yeah , that was my impression too
 
6:58 AM
well it's a bit of a hog, welcome to java ... I don't think theres a set of tools that should exist that do not for eclipse
 
Storm performs much better and yet is Java too.
 
@Leri Have you tried IntelliJ Idea? Same guys that do PHPStorm.
 

« first day (1076 days earlier)      last day (3858 days later) »