Sufjan Stevens – The Age of Adz – Review

sufjan_stevens_-.Age_of_Adz

If you like music, you will like The Age of Adz.

Review over.

Don’t just sit there and be baffled by my excellent review, go buy it!!!!!!!

Also, I created a YouTube Playlist.

Pitchfork 'Best New Albums' Torrent Search

Pitchfork_Best_new_Music_BTJunkie_Search

Ok so this might be slightly illegal, but I am really just generating some links.

I wrote some code that will take the RSS feed from this page: http://pitchfork.com/reviews/best/albums/ and searches BTJunkie for torrents.

Here it is in action:
http://danfolkes.com/pitchfork_torrent_albums_best/

Here is the source: (also here)

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
<?php
  echo "<table border=1>";
  $doc = new DOMDocument();
  $doc->load('http://feeds2.feedburner.com/PitchforkBestNewAlbums');
 
  foreach ($doc->getElementsByTagName('item') as $node) {
	echo "<tr><th colspan='2'>";
	$title = $node->getElementsByTagName('title')->item(0)->nodeValue;
	echo $title;
    $doc2 = new DOMDocument();
 	$doc2->load("http://btjunkie.org/rss.xml?query=".urlencode($title));
	echo "</th></tr>";
	foreach ($doc2->getElementsByTagName('item') as $node2) {
		echo "<tr><td></td><td>";
		$link = "<a href='".$node2->getElementsByTagName('link')->item(0)->nodeValue."' target='_blank'>";
		$link.= $node2->getElementsByTagName('title')->item(0)->nodeValue."</a>";
		echo $link;
		echo "</td></tr>";
	}
 
  }
  //print_r($arrFeeds);
  echo "</table>";
 
?>

PHP Base64_Encode – Intentionally screwing up pictures

A screwed up base64 image.  Replaced all of the 'da' with 'ha'
A screwed up base64 image. Replaced all of the 'da' with 'ha'

So, I was a little bored so I made some PHP code.

This is what it does:

  • Takes query string values
  • Pulls an image from the web
  • base64_encodes it.
  • Distorts the image.
  • Replaces some of the base64 string data with other string data.
  • Outputs the image in an img tag.

Hope this helps someone, let me know if it does IN THE COMMENTS

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
<?php
	if ((isset($_GET['i']))&&(isset($_GET['f']))&&(isset($_GET['r'])))
	{
		$find = $_GET['f'];
		$replace = $_GET['r'];
		$type = "gif";
		print_r($_GET);
 
		if (isset($_GET['t']))
		{
			$type = $_GET['t'];
		}
		$imgfile = $_GET['i'];
		$contents = implode (file($imgfile));
		$start = base64_encode($contents);
 
 
		$start = str_ireplace($find, $replace, $start);
 
	echo '<img src="data:image/'.$type.';base64,' . $start . '" />';
	}
	else
	{
	?>
		Try: <a href='base64.php?i=http://ec.europa.eu/culture/media/programme/images/logos/02/02.gif17.gif&f=lo&r=ha&t=gif'>http://ec.europa.eu/culture/media/programme/images/logos/02/02.gif17.gif&f=lo&re=ha&t=gif</a>
	<?php
	}
 
?>

What is the Percentage of the World going to College?

nasa_earth_with_mortar_board

Disclaimer: I am not a statistician, I am merely interested. If you have any better numbers, let me know.

Students Enrolled (2007):
18 200 000

World Population:
1995: 5 713 073 000
2000: 6 115 367 000
Average(2007): 5 914 220 000

Percent of World Population Enrolled in College:
18 200 000 / 5 914 220 000 = 0.0030773288
or 0.308%

Sources:
http://howtoedu.org/college-facts/how-many-people-go-to-college-every-year/
http://esa.un.org/unpp/