« first day (2148 days earlier)      last day (2800 days later) » 

12:24 AM
@bwoebi public key encryption but without being as stupid as, say, RSA in ECB mode
 
@ScottArciszewski well, that sounds much more interesting than hybrid cryptosystem; I mean, people usually choose options which they've ever heard off.
 
12:38 AM
hello
ive found a tutorial but whats the use of & in this code? function filterData(&$str)
 
Wes
mornggng
 
0
Q: Whats the use of & in function parameters?

Pure Rhymer OrganizationIve found this in tutorial on how to import excel in PHP but I cant find it in internet whats the use of & in the function paramater Here is the code <?php $data = array( array("First Name" => "Nitya", "Last Name" => "Maity", "Email" => "nityamaity87@gmail.com", "Message" => "Test ...

 
1:05 AM
array_walk
can i use this array_walk($something,"myFunction"); if the myFunction() is in another file?
@Wes
@bwoebi
@ScottArciszewski
 
Don't ping random people
 
sorry
bdw can i use that?
 
1:31 AM
@bwoebi Can you help me understand a bit of DECLARE_LAMBDA_FUNCTION? I'm not sure what this is doing: zfunc = zend_hash_find(EG(function_table), Z_STR_P(EX_CONSTANT(opline->op1)));
I understand it's expecting op1 to be a string literal and it is looking that in the function_table but... why?
 
 
1 hour later…
Wes
2:44 AM
lol i've became so skilled that i ignore vamps before they can harm me
 
Wes
3:09 AM
perfect cable holders
 
Ekn
hah indeed
@Wes lol
 
Wes
lol
 
Ekn
damn I need a new keyboard... another coffee incident
 
they make rubber covers for keyboards used in industrial settings that work well
 
Wes
3:17 AM
if i changed a keyboard for every coffee incident i'd be broke in few months :B
especially because i don't use any longer a 10$ keyboard :B
 
Ekn
I'0ll try to get something like that
 
Wes
@PaulCrovella do they? i couldn't actually write (as in programmer-speed writing) with those things on
 
oh no, they totally suck to type through - but they do protect the shit outta the keyboard
 
Ekn
ugh... look at this... only clicking 'one' : |1 'five' : 54
ctrl refreshes the page lol
 
you might want to go clean that out with rubbing alcohol
 
Wes
3:21 AM
will make a nice coffee alcohol cocktail :B
 
Ekn
hmm I guess it wouldn'0t get any worse than this
 
Wes
i always disassemble it entirely and clean the plastic pieces in hot water
i make a soup of keys :B hot water removes the dirt almost immediately just by immersion, while other stuff requires rubbing anyway
 
Ekn
it sucks to be in a small beach town in cases like this... I have to go to the city centre to get something proper, which takes about 1.5 hrs
 
Morning
 
Wes
but just clean it :B
 
3:26 AM
@Wes Stylin' love it.
Big lego fan back in the day ...
 
Ekn
yeh I'm off to do that... laters
 
Wes
lata
 
 
2 hours later…
Anonymous
5:09 AM
@PeeHaa nice! \o/... You can do the building :D
 
@NikiC I'm trying to plan the best way to reduce the number of allocations while keeping the zend_object and the internal structure as separate as possible. The only way I can see this working is like this: if there's a function which produces a new structure, eg "clone" or "merge", instead of allocating a new one internally (safe, predictable, scoped), return nothing and simply initialize a return_value structure pointer.
So you allocate the (zend_object + internal), then pass (&internal) to be initialized internally. Or actually.. always assumed initialized, so you'd call ds_structure_init(&internal) externally.
The only reason to keep the zend_object and structure separate is to allow another package to use the structures internally without the need to allocate the zend_object as well. I suspect there's a very small chance of that happening, in which case I'm inclined to just combine them.
 
5:40 AM
i am rewriting my url with htaccess with this " RewriteRule ^([0-9a-zA-Z-]+) /resume.php?id=$1 [QSA,L] " but it is strange working with http://mywebsite.com/cv/naresh and also with http://mywebsite.com/naresh and anything i am adding before " naresh " .. how to fix ?
i strickly want this url only http://mywebsite.com/naresh
 
5:58 AM
@Fabor have a safe journey o/
Also, moin
 
Ekn
murnin
!!rebecca
 
get yer keyboard fixed up?
 
Ekn
well, I did my best but: |1 |1 2 3 54 54 67 67 ¿8 :D
at least ctrl does not refresh now
 
success!
 
Ekn
6:02 AM
sorta, yeah :)
 
Wes
@Ekn hey, just pretend you have big fingers :B
 
Ekn
heh
 
on the plus side you can type 54 faster than anyone else now
 
Ekn
I'll get a new one in about 6 hours
 
Wes
was it an expensive keyboard?
 
6:12 AM
for my desktop I'm still using the same keyboard I've had for ~13 years... it's my single longest-lived bit of computer hardware
 
Ekn
hmm someone's working on a jit
no, it was a cheap one I got quickly last time this happened
related to that jit link
 
and probably the biggest biohazard in your entire place ;)
 
