« first day (1717 days earlier)      last day (3456 days later) » 

13:00
btw, why is it Gay Overflow on main page today ? (:
Because American politics are world politics apparently
Or just that the owners of SO are american.
Ah well, it's a good thing anyway. Positivity
I will never understand that. I mean - I'm really ok with anybody who wants to be "different" in that sense. I just never understood why they need to shout about that..
Anonymous
13:02
oh no..
Anonymous
xD
lol
Hey, aren't you aware that USA law is world law?
Answer incorrectly and they'll send the F18 right away
13:04
what gay overflow?
hehe
I trolled the entire channel. Big success
The shout about is one of the steps of progression. The final being "No body cares anymore". Which means it's normal.
@Fabor but there was not even a single moment in a history when people were in need to shout about being "normal" in that sense
Because normal is accepted and by definition "normal"
Ignorance stems from inexperience. False perceptions and misinformation on the subject lead to bias and often derogatory opinions. This is why the shout out stage exists, to let people know they're not alone, or this is becoming an accepted part of life.
Normal becomes standard before it is normal, what today is normal was not normal 70 years ago and was indeed shouted (Hello woman rights?).
and you can spot next "normal" standard when someone comes to you with a sentence "back in the old days ..." and you think "fuck your old days grandpa"
13:09
Eventually the idea of a person "coming out" will become archaic. That's the goal I presume.
user4433485
Hi all, I was wondering how do we check user role in php? when I google this, I only find results for Drupal and Wordpress :(
because there's no concept of "user role" in php
you have to make your own
(which drupal and wordpress and many others did)
user4433485
uggh sounds difficult :p I've got in my database a table named users and there is the username password email and user role
@Katherina I would suggest looking at framework.zend.com/manual/current/en/modules/…
it's a decent-ish idea of how to restrict users by role.
13:17
@Fabor I just keep remembering Trapped In The Closet. May have to go watch it again.
Anonymous
lol
user4433485
Thanks @Danack
@Katherina It's MVC orientated but here's a potentially relevant answer from @tereško
@DaveRandom The R Kelly thing? :-/
"Trapped in the Closet" is the twelfth episode of the ninth season of the animated series South Park, and the 137th episode of the series overall. It originally aired on Comedy Central in the United States on November 16, 2005. In the episode, Stan joins Scientology in an attempt to find something "fun and free." After the discovery of his surprisingly high "thetan levels," he is recognized as the reincarnation of L. Ron Hubbard, the founder of the church. The episode was written and directed by series co-creator Trey Parker and is rated TV-MA L in the United States, except on syndicated broadcasts...
But yeh, named after the R Kelly thing
oh heh. I could never consistently watch South Park
13:23
Which is worth watching in its own right, if only for the end of chapter 9 en.wikipedia.org/wiki/Trapped_in_the_Closet
That is in the top 5 weirdest things I have ever seen
Good day guys, I would like to ask for your assisstance because we're currently taking up the part 1 of our thesis and I don't have any idea yet on what programming language we will use to develop a web-based enrollment system. Do we still need to use c# etc. or PHP is enough?
@William you should use the language that you know
yeah, learning a programming language + the business stuff... is hard
if it's a simple (relative term) web application that is database-bound, you can write it in php, python, ruby, java, c#
depends on which one you actually know
so, @William, have you made a website in either c# or php?
not yet sir
13:33
have made any website at all?
not yet sir.
I'm only a student
so sir can I use php only for developing a web-based enrollment system for example?
yes, you can
but you also can make it in c# (which according to your SO profle, you have actually used before)
or in ruby
or in python
Ok thanks...
@William how much time do you have ?
13:38
no i'm just asking...we will develop it next sem
we're just on the part of making documentation
ouch .. I think I remember doing something like this
and i think we have 3-4 months to develop it.
hmm ... lemme think for a moment
thank you very much @tereško for your help
I have 1 situation here please help
13:41
@DaveRandom BAAAAAHAHAHAHAHAHA
@William ok, just to be sure, with "enrolment" you mean the system that students would use to choose which classes to attend. right?
yea...
and think i can't develop it in c# because i only learned the basics
in that case, I recommend you to change your primary focus
my site is not https:// right now and now I wanted to take 1 more web hosting space and I will copy all my code to that server .Now my new server is htts:// and I solved all problems related to new server and now can I change domain name of new server to old one?
developing actually functional enrolment system is complicated
really complicated
can you somehow shift the project goal?
13:44
@tereško was that question to me?
no sir
for example develop full functional technical design and project documentation, but implement only a minor part of the entire system ?
we're on the part of conducting interview
huh ?
also, drop the "sir"
nobody outside India speaks like that
oh ok..
13:46
@tereško ohh that is new to me "nobody outside India speaks like that"
I always wondered if they learn that in English school or if it's how they speak in their native language
And they translate it
so indians gives to respect to elder one then
AFK, 2 min
@Patrick And why isn't it corrected.
we cannot shift our project or change the system we're going to develop.
13:49
Someone help me out, I've spent 3 hours looking at this and I can't get it right! WHAT HAVE I DONE WRONG? http://pastebin.com/RSP9EAdD

Edit -- Files don't delete, Database row doesn't delete, and header doesn't Locate. Anyone got any ideas?
Sir is more reserved for people of authority. Like a teacher or a literal Sir.
Just for the record, yield from $expression; is ultimately the same as foreach ($expression as $key => $value) yield $key => $value; -- Correct?
ok, I'm back
ok, I'm forward
@William "we" , how many people do you have ?
13:50
ok, I'm middle
4
members
/me is trying to come up with an approximate estimate
anyone good at programming, technical design or any other web-development related skill ?
@tereško Yes. I think?
haha no one
my groupmates are expecting from me
@William well, the short version is: you are all fucked
13:52
lol
AWW
haha
Anonymous
XD
@William well... then have them work something that they are qualified for and use the wage to pay for someone else to do it? (I didn't read the whole thing)
so, you are right now conducting interviews to understand what you will have to create and then you will be going for the "project requirements" doc and the technical design
13:54
best case scenario: you will be done with it in 2 weeks
haha hope so
then you will need someone who will do the graphical design and slice it to HTML, the rest of you should be starting to work on backend code
we're currently taking up our thesis
Only because, I'm a graphic designer :) :)
okay
13:57
as for language choice: php might be a better option, because the server infrastructure is virtually free
no license issues
so do i need to advance study in php because we will take it next sem and the development for the system is next sem too
you will be having a class in PHP ?
yes next sem..we are currently taking html
You almost certainly want to talk to your tutors and get their advice on how to do your project.....not random people on the internet.
one can learn HTML/CSS in a week =/
it's the javascript part that's actually tricky
@William , yeah, what @Danack said
13:59
ok guys
Tutor advises: install wordpress, find module.
hope not ..
thanks for your help especially @tereško
I actually worked on a "lecture timetable thing" for my bachelor thesis
making an enrolment system is actually something that would need to be built on top of something like that
Anonymous
I can't remember who it was but someone who is always in room 11 created a php to js application? Don't suppose anyone knows who?
14:01
since classes that a student picks must not overlap ... and some classes have prerequisites
@Jay Sounds like just the thing @Danack would do
I DENY EVERYTHING....
;-)
Anonymous
14:03
@Danack @PeeHaa Awesome, thanks!
@Jay you don't want to convert PHP applications to JS, it just won't work. But being able to convert simple value classes and code to JS is kind of worthwhile....
@Danack ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ ಠ_ಠ
And I really need to give that library some love, but am busy....
@Ocramius Jelly?
@Patrick how's your book doing?
what will be the HTTP caching headers for html pages
14:06
@PeeHaa not good at all. Weather has been to good lately
@Danack Some "love" of the "git push --delete origin master" kind? :-P
I guess it will have to wait until fall... :)
@Patrick *too good cc @Fabor ;)
Anonymous
@Danack Yeah I know :) I was just trying to work out what the js equiv for php 'or' is.
@PeeHaa Maybe the weather went to a place called good, you don't know that's not what he meant...
14:07
@Patrick Yeah I assume it works best when the weather is sheit
@DaveRandom You raise a valid point as always
ThW
ThW
@Jay || works in php and js
@Jay PHP's or is just the same as || with a different precedence. What are you actually trying to do?
@ThW but with other semantics.
@PeeHaa Somehow I get this feeling I'm being mocked...
@DaveRandom cc @Fabor you guys don't have 30+ degrees and sun?
14:10
Never!
ThW
ThW
@bwoebi indeed
@PeeHaa that looks like spring in latvia
lol asshole climate
Anonymous
@ThW @DaveRandom Yeah that worked, thanks. I really need to learn js... I just hate it with a passion.
14:25
just a quick question, but why does calling instance functions statically still work? Example
@DaveChen because no one has changed the code to make it not work yet?
It's hard deprecated in 7
It's a PHP4 hangover
oh just a warning though :P
Also, pretty obviously it doesn't work if the method references $this anywhere
14:29
Turns out my boss can't make it to PHPSC with me.
\o/
Might be a free ticket floating around if it doesn't get snapped up by the first two people being offered it from my boss.
We shall see.
DId I already mention I just love pirate hunters??? :)
lol
Oh nope, got swooped up.
@PeeHaa we all know in which sense
14:35
@PeeHaa Especially those that send you DCMA notices
:D
Are you even coming @PeeHaa?
That reminds me I still have to setup a generic proxy
Also @PeeHaa kudos on your correction of to->too
to->too->two->tutu
@Fabor Nope. You people didn't invite me. Only @Jimbo did but I don't like him very much
<3 @Jimbo
14:39
I only did it for equal opportunities.
lol
<3
Seems like iterator_to_array is buggy, or did I miss something? 3v4l.org/0g1Ya
@PeeHaa -_- slacker
R::dispense('users');
O.o
God that redbean orm thing is gawdawful
@kelunik that's a weird output o_O
@AlmaDo Meh just wait till he is 15 and starts drinking beer and smoking pot
@AlmaDo I am tempted to write up a really scary answer containing religious references and talking about possessions
Does this remove directories or files or both?
$files = glob('project_images/'.$row['id'].'{,.}*', GLOB_BRACE);
foreach($files as $file) {
if(is_file($file))
unlink($file);
}
Everyone – no matter if they are alcoholics or gay or highly intelligent – is relieved once he finds others who are like him.
What about teetotal straight idiots, hmmm?? What about them???
14:54
:P
I do not care about idiots
@bwoebi It's just one special case where it works, the one already starred: 3v4l.org/tHRqg ^^
/me fires up debugger ...
@AlmaDo You must be pretty lonely :-P
^ ouch
14:58
@DaveRandom I am
Also, I care about idiots, I just don't care for them
Neither about nor for here
"I don't suffer fools gladly" <-- if anyone ever says this, punch them in the face and walk away. Firstly the only people who this are twats, and secondly no-one suffers anything gladly so the person who said this is clearly a fool.
? ok, I didn't get it..
I got it, but it's just saying I hate stupid people?
15:03
hate != do not care
idiots != stupid people
@kelunik ah, you missed something
specify false as second parameter.
@kelunik If you dont use the iterator element keys as index it works
Ahhh! @bwoebi beat me by seconds
@LeeDavis exactly that
@LeeDavis @bwoebi oh right, thanks.
the cat is snoring
15:14
@bwoebi I'm not sure, but shouldn't yield from behave like the code would be inlined, so it just continues with keys if none are specified?
@kelunik no. … consider…
function gen() {
    yield from [1, 2, 3];
}
function from($gen) {
    yield from [0, 1];
    yield from $gen;
}
$gen = gen();
var_dump($gen->key());
foreach(from($gen) as $key => $val) {
    var_dump($key);
}
@bwoebi sigh @ division by zero
or would you expect the key to change magically?
I blame it on @Andrea
@NikiC Not sure if sigh at me or sigh at the issue
JRK
JRK
15:19
Hi
@bwoebi What do you want to tell me? I'd expect it to be [0 => 0, 1 => 1, 2 => 1, 3 => 2, 4 => 3] afterwards.
@bwoebi Sigh at people not taking a change when dmitry offers to throw an exception for something
And instead start arguing about how division by zero should be inf instead
JRK
JRK
this is my code
@kelunik note that I have var_dump($gen->key()) first. the key is 0 there. When now going into generator, the key of that very yield becomes 2 according to what you expect?!?
@JRK up arrow -> up arrow -> ctrl+k or even better gist.github.com
JRK
JRK
15:21
But, the result i'm getting like this

