« first day (1325 days earlier)      last day (3849 days later) » 

15:00
hey @ThW, you're probably a good person to ask:
1 hour ago, by DaveRandom
OK people: anyone got any recommendations for a HTML -> plain text lib (pure PHP, must be compatible with 5.4)?
ThW
ThW
I am moving a project from svn to git + github
@DaveRandom depends, I use XSLT for that task
@ThW Hey man, will you be heading to phpnw this year? :-)
1 hour ago, by DaveRandom
@rdlowrey Email templating with user-defined templates defined with wysiwyg editor ( just for the record my thoughts on this are :'( ), autogenerating text templates from HTML. So yes, I can relatively easily build something myself but I was just wondering if anyone has a recommended lib from doing anything similar
So prolly not viable
ThW
ThW
@Jimbo Sorry no
Although I admit I'm not that familiar with XSLT, but I was under the impression you needed to have a vague idea of the structure of the input for it to be useful
ThW
ThW
15:06
@DaveRandom well our newsletter module outputs a structure with xhtml snippets inside
@DaveRandom So it is two parts, the outer xml structure builds basic stuff like toc and headers, the inner switches the mode and cleans up the xhtml, matches some tags replaces them with text formatting
@ThW And therein lies the problem. I basically would need to match the entire plain of HTML here and work out a sane way to "render" it into text
(hence the reason I'd rather, in this case, use a black-box lib)
@ThW Ah that sucks, I was hoping you might be giving the talk I missed at phpuceu on xpath awesomeness
Maybe next time
ThW
ThW
@DaveRandom Do you know github.com/zetacomponents/Document ?
@ThW Interesting, checking it out now
ThW
ThW
@Jimbo btw I got FluentDOM and PhpCss working on HHVM
@rdlowrey you might want to unfollow me for the next days, I need to create a lot more repositories :-P
user895378
15:17
hehe it's okay, I was just joking :)
@ThW Was it tough?
@DaveRandom Did you follow any decent guide for your chrome extension needs or just docs?
ThW
ThW
@Jimbo PhpCss worked out of the box, but FluentDOM needed some workarounds for bugs, like this one github.com/FluentDOM/FluentDOM/blob/master/src/FluentDOM/…
@Fabien Just docs, but I've done it before anyway
Yeah. I used just docs before too but was a while ago. At least it's well documented.
15:30
@Fabien What are you doing?
@DaveRandom Just something for myself. I watch a lot of game play throughs (to sleep) on youtube which are 95% in playlists. Problem is YT doesn't really track where you left off (video number wise). So I'm writing an extension where I can add playlists and it simply keeps a history of what the last video I watched from those playlists are. This way I can pick up where I left off easily.
Though thinking about it, multi-device won't really work. :( Maybe it's not such a good plan.
@Fabien Why not? Post the data to server-side, store in db
predominantly I watch on my iPad though.
As long as you're signed in to Chrome, it's all automagical
Aye. That's what I planned on using. Syncs across as long as a key is provided.
But I am left with the iPad issue. Which is watching through an app. Closest compromise I can think of is having the extension as more of a reference point. Connect the extension to youtube's API. Check the history to update.
Short of building an iOs app :P
15:40
You can get chrome on the iPad
But youtube through chrome is a bit wanky.
Need a newer iPad then ;)
lol.
Maybe. I can still build it though. iPad woes can be mostly ignored. It'll simplify the build.
Either that or bug Google Youtube to implement some feature for this :P
What's a good reason youtube loads but the videos don't. But this functions fine on a proxy.
@Fabien Firewall?
@Fabien It's probably related to the fact that flash is the worst piece of software designed by anyone ever
15:54
lol
It only started happening today too.
@Naruto sorry for the late reply
Switching to HTML5 doesn't seem to work either. Wonder if it is a block.
No one in the office can access it.
16:13
an excellent read ...
oh wait, not excellent ... shit, it's a shit read ...
@JoeWatkins what the actual fuck is that?
yeah, I don't know ... it was on reddit earlier I think, I was just closing some windows and thought I'd share ... sorry :D
> There are lots programming languages out there and each works to do specific and unique tasks. Each language has a unique set of keywords and special syntaxes for organizing program commands. [... entire article here ...] All of them are good options. There is no real good or bad answer.
Real informative article you got there mate
ruby sucks
it's terrible isn't it ...
> There is no real good or bad answer
...
> PHP is the best language for creating HTML pages
16:19
Right tool for the job.
@JoeWatkins by the pits of hell. Why does PHP/Python/Ruby overview appear in /css/tutoruals-css ?
> Not suitable for making desktop applications
> Objects are CallByValue by default, which is the opposite of most languages and catches lots of programmers off-guard
> Generally considered to be less secured than the other programming languages
NSFTH Not Safe For The Hungry
@ircmaxell yeah. Sure. It's one of disadvantages of hammer that it can't be used for catching butterflies.
> Smaller pool of Python developers compared to other languages, such as Java
16:22
I know, I don't know what that means ... I dunno what most of it means ... I left it open because he opens the php bit with "Rasmus wrote PHP" ... which has never really been true for any version of PHP that you would recognize and want to use ... I was going to say something ... but what is really the point, I couldn't make it into a good article ....
did he?
At least he used past tense
Guys if I want to create a 2D array with 5 rows and 5 columns

$array = array (array(5));
How do I do it?
> It is the third most popular language whose grammatical syntax is not predominantly based on C, e.g. C++, C#, Objective-C, Java.
16:24
Great, guys. Having fun with that article? Well... read comments after it.
@BDillan Check out array_fill(), although also note that PHP does not require you to declare this in advance and you are making your life more difficult by declaring that particular structure in advance IMO
In java its array [5][5]? How can I translate that to PHP? (without initializing elements)
ignore the first ?
> PHP still have a lot of things from the past, like convention-less functions names/arguments but every release they are improving and removing old things as well.
@BDillan Fill an array with 5 elements, each of which are arrays of 5 elements
16:26
hehe
0
Q: Name for subdividing an integer into partitions?

Levi MorrisonI have an unsigned integer that I am dividing into n partitions. For example, if it is a 32 bit number with 4 partitions, each partition would be a byte. Each partition represents a level in a hierarchy. The final value is used as a number; it isn't a bit mask. What is the name for this technique...

@DaveRandom how do I do that?
> but people seem to use that phrase as a trash can for code.
^click on the link that he've provided
lol
16:28
But you really probably don't actually want to do this. There's little-to-no point in initialising an array of null values in PHP
^ don't check out array fill, that's a knee jerk reaction to the question ... the proper answer has been given twice now at least on my screen ...
I smell someone who's trying to translate some Java to PHP without really understanding either language
inorite ... smells like shame, regret, and confusion in here ...
@JoeWatkins The 3 stages of Java: Shame (Oh God, I'm using Java), Regret (I wish I hadn't used Java) and Confusion (Why did I choose Java?)
9
@LeviMorrison what more specifically are you doing?
16:36
We are mapping our organizational levels into bits.
For example: college, department, faculty, student
@LeviMorrison that sounds... interesting
But it's not just a bit index; the value at the college level should always be bigger than the department when used as a number.
would you mind if I ask what the primary reason for packing it into an integer?
We use it for calculating job priority.
AHHHH
nevermind then :-)
16:37
It's not hard-coded either; we can only care about faculty and students while other places may care about more levels.
@DaveRandom hehe
@DaveRandom what's your twitter handle again? Is it @daverandom?
ah, @_DaveRandom
@_DaveRandom, Manchester, UK
Blithering idiot. Also, I write code and hope things don't catch fire.
11 tweets, 17 followers, following 28 users
@PeeHaa Thank you for sorting out your autodiscover :)
The 3 stages of Java: Shame (Oh God I'm using Java), Regret (I wish I hadn't used it) and Confusion (Why did I choose it) via @_DaveRandom
it was surprisingly hard to fit that into a tweet :-)
ThW
ThW
16:58
@rdlowrey That was most of it. :-) 40 new repositories
@ircmaxell I'm currently in stage 1
@PeeHaa A Go game board
In web technologies :)
Ne, @Fabien?
Java is a good language for learning the concepts of object-oriented programming, without having to deal with pointers and memory allocation and all that scary shit
@SecondRikudo yes :P
@BDillan No.
PHP is a good language for learning the concepts of object oriented programming, without having to deal with points and memory allocation and java and all that scary shit.
Java's way of programming is simply horrendeus, especially if you get sucked into Spring.
But what I don't like about PHP is that everything is a type
17:06
@BDillan huh?
@BDillan I think you misspelled "Java".
$something = $ogodwhatisthig($randomobject)
sorry mis-use of function remove the $
@LeviMorrison In C they're called union, which is not a brilliant name:
union u_color {
	// first representation (member of union)
	struct s_color {
		unsigned char a, b, g, r;
	} uc_color;