no, that'd be me
 
I was using my MS Natural Keyboard for a similar amount of time. But I've opened it up several times to clean it. It's very amazing (and somewhat icky) to see how much hair, bread crumbs, dust and what not accumulates in a keyboard over time.
 
yeah, I clean mine more or less (less) on the regular.
I swear I don't eat toast over it, but somehow it ends up in there.
 
6:21 AM
@Hi Everyone.
 
hehe, yeah. though for me it was mostly hair. could have made a small wig out of it. I guess that proves I am pulling out my hair over php a lot
 
Wes
i don't get what jit is in this case. isn't php jit already?
 
@Gordon How are you ?
 
@Wes nope
 
Wes
isn't jit just the compilation performed immediately before the execution?
 
6:34 AM
@Wes No.
JIT is compilation during execution, at runtime
Not before execution (or even, immediately before execution)
 
Wes
ah. now it makes sense
is it really worth it, with opcache and stuff?
 
Hello All
any one there ?
 
Ekn
it seems there is an ongoing discussion on the topic
 
6:56 AM
@Ekn every time anyone works on anything for php there's some asshole bitching that they're not working on async/await instead. so tired of that.
it reminds me of the people who want every scientist in the world to be working on a cure for cancer rather than study anything else, because that's their personal most important issue
 
Ekn
that's ridiculous indeed
 
any body know quick payment gateway
?
want to implement in php
 
Ekn
pretty sure a quick google search would give you a few options.
 
yeah but i know how to do payment and all
but i am not sure what is reseller and merchant in quick pay
 
@AmitChauhan any knowledge about socket ?
 
Wes
7:09 AM
well considered that despite they say they find new treatments, mortality by cancer is increasing nevertheless and at a worrying rate... i'd say it's pretty much personal to anyone in the world @PaulCrovella
 
@Wes you've entirely missed the point
 
Wes
what was the point?
 
no @Bajaj
 
Wes
that async await is just as important at that?
 
why need socket for @Bajaj
 
zan
7:12 AM
go for stripe
easy to implement
 
but in my project want to implement quick pay
i know stripe but
 
@AmitChauhan chatting implementation
 
no but my senior implemented it
using node js
 
Guys, how do i import a certificate into my browser ?
 
o/
 
7:15 AM
@Wes That it's idiotic when people suggest that scientists working on battery technology, or dna sequencing, or crop yield, or anything but curing cancer should be working on curing cancer instead. And that's an analogy for those people who bring up their pet issue async/await whenever someone is working on anything else in PHP.
 
!!? how do i import a certificate into my browser
 