Aptitude
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
Arithmetic
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
Reasoning
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
Computer
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
(see full text)
@NikiC Is it worth bringing the topic back up on internals?
3 messages moved to Trash can (please use gist for large blobs of text)
@PeeHaa Ctrl + K works? I've never known that.
@kelunik Yeah
Doesn't ampchat do that?
@bwoebi Yeah, right, but that's ugly anyway. :P
15:23
@kelunik never tried hovering over fixed code button…? there's a title-attribute…
@PeeHaa no, in ampchat you do, ctrl+a, tab. (select all and then tab)
@PeeHaa It doesn't need those ugly indents. It has fenced code blocks and you could always do Ctrl + A, Tab otherwise.
Hi everyone.
@NikiC or do you think it'll open a can of worms?
@bwoebi I do not ever wait for those tooltips to show up if there's no indicator for that.
@bwoebi I think it would be good to resolve it
15:25
@kelunik you're just too impatient!
Because right now this is just new unreleased behavior, we can change it
It's really ugly to have div by zero and mod by zero behave totally differently
@bwoebi Nope, the UX is just bad there.
Anyone got a good safe snippet for deleting folders and their contents?
Can't find any that work
@Rahul exec('rm / -Rf') you are welcome
@PeeHaa you should give him a less effective way
also, it's "-r"
15:32
R also works
@tereško Doesn't matter.
-r, -R, --recursive
remove directories and their contents recursively
@PeeHaa You forgot --no-preserve-root. ;-)
hmm ...
Ah damnit of course
15:33
and the sudo, just to be safe.
@bwoebi Nope, doesn't matter, my webserver runs always as root. :P
@bwoebi What's a sudo? Is that the same as su?
Anyone here use UML?
@PeeHaa @bwoebi REST API or everything over websockets? I'm not sure.
@tereško Why? Thanks @PeeHaa
15:38
hi see this openspeedtest.com/results/399 how can i make carrier name always come under the user icon? it is dynamic so some times 4 letter some time 10 or 15 ..
@Rahul because that particular line will remove all all of the files and directories in the entire server, that are owned by the user which runs the script
I assume you have no clue about command line stuff on unix-like operating systems
@PeeHaa it's basically "su -c"
:P
@tereško Never ever seen anybody do that
@user3002233 not in general, but some of use use parts of UML when we need to model some part of the system
@PeeHaa I do
I've seen people suck, is that the same?
15:45
@kelunik You mean like in an external API? (so, unrelated to the webapp) then REST, I think.
@tereško There should be a tool for reviewing a program. I write PHP. and I use many comments. Just for not forgetting how it wokrs when I review it. Is there any other way to do that? I heard something about UML, like activity diagram and a few more. What do you do for that?
@bwoebi for amp-chat (the web client)
@kelunik for the webclient itself websocket is enough (and faster)
@user3002233 ULM diagrams (there are various types of them) are for either designing project's structure or documenting the existing code
@bwoebi But it's harder to implement something like a request response thing (promises).
15:51
@tereško Thanks, @PeeHaa's actually a bit of a dick isn't he?
12
instastar
@user3002233 you can think of ULM as a standardized system for what developers tend to doodle on piece of paper, when trying to figure out, how to make somthing
@Rahul this chatroom has low tolerance for incompetence
I see.
Or a low competence in the field of tolerance. Depends how you look at it.
@tereško Do you know a good tool for designing UML diagrams?
15:54
@DaveRandom Column A, column B...
@user3002233 I personally have been using yEd laterly, it free and not too slow (I have heard about performance issues on non-windows systems). Another reasonable option is "Visual Paradgm for UML" (the community edition, which is free)
@Rahul It does what you asked no? :)
@kelunik rest api please. I could really use that for my next project and as a matter of fact I have been thinking about how to integrate chat
Hm, the time of my starred message on the right just switched from 14:30 to 16:30, weird SO..
@PeeHaa that's like saying, that H-bomb is good at clearing out the underbrush ... it's technically true
 SELECT competence, tolerance FROM rooms WHERE id = 11

 competence | tolerance