	// second representation (member of union)
	unsigned int i_color;
};
well ...
I see the code you typed there @BDillan ...
but
> But what I don't like about PHP is that everything is a type
couldn't be further from correct, it's almost the exact opposite of correct ...
@JoeWatkins "Who uses Python? Yahoo Map, Zope Corporation, Linux Weekly News, Shopzilla, Ultraseek" That's quite a recommendation there.
17:10
My argument is that e.g. for boolean you put
$foo = True;

which hides the 'type' and obcufcates it
@Danack yup, especially since it ignores most of the big users
@BDillan it doesn't hide or obfuscate it.
Scripting languages do this I know
@ircmaxell He means he doesn't like PHP being loosly typed.
PHP is a dynamic typed language. Meaning that the type is inferred when you use it. The type of the variable isn't really needed.
I am used to strongly typed languages with explicit type punning
17:12
and I don't like the term loosely typed ... it implies that the type is somehow unknown or doesn't matter, in fact it is known, and it's converted where appropriate (and so does definitely matter) ...
Maybe PHP is better that way, nevertheless I dont like change
@JoeWatkins it is unknown
$something = foo($somethingelse)

what type is $something?
@BDillan Whatever type foo returns. Or in other words, you don't care.
@BDillan you realize, this doesn't make sense ... lets say that were true, and the type was unknown, how on earth would the language even work ?? it's definitely known, but it is dynamic, ie. dependent on the data assigned to it ...
or how it's used
Im not criticizing the language, just what I said originally was that I dislike weak typed languages
it's a shift in mentality for sure
user924016
17:25
just love them all =]
yeah it probably is ... I was just questioning the original statement that "everything is a type" ...
Static typing with sensible built-in conversion/boxing is nice.
$i:int = $s; // $s:string --> implicit cast calls $s->asInt()
please no hungarian notation
things changed since I formed my views; while I was hating java, it got fast ... I started out knowing C, I don't mind mind being extremely explicit about everything there because of what that gives you (extreme efficiency not on offer anywhere else) ... when I came to have to use Java, I begrudged it all the additional information I have to provide it by being so explicit about types ...
php is a happy medium for me ...
17:33
@ircmaxell lol, wasn't hungarian, just colon-delimited type declarations.
yeah, typed when you want it (mostly), not when you don't
@DanLugg I know :-)
$I_AM_NOT_AN_INT:int
^^ HHVM?
when is an int not an int? When it's intish
yeah, I was looking for that :)
I suppose I can best articulate my preference of a type system as: a well defined (spec defined perhaps) framework of rules and laws; a strong foundation supported natively which can be rationalized about, and extended though system interfaces.
Rather than a loose set of rules scribbled on the back of a grocery list.
@ircmaxell Or doublish, apparently.
17:40
@DanLugg :-D
@Fabien does it work again?
Yup
Good :)
> Rather than a loose set of rules scribbled on the back of a grocery list.
the front of the piece of paper is a grocery list, the back is the specification :D
Nice feature. Just used it for illustration (second picture).
@Danack It's not a union because it isn't static; it's dynamic at runtime.
Well... that last episode of GoT was quite... hmm.
@Fabien :-)
@JoeWatkins 2oz butter, array > scalar, 4 carrots, objects are always truthy, 2 liters of milk
18:01
Right in my feels :(
Gunna go drink bbl
later @Fabien
@JoeWatkins Related, and surely read before james-iry.blogspot.co.at/2009/05/… skip to 1995
lata @Fab
Later @Fabien -- remember, you can't drink the feels away.
(but you can sure as shit try)
18:21
@JoeWatkins how does that notify me when I'm not even in the room
Seems like a bug on the chat notifications
He is everywhere and nowhere; he writes php-src with alphabet soup; he is Watkins. Joe, Watkins.
@FabrícioMatté sorry about that ... anyone with a name starting with Fab gets pinged ... didn't think to check ...
@FabrícioMatté Chat never forgets ™
@JoeWatkins no problem, I'm just wondering if that was worth a bug report on meta
Thought it'd notify a single person only
they must know about it I guess ... I assumed it worked like that for a reason ...
18:26
it is like that for a reason
Yeah they know.
Oh okay
I just find it a bit weird that @ mentions on comments can only notify a single person as per meta post, and I can't find any reference for chat mentions
@FabrícioMatté doesn't the chat FAQ give enough information? chat.stackoverflow.com/faq#notifications
@PeeHaa oh thanks, found a related question meta.stackexchange.com/q/144799/186879
18:37
@ircmaxell ... do I misunderstand load elem ?
<?php
use JITFU\Context;
use JITFU\Type;
use JITFU\Signature;
use JITFU\Func;
use JITFU\Value;
use JITFU\Builder;

$context = new Context();

$context->start();

$long = new Type(JIT_TYPE_LONG);
$longs = new Type($long, true);

$signature = new Signature
	($long, [$longs, $long]);

$function = new Func($context, $signature);

$n = $function->getParameter(0);
$f = $function->getParameter(1);

$builder  = new Builder($function);

/*
long function (long[] $n, $f) {
	return $n[$f];
}
*/

$builder->doReturn(
@JoeWatkins I have no idea
@salathe does that mention pinging multiple users with a single @ mention?
@FabrícioMatté Read it and find out.
little too noisy where I'm at atm, my skim reading failed to find anything related
ctrl+f time then
@ircmaxell okay ... it seems pretty simple, I get totally unexpected but predictable results ... it's hard to debug jit'd code ... this is problem no1 for fu (or whatever the name of that language is if it comes about)
18:40
@salathe have you read it, by the way?
@FabrícioMatté Yup.
@salathe I've read it thrice and can't find a single statement about multiple users being notified by a single @ mention
@JoeWatkins Well, as long as you make sure the compiler is working correctly, you can debug PHP code.
@FabrícioMatté You've really read it three times? 30 seconds ago you were resorting to ctrl+f.
@salathe the whole notifications section, yeah
18:42
@ircmaxell yeah that's true I guess ...
P.S. I asked a question originally. I guess we both now know the answer. :)
I think load is right, I think I fucked up passing params ... dunno how ...
@salathe I had read it twice before ctrl+f, and well, I didn't know what to ctrl+f for so I just read it again.
@salathe lol okay. :P
@JoeWatkins write a unit test just for that part of the builder
actually, do that in general :-)
yeah tests are coming ...
18:47
well, Apple just introduced a new programming language
Oh god
I hope it's not another Objective-C
it is :-)
link?
they made Objective-C look like Javascript :-D
18:50
they are announcing it right now, no links that I know of yet
Man, Apple has real talent. It's not easy to create a language that's worse than PHP and they did it two times?!
9
swifly, please ;] <-- that joke wont be funny until there's a link
@ircmaxell like JS? You mean loose typing, lexical scoping, closures?
@FabrícioMatté looks that way. But with type inferance and generics
@ircmaxell seems interesting
interesting doesn't mean that I want to code in it, but it is interesting nonetheless
18:51
@ircmaxell So... Dart from Apple?
Or is the type inference static?
@LeviMorrison it's hard to tell.
@ircmaxell okay, that doesn't sound so bad
@LeviMorrison no, because it doesn't cross-compile (except via LLVM)
@NikiC I don't know... Possibly, possibly not...
time will tell
my bigger issue is yet another proprietary language
Would supporting and aliasing [] in a write-context for strings end the world as we know it, such that it would essentially be an alias for .=
$s[] = 'f' -> $s .= 'f'
Swift programming language.
18:59
swift-lang.org is down, lol
Aimed at game development, supposedly.
@DanLugg the question is: why?
@NikiC Uniformity with treating strings as byte arrays
@LeviMorrison Well, general iOS dev
19:02
> 10:31AM PDT - "6.5x typical JS performance advantage over other browsers"
Uh... where do they get these numbers?
I'm really curious with that one
if it's true, that's game changing
That's for JS, not Swift.
yeha, in safari
Probably only on another artificial specially-constructed benchmark.
Here's the first official link about swift: developer.apple.com/swift
19:07
looks okay. not objective-c for sure
@NikiC ROFL
"This book can’t be viewed using this computer. You can view this book using iBooks on your iOS device."
Because why would I want to read a book about programming on a computer.
there is nothing in that first paragraph that encourages me to read any further ...
luckily, I'm allergic to mac, so I don't have to worry about how pointless it is ... so I wont ...
so ... there's already a language called swift ...
but I guess because they are apple they figure they can do whatever, right ??
seems fair ...
19:29
inb4 apple gets sued
or, they could buy the intellectual property or whatever it is
I mean, copyright
I mean, I have no idea what I'm talking about
a trademark I guess?
@FabrícioMatté Yes, trademark.
Question for you guys. Our site has several distinct sections (reflective of internal departments), each with their own brand identity. There is a universal navigation which can move a user from one section to another, and the "parent" site is where all the user account stuff lives. The brands would like to use their own domain names. Currently, I just forward request, so "xyz.org" becomes "abc.org/xyz" -- they don't like it.
Does anyone have a tl;dr on the NeoMedia patent trollery regarding QR codes?
@FabrícioMatté related
My challenge is, how to unify the login across those domains. I have seen how SO does it, but the page refresh thing is not something the departments like.
19:36
@CarrieKendall thanks, I'll save it for future use
@JoeWatkins oh yeah? anyone big behind it?
> The Swift project is supported by the National Science Foundation with additional support from NIH, Argonne National Laboratory and the University of Chicago Computation Institute.
so ... yeah ... looks like it ...
they know about it, they link to it from their own documents ... apple I mean ...
> also, it looks like variables must explicitly be defined as being optional to even allow assigning nil.
"if you are looking for the swift programming language" ...
My favorite bit so far in the Swift Language Guide: http://t.co/ARXut2Y7x6
19:44
haha
dogcow
@LorenBednar Looks like Apple didn’t get the memo that every symbol you can possibly type *is* a Unicode character. +@dalmaer
on a serious note, that's not useful ...
imagine this, imagine Xinchen doing that in php-src ... it's a stupid idea ...
@ircmaxell The interesting part being that the editor supports those characters, above anything else
@JoeWatkins I see both sides of that coin
it can be abused, yes. Horrifically so. But it also can solve a lot of problems to the non-english speaking world
@NikiC why is that interesting?
from a font standpoint?
@ircmaxell Languages often support unicode labels. But programming editors often have trouble with that, especially outside the BMP
Yes, from a font standpoint basically
19:48
Ah, then yeah...
Or from a it's-written-in-java-and-uses-ucs2-standpoint ^^
(not sure what the state of non-bmp chars in java is)
UCS-2... sigh
@JoeWatkins He can already do that in PHP (does he write PHP?!)
@salathe that's laruence, he does zend things ...
@JoeWatkins Yes I know, but does he write PHP code is what I meant. :)
19:52
oh I dunno ... probably not ... no time probably ... I don't really ...
@JoeWatkins So up to PHP's level then - 3v4l.org/0ob93
No php SSO library recommendations? :( sadtrombone.com Okay, Google, you win.
does "let" feel old fashioned to anyone else ?
@JoeWatkins reminds me of basic
19:58
I always think we're going backwards when I see "let" ...
@JoeWatkins Ya, makes me think of that old game with the banana-tossing gorillas
the last place I saw it was ... zephir-lang.com/intro.html
2
A: javascript disabled in Mac by default?

QuentinNo. All of the mainstream OS X browsers support JavaScript and have it enabled by default.

...
@JoeWatkins Not to me.
Hey, do you guys like the download section left aligned or right aligned? See php.net and leviathon.homenet.org
stackoverflow.com/questions/24001919/… Also why to people keep answering such vague questions?
20:17
@LeviMorrison is yours supposed to be center-aligned?
@LeviMorrison As salathe mentioned, one is centered, one is left. Of those two, I strongly prefer left.
Firebugged it right, and if you're just talking about the downloads section but NOT the content below, then still vote for left. If you right align the whole right side... not bad, I like those equally well.
 
1 hour later…
I guess everyone is busy watching crimewatch
no? just me?
just you ...
I was just waiting for hignfy
21:58
Err, I did mean left and centered aligned.
Hi everyone
what do you think of laravel framework
What does it matter what we think?
> That's because they renamed PHP 6 into PHP 5.1 ~neform
... okay, buddy. Think that if you want to.
Oi oi oi
@LeviMorrison are you talking to me?
22:03
@sabsab This was: "What does it matter what we think?"
@LeviMorrison I just like to know the opinion of some experts, is that bad?
Room 11 is a swath of experts, expertly expounding expertise
[joe@localhost jit]$ php -dextension=jitfu.so test.php
int(1)
int(4294967298)
int(0)
Disassembly:
function function(ptr, long) : long

/tmp/libjit-dump.o:     file format elf64-x86-64


Disassembly of section .text:

00007f1aec46c148 <.text>:
    7f1aec46c148:       55                      push   %rbp
    7f1aec46c149:       48 8b ec                mov    %rsp,%rbp
    7f1aec46c14c:       48 83 ec 10             sub    $0x10,%rsp
    7f1aec46c150:       48 89 7d f8             mov    %rdi,-0x8(%rbp)
hmmf
I am trying to learn the SOLID principles on laravel but I don't really know where to put the interface {} of course not in the controller but where?
@LeviMorrison are you going to correct that ?
22:10
@JoeWatkins Correct what?
Oh, I'm too busy to bother atm.
@LeviMorrison fair enuff, I want to ... but pretty tactless Joe doesn't want to, just wants to type "SHUT UP"
Interfaces are used within all layers. (model, view, and controllers). You can put them anywhere as long as they are included by the compiler
Thanks @sabsab for helping me
22:15
dafuq?
you are must welcome .. happy coding
How much involvement does Rasmurf have in terms of PHP these days?
Oh my goodness! Look at the time my wine glass!
@Fabien much less than the most active contributors ...
> Rasmus: First, I want to emphasize that PHP is driven by the needs of developers. People will present features, including test cases. If it’s reasonable, then the feature will get into PHP. It’s not about my wishlist. I don’t have a team of developers. This is a community of developers building PHP for other developers.
22:17
but he's still around, you can usually get his attention on irc if you've got an actual problem ...
yeah that was a pretty good response I think ... you have to remember that these questions, PHP6/HHVM/Unicode, he gets asked these questions whenever he stands infront of more than 5 people, it must be a ballache ...
he's probably explained how it really works a million times, nobody really listens to anybody ... not really ...
True enough.
22:40
@JoeWatkins True, but on the flip side it must be nice knowing that the only thing you have to put on your CV is your name
Works at Etsy
Seems so vanilla
I do find it weird how someones fame can be big in such a medium sized community. I bet someone like the producer or marketing guy at Etsy is oblivious. Someone could say to him. "Yo, that's Rasmus Lerdorf! He helped create PHP! That powers like 80% of the web". And marketing guy would be like... "Oh... cool?"
Then again if some Arsenal player walked by me and someone pointed him out I would also be like "Oh... cool?"
He probably met the CTO in a bar one night
> Sir, here is a check with my name on it. Write down any number on this piece of paper and I will pay it.
@Fabien I know, I used to live round the corner from Roy Keane, when my friend told me my reaction was basically "Oh... good."
Was it a nice place?
TBF though, if you'd asked me who Rasmus was before I joined this room I wouldn't have known.
Back then I was still using mysql, my cli experience was a single sync script and OOP was just a way of structuring my code to use precedurally.
probably true for a majority ...
22:53
Wonder how long I have been in this room now. At a guess... 1 year and a few months.
@DaveRandom That is a nice place.
(That's his place, obviously)
And he doesn't live there any more
there's a baby that can play football ... I hope all footballers see it, and weep themselves to sleep every night ...
Oh dear...
Jul 1 '13 at 23:04, by Fabien
But if I was to build a small CMS style website, minimal to no maintanence. Should I start looking at Symfony/Laravel? Not like I will use it much in my immediate future but would it be beneficial to do.
10 months ago
The street view pic of my parent's house is at least 5 years old, apparently Google don't care about my former residences
@Fabien "...minimal to no maintenance..." haha
22:58
@DaveRandom I think they only do it when the weather is clear. Which is about every decade up there.
Good point
Although it looks like I was there at the time, my car is parked on the street

« first day (1325 days earlier)      last day (3849 days later) »