Comment on 4chan hacked and taken offline. Hacker reopens /qa/ and leaks all admins emails.

<- View Parent
Realitaetsverlust@lemmy.zip ⁨2⁩ ⁨days⁩ ago

but oh man in a much better, cleaner, and more sparingly way

I don’t think we’re looking at the same source code. The first thing I see in wp-activate.php:

function wpmu_activate_stylesheet() {
	?>
	<style type="text/css">
		.wp-activate-container { width: 90%; margin: 0 auto; }
		.wp-activate-container form { margin-top: 2em; }
		#submit, #key { width: 100%; font-size: 24px; box-sizing: border-box; }
		#language { margin-top: 0.5em; }
		.wp-activate-container .error { background: #f66; color: #333; }
		span.h3 { padding: 0 8px; font-size: 1.3em; font-weight: 600; }
	</style>
	<?php
}

This isn’t better nor cleaner. This is a disaster. A function that stops PHP execution halfway-through, outputs some text and then restarts PHP execution? Hell, I’ve been in the PHP ecosystem for over a decade now and I didn’t even know this was possible and I wish that knowledge was still hidden from me.

Maybe I was wrong by saying that the 4chan source code is better than wordpress, fair. Maybe I should just say both are abominations, I will not judge which one is better and both should be discarded and forgotten.

source
Sort:hotnewtop