Search for "how do i import a certificate into my browser" (https://www.google.com/search?q=how+do+i+import+a+certificate+into+my+browser&lr=lang_en)
• Installing the Certificate through the Web Browse… - Import the IC Control SSL certificate through the Internet Explorer 7.0 or later, browser. The end… (https://help-icc.untangle.com/Content/User%20Guide/UI_Tabs/SSLCertificateGPO_v4/Appendix%20B%20Installing%20the.htm)
• Importing site certificate into Java Runtime cert… - 2 dec. 2008 - Step 1 - Get the certificate into your browser store. Browse to your … keytool -impor… (http://www.grim.s
 
@Joseph ^
 
Have you ever been sitting for so long that when you go to stand up your knees just give in?
That's when you know you've been in the zone!
 
mine tend to kinda lock up and take a bit to get moving again
 
Wes
7:21 AM
@PaulCrovella i didn't miss the point then. i'm saying that we aren't probably doing enough against cancer and yeah i kind of agree with that. science is failing hard with it
dna sequencing would be part of it, though
 
anybody dont know quick payment gatewaY?
 
what i want to know , in fact what i want to understand is, I enabled ssl mod for apache and created a self signed certificate and did what needs to be done in the virtual host conf to always redirect to https, untill here all is ok. Now when i try to connect to my website it asks me if i trust this site and then i can add it as an exception and connect . Now what i don't understand is this, should i not be importing the certificate manually into the browser ?
 
@Joseph why self-signed? letsencrypt.org
 
i am local
my site is local
 
7:25 AM
i mean if i am going to add the thing to the exceptions then what's the point of using ssl ?
 
@Sherif s/in the zone/on the potty
 
i think i lack some basic knowledge on this subject :(
 
@Gordon possibly
@Joseph The reason your browser gives you that warning is because your self-signed certificate has no certificate authority that it can verify.
Because you're the only one that can verify it.
 
then it's pretty much useless to use ssl if you don't have a CA ?
 
Correct. SLL is built on trust. Without a CA there's no way to know for sure that you're securely talking to who you think you're talking to.
 
7:32 AM
In other words are self signed certificates good to anything ?
 
@Joseph Only for local development.
 
ok for that , but what good does it bring locally ?
 
morning
 
i mean if i am locally working do i really need this security ?
 
Well, if your site strictly uses SSL, which it should, it helps to make sure you don't accidentally start serving up non-SSL over SSL.
@Joseph It's not about security. You're talking over a local loop back or at worst a LAN. You just want to make sure your dev is a 1-to-1 to your prod/staging.
Because if your page serves up assets over non-ssl and you deploy to a production box that requires SSL you got ohnoes I can haz browser fscked
Same thing in your local dev. You can't get ssl over non-ssl.
Otherwise known as...
 
7:39 AM
@Sherif OK . Just one thing , what do you mean by "production box that requires SSL" ? What if i am my own production box ?
and why should it work fine in dev and not in production? i mean it's not sources related, it's more server conf
no ?
 
and in case you're not talking about just an internal dev/staging server (or even if you are) but instead an actual intranet site, encryption is still useful against local traffic sniffing - sure if you're just accepting any old cert then you don't necessarily know who you're talking to, but you know no one else is listening (more or less)
 
@Joseph Yes and no. If all your assets are served up using /// then you're fine, otherwise you're screwed.
 
@Sherif excuse me if my question seems dumb but what do you mean by served up using /// ?
@PaulCrovella so in short there's always a plus in having it ?
 
Relative schemes, basically. If you're doing stuff like this in dev <img src="http://domain.com/img/logo.png"> then it breaks in production if the production uses SSL, because you can't downgrade from SSL to non-ssl in the same request. The browser won't allow it. So instead you need to do something like <img src="//domain.com/img/logo.png"> to be backwards compatible.
If the initial request was made over http the browser will continue to use http. If it was made over ssl the browser will continue to use ssl.
It's when you start sticking http vs. https in your assets that everything gets screwy.
Also redirects.
 
@PaulCrovella No, you don't know nobody else is listening.
 
7:50 AM
Also, cookies.
Lots of configuration issues can cause this "Worked in Dev" meme.
 
@Sherif Thank you :) that's clear now
just wondering though about this <img src="http://domain.com/img/logo.png"> , why not use relative src ?
 
@kelunik ? if you're talking about mitm that's covered in "you don't know who you're talking to"
 
@Joseph Because it might not be the same domain.
 
@PaulCrovella "..., but". If you accept any cert, you can as well just drop TLS basically.
 
!!rfcs
 
@PaulCrovella I used run an unencrypted access point in my neighborhood just to see who'll be dumb enough to connect. If connect to it and visit google.com or any of the popular search engines you get a page that says "Big brother is always watching..."
And yet still people continued to try logging into their emails.
 
@rtheunissen Yeah, just passing in a pointer to the target structure is how it's usually done
 
Moin' Happy Friday 11!
Oh, what a lovely snippet of code to find at 9AM
 
8:13 AM
lol
 
@Sherif is that legal ? lol
 
@Joseph Yes, there's no law against being stupid.
Unfortunately.
 
Ah found out why it's in there. Just found this pastebin.com/PP3XEjH7
I want to scream at whoever wrote that
 
@Sean why?
 
Because it's currently stopping all forms across the front end of our site from being submitted via enter key.
 
8:25 AM
(I seem to recall having to do that, as some browser had really shitty textboxes, where you can't press enter for new lines...)
 
Yeah, I check through commit logs and ask the author why. Doing that atm ^^
 
And yeah, should probably be bound to specific fields where people are inclined to press enter...
 
posted on September 02, 2016

New Cyanide and Happiness Comic

 
"I don't know, I don't remember"
 
btw I should have said yesterday - if you are forced to continue using Apache rewrite rules - you might be better off just autogenerating them from a sane config language, rather than trying to debug hand-written ones.
@Sean ....and that's why commits should have bug issue numbers associated with them...
 
8:30 AM
And commit messages should be less vague in general ^^
Ah well, you can't win them all
 
Haaaaaaaands.
 
:P My hands are typing things~
 
How can i create database in php Sorry i am newbee in php
@Sean
@Sherif
 
@AdityaVyas-Lakhan This room really isn't a great place to ask starter questions. You should use google to find basic tutorials and then ask if you have a specific question.
And pinging people at random is rude.
 
@Sean You mean you don't just do git commit -m echo curl -s http://whaththecommit.com?
 
8:42 AM
Sorry Danack
 
@Sean I thought everyone added this to their .gitconfig gist.github.com/imkevinxu/4016346
@AdityaVyas-Lakhan You typically don't create databases in PHP.
Use one maybe. But create one sounds like you're doing at least 20 different things wrong.
 
Correction: 21 different things wrong.
 
Good show.
 
@AdityaVyas-Lakhan stop using w3schools
 
8:52 AM
ok linus and sheriff
 
Says w3schools isn't good, links to a PHP 5.3 book.
 
@Danack Danack that book covers good material grasping basic php will help him
 
php developer => =_=
 
o/
 
hi all
 
9:02 AM
@AdityaVyas-Lakhan phptherightway.com
 
thanks duikboot
 
Offtopic but I know some of you here have knowledge of it. When I have an ethernet cable which I want to connect to device X where the starting point is a router... can I use 100m or more? Or will that have impact on my signal quality? I've heard when using + 40 meters of UTP cable, I need to add a switch?
 
purfect
thx
 
Hey
if (mysqli_num_rows($query) > 0) {
$row_cnt_all = mysqli_num_rows($query);
$row_cnt_updatet = 0;
$row_cnt_insertet = 0;
$row_cnt_doubt = 0;
$doubtEntrys;

while ($row = mysqli_fetch_array($query)) {
echo "<pre>";print_r(mysqli_fetch_array($query));

Got this structure inside my function.
mysqli_num_rows returns 40 - so i got 40 entry

the while statement only run twice, how is this possible ?
 
9:17 AM
@Traxstar you should step through your code and see what it's doing on a per line basis. It's almost certainly doing what you told it to do rather than what you hoped it would do.
And you should probably refactor your code to not use mysqli_num_rows - I doubt it's actually doing anything useful, and instead is just making your code more complex.
 
@Danack yeah u are right, but i tried everything i know - i my results are length of 40, but loop only run 3 times and i dont understand this
 
Hi. Anyone knows python language ?
 
@Traxstar did you step through the code with a debugger?
 
now, i dont got acces over here to a debugger
just working with atom
 
@GulnazGhanchi these guys do - chat.stackoverflow.com/rooms/6/python
@Traxstar download the evaluation version of PHPStorm.....
 
9:20 AM
@Dan
@Danack Yeah.,thanks :)
 
AudioQuest - Cheap cable
 
dump error - return statement one line to early :D
 
hehe
 
@LeviMorrison Probably looking up the function pointer by name
 
9:43 AM
Hello all
 
dat moment when you realize you cannot eat a large pizza by yourself... burp
 
share it :P
 
 
not a php problem
 
help me
@tereško
 
10:01 AM
Try JavaScript room?
 
Just out of interest - has school just started in the sub-continent?
 
@Danack where?
Europe is large
Usually school starts in most European countries somewhere between 31.8 and 20.9
 
@bwoebi I thought the phrase was more universal - for most English people, the sub-continent refers to a specific one: en.wikipedia.org/wiki/Indian_subcontinent
/south asia from now on then.
 
@Danack ah … I understood "the continent under you" (aka Europe)
 
10:30 AM
what I've never heard that before
 
Is .git extension mandatory for a git repo on private server?
 
@MajidFouladpour .git is not an extension. It's a directory.
Directories starting . have a special meaning on *nix filesystems.
 
@Sherif I think he means the clone url ending .git
 
@Leigh Ahh
That would make a lot more sense in that context.
Look, yet another question that starts with "I'm using PHP Laravel framework and..." that results in a complete and utter failure to understand paragraph 1 of page 1 of chapter 1 of php.
It's like Laravel has become synonymous with PHP for all the wrong reasons.
 
10:50 AM
is it ok to ignore this error?
while installing xammp
 
vagrantup.com phansible.com there you go. no more reason to use xampp
xampp is not a proper development setup
 
And the question was asked here if you are interested in the answers given: stackoverflow.com/questions/26208848/…
 
yeah but in that answer they say that need to disable,but there is chance of less security of my pc
gordon thats awesome thing
thanks
 
@Danack is there a place for another example in Object-Types RFC? I'm thinking of Specification Pattern it's isSatisfied() method should have generic object parameter type hint IMO
 
you're welcome. If you prefer Puppet over Ansible, you can also use puphpet.com
 
11:01 AM
ok
PuPHPet nice "PHP" :D
 
11:15 AM
morgnins
 
morning
 
@MajidFouladpour It's convention that bare repos have the .git extension
@brzuchal o/
 
Anonymous
yo pan
 
@AdityaVyas-Lakhan yet another reason to not use XAMPP
 
mr common
 
11:18 AM
moin
 
@PeeHaa what does those o/ and \o really means ?
 
mogguh
@brzuchal wave to say hi
 
\o
 
Anonymous
o/
 
11:19 AM
\o/
 
\o/
:D
 
|o/
\o|
\o/
 
Anonymous
leaning against a wall like a badass?
 
o|
o/
o-~
 
Ok, I got it :)
 
11:21 AM
:-)8
peter griffin ^
 
Anonymous
lol
 
Hello Everyone..
is there any caching utility like varnish for a separate mysql server ?
 
1 message moved to bin
 
for fast response from mysql server which on separate VM.
 
11:29 AM
The fact that MySQL is running on a separate server should not be the bottleneck
if it is you have serious infrastructure problems
 
Anonymous
@salathe penisphobe.
 
Thanks for your response @DaveRandom. Does it mean the problem is with the Apache Server ?
 
and to answer the question - no there isn't, but you could maybe cache results in e.g. memcache/apc
@VikasSharma depends what the problem is
 
@JayIsTooCommon that's what she said.
 
if you problem is slow responses from MySQL then either your queries need improvement, your indexing needs improvement, or both
or maybe your server is just too busy and you need a more distributed architecture
or maybe one of a million other things
 
11:33 AM
Problem is I am migrating from old server to New Server... New Server have much better hardware configuration than Old One..On the Front End , I mean on Website , I can see performance is better .. but When I am using Web Services to compare both server than there is difference.
Only Downside of NEW Server is its Distance From me is Far.
 
Define "far"
what is the ping round trip time?
 
125 ms more time.
Old server is located in Delhi , India and NEW one is in Singapore.
 
And why are you wanting to move your database server to a new location but not the web server with it?
 
I am migrating both.
NEW server is free for Client. I mean he got some FREE credits to use
 
Then I don't see what the problem is?
I mean 125ms is a pretty shocking ping time from anywhere to anywhere in this day and age
but it's still not likely to make a huge difference
 
11:37 AM
its not the ping time but the extra time that server guy told me after looking MTR reports.
 
What extra time, sorry?
i.e. where is the bottleneck you are trying to eliminate?
 
Extra time due to HOPs.. number of HOPs are little high..
Old server is 2 CORE 6 GB (EACH Apache and MYSQL) ....NEW SERVER ( EACH 4 CORE 12 GB)
 
Right, but the client has asked you to move the application to this server
if they are not happy about the number of hops to the server they have chosen, they should choose one they are happy with
It sounds like your client is essentially complaining that the free thing they got is not good enough
more than that, they are complaining to the developer that the server they instructed them to use is not good enough
 
Hey Fellas, i have two mysql DATETIME values, i am looking to compare those client side to see which is bigger (As in which date is the latest). Is there any way to do that without having to create date objects ? i.e new Date() ?
 
Ok ..Does that mean response time will be High .although the Configurations are Much Better.. its should be Max 500 ms Response time difference.. But I am getting 3 Sec Difference.
 
11:41 AM
@VikasSharma The client have chosen this new server, correct?
 
Yes DaveRandom
 
@VikasSharma OK, and you are not the administrator of this server, correct?
They are asking you to fix a problem that they have created, and you have no power to fix
 
yes.
Okay .. Thank you ...Thanks for your Help.
 
@VikasSharma sorry it's not more helpful
I would remind them that there tends to be a reason that free things are free
@Joseph not a sane way, no.
 
yes.. but they are saying that ..processor , CORE , RAM .. everything is Higher..
 
11:44 AM
Dave and whats that?
 
@VikasSharma If I have a bicycle outside my house, and a Ferrari on the other side of the world, which one is going to get me to work faster?
 
are you telling me that i can't compare this 2016-09-18 10:17:00 to this 2014-09-18 10:17:00 ?
basically i need to say that 2016 ... is the highest date
latest
whatever the term is :D
 
!!> var_dump(new DateTime('2016-09-18 10:17:00') > new DateTime('2014-09-18 10:17:00'));
 
11:46 AM
most recent :d
yea but that's doing it server side
 
wait you mean you want to do it in SQL?
 
no
javascript
 
oh right, well regardless, you can to the same thing in all of those places
in JS you just create a Date object
!!mdn date
 
[ Date ] Creates a JavaScript Date instance that represents a single moment in time. Date objects are based on a time value that is the number of milliseconds since 1 January, 1970 UTC.
 
but that's what i did ask not to do if possible in my question :D
Is there any way to do that without having to create date objects ? i.e new Date() ?
 
11:49 AM
why one earth would you not want to do that?
That's the tool for the job
 
like just get the int value and compare the two
 
yeh you can get the int value from a string... guess how...
 
new Date() ? :p
 
bingo
 
if( (new Date(first).getTime() > new Date(second).getTime())) { }
 
11:55 AM
I think you can just compare date instances (i.e. if (new Date(first) > new Date(second)) { } but I'm not 100% on that, you certainly can in PHP
 
Afternoon'
 
In C# for example you can have one solution and many projects in that solution all referencing classes and files from each other while each project can still be treated as standalone and deployed as such. Does anyone have any ideas how to do this in PHP? I follow a DDD approach and have 2 core domains, about 5 sub domains and 1 generic. I don't want them all in one project so they can be deployed standalone but still need to be able to reference each other in development
 
@tibanez In PHP we have composer which is sort of like nuget
PHP Storm supports composer directly so that the "references" are there
 
@DaveRandom So then wouldn't I have develop each subdomain, tag them, put them in private repositories, then reference a subdomain in a composer.json to get it
 
@tibanez Just put them in a common directory, and then open that common directory:
/data
  /project1 - this is a git root
  /project2 - this is a git root
 
11:59 AM
^ you can also do this
 

« first day (2148 days earlier)      last day (2800 days later) »