------------+-----------
 0          | 0
@DanLugg stupid markdown
15:57
@PeeHaa There will be a REST api anyway, I think I'll just "proxy" websockets with a sequence id, so I can map the responses.
@tereško How about documentation? Is UML the best options that is available?
@tereško :P
@DaveRandom stupid SO :P
@user3002233 "documentation" is a broad term. UML is good for "high level code documentation". It's something that a developer would read to understand the projects structure as a whole. It does not replace project's specification or code comments. It is not "the best". It just has a specific scope at which it can be useful.
@kelunik yes, that would be my suggestion too.
16:01
Writing that kind of APIs is a PITA compared to libraries...
@tereško Oh wait. I think I need to learn a lot. How can I learn about these all? About the process of creating a program. and the details. and ... all.
@tereško Is there any book about that?
about which part , exactly ?
Anonymous
I'm off, see you tomorrow o/
also, you have to understand this: theory and practice do not always work the same
project specifications are quite often replaced by graphical designs and wireframes ... and some "requirements document"
UML diagrams are rarely used outside large scale projects
@tereško About having the confidence to introduce a program. I mean, I want to know what others do to create a program.
@tereško what's needed. like documentation. how to write the documentation.
@tereško and ...
16:09
@DaveRandom is the scala ]-∞, 0] ?
@tereško Yeah, It seems boring.
it's not "boring", it's just not useful in tiny projects
every tool has a purpose
lol, I find UML exciting.
I find it a (sometimes) necessary evil
I'm looking for it.
16:11
I find UML terrible
I suppose the excitement is dependent on what you're in fact modelling though.
It's something in between… not great, but also not totally terrible.
@bwoebi Why does touching $gen->key() in your example effect the iteration behaviour? See 3v4l.org/ceYFU vs 3v4l.org/6XKCZ // @kelunik
so, @user3002233 , what book exactly are you looking for?
@LeeDavis uuuuuuuuh
16:13
It's terrible, charts are important, communication is important, a java centric specification model is terrible. Especially if you abuse it or do silly things like model a ton in advance (see Fowler's agile is dead).
Something broken, or am I missing something?
@tereško About software development in general. I also want to know the about specification, documentation.
@LeeDavis that looks wrong to me…
Yah. Me too.
Yeah, looks wrong. It's probably calling always next in the foreach?
16:16
@user3002233 hmm ... that's actually a strange request. Most of people want to "learn programming" and not "learn about programming"
@kelunik no, that's a mistake on yield from level
...
@tereško I don't have any serious problem about programming! But I'm suck at the process of creating a program and the details.
@bwoebi Is yield from essentially calling next() to begin iteration?
@user3002233 so you want a book that teaches programming?
16:21
@tereško oh thanks. but which one should I read first?
@Trowski not quite. It's essentially resuming the generator up to next yield. So, like next() in case where generator already was started. And in case it wasn't started, it just advances to first yield.
I'm not sure if wrong or not.
@SiimKallari Programming? Writing code? No. I know how to do that.
posted on June 29, 2015 by kbironneau

/* by MrNeutro */

I hate it when good gifs are captioned inappropriately ^^
@bwoebi I would say correct, because if using a generator in multiple contexts, you have to assume that the value at current has already been used when the generator was previously started.
16:26
@Trowski That was my thought too.
Woulda been better as "I'll just use a goto to skip over to..."
@bwoebi @Trowski Once again makes me think that we might have been better off with disallowing such usages...
@NikiC Ehm. That one… actually is not having multiple simultaneous yield froms, but advancing the generator before being passed to yield from, which never was brought up before…
@bwoebi It's in many ways a similar situation ^^
Basically: Whether you do a rewind() call at the beginning of a yield from
If you do that, you a) effectively forbid sharing and b) don't allow the use of a generator that has been advanced past the first yield
depends on how you put it…
16:33
And now that I think about it, doing a rewind() call at the start makes a lot of sense -- we do this for all other Iterators
(Of course not an actual call, but check if we're AT_FIRST_YIELD and throwing otherwise)
does that reasoning make any sense?
@NikiC This makes a lot of sense to me. I've thought about adding a call to rewind() in my coroutine implementation to disallow generators that were started.
It seemed pointless though if you could circumvent it with yield from.
why are we doing a rewind call? sounds counter-intuituve to me.
16:56
It is nice when as new programmer you find topic about programming jokes, thank you
@bwoebi Because
yield from $iter;
// is equivalent to
foreach ($iter as $k => $v) {
    yield $k => $v;
}
// for everything that isn't a generator. So we do rewind() calls there.
// However we don't do them for generators
@NikiC My question rather was why we do rewind() calls for Iterators?
And the lack of the rewind() call is what causes the issues with sharing and advancing before the yield from etc
@bwoebi How do you mean? Before we use an iterator we must rewind it
@NikiC Interesting… I got that ping even though it's not highlighted and in a code block…
@NikiC yes, why? Why don't we just continue the iterator?
@bwoebi Apart from reusing an iterator being a bug in the vast majority of cases (if it's not, use NoRewindIterator), some iterators require it
If you use SPL iterators and don't rewind you're going to have a bad time

« first day (1717 days earlier)      last day (3456 days later) »