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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
<?php showSiteSourceIfRequested();
define('DEFAULT_TWITTER_SEARCH', 'php developer rotterdam');
include './cnf.php';
$ver = '1.2'; // not arbitrary at all :)
$gotRU = (1 < strlen($_SERVER['REQUEST_URI']));
$pages = array('bio','resume','work','site','play','linkedin','facebook','twitter','blogger','flickr','lics');
$page = null;
if ($gotRU) switch (true) {
case ($slashQ = (substr($_SERVER['REQUEST_URI'], 0, 2) === '/?')) && in_array($q = substr($_SERVER['REQUEST_URI'], 2), $pages):
$page = $q; break;
case (substr($_SERVER['REQUEST_URI'], 0, 1) === '/') && in_array($q = substr($_SERVER['REQUEST_URI'], 1), $pages):
header('Location: http://'.$_SERVER['SERVER_NAME'].'/#'.$q); exit;
case !$slashQ && in_array($q = substr($_SERVER['REQUEST_URI'], 1), $pages):
$page = $q; break;
}
$_404 = $gotRU && is_null($page);
if (!$_404)
header('Status: 200 OK');
else
$page = 'fourohfour';
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>I am jochem, nice to meet you.</title>
<link rel="canonical" href="http://iamjochem.com/" />
<meta name="keywords" content="web development, PHP, JavaScript, CSS, SQL, Apache, Linux, AJAX, me, piano, other stuff" />
<meta name="description" content="My personal website, a place for me to tinker with all sorts of web technology and show case some of my skills, experience and past work ... oh and all that web2.0 stuff :-)" />
<style type="text/css">
body { margin: 0px; padding: 0px; font-size: small; color: #ddd; background: #000 url(/assets/img/bg.jpg) no-repeat; position: relative; cursor: default; }
body iframe { width: auto !important; height: auto !important; }
h3 { margin-top: 2em; }
h3, h3 > * { color: #534B4B !important; }
a,a:link { color: #c9c1c1; text-decoration: none; cursor: pointer; }
a:hover { color: #eee; text-decoration: underline; }
abbr { cursor: help; }
a img { border: none !important; }
blockquote { margin: 2.4em 4.8em 2.4em 2.4em; text-align: justify; font-size: 113%; }
ul { padding: 0px; list-style-type:none; }
a.exturl { background: url(/assets/img/exturl.gif) center right no-repeat; padding-right: 12px; }
a.inturl { background: url(/assets/img/inturl.gif) center right no-repeat !important; padding-right: 12px; }
h3.entity > a > *,
h3.entity > *
{ color: #fff !important; }
.s { font-family: "Adobe Caslon Pro", "Hoefler Text", "Georgia", "Garamond", "Times", serif; }
.ss, body { font-family: "Lucida Sans Unicode", "Lucida Grande", sans-serif; }
.ms { font-family: "Andale Mono", "Courier New", monospace; }
.elk { vertical-align: bottom; }
.data { display: none; }
.ftl { cursor: default !important; }
.ft { border: none; margin: 3px; width: 75px; height: 75px; display: none; float: left; }
img.r { float: right; margin: 8px; margin-right: 0px; }
img.l { float: left; margin: 8px; margin-left: 0px; }
.avatar { width: 48px; height: 48px; margin-bottom: 5px; margin-right: 5px; float: left; border: none; clear: left; }
.tweet { margin-top: 5px; padding-bottom: 5px; border-bottom: 1px solid #4c3d3a; }
.tweet time { padding-left: 3em; font-style: italic; }
.fnblock { font-size: .786em; line-height: 1.57em; }
.fnglyph { line-height: .625em; vertical-align: super; font-weight: bold; text-decoration: none !important; }
.fnglyph,
.fnglyph > *,
.fnbk
{ font-size: .76em; }
.fnglyph,
.fnglyph > *,
.fnbk,
.ouch > * { color: #dd4242 !important; }
.ouch > * { text-transform: uppercase; font-size:1.4em; }
.occu { border-bottom: 1px solid #4c3d3a; margin-bottom: 2em; padding-bottom: 2em; }
.occu.last { border-bottom: none; }
.occu p { font-size: 2.1em; margin: 0px; }
.occu span.d{ color: #8e8787; }
.occu span.w{ font-style: italic; padding-left: 2.1em; }
blockquote.question,
blockquote.answer { margin: 0em; font-style: normal; font-size: 5.8em; padding:2.2em; margin-bottom: 0px; line-height: 67%; color: #b0a8a8; }
blockquote.question { color: #4c3d3a; top:0px; height: 1600px; }
.do_gd blockquote span { color: #fff !important; }
div.q { font-size: 3.825em; color: #201D1A; line-height: 87%; display: inline; }
div.q.o { float: left; margin-left: -.4em; }
div.q.c { margin-left: -.01em; }
div.a { font-size: 37%; vertical-align: top; padding-left: .6em; display: inline; }
#cntWrap { z-index: 4; margin: 5.8em 0 5.8em 5.8em; position: absolute; top: 0px; }
#cnt,
#cntFoot { display: none; overflow: hidden; }
#cnt .pad,
#cntFoot .pad
{ padding: 32px 32px 0 32px; width: 624px; background: url(/assets/img/darken_bg.png); }
#cntFoot .pad
{ padding-top:8px; padding-bottom: 8px; }
#cnt a.ctl { margin-bottom: 1em; float: right; clear: right; }
#cntClose { display: block; width: 24px; height: 24px; background: url(/assets/img/close.png) 0 0 no-repeat; }
#cntClose span
{ display: none; }
#cntTitle { font-size: 176%; }
#cntBody,
#cntBody2 { line-height: 1.7825em; font-size: 127%; }
#cntBody a,
#cntBody2 a { text-decoration: underline; }
#cntWidpad { margin:0px; padding:0px; text-align: center; }
#cntWidget { display: inline-table; }
#cntWidget > *
{ text-align: left; }
#cntWidget > dl
{ text-align: center !important; }
#cntWidget dl
{ width: auto; height: auto; position: relative; padding: 0; margin: 0; }
#cntWidget dl dt
{ clear: none; display: inline-table; padding: 8px; margin-left: 8px; border: 1px #201D1A solid; }
#cntWidget dl dd
{ clear: left; display: block; top: 45px; padding: 0; margin: 0; text-align: left !important; }
#cntWidget dl dt.here
{ font-weight: bold; font-size: 107%; border-color: #4c3d3a; }
#cntFoot { border-top: 1px solid #4c3d3a; }
#nav { z-index: 2; border: 1px solid #000; font-size: 1.1em; position: fixed; top: 148px; left: 512px; width: 0px; white-space: nowrap; overflow: hidden; padding-bottom: 2em; }
#nav ul { margin: 0 0 2em 0; }
#nav h4 { font-size: 1.425em; line-height: 1.2em; padding: 0; margin: 0 0 0.5em 0; color: #635451; }
.preview { position: absolute; display: none; z-index: 100; }
.sbb, .sbbl { z-index: 1; width: 116px; height: 60px; position: absolute; right: 0px; display: none; }
.sbb { top: 120px; }
.sbbl { bottom: 0px; cursor: pointer; }
#validated { display: none; background: url(/assets/img/valid.gif); }
#validated span
{ display: none; }
#topcontrol { cursor: pointer; z-index: 5; }
#panorama { z-index: 3; display: none; position: absolute; bottom: 0px; height: 99px; width: 100%; background: transparent url(/assets/img/sydney_harbour.jpg) bottom left repeat-x; }
#reddoor { position: absolute; height: 100%; top: 0px; width: 782px; background: url(/assets/img/reddoor.jpg) bottom right no-repeat; }
#reddoor div{ position: absolute; bottom: 0px; width: 312px; left: 296px; font-size: 10px; }
#ukawareBtn { z-index: 3; width: 361px; height: 361px; position: absolute; left: 620px; top: 70px; display: none; }
#ukawareBuyBtn { z-index: 4; width: 119px; height: 119px; position: absolute; left: 790px; top: 360px; display: none; }
.clearfix:after { content:"."; display:block; height:0; clear:both; visibility:hidden; }
html .clearfix { height:1%; }
@media print {
body { color: #222; background: #fff; height: auto; }
#nav { border: none; }
blockquote.question, blockquote.answer,
#cntWrap, #nav,
.sbb, .sbbl,
#panorama,
object, embed,
body * #fourohfour,
.fnbk,
div#linkedin.data, div#facebook.data, div#blogger.data,
div#twitter.data, div#flickr.data, div#lics.data,
#topcontrol,
#ukawareBtn, #ukawareBuyBtn
{ display: none !important; }
body div.data
{ display: block !important; }
body div.data div.title
{ font-size: 3.625em; color: #201D1A; margin: 2.375em 0 1.275em 0; }
body div.data div.title.pb
{ page-break-before: always; margin-top: 0; }
body div.data div.body,
body div.data div.body2
{ padding: 0 3em 0 3em; }
body div.data h3
{ font-size: 2.235em; color: #635451; margin-top: .765em; margin-bottom: .3625em }
.twentyems
{ display: inline-table; width: 20em; }
}
</style>
<!--[if lt IE 8]>
<style type="text/css">
body {overflow-x: hidden;}
#cnt .pad, #cntFoot .pad { background: url(/assets/img/darken_bg.gif); }
</style>
<![endif]-->
</head>
<body>
<div>
<a name="top"></a>
<?php $UKAwareTitle = 'Buy yourself a ticket to UKAware2010, join us in London Olympia2 on the 16th & 17th of April .. and get inspired!';
$UKAwareAffLink = 'http://www.eventbrite.com/event/508059620/SpecialpartnerUKAWARE2010/3279869490'; ?>
<a title="<?php echo $UKAwareTitle; ?>" href="<?php echo $UKAwareAffLink; ?>"><img id="ukawareBtn" src="/assets/img/ukaware2010.png" alt="UKAware 2010 - The UK's leading Green Expo!" /></a>
<a title="<?php echo $UKAwareTitle; ?>" href="<?php echo $UKAwareAffLink; ?>"><img id="ukawareBuyBtn" src="/assets/img/ukaware2010-buynow.png" alt="Buy discounted tickets for UKAware 2010" /></a>
<blockquote class="question s">
<div class="q o">“</div><p>How<br />deep<br />does<br />the<br />rabbit<br />hole<br />go?</p><div class="q c">”</div>
</blockquote>
<blockquote class="answer s">
<div class="q o">“</div><p>Currently,<br />I’m<br />going<br />with …<br /><br />… <em>very</em></p><div class="q c">”</div>
<div class="a">- Jochem, <?php echo date('Y'); ?></div>
</blockquote>
<div id="cntWrap">
<div id="cnt">
<div class="pad">
<a class="ctl" href="#" id="cntClose" title="close the panel"><span>close</span></a>
<h2 id="cntTitle"></h2>
<div id="cntBody" class="clearfix"></div>
<div id="cntWidpad"><div id="cntWidget" class="clearfix"></div></div>
<div id="cntBody2" class="clearfix"></div>
</div>
</div>
<div id="cntFoot" class="clearfix">
<div class="pad"><a class="ctl" href="#top">back to top</a><!-- | <a class="ctl" href="#" id="permalink"></a> --></div>
</div>
</div>
<?php if ($_404): ?>
<div id="fourohfour" class="data">
<div class="title">Four Oh Four : page not found.</div>
<div class="body">
<?php /* TODO: add some request input based output ?!? :-) */ ?>
<div class="do_gd">
<p>I'm really sorry you had to sit through all that sliding animation in order to view my oh-so-lame error page.</p>
<p>My site contains a total of one pages, so you’ll have to forgive me for not implementing a search function. </p>
<p>Today’s recommendation? hit the ‘close’ icon above and check the links in the menu that appears (eventually, you’ll have to sit through more sliding animations), alternatively <a href="/">click here</a> and start again.</p>
<p>For those of you that are getting frustrated with all these broken inter-tubes I have selected the video below, it’s not guaranteed to lower your blood pressure but once your done watching it will be closer to 5pm.</p>
<p style="text-align: center">
<?php echo genFlashObjectHTML('http://www.youtube.com/v/-zcOFN_VBVo&hl=en_US&fs=1&rel=0&color1=0x3a3a3a&color2=0x999999', 480, 400, array(
'allowFullScreen' => 'true',
'allowscriptaccess' => 'always',
), 'Video of canadian students performing a song.'); ?>
</p>
<p>Feel better already don't you! maybe this 404 is a sign from above, time to go out and get some fresh air? if your lucky we'll have fixed the inter-tubes by the time you get back.</p>
</div>
</div>
</div>
<?php endif; ?>
<div id="persinfo" class="data">
<div class="title first">Details: Jochem Maas</div>
<div class="body">
<ul>
<li><strong class="twentyems ss">Email Address</strong>: <?php echo jsObsfucate(getCnf('email_addr') , false, true); ?></li>
<li><strong class="twentyems ss">(Mobile) Telephone Number</strong>: <?php echo strObsfucate(getCnf('mobile_no')); ?></li>
<li><strong class="twentyems ss">Skype</strong>: <?php echo strObsfucate(getCnf('skype_addr')); ?></li>
<li><strong class="twentyems ss">Google Wave & Google Talk</strong>: <?php echo jsObsfucate(getCnf('gmail_addr'), false, true); ?></li>
<li><strong class="twentyems ss">Live Messenger</strong>: <?php echo jsObsfucate(getCnf('msn_account'), false, true); ?></li>
</ul>
</div>
</div>
<div id="play" class="data">
<div class="title first">Play</div>
<div class="body">
<div class="do_gd">
<p>I have been studying the piano for about a year and a half and practice about 30 minutes a day. It can be quite frustrating ... mostly for the neighbours. I have lessons once a week with a <a href="http://www.pianolespraktijk.nl/hanneke.htm">brilliant teacher</a>, and slowly but surely I’m starting to show signs of musical ability! I love playing and hope one day to be able to do so, my goal is to be able to play Rachmaninoff, why you ask? because it’s hard, have a listen and decide for yourself:</p>
</div>
</div>
<div class="body2">
<div class="do_gd">
<h3>Excercise</h3>
<p>I have been known to go for the occasional jog, I’d go more often if it wasn’t for the great winter weather.</p>
<p>I’m a bit of bicycle freak. I love mountain biking, although I think I should reclassify that somewhat because we have soooo many hills in Holland. Still, there is lots of fun to be had jumping stairs and the like, here in the 2 dimensional land of the Dutch.</p>
<p>I recently took up SCUBA again and passed my Open Water Diver’s training. SCUBA is fantastic, I really want to do more! During my last dive in tropical waters I saw Nemo (and mom & pop) living in a anemone ... that was mind blowing. Great Barrier Reef, here I come!</p>
<h3>Food & Drink</h3>
<p>I enjoy the occasional drink and just hanging out, love to go out to dinner and I’m almost always up for a philosophical or political discussion.</p>
<p>I like to cook occasionally, taking on a ‘big’ project, for instance a five course Christmas dinner for 12 people ... the great thing about such evenings is that you get to go all out with the ingredients, make a complete mess and then sit back at the end of it all and watch everyone do the dishes!</p>
<p>I like plants too, although sometimes the feeling isn’t mutual, I tend to stick with succulents and cactus’ as they are a lot more forgiving with regard to my forgetfulness when it comes to feeding & watering the plants.</p>
<h3>Any Other Business</h3>
<p>On a very rare occasion I have been known to paint miniatures, but please don’t hold that against me (just for the record I don’t have a train set.).</p>
<p>I spend a lot of time reading, I enjoy all sorts of literature but have a soft spot for quality science fiction. I also read quite a bit about spirituality<a href="#fn_mulder" name="fnbk_mulder" class="fnglyph">†</a> and other things of that nature (you know, the kind of books they hide in the ‘fruitcake’ section at the local book store ;-). Some of my favorite authors are Krisnamurti (J. and U.), Kahlil Gibran, Issac Asimov, George Orwell, Sun Tzu, C. S. Lewis, A. A. Milne, Roald Dahl, Terry Pratchett and Neal Stephenson.</p>
<p>Lastly, you might catch me doing stuff that looks like work during my free time, I spend a lot of time reading about and experimenting with web technology. To me that’s not work, it’s fun, well sometimes it is work (deadlines wait for no man) but it’s still fun. Some people enjoy a crossword puzzle on a sunday afternoon - I prefer to write code.</p>
<p>I admit it, I’m a geek.</p>
</div>
<p class="fnblock">
<a class="fnglyph" name="fn_mulder">†</a><a href="http://lmgtfy.com/?q=the+truth+is+out+there">Mulder</a> was wrong, the truth isn’t out there. <a class="fnbk" href="#fnbk_mulder">[back]</a>
</p>
</div>
</div>
<div id="work" class="data">
<div class="title pb">Work</div>
<div class="body">
<div class="do_gd">
<p>What do I do? The short answer is “I develop web applications”, to get you started below is an exhubrient rendering of some of the main tools I use as a developer (size matters).</p>
<div id="skilltags"></div>
<p>Incidentally, the speed of the cloud animation is set to 78, and the size of the ‘PHP’ item is set to 42, I find this amusing, I hope you do too. :-)</p>
<h3>Tasks & Projects</h3>
<p>In the course of my work I have been known to document requirements, provide cost estimates, write functional & technical specifications, lead a team of developers and design implement & manage the release of databases, software stacks, web applications and sites.</p>
<p>In my time I have, amongst other things, developed two custom, extensible CMS/ORM implementations, a custom-bicycle configurator, a real estate portal, numerous online payment integrations, a white-label online ticket sales platform, an ajax calendar/planning application, data synchronisation routines and something called Banshee<a href="#fn_banshee" name="fnbk_banshee" class="fnglyph">†</a>.</p>
<p class="clearfix"><a href="http://beeldspraak.com/"><img class="r" src="/assets/img/bs.png" alt="Beeldspraak BV Logo" /></a>If you would like to view a list of projects that I have been involved with, I would invite you to peruse <!-- <a href="#portfolio">my portfolio page</a> or -->the portfolio at <a href="http://beeldspraak.com/#werk">beeldspraak.com</a>.</p>
<h3>Languages</h3>
<p>On a day to day basis my primary tool is PHP, I have ten years of experience, and have spent quite some time training others in it’s use. I’m also very comfortable with JavaScript (technically ECMAScript) and have also been known to debug other people’s ActionScript. I dream in valid, semantic HTML<a href="#fn_dream" name="fnbk_dream" class="fnglyph">‡</a>. I have written recursive stored procedures in SQL<a href="#fn_recspsql" name="fnbk_recspsql" class="fnglyph">ƒ</a> and know enough about bash to be scared :-).<br />Whilst I’m writing about languages, I’d like to say that I am interested in branching out into Objective-C, Python and C.</p>
<h3>Silly Old Bear</h3>
<p>Fundamentally I offer strong problem solving skills, attention to detail and an ability to see the larger picture. I can sometimes be a bit blunt. I like my code to be as neat and tidy as the designs of the pages that it outputs, I believe in doing things right whenever possible (as opposed to not caring as long as something ‘works’, sometimes budget constraints require a crude implementation - which is the right thing, only it’s grates against the aesthetic nerve of a developer!). I am loyal and I am passionate about delivering successful web applications on time.</p>
</div>
<p class="fnblock">
<a class="fnglyph" name="fn_banshee">†</a> A custom data management platform driving multiple sites (on seperate platforms) connected to a SAP backend. <a class="fnbk" href="#fnbk_banshee">[back]</a><br />
<a class="fnglyph" name="fn_dream">‡</a> you should see the CSS! <a class="fnbk" href="#fnbk_dream">[back]</a><br />
<a class="fnglyph" name="fnbk_recspsql">ƒ</a> Completely possible with <a href="http://firebirdsql.org/">Firebird DB</a>. <a class="fnbk" href="#fnbk_recspsql">[back]</a>
</p>
</div>
</div>
<!--
<div id="portfolio" class="data">
<div class="title pb">Portfolio</div>
<div class="body">
I really need to get a personal portfolio up :(
</div>
</div>
-->
<div id="resume" class="data">
<div class="title pb">Résumé</div>
<div class="body">
<p class="do_gd2">Is your web bureau the next to be added to this list? Reference available upon request.</p>
<div class="occu">
<span class="d">January, 2010 ~</span>
<p><span class="do_gd2">VERY EXPERIENCED WEB DEVELOPER</span></p>
<span class="w">- Self Employed, Planet Earth</span>
</div>
<div class="occu">
<span class="d">April, 2005 - January, 2010</span>
<p><span class="do_gd2">LEAD WEB DEVELOPER</span></p>
<span class="w">- <a href="http://beeldspraak.com/" title="Rotterdam Web Design and Development">Beeldspraak BV</a>, Rotterdam, The Netherlands</span>
</div>
<div class="occu">
<span class="d">May, 2002 - April, 2005</span>
<p><span class="do_gd2">WEB DEVELOPER</span></p>
<span class="w">- Self Employed, Rotterdam, The Netherlands</span>
</div>
<div class="occu">
<span class="d">November, 1999 - May, 2002</span>
<p><span class="do_gd2">TECHNICAL SUPPORT</span></p>
<span class="w">- Jason Geosystems BV, Rotterdam, The Netherlands (<a href="http://www.fugro-jason.com/">became Fugro-Jason</a>)</span>
</div>
<div class="occu last">
<span class="d">July, 1998 - June 1999</span>
<p><span class="do_gd2">JUNIOR DB PROGRAMMER</span></p>
<span class="w">- Sane Systems, Exeter, UK</span>
</div>
</div>
</div>
<div id="bio" class="data">
<div class="title pb">Bio</div>
<div class="body">
<div class="do_gd">
<p>I was born on the 10th of February 1977 in Rotterdam, The Netherlands.<br />I emigrated to the UK with my family in 1982 and subsequently grew up and went to school there.</p>
<p>I lived in various places in England during my time, including the counties of Hertfordshire, Surrey and Devon. My family eventually moved back to mainland Europe and I stayed on living and working in Devon.</p>
<p>Having had various part-time, summer and incidental jobs, I was offered my first real opportunity in the IT sector by the mother of a good friend of mine. The lady in question had run a successful financial software business during the 80's and wanted to develop custom financial software for the organic farm she was employed by. She introduced me to “VisualFoxPro 5.0” and challenged me to help her develop the software. We spent the best part of a year trying before deciding to cancel the project. The fact that my only previous computer experience was programming basic BASIC on the BBC Master 10 years before compounded the difficulty we had in building a complete and stable product. I was very disappointed with my failure but at the same time very grateful for all the things I learnt, the value of which I only came to realise much later.</p>
<p>In 2000 I travelled back to Holland in order to undergo back surgery, and afterwards decided to stay for financial reasons, quite simply, at that time, I calculated that my spending power was almost 3 times what it was in the UK. </p>
<p>After my recuperation I took up employment with a dutch software company as a junior system administrator. My main responsibilities centered around supporting Windows users and the related PCs and Servers. I was very lucky to have the opportunity to interact with so many gifted scientists & programmers, and I’m especially grateful for the wisdom & guidance of General IT Manager. During this time I started to develop websites as a hobby in my free time.</p>
<p>Having become completely hooked on web development and after having done a few small, unpaid projects with friends I decided to start up for myself. For the next few years I etched out a fairly decent living for my then girlfriend, our son and myself, doing graphic design, programming and SEO for various clients. This endeavor culminated in a freelance offer in 2004, from a multi-media company in Rotterdam, to ‘reboot’ the failed website of a major, dutch high street electronics retailer. The successful implementation of a new e-commerce website and the coupling with a legacy FoxPro2.0 (oh isn’t life sweet sometimes!) back office system led to job offer with the afore mentioned multi-media company.</p>
</div>
<p>It was a good offer, so I took on the position of “Web Developer” at Beeldspraak. The company grew and took on more programmers, a number moved on, and I took on the role of “Lead Developer”, essentially being responsible for all programming work that was delivered and all systems that ran in production. Amongst other things, I designed a number of custom extensible platforms developed to meet the needs of clients who maintained ongoing accounts, of which the afore mentioned electronics retailer formed a part. I acted as the last resort for any technical problem, which sometimes meant pulling all-nighters to fix some server or application - mostly I pulled it off, a great feeling!</p>
<p>“Beeldspraak” is the dutch word for “metaphor”, a very apt name for a company that brings sophistication, creativity and “colour” to everything they do - the thinking person’s web bureau. Beeldspraak was the place I first truly, successfully applied the skills I had spent so long developing during the preceding years, at a level that I was satisfied with. As such the company has grown from three (for a small period we were just the two of us) to 10 employees (as of 2009), something I’m very proud to have been able to help accomplish.</p>
<p>As of the 1st of January, 2010, I have decided to end my contract with Beeldspraak, for the very simple reason. I want to live in the same city as my sister ... she lives in Sydney, Australia.</p>
<p>That is my dream ... and I’m following it!</p>
<h3>Update:<br />Life is what happens when your busy making other plans …</h3>
<p>
… and you can't always get what you want either (or so the song goes)!<br />
Either way, I have come to the conclusion that emigrating to Australia is not a viable option for me and as a result I'm now looking to join a web development team in Rotterdam where I can practice and expand my skills.
</p>
</div>
</div>
<div id="site" class="data">
<div class="title pb">My Site</div>
<div class="body">
<div class="do_gd">
<h3>Version <?php echo $ver; ?></h3>
<p>My site is a hand built, essentially, static show case. The intended audience is assumed to be using a browser (i.e. not Internet Explorer) with JavaScript enabled on a fast PC with a decent screen resolution (although the site still displays okay at 800*600).</p>
<p>My site is not something I use to actively or regularly publish content, manage a ‘presence’, sell products or anything of that nature.</p>
<p>Accessibility and browser backward compatibility are not a priority for my site, given that there are only so many hours in one day I focused on the quality of the content and the whizz-bang functionality. I suppose you could classify my site as somewhere between ‘experiment’ and ‘work of art’, given that we’re on the internet, it’s a work in progress.</p>
<h3>Brief yourself</h3>
<p>I set myself the following design brief, do you think I succeeded?:</p>
<ol>
<li>Confine all code to a single file with the exception of images and <abbr title="Content Delivery Network">CDN</abbr> derived resources.</li>
<li>Output that validates.</li>
<li>Be dark.</li>
<li>Be unconventional.</li>
<li>Offer honest, consise information about myself.</li>
<li>Reward people who take the time to look at the details (and the title attributes) with a bit of humour.</li>
<li>Be a little bit thought provoking.</li>
<li>Be a little bit zen.</li>
</ol>
<p>Actually those last two are somewhat mutually exclusive, but I think I’ll leave the paradox undisturbed.</p>
</div>
<div class="do_gd">
<h3>Darkness</h3>
<p>I’d like to explain the dark theme a little, firstly I’m rather a philosophical person and I’m a geek. Geeks often like black screens because they are less painful on the eyes (I’m writing this in <a href="http://www.hogbaysoftware.com/products/writeroom">WriteRoom</a>, which gives an indication of what kind of geek I am.). A lot of geeks and philosophical-types like ‘The Matrix’ (<a href="http://xkcd.com/566/" title="xkcd, the other religion.">but not the other two</a>), I’m one of those too. I like black terminals, I’m interested in following the white rabbit to see how deep the hole goes and lastly, and most importantly, an enlightened man once explained to me, and I paraphrase heavily here, that:</p>
<blockquote><span class="s">The whole universe is but an illusion, and the world we see is constructed of nothing but the light of our own mind. To seek the truth one must go beyond the illusion, light is illusion, light does not exist.</span> <em>- w.b.</em></blockquote>
<p>I can only vaguely imagine what he really means (yes I see the irony in the use of the word ‘imagine’), but in my limited, philosophical dream ‘dark’ is the only adequate metaphor in existence to describe the non-existence of light.</p>
<p>So the whole dark theme is nothing more than my pseudo-artistic attempt to express my journey for the truth. A journey which I’ve decided should take me to Australia, which in turn was, indirectly, the driving force behind creating this site.</p>
<h3>Tech & Fun</h3>
<p>I’ve used arbitrary but meaningful numbers where ever I can get away with it (e.g. various dimension & duration parameters), numbers like <a href="http://en.wikipedia.org/wiki/1066_and_All_That">1066</a>, <a href="http://en.wikipedia.org/wiki/1812_Overture">1812</a>, the reciprocal of φ and <a href="http://www.google.nl/search?q=the+answer+to+life%2C+the+universe+and+everything&ie=utf-8">42</a>. There are also various subtle (or not) references to various things I like, like a bear might imply his preference for honey.</p>
<p>The site should validate, I like valid output but I can live with some flavours of tag soup, the law of diminishing returns leads me to accept invalid output if it becomes too much work to ‘fix’ an issue (assuming that the issue is not known to cause any practical issues).</p>
<p>The JavaScript is based on jQuery, all the animations are custom, the scrollbar thought bubbles are positions according to the viewport height and ‘yeehaw’ animation is self-generating & recursive. I’m very sorry if the color graduated text rendering nonsense turns your <a href="http://www.apple.com/getamac/" title="sorry for the fanboy moment ladies and gentlemen, please move along now.">PC</a> too mush.</p>
<p>I drew the doodle imagery myself and the background image (et al) was photoshopped together by your truly also.</p>
<p>Visitors longing for a taste of the red door of old are advised to disable JavaScript and refresh the site.</p>
</div>
</div>
</div>
<div id="linkedin" class="data">
<div class="title">LinkedIn</div>
<div class="body">
<div class="do_gd">
<div style="background: #fff; padding: 8px; float: right;"><a class="linkedin-profileinsider-inline" href="http://nl.linkedin.com/in/iamjochem">Jochem Maas</a></div>
<p style="width: 284px">I have a profile on LinkedIn, look:</p>
<p style="width: 284px">I would have preferred to do something a little more impressive than a simple profile display widget, but LinkedIn have yet to announce a public API with which one could interact with their platform.</p>
<p>I did intend to dig into the JavaScript LinkedIn prodives for the 'widget' but it's somewhat obsfucated and when I originally ran it it managed destory DOM elements other than the one it was supposed to replace, fudging my HTML fixed this. It didn't seem fruitful bothering to introspect it further, much better to wait until such time as LinkeIn decide to release a public API.</p>
</div>
</div>
</div>
<div id="facebook" class="data">
<div class="title">Facebook</div>
<div class="body">
<div class="do_gd">
<p>A wise man once said to me:</p>
<blockquote><span class="s">I am a very lucky man, I have many friends ...</span> <em>- b.s.</em></blockquote>
<p>He subsequently held up his hand and extended three fingers.</p>
<p>I can manage to keep the details of ten's of project, hundred's of logins, passwords, URLs, scores of appointments, telephone numbers, addresses facts and more trivia than you care for, stored in my head some how.</p>
<p>I think I can manage three relationships without the use of a social networking platform. Don't get me wrong, I think Facebook is a marvelous application, I just don't have much of a use for it personally, at least I've lived quite happily without it up until now, who knows what tomorrow may bring.</p>
<p>The most interesting thing about Facebook, in my opinion, is their API. As soon as I think of an app someone has not already built (which is harder than it sounds), and find the time to write it, I will get myself an account :-).</p>
</div>
<h3>Update:<br />I admit it, I got sucked into Facebook …</h3>
<p>I lost contact with a friend of mine and after having exhausted all other avenues I caved in and signed up to Facebook ... I did find my friend (and a few others!) but admittedly I still have not come up with an app.</p>
</div>
</div>
<div id="blogger" class="data">
<div class="title">Blogger</div>
<div class="body">
<div class="do_gd">
<p>
V<span class="ouch">i</span>vamus luctus feugiat consequat.
Mo<span class="ouch">r</span>rbi t<span class="ouch">e</span>mpor <span class="ouch">a</span>rcu sit amet
do<span class="ouch">l</span>or porttitor fermentum. Maecenas <span class="ouch">l</span>aoreet justo a
turp<span class="ouch" title="lipsum.com refuses to give me text containing a Y">y</span>s
co<span class="ouch">n</span>dim<span class="ouch">e</span>ntum v<span class="ouch">e</span>l iaculis
mauris vulputate. Nunc viverra <span class="ouch">d</span>apibus <span class="ouch">to</span>rtor sed tempus.
In pretium varius purus, vel pellentesque nunc tristique vitae. Nullam sit amet libero lectus.
Sed ut li<span class="ouch">g</span>ula m<span class="ouch">et</span>us.
Sed in ligula quis tort<span class="ouch">o</span>r cursus viverra vitae ut augue. <span class="ouch">N</span>ulla
<span class="ouch">e</span>t massa elit, non ultrices purus. Aliquam posuere ultricies ante id
s<span class="ouch">o</span>dales. Suspendisse <span class="ouch">f</span>eugiat felis nibh,
vitae feugiat neque. Nam sed nisl vi<span class="ouch">t</span>ae purus r<span class="ouch">h</span>oncus
cursus quis non nulla.
</p>
<p>
L<span class="ouch">o</span>rem ipsum dolor sit amet, con<span class="ouch">se</span>ctetur adipiscing
el<span class="ouch">i</span>t. <span class="ouch">N</span>am <span class="ouch">te</span>mpus lacus sed
nulla dapibus vehicula.
Maecenas bibendum, quam quis po<span class="ouch">r</span>t<span class="ouch">t</span>itor aliquam,
lorem est luctus massa, et ornare risus aug<span class="ouch">u</span>e nec ni<span class="ouch">b</span>h.
Donec vel elit l<span class="ouch">e</span>ctus. Cum sociis natoque
penati<span class="ouch">b</span>us et magnis dis parturient montes,
Nulla sed e<span class="ouch">l</span>it purus, eu m<span class="ouch">o</span>lestie erat. Sed dictum,
ipsum vel e<span class="ouch">g</span>esta<span class="ouch">s</span> cursus, dui nunc pellentesque neque,
et elementum ligula dui et erat<span class="ouch">.</span><a href="#fn_ouch" name="fnbk_ouch" class="fnglyph">†</a>
</p>
</div>
<p class="fnblock">
<a class="fnglyph" name="fn_ouch">†</a> “I really need to get one of those intertube blogs.” <!-- <a class="fnbk" href="#fnbk_ouch">[back]</a> -->
</p>
</div>
</div>
<div id="twitter" class="data">
<div class="title">Twitter</div>
<div class="body">
<div class="do_gd">
<p>Twitter is. There is really no getting around it for now, whether you love or hate it.</p>
<p>Even though twitter may have an inherently high signal to noise ratio, it's widespread use means it is definitely [becoming] a valuable marketing & networking tool in my opinion</p>
<p>Twitter has as many critics as fans, personally I feel that the rapid developments and seemingly steady influx new communication platforms means it is too early to call the match on what the evolution of [digital] communication will bare as the winners. I do believe that the current generation of social networking & messaging tools will tend towards a much richer, integrated fabric, with less and less emphasis on brands and applications and more and more on the communication channel.</p>
<p>For fun I integrated a sample twitter 'feed' showing the last 20 tweets contain the phrase “<strong><?php echo DEFAULT_TWITTER_SEARCH ?></strong>”<!-- , you can play with the search widget to list other tweets. --></p>
</div>
</div>
</div>
<div id="flickr" class="data">
<div class="title">Flickr</div>
<div class="body">
<div class="do_gd clearfix">
<span style="float:right; margin-left:1em;" id="amazonprods"></span>
<p style="float: left; width: 358px;">
Because every website should have pictures of cats, if, than for no other reason than to demonstrate a trivial flickr.com integration.
</p>
<p style="float: left; width: 358px;">
Given my pro-cat-picture stance I offer the fine cat related gallery below, which per chance, also doubles up as an example of a trivial flickr.com integration.
</p>
</div>
<h3>Cats</h3>
</div>
<div class="body2">
<h3>Nonsense</h3>
<div class="do_gd">
<p>Aside from all this cat nonsense, I do have an account at flickr.com but it's mostly used for [web development] testing purposes, you can <a href="http://www.flickr.com/photos/33238887@N02/">find it here</a>.</p>
<p>A friend suggested that it should be rabbits instead of cats presented here, he is right of course, but I just really like cats … and the axiom that every website should have pictures of rabbits just isn't true, so it wouldn't work. Besides I’d still have to find somewhere to put cat pictures.</p>
<p>Lastly, It's a long shot, but if you happen to be looking for cat related products why not browse my hand-picked selection from the widget above and to the right. :-).</p>
</div>
</div>
</div>
<div id="lics" class="data">
<div class="title">Attribution, Kudos etc.</div>
<div class="body">
<div class="do_gd">
<p>I am grateful to the following people and organisations for inspiration, code, images and ideas (as appropriate), that helped me to build my site.</p>
<p>If I have missed anybody out, please accept my apologies. I know I stand on the shoulders of giants every day and essentially the list below could stretch into the thousands of people, all the way back to Archimedes.</p>
<ul>
<li>
<h3 class="entity"><a href="http://www.mixedstudio.com/">Joel Rossol</a></h3>
.. for his super photo of Sydney, Australia, which I munged somewhat to fit in with my rabbit hole theme :-)
</li>
<li>
<h3 class="entity"><a href="http://www.roytanck.com/">Roy Tanck</a> & <a href="http://www.bloggerbuster.com">Amanda Fazani</a></h3>
... for their lovely <a href="http://www.bloggerbuster.com/2008/08/blogumus-flash-animated-label-cloud-for.html">“Blogumulus” 3D tagcloud</a>,
which I misappropriated in order to display some of my web development skills.
</li>
<li>
<h3 class="entity"><a href="http://dynamicdrive.com/">Dynamic Drive</a></h3>
... for their <a href="http://www.dynamicdrive.com/dynamicindex3/scrolltop.htm">JQuery ScrollToTop plugin</a>,
which I refactored slightly (and which I failed to get to work in IE).<br />
<a href="/lics/scrolltotop.txt" class="inturl">[view license]</a>
</li>
<li>
<h3 class="entity"><a href="http://www.eyecon.ro/">Stefan Petre</a></h3>
... for the help his <a href="http://www.eyecon.ro/zoomimage/">JQuery zoomimage plugin</a> was
in writing the flickr image grid mouse over zoom.<br />
</li>
<li>
<h3 class="entity"><a href="http://allmarkedup.com/">Mark Perkins</a></h3>
... for bits and pieces of his <a href="http://projects.allmarkedup.com/jquery_url_parser/">JQuery URL Parser plugin</a>,
mainly the regexp.<br />
<a href="/lics/jquery_url_parser.txt" class="inturl">[view license]</a>
</li>
<li>
<h3 class="entity">Sergiy Timashov</h3>
... for one of his, seemingly thousands of, icons, which I mauled with Photoshop and used as the basis for my content panel close button. I hope he doesn't mind, I could find an email address to check.
</li>
<li>
<h3 class="entity"><a href="http://www.linksplace.com/" class="entity">LinksPlace</a></h3>
... for their yeehaw.wav file. :-)
</li>
<li>
<h3 class="entity">Code, Content & Resource providers</h3>
... jQuery, Google, Amazon, Archive.org, Twitter, linkedIn, et al. for the nuts and bolts that make my site possible.
</li>
</ul>
</div>
</div>
</div>
<div id="nav">
<h4>Me</h4>
<ul>
<li><a href="/?play" id="link_play" title="what I do ... (sometimes with computers)">play</a></li>
<li><a href="/?work" id="link_work" title="what I do ... with computers">work</a></li>
<!-- <li><a href="/?portfolio" id="link_portfolio" title="some of the things I have worked on">portfolio</a></li> -->
<li><a href="/?resume" id="link_resume" title="without the ´s it would be just like the play button on your iPod.">résumé</a></li>
<li><a href="/?bio" id="link_bio" title="my history, as written by the winner?">bio</a></li>
</ul>
<h4>Web 2.oh</h4>
<ul>
<li><a href="/?site" id="link_site" title="tinkering!">my site</a></li>
<li><a href="/?linkedin" id="link_linkedin" title="big machine, small cog, all connected.">linkedin</a></li>
<li><a href="/?facebook" id="link_facebook" title="I exist on facebook ... forever.">facebook</a></li>
<li><a href="/?blogger" id="link_blogger" title="doing my bit for the signal to noise ratio.">blogger</a></li>
<li><a href="/?twitter" id="link_twitter" title="I find the first 4 letters somewhat ironic.">twitter</a></li>
<li><a href="/?flickr" id="link_flickr" title="apologies upfront.">flickr</a></li>
</ul>
<h4>Contact</h4>
<ul>
<li><strong class="ms"><abbr title="Email Address">E</abbr></strong>: <?php echo jsObsfucate(getCnf('email_addr') , true, true, array('subject' => 'Hi there!')); ?></li>
<li><strong class="ms"><abbr title="(Mobile) Telephone Number">T</abbr></strong>: <?php echo strObsfucate(getCnf('mobile_no')); ?></li>
<li><strong class="ms"><abbr title="Skype">S</abbr></strong>: <?php echo strObsfucate(getCnf('skype_addr')); ?></li>
<li><strong class="ms"><abbr title="Google Wave & Google Talk">W</abbr></strong>: <span title="Sometimes I’m Jochem"><?php echo jsObsfucate(getCnf('gmail_addr'), false, true); ?></span></li>
<li><strong class="ms"><abbr title="Live Messenger">M</abbr></strong>: <?php echo jsObsfucate(getCnf('msn_account'), false, true); ?></li>
</ul>
<h4>Misc.</h4>
<ul>
<li><a href="#" id="link_print" title="printer-friendly version of my site">print my site</a></li>
<li><a href="/?source=1" id="link_source" title="view the source of my [complete] website">view source</a></li>
<li><a href="/?lics" id="link_lics" title="lisencing & rights attribution for 3rd party code used on this site.">lics & attribution</a></li>
</ul>
<div id="validated"><span>Validated XHTML1.0 & CSS2.1 (I'm ignoring errors related to the .flipvert class and anything spat out by LinkedIn)</span></div>
</div>
<img src="/assets/img/bubble_scrollme.gif" class="sbb" id="scrollme" alt="" title="scroll downwards" />
<img src="/assets/img/bubble_keepgoing.gif" class="sbb" id="keepgoing" alt="" title="dark in here isn't it" />
<img src="/assets/img/bubble_almostthere.gif" class="sbb" id="almostthere" alt="" title="tiddly pom, toddly pom" />
<img src="/assets/img/bubble_yeehaw.gif" class="sbbl" id="yeehaw" alt="" title="Dig a rabbit hole far enough, assuming your a european rabbit, and where do you end up?. My sister is already there, want to take a look?" />
<div id="panorama"></div>
</div>
<script type="text/javascript" src="http://www.google.com/jsapi?key=<?php echo getCnf('google_api_key'); ?>"></script>
<script type="text/javascript">
/* <![CDATA[ */
var jom = {
genTabs : (function(){
var i = 1, geti = function() { var j = i; i++; return j; };
return function(r)
{
var d = '', t = '';
$(r).each(function() {
var id = this.id ? this.id : 'wt_' + geti();
t += '<dt target="' + id + '">' + this.title + '</dt>';
d += '<dd id="' + id + '">' + this.content + '</dd>';
});
return '<dl>' + t + d + '</dl>';
}
})(),
trackEvent : (function(){
<?php echo (!getCnf('ga_key') ? 'return function(c,a,o,v){};' : ''); ?>
var store = [];
var dowork = function(c,a,o,v) {
if (c == 'content' && a == 'show')
window.gat._trackPageview('/' + o);
window.gat._trackEvent(c, a, o, v);
}
return function(cat, act, optlbl, optval) {
if (!window.gat) {
store[store.length] = [cat, act, optlbl, optval];
return;
}
var r;
while (store.length) {
r = store.shift();
dowork(r[0], r[1], r[2], r[3]);
}
dowork(cat, act, optlbl, optval);
}
})(),
fixScreen : function() {
// small screens need to see the menu too
var nav = $('#nav'),
abs = jom.absPos( nav.get(0) ),
mht = (abs[1] + nav.height()),
wht = $(window).height();
if (mht > wht)
nav.css('position', 'absolute');
},
initFluff : function() {
// show the UKAware button!
var now = new Date();
if (now.getFullYear() <= 2010 && now.getMonth() <= 3 && now.getDate() <= 17)
$('#ukawareBtn').animate({width: 'show', height: 'show', opacity: 'show'}, 1280, 'bounce', function() {
$('#ukawareBuyBtn').animate({width: 'show', height: 'show', opacity: 'show'}, 786, 'bounce');
});
// make validation text available to user as a title attrib
var v = $('#validated'),
t = $('span', v).text(),
i = $('<img src="' + v.css('backgroundImage').replace(/^url\(["']?([^\"')]+)["']?\)/g, '$1') + '" style="width:100%;height:100%"/>'),
w = parseInt(84 / 2),
h = parseInt(72 / 2);
i.attr('alt', t);
v.attr('title', t).height( h ).width( w ).append( i ).show(1066);
i.hover(
function(){ v.animate({height: '+='+h, width: '+='+w}); },
function(){ v.animate({height: '-='+h, width: '-='+w}); }
);
// add stylesheet def - get around the fact that the following CSS works, but doesn't validate
$('head').append('<style type="text/css">.flipvert { -moz-transform: scaleY(-1); -webkit-transform: scaleY(-1); transform: scaleY(-1); filter: flipv; }</style>');
var height;
height = (($('.sbb').height() * 2) + $(window).height());
if (height > $(document).height())
$('#keepgoing').remove();
else
$('#keepgoing').css('top', height + 'px');
height = (($('.sbb').height() * 2) + ($(window).height() * 2));
if (height > $(document).height())
$('#almostthere').remove();
else
$('#almostthere').css('top', height + 'px');
$('.sbbl').bind('click', function() {
jom.exposeOz();
}).animate({opacity: 'show'}, 3624, 'easeout');
// return a callback function - can be called during init or given to jom.cntOpen() or whatever
return function() {
setTimeout(function() {
$('.sbb').animate({width: 'show', height: 'show', opacity: 'show', top: '-=' + $('.sbb').height()}, 1812, 'easeout');
}, 1812);
}
},
loadFlashObjects: function() {
<?php
// id="Player_64800fe9-c9ce-452b-ae15-3d1af2e2e692"
$f['amazon'] = genFlashObjectHTML('http://ws.amazon.com/widgets/q?ServiceVersion=20070822&MarketPlace=US&ID=V20070822%2FUS%2Fiamjo-20%2F8003%2F64800fe9-c9ce-452b-ae15-3d1af2e2e692&Operation=GetDisplayTemplate', 250, 250, array(
"quality" => "high",
"bgcolor" => "#000000",
"allowscriptaccess" => "always",
"wmode" => "transparent",
), 'An Amazon.com widget displaying cat related products.');
$f['tagcloud'] = genFlashObjectHTML('/assets/flash/tagcloud.swf', 624, 454, array(
"quality" => "high",
"bgcolor" => "#000000",
"allowscriptaccess" => "always",
"wmode" => "transparent",
"flashvars" => "tcolor=0xffffff&tcolor2=0xffffff&hicolor=0xffffff&mode=0&distr=true&tspeed=78&tagcloud=" . htmlentities('<tags>'.renderTagCloudXML(array(
array('name' => '(x)HTML', 'size' => 36),
array('name' => 'CSS', 'size' => 36),
array('name' => 'PHP', 'size' => 42),
array('name' => 'MySQL', 'size' => 36),
array('name' => 'firebird', 'size' => 22),
array('name' => 'Apache', 'size' => 28),
array('name' => 'Linux', 'size' => 24),
array('name' => 'bash', 'size' => 20),
array('name' => 'JavaScript', 'size' => 32),
array('name' => 'CVS', 'size' => 26),
array('name' => 'Photoshop', 'size' => 20),
array('name' => 'firebug', 'size' => 14),
array('name' => 'ySlow', 'size' => 14),
array('name' => 'Eclipse', 'size' => 20),
array('name' => 'svn', 'size' => 10),
array('name' => 'jquery', 'size' => 10),
array('name' => 'prototype', 'size' => 10),
array('name' => 'dojo', 'size' => 10),
array('name' => 'mootools', 'size' => 10),
array('name' => 'apc', 'size' => 11),
array('name' => 'gd', 'size' => 11),
array('name' => 'Windows', 'size' => 7),
array('name' => 'Office', 'size' => 7),
array('name' => 'Mac OS X', 'size' => 14),
array('name' => 'symfony', 'size' => 14),
array('name' => 'iDeal', 'size' => 10),
array('name' => 'Ogone', 'size' => 10),
array('name' => 'gettext', 'size' => 11),
array('name' => 'json', 'size' => 14),
array('name' => 'xdebug', 'size' => 10),
array('name' => 'ZendStudio', 'size' => 16),
array('name' => 'ZendDebugger', 'size' => 16),
array('name' => 'AJAX', 'size' => 14),
array('name' => 'XML', 'size' => 12),
array('name' => 'REST', 'size' => 14),
array('name' => 'HTTP', 'size' => 14),
array('name' => 'squid', 'size' => 10),
array('name' => 'mod_rewrite', 'size' => 24),
array('name' => 'smarty', 'size' => 16),
array('name' => 'wordpress', 'size' => 12),
array('name' => 'drupal', 'size' => 9),
array('name' => 'CDN', 'size' => 10, 'url' => 'http://code.google.com/apis/ajaxlibs/'),
)).'</tags>', ENT_QUOTES)
), 'A 3D rendered tagcloud displaying the names of various technologies I work.');
?>
$('#amazonprods').html('<?php echo $f['amazon']; ?>');
$('#skilltags').html('<?php echo $f['tagcloud']; ?>');
},
scrollToTop : {
setting : {startline:600, scrollto:0, scrollduration:786, fadeduration:[500, 100]},
controlHTML : '<span class="upscroller">back to top</span>',
controlattrs : {offsety: '102px', offsetx: '12px'},
anchorkeyword : '#top',
state : {isvisible:false, shouldvisible:false},
scrollup : function(){if (!this.cssfixedsupport)this.$control.css({opacity:0});var dest=!isNaN(this.setting.scrollto)? this.setting.scrollto : parseInt(this.setting.scrollto);if (typeof dest=="string" && jQuery('#'+dest).length==1) dest=jQuery('#'+dest).offset().top; else dest=0;this.$body.animate({scrollTop: dest}, this.setting.scrollduration);},
keepfixed : function(){var $window=jQuery(window);var controlx=$window.scrollLeft() + $window.width() - this.$control.width() - this.controlattrs.offsetx;var controly=$window.scrollTop() + $window.height() - this.$control.height() - this.controlattrs.offsety;this.$control.css({left:controlx+'px', top:controly+'px'});},
togglecontrol : function(){var scrolltop=jQuery(window).scrollTop();if (!this.cssfixedsupport)this.keepfixed();this.state.shouldvisible=(scrolltop>=this.setting.startline)? true : false;if (this.state.shouldvisible && !this.state.isvisible){this.$control.stop().animate({opacity:1}, this.setting.fadeduration[0]);this.state.isvisible=true;} else if (this.state.shouldvisible==false && this.state.isvisible){this.$control.stop().animate({opacity:0}, this.setting.fadeduration[1]);this.state.isvisible=false;}},
init : function(){jQuery(document).ready(function($){var mainobj=jom.scrollToTop;var iebrws=document.all;mainobj.cssfixedsupport=!iebrws || iebrws && document.compatMode=="CSS1Compat" && window.XMLHttpRequest;mainobj.$body=(window.opera)? (document.compatMode=="CSS1Compat"? $('html') : $('body')) : $('html,body');var extTcObj = $('#topcontrol'); mainobj.$control=(extTcObj.length ? extTcObj : $('<div id="topcontrol">'+mainobj.controlHTML+'</div>').css({position:mainobj.cssfixedsupport? 'fixed' : 'absolute', bottom:mainobj.controlattrs.offsety, left:mainobj.controlattrs.offsetx, opacity:0, cursor:'pointer'}).attr({title:'Scroll Back to Top'})).click(function(){mainobj.scrollup(); return false}).css('opacity',0.0).appendTo('body');if (document.all && !window.XMLHttpRequest && mainobj.$control.text()!='')mainobj.$control.css({width:mainobj.$control.width()});mainobj.togglecontrol();$('a[href="' + mainobj.anchorkeyword +'"]').click(function(){mainobj.scrollup();return false;});$(window).bind('scroll resize', function(e){mainobj.togglecontrol()});})}
},
extUrls : (function(){
var parsedUri = function() {
this.attr = function(k) { return this[k]; }
}
var parseUri = function(url) {
var fld = ["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];
var re = /^(?:(?![^:@]+:[^:@\/]*@)([^:\/?#.]+):)?(?:\/\/)?((?:(([^:@]*):?([^:@]*))?@)?([^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/;
var m = re.exec( decodeURI( url ));
var uri = new parsedUri;
var i = 14;
while ( i-- )
uri[ fld[i] ] = m[i] || "";
uri[ 'qryTmp' ] = {};
uri[ fld[12] ].replace( /(?:^|&)([^&=]*)=?([^&]*)/g, function ($0, $1, $2) {
if ($1) uri['qryTmp'][$1] = $2;
});
uri[fld[12]] = uri['qryTmp']
uri['qryTmp'] = undefined;
return uri;
}
return function(settings) {
// define default settings
settings = jQuery.extend({
local_domain : parseUri( location.href ).attr('host').toLowerCase(),
local_domains : [],
css_class : 'exturl',
target : '_blank',
force_extensions : []
}, settings);
settings.local_domains[ settings.local_domains.length ] = settings.local_domain;
// find links and 'fix them'
$("a[href]").each(function() {
var href, dom, ext, has;
var jqSelf = $(this);
if ($('img', jqSelf).length > 0)
return;
href = parseUri( this.href.toLowerCase() );
if (href.attr("protocol") == 'mailto') {
jqSelf.bind('click', function() { jom.trackEvent('exit', 'mail', '?'); return true; });
return;
}
dom = href.attr("host");
ext = href.attr("file");
href = href.attr("source");
if (ext) {
ext = ext.split('.');
ext = ext[ ext.length - 1 ];
}
has = [
ext != null && settings.force_extensions.length > 0 && jQuery.inArray(ext, settings.force_extensions) > -1,
dom && jQuery.inArray(dom, settings.local_domains) == -1
];
if (has[0] || has[1])
jqSelf.addClass(settings.css_class).attr({ target: settings.target }).bind('click', function(){
jom.trackEvent('exit', 'url', href);
});
});
};
})(),
watchLocHash : (function(){
var strInt, strHash;
return function(turnOn) {
if (typeof turnOn == 'string') {
clearInterval(strInt);
window.location.hash = turnOn;
jom.watchLocHash( true );
return;
}
if (!turnOn) {
if (strInt) {
clearInterval(strInt);
strInt = undefined;
}
return;
}
strHash = window.location.hash;
strInt = setInterval(function(){
if (strHash == window.location.hash)
return;
if ($('#cnt:animated').length > 0)
return;
var prv = strHash,
id = window.location.hash.substring(1),
hp = (prv.length > 1);
//*
if (!id.length) {
strHash = window.location.hash;
jom.cntClose( prv.substring(1) );
return true;
} //*/
if ($('#link_' + id).length !== 1)
return true;
strHash = window.location.hash;
if ($('#cnt:visible').length > 0) {
var hof = (function(i){
return function() { jom.initWidget( i ); jom.cntOpen( i ); };
})(id);
if (hp) jom.cntClose( prv.substring(1), hof ); else hof();
} else {
jom.initWidget( id );
jom.navClose(function() { jom.cntOpen( id ); });
}
}, 234);
};
})(),
getRach : function() {
var rach = $('#rachmaninoff');
if (rach.length === 1)
return {jqObj: rach, isnew: true, player: $f('rachmaninoff')};
var w = 300
h = 24,
config =
{
width : '350',
height : '24',
wmode : 'opaque',
allowfullscreen : true,
allowscriptaccess : 'always',
key : "#$b6eb72a0f2f1e29f3d4",
playlist : [
{url: "http://www.archive.org/download/RachmaninoffPreludesForPianoOp.32/RachmaninoffPreludesOp32.mp3", autoPlay: false}
],
clip : {
autoPlay : false,
onPlay : function() { jom.trackEvent('rach', 'play'); },
onPause : function() { jom.trackEvent('rach', 'pause'); },
onStop : function() { jom.trackEvent('rach', 'stop'); }
},
canvas : {
backgroundColor : "0x000000",
backgroundGradient : "none"
},
plugins : {
audio : {url: "http://www.archive.org/flow/flowplayer.audio-3.0.3-dev.swf"},
controls : {
stop : true,
autoHide : 'never',
playlist : false,
fullscreen : false,
gloss : "none",
backgroundColor : "0x000000",
backgroundGradient : [0.5,0.3,0,0,0,0],
sliderColor : "0x555555",
progressColor : "0xC9C1C1",
timeColor : "0xf3f3f3",
durationColor : "0xC9C1C1",
buttonColor : "0x000000",
buttonOverColor : "0x505050"
}
},
contextMenu : [{"Item RachmaninoffPreludesForPianoOp.32 at archive.org" : "function()"}, "-", "Flowplayer 3.0.5"]
}
rach = $('<div id="rachmaninoff" />').css('position', 'absolute')
.css('display', 'none')
.css('z-index', '1234')
.width(w + 'px')
.height(h + 'px');
$('body').prepend(rach);
return {
jqObj : rach,
isnew : true,
player : $f('rachmaninoff', "http://www.archive.org/flow/flowplayer.commercial-3.0.5.swf", config)
};
},
gradiateQuotes : function() {
var s = jom.str2color( $('blockquote.question').css('color') );
var c = [
{ pc: 10, col: [s[0] + 48, s[1] + 48, s[2] + 48]},
{ pc: 45, col: s},
{ pc: 55, col: [s[0] - 28, s[1] - 16, s[2] - 16]},
{ pc: 80, col: [s[0] - 44, s[1] - 32, s[2] - 32]}
];
jom.colorizeText('blockquote.question p', 1, null, null, '|', c, function() {});
var s = jom.str2color( $('blockquote.answer').css('color') );
var c = [
{ pc: 10, col: s},
{ pc: 30, col: [s[0] - 32, s[1] - 32, s[2] - 32]},
{ pc: 60, col: [s[0] - 64, s[1] - 64, s[2] - 64]},
{ pc: 100, col: [s[0] - 102, s[1] - 102, s[2] - 102]}
];
jom.colorizeText('blockquote.answer p', 1, null, null, '|', c, function() {});
},
spanizeText : function(obj, cssClass, grpSize) {
var res = "", tag = "", len = 1;
var text = $(obj).html();
var reg = new RegExp( "^([^\\s<&]|&[a-z]*;){1," + grpSize + "}" );
while (text.length) {
//if (text.length > 3072) return false;
if ((tag = text.match(/^(\s|(<[^>]*>))+\s*/)) && tag.length > 0) {
text = text.substr(tag[0].length);
res += tag[0];
}
len = (tag = text.match(reg)) ? tag[0].length : 1;
res += '<span' + (cssClass ? ' class="'+cssClass+'"' : '') + '>' + text.substring(0, len) + '</span>';
text = text.substring(len);
}
$(obj).html(res);
return true;
},
absPos : function(jobj) {
var obj = jobj, curleft = 0, curtop = 0;
if (jobj.offsetParent) {
curleft += jobj.offsetLeft;
curtop += jobj.offsetTop;
while (obj = obj.offsetParent) {
curleft += obj.offsetLeft;
curtop += obj.offsetTop;
}
}
return [curleft, curtop];
},
str2color : function(str) {
var fixBounds = function(m) {
for (var i = 0, v; i < 3; i++) {
v = parseInt(m[i]);
if (v > 255) m[i] = 255;
else if (v < 0) m[i] = 0;
else m[i] = v;
}
return m;
};
if (str && str.constructor == Array && str.length == 3)
return fixBounds( str );
if (str.match(/rgb\([0-9]{1,3},( )*[0-9]{1,3},( )*[0-9]{1,3}( )*\)/))
return fixBounds(str.replace("rgb(","").replace(")","").split(","));
if (str.match(/#?[0-9a-fA-F]{6}/)) {
if (str.length == 7)
str = str.substring(1);
return fixBounds([parseInt(str.substring(0,2), 16), parseInt(str.substring(2,4), 16), parseInt(str.substring(4,6), 16)]);
}
if (str.match(/#?[0-9a-fA-F]{3}/)) {
if (str.length == 4)
str = str.substring(1);
res = [str.substring(0,1), str.substring(1,2), str.substring(2,3)];
res = fixBound([parseInt(res[0] + res[0], 16), parseInt(res[1] + res[1], 16), parseInt(res[2] + res[2], 16)]);
return res;
}
return [0,0,0];
},
colorizeText : function(selector, grpSize, sColor, eColor, type, complexgrad, cb) {
if ($.browser.msie)
return; // or we could turn the browser into mush.
var boxpos = function(jobj) {
$(jobj).prepend('<span class="test">p</span>');
var obj = $('span.test', jobj).get(0);
var tpos = jom.absPos(jobj);
var res = [
tpos[0] + 0.5 * obj.offsetWidth,
tpos[1] + 0.5 * obj.offsetHeight,
jobj.offsetWidth - 0.5 * obj.offsetWidth,
jobj.offsetHeight - 0.5 * obj.offsetHeight
];
$('span.test', jobj).remove();
return res;
};
var spandim = function(span) {
var res = jom.absPos(span);
var tpos = [res[0] - 0.5 * span.offsetWidth, res[1] + 0.5 * span.offsetHeight];
return [tpos[0], tpos[1], 0.5 * span.offsetWidth, 0.5 * span.offsetHeight];
};
var pickingrad = function(point) {
if (grad.length == 0) return [0,0,0];
if (grad.length == 1) return grad[0]['col'];
point = 100 * point;
if (point <= grad[0]['pc']) return grad[0]['col'];
if (point >= grad[grad.length-1]['pc']) return grad[grad.length-1]['col'];
var i = 0, mins = 0, maxs = 100, minc = [0,0,0], maxc = [0,0,0];
while(point >= grad[i]['pc'] && i < grad.length) {
mins = grad[i]['pc'];
minc = grad[i]['col'];
i++;
}
i = grad.length-1;
while(point <= grad[i]['pc'] && i >= 0) {
maxs = grad[i]['pc'];
maxc = grad[i]['col'];
i--;
}
var res = [0,0,0];
var mult = (point - mins) / (maxs - mins);
for (i = 0;i < 3; i++)
res[i] = minc[i] + (maxc[i] - minc[i]) * mult;
return res;
};
var treatgrad = function(colgrad) {
for (i = 0; i < colgrad.length; i++)
colgrad[i]['col'] = jom.str2color(colgrad[i]['col']);
return colgrad;
};
var getcolor = function(span, bp)
{
var sp = spandim(span),
res = [0,0,0],
delta = null;
if (type == '|') {
delta = (sp[1] - bp[1]) / bp[3];
} else if (type == 'o') {
var Cx = bp[0] + bp[2] / 2;
var Cy = bp[1] + bp[3] / 2;
var r = Math.sqrt((Cx - sp[0]) * (Cx - sp[0]) + (Cy - sp[1]) * (Cy - sp[1]));
var R = Math.sqrt((bp[2]) * (bp[2]) / 4 + (bp[3]) * (bp[3]) / 4);
delta = r / R;
} else if (type == '_' || 2.5 * sp[3] > bp[3]) {
delta = (sp[0]-bp[0])/bp[2];
} else if (type == '/') {
delta = (((sp[0] - bp[0]) / bp[2]) + ((bp[3] - sp[1] + bp[1]) / bp[3])) / 2;
} else {
delta = (((sp[0] - bp[0]) / bp[2]) + ((sp[1] - bp[1]) / bp[3])) / 2;
}
res = pickingrad(delta);
return "rgb(" + Math.round(res[0]) + "," + Math.round(res[1]) + "," + Math.round(res[2]) + ")";
};
var type = type || '';
if (typeof complexgrad == 'object' && complexgrad.constructor == Array)
var grad = treatgrad(complexgrad);
else
var grad = [
{ pc: 0, col: jom.str2color( sColor ) },
{ pc: 100, col: jom.str2color( eColor ) }
];
$( selector ).each(function(){
if (!jom.spanizeText(this, 'grad', grpSize || 1))
return;
var blockpos = boxpos(this);
$('span.grad', this).each(function(){
var c = getcolor(this, blockpos);
$(this).css('color', c);
});
});
if (cb && cb.constructor == Function)
cb.call();
},
bindMainMenu: function() {
$('#link_bio').bind('click', function() { $('#nav').stop(true); jom.initWidget('bio'); jom.navClose(function() { jom.cntOpen('bio'); }); return false; });
$('#link_resume').bind('click', function() { $('#nav').stop(true); jom.initWidget('resume'); jom.navClose(function() { jom.cntOpen('resume'); }); return false; });
$('#link_work').bind('click', function() { $('#nav').stop(true); jom.initWidget('work'); jom.navClose(function() { jom.cntOpen('work'); }); return false; });
$('#link_site').bind('click', function() { $('#nav').stop(true); jom.initWidget('site'); jom.navClose(function() { jom.cntOpen('site'); }); return false; });
$('#link_play').bind('click', function() { $('#nav').stop(true); jom.initWidget('play'); jom.navClose(function() { jom.cntOpen('play'); }); return false; });
$('#link_linkedin').bind('click', function() { $('#nav').stop(true); jom.initWidget('linkedin');jom.navClose(function() { jom.cntOpen('linkedin'); }); return false; });
$('#link_facebook').bind('click', function() { $('#nav').stop(true); jom.initWidget('facebook');jom.navClose(function() { jom.cntOpen('facebook'); }); return false; });
$('#link_blogger').bind('click', function() { $('#nav').stop(true); jom.initWidget('blogger'); jom.navClose(function() { jom.cntOpen('blogger'); }); return false; });
$('#link_twitter').bind('click', function() { $('#nav').stop(true); jom.initWidget('twitter'); jom.navClose(function() { jom.cntOpen('twitter'); }); return false; });
$('#link_flickr').bind('click', function() { $('#nav').stop(true); jom.initWidget('flickr'); jom.navClose(function() { jom.cntOpen('flickr'); }); return false; });
$('#link_lics').bind('click', function() { $('#nav').stop(true); jom.initWidget('lics'); jom.navClose(function() { jom.cntOpen('lics'); }); return false; });
$('#link_print').bind('click', function() { window.print(); return false; });
},
navOpen : function(cb) {
jom.watchLocHash('');
$('#nav').animate({borderRightColor: '#4c3d3a'}, 256).animate({width: '248px', opacity: 1}, 1812, 'bounce', function() {
$('#nav').animate({opacity: 0.7}, 128, null, function() {
$('#nav').animate({opacity: 1.0, borderRightColor: '#000000'}, 128, null, cb);
});
});
},
navClose : function(cb) {
$('#nav').css('borderRightColor', '#000000').animate({opacity: 0.7, borderBottomColor: '#4c3d3a'}, 128, null, function() {
$('#nav').animate({opacity: 1.0}, 128, null, function() {
$('#nav').animate({height: '0px'}, 1612, 'bounce', function() {
$('#nav').animate({borderBottomColor: '#000000'}, 256, null, cb).css('width', '0px').css('height', 'auto');
});
});
});
},
cntClear : function() {
$('#cntTitle').html('');
$('#cntBody').html('');
$('#cntBody2').html('');
},
cntOpen : function(id) {
if (!$.browser.msie)
jom.scrollToTop.scrollup();
jom.cntClear();
jom.watchLocHash(id);
jom.trackEvent('content', 'show', id);
$('#cntClose').bind('click', function() { jom.cntClose(id); return false; })
$(document).bind('keypress', {id: id}, jom.cntEsc);
var cEl = $('#cnt');
$('#cntTitle').append( $('#'+id+' > .title').clone() );
$('#cntBody').append( $('#'+id+' > .body > *').clone() );
$('#cntBody2').append( $('#'+id+' > .body2 > *').clone() );
var c = [
{ pc: 2, col: '#655653'},
{ pc: 32, col: '#dddddd'},
{ pc: 50, col: '#eeeeee'},
{ pc: 62, col: '#dddddd'},
{ pc: 97, col: '#4c3d3a'}
];
var c2 = [
{ pc: 2, col: '#eeeeee'},
{ pc: 32, col: '#dddddd'},
{ pc: 62, col: '#4c3d3a'},
{ pc: 97, col: '#655653'}
];
$('a.ctl', cEl).css('opacity', 1.0).css('display', 'inline');
cEl.css('width', '706px')
.css('display', 'block')
.css('visibility', 'hidden');
jom.colorizeText('#cntBody > .do_gd', 1, null, null, '\\', c);
jom.colorizeText('#cntBody2 > .do_gd', 1, null, null, '\\', c);
jom.colorizeText('#cntBody .do_gd2', 1, null, null, '-', c2);
jom.colorizeText('#cntBody2 .do_gd2', 1, null, null, '-', c2);
var fnfn = function() {
if (!this.href) return false;
var h = document.location.hash;
jom.watchLocHash(false); setTimeout(function() { jom.watchLocHash(h.length > 1 ? h : true); }, 23);
return true;
}
$('.fnglyph', cEl).bind('click', fnfn);
$('.fnbk', cEl).bind('click', fnfn);
cEl.css('display', 'none')
.css('visibility', '')
.css('borderBottom', '1px solid #4c3d3a');
cEl.animate({height: 'show'}, 1216, 'bounce', function() {
$('#cnt').animate({opacity: 0.7}, 128, null, function() {
jom.getWidget(id);
$('#cnt').css('borderBottom', 'none').animate({opacity: 1.0}, 128);
$('#cntFoot').animate({width: 'show'}, 512);
});
});
},
cntClose : function(id, cb) {
$(document).unbind('keypress');
jom.trackEvent('content', 'hide', id);
jom.closeWidget(id);
$('#cnt a.ctl').animate({'opacity': 'hide'}, 100, null, function() {
$('#cnt a.ctl').css('display', 'none');
});
$('#cntFoot').animate({height: 'hide'}, 256, null, function() {
$('#cnt').css('borderBottom', 'none')
.css('borderRight', '1px solid #4c3d3a')
.animate({width: 'hide'}, 727, 'bounce', function() { $('#cnt').css('borderRight', 'none'); (cb ? cb() : jom.navOpen()); });
});
},
cntEsc : function(event) {
if (event.keyCode == 27) jom.cntClose(event.data.id);
},
closeWidget : function(id) {
switch (id) {
case 'bio':
case 'resume':
case 'work':
case 'site':
case 'linkedin':
case 'facebook':
case 'blogger':
case 'twitter':
case 'lics':
break;
case 'play':
var r = jom.getRach();
switch (r.player.getState()) {
case 2:
case 3:
case 4:
r.jqObj.animate({top: 0}, 633, function(){ jom.getRach().jqObj.css('position', 'absolute'); });
break;
default:
r.jqObj.hide();
}
break;
case 'flickr':
$('body > .preview').each(function(){ $(this).click(); }).unbind('click');
break;
}
},
initWidget : function(id) {
var cWgt = $('#cntWidget');
cWgt.empty();
switch (id) {
case 'bio':
case 'resume':
case 'work':
case 'site':
case 'linkedin':
case 'facebook':
case 'blogger':
case 'lics':
break;
case 'play':
var r = jom.getRach();
$('<div id="rachmanpos">').appendTo(cWgt).width(r.jqObj.width()).height(r.jqObj.height());
break;
case 'twitter':
var tabs = [
{title: '<?php echo DEFAULT_TWITTER_SEARCH ?>', content: ''}/*,
{title: 'My Tweets', content: ''},
{title: '@iamjochem', content: ''},
{title: 'Search', content: ''}*/
];
cWgt.html(jom.genTabs( tabs ));
break;
case 'flickr':
var url = 'http://flickr.com/services/rest/?method=flickr.photos.search&per_page=25&tags=kitten,cat&content_type=1&media=photos&min_taken_date=<?php echo urlencode(strftime('%Y-%m-%d %H:%M:%S', $_SERVER['REQUEST_TIME'] - (7 * 86400))); ?>&api_key=<?php echo getCnf('flickr_api_key'); ?>&format=json&jsoncallback=?';
$.getJSON(url, function(data) {
jom.flickrImages = [];
if (data.stat == 'ok') $.each(data.photos.photo, function(i, item) {
var img = new Image();
img.imgid = item.id;
img.src = 'http://farm' + item.farm + '.static.flickr.com/' + item.server + '/' + item.id + '_' + item.secret + '_s.jpg';
img.largeSrc = 'http://farm' + item.farm + '.static.flickr.com/' + item.server + '/' + item.id + '_' + item.secret + '_m.jpg';
img.title = item.title;
jom.flickrImages.push( img );
});
if (jom.flickrImages.length)
$.each(jom.flickrImages, function(i, item) {
item.largeImg = new Image();
item.largeImg.src = item.largeSrc;
if ((i > 0) && (i % 5) == 0)
$('<br style="clear:both;" />').appendTo('#cntWidget');
$('<a class="ftl" href="'+ item.largeSrc + '"><img alt="' + item.title + '" src="' + item.src + '" class="ft" /></a>').bind('click', function() { return false; }).attr('imgid', item.imgid).appendTo('#cntWidget');
});
});
break;
}
},
getWidget : function(id) {
switch (id) {
case 'bio':
case 'resume':
case 'work':
case 'site':
case 'linkedin':
case 'facebook':
case 'blogger':
case 'lics':
break;
case 'play':
var r = jom.getRach();
p = jom.absPos( $('#rachmanpos')[0] );
if (r.isnew)
r.jqObj.css("top", p[1] + "px").css("left", p[0] + "px").animate({opacity: 'show'}, 2010);
else if ($(':hidden', r.jqObj).length)
r.jqObj.show();
else
r.jqObj.animate({top: p[1] + 'px'});
break;
case 'twitter':
$.Juitter.start({
searchType : 'searchWord',
searchObject : "<?php echo DEFAULT_TWITTER_SEARCH ?>",
placeHolder : 'wt_1',
lang : ''
});
break;
case 'flickr':
if (typeof jom.flickrImages == 'undefined')
return window.setTimeout(function() { jom.getWidget(id); }, 100);
if (jom.flickrImages.length) {
var clsAnim = function() {
var s = $(this);
s.animate({width: 'hide', height: 'hide', opacity: 'hide', top: '+='+(s.height() / 2), left: '+='+(s.width() / 2)}, 789, 'easeout', function() { $(this).remove(); });
};
$('#cntWidget a.ftl').bind('mouseover click', function(e) {
var im = $('img', this),
ip = im.position(),
id = $(this).attr('imgid');
if ($("#preview" + id).length)
return;
$('.preview').each(function(){ if (this.id != ('preview' + id)) clsAnim.apply(this); });
$("body").append("<p class='preview' id='preview" + id +"'><img src='"+ this.href +"'/></p>");
var pd = $('#preview' + id);
var h = pd.height(),
w = pd.width();
if (!w || !h)
return;
var x = ip.left + im.width(),
y = ip.top + im.height();
pd.bind('mouseout click', function(e) { clsAnim.apply(this); });
pd.css("top", y + "px").css("left", x + "px");
pd.animate({width: 'show', height: 'show', opacity: 'show', top: '-='+(h / 2), left: '-='+(w / 2)}, 678, 'easeout');
});
$('#cntWidget .ft').each(function() { $(this).show( 1000 ); });
}
break;
}
},
exposeOz : function() {
var yeehaw = $('#yeehaw').attr('title', 'Sydney, Australia ... Yeehaw!'),
pano = $('#panorama'),
pHeight = pano.height(),
factor = 1.61803399;
numbers = ['One','Two','Three','Four','Five','Six','Seven','Eight'],
recursiveYeehaw = function(el, title, i) {
var vol = 50, j = i;
while (j = (j - 1))
vol /= factor;
$('body').append('<span id="yeehaw_run_wav"><object><embed volume="' + vol + '" src="/assets/audio/yeehaw.wav" hidden="true" autostart="true" loop="false" /></object></span>');
var yeehaw = $(el).unbind('click'),
trooper = yeehaw.clone().attr('id', yeehaw.attr('id') + i).insertAfter( yeehaw );
yeehaw.css('cursor', 'help');
trooper.css('right', parseInt(yeehaw.css('right')) + parseInt(trooper.width()))
.css('bottom', '0')
.width(parseInt(trooper.width() / factor))
.height(parseInt(trooper.height() / factor));
trooper.attr('title', (title ? title : 'Yeehaw!'));
trooper.animate({bottom: '+=' + parseInt(pHeight)}, 512, 'bounce');
trooper.bind('click', function() { recursiveYeehaw( trooper, null, i+1 ); })
if (typeof numbers[i] != undefined)
jom.trackEvent('yeehaw', numbers[i]);
};
pano.animate({opacity: 'show'}, 1266, null, function() {
pano.bind('mouseout', function() { $(this).removeClass('flipvert'); });
pano.bind('mouseover', function() { $(this).addClass('flipvert'); })
yeehaw.animate({bottom: '+=' + pHeight}, 512, 'bounce', function() {
recursiveYeehaw(yeehaw, 'Australia ... Double Yeehaw!', 1);
});
});
},
initPage : function() {
(function($) {
// custom animation easing
$.extend( $.easing,
{
bounce : function (x, t, b, c, d) {
A = 7.5625;
B = 2.75;
if ((t /= d) < (1 / B)) return c * (A * t * t) + b;
if (t < (2 / B)) return c * (A * (t -= (1.5 / B)) * t + .75) + b;
if (t < (2.5 / B)) return c * (A * (t -= (2.25 / B)) * t + .9375) + b;
return c * (A * (t -= (2.625 / B)) * t + .984375) + b;
},
easeout : function(p, n, fn, delta, dur) {
return -delta * ((n = n / dur - 1) * n * n * n - 1) + fn;
}
});
// 'junky' globals used by Juitter
var mode, param, timer, lang, contDiv, loadMSG, gifName,
numMSG, readMore, fromID, ultID, filterWords,
aURL = "", msgNb = 1, running = false;
$.Juitter = {};
$.extend( $.Juitter,
{
apifMultipleUSER : "http://search.twitter.com/search.json?from%3A",
apifUSER : "http://search.twitter.com/search.json?q=from%3A",
apitMultipleUSER : "http://search.twitter.com/search.json?to%3A",
apitUSER : "http://search.twitter.com/search.json?q=to%3A",
apiSEARCH : "http://search.twitter.com/search.json?q=",
registerVar : function(opt) {
mode = opt.searchType;
param = opt.searchObject;
timer = opt.live;
filterWords = opt.filter;
lang = opt.lang ? opt.lang : "";
loadMSG = opt.loadMSG ? opt.loadMSG : "Loading messages..."; // set to "image/gif" to showing loading image
gifName = opt.imgName ? opt.imgName : "/assets/img/loader.gif";
numMSG = opt.total ? opt.total : 20;
readMore = opt.readMore ? opt.readMore : "Read it on Twitter";
fromID = opt.nameUser ? opt.nameUser : "image";
contDiv = opt.placeHolder ? opt.placeHolder : containerDiv;
openLink = opt.openExternalLinks ? "target='_blank'" : "";
},
start : function(opt) {
ultID = 0;
if ($("#"+contDiv)) {
this.registerVar(opt);
this.loading();
// create the URL to be request at the Twitter API
aURL = this.createURL();
// query the twitter API and create the tweets list
this.conectaTwitter(1);
// if live mode is enabled, schedule the next twitter API query
if(timer != undefined && !running)
this.temporizador();
}
},
update : function() { this.conectaTwitter(2); if (timer != undefined) this.temporizador(); },
loading : function() { $("#"+contDiv).html((loadMSG == "image/gif") ? $("<img></img>").attr('src', gifName) : loadMSG) },
createURL : function() {
var url = "", seachMult = param.search(/,/);
if (seachMult > 0) param = "&ors="+param.replace(/,/g,"+");
if (mode=="fromUser" && seachMult<=0) url = this.apifUSER + param;
else if (mode=="fromUser" && seachMult>=0) url = this.apifMultipleUSER + param;
else if (mode=="toUser" && seachMult<=0) url = this.apitUSER + param;
else if (mode=="toUser" && seachMult>=0) url = this.apitMultipleUSER + param;
else if (mode=="searchWord") url = this.apiSEARCH + param + (lang.length > 0 ? "&lang="+lang : "");
return url + "&rpp=" + numMSG;
},
delRegister : function() { if (msgNb >= numMSG) $(".tweet").each(function(o,e) { if (o >= numMSG) $(this).hide("slow"); }); }, // remove the oldest entry on the tweets list
filter : function(s) {
if (filterWords) {
var searchWords = filterWords.split(","), cleanHTML = s;
if (searchWords.length > 0) {
cleanHTML = s;
$.each(searchWords, function(i,item) {
sW = item.split("->").length>0 ? item.split("->")[0] : item;
rW = item.split("->").length>0 ? item.split("->")[1] : "";
regExp = eval('/'+sW+'/gi');
cleanHTML = cleanHTML.replace(regExp, rW);
});
}
return cleanHTML;
}
return s;
},
textFormat : function(texto) { // make links in text and bolden search words
texto = texto.replace(/(\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])/ig,
"<a href='$1' class='extLink' "+openLink+">$1</a>");
texto = texto.replace(/[\@]+([A-Za-z0-9-_]+)/ig,
"<a href='http://twitter.com/$1' class='profileLink'>@$1</a>");
texto = texto.replace(/[\#]+([A-Za-z0-9-_]+)/ig,
"<a href='http://juitter.com/#$1' onclick='$.Juitter.start({searchType:\"searchWord\",searchObject:\"$1\"});return false;' class='hashLink'>#$1</a>");
if (mode == "searchWord") {
var tempParam = param.replace(/&ors=/,"");
var arrParam = tempParam.split("+");
$.each(arrParam, function(i,item) {
var regExp = eval('/\w'+item+'\w/gi');
texto = texto.replace(regExp, ' <b>'+item+'</b> ');
});
}
return texto;
},
temporizador : function() {
var aTim = timer.split("-");
running = true;
if(aTim[0] == "live" && aTim[1].length > 0)
setTimeout($.Juitter.update, aTim[1] * 1000);
},
conectaTwitter : function(e) {
// query the twitter api and create the tweets list
$.ajax({
url: aURL, type: 'GET', dataType: 'jsonp', timeout: 1000,
error : function() { $("#"+contDiv).html("Fail"); },
success : function(json) {
if(e == 1) $("#"+contDiv).html("");
tultID = 0;
$.each(json.results, function(i,item) {
if(e == 1 || (i < numMSG && item.id > ultID)) {
if (i == 0) {
tultID = item.id;
$("<ul></ul>").attr('id', 'tul_' + ultID).attr('class','tweetlist').prependTo("#"+contDiv);
}
if (item.text != "undefined") {
var liID = 'tli_' + msgNb;
var link = "http://twitter.com/"+item.from_user+"/status/"+item.id;
var tweet = $.Juitter.filter(item.text);
var mHTML = (fromID == "image")
? "<a href='" + link + "'><img src='" + item.profile_image_url + "' alt='" + item.from_user + "' class='avatar' /></a> " + $.Juitter.textFormat(tweet) + "<br /> - <span class='time'>" + item.created_at + "</span>"
: "<a href='http://www.twitter.com/" + item.from_user + "'>@" + item.from_user + ":</a> " + $.Juitter.textFormat(tweet) + " -| <span class='time'>" + item.created_at + "</span> |- <a href='" + link + "' " + openLink + ">" + readMore + "</a>"
;
$("<li></li>").html(mHTML).attr('id', liID).attr('class', 'tweet clearfix').appendTo("#tul_" + ultID);
$('#' + liID).hide().show();
$.Juitter.delRegister();
msgNb++;
}
}
});
if (tultID) ultID = tultID;
}
});
}
});
})(jQuery);
jom.fixScreen();
// browser functionality support info
// $.each($.support, function(i,v) { $('body').prepend(v + '<br />'); });
if (!$.browser.msie || $.browser.version.substr(0,1) > 7)
jom.scrollToTop.init();
jom.gradiateQuotes();
jom.extUrls();
<?php if ($page) echo "var p = '{$page}';"; else echo "var p = null;"; ?>
try {
if (document.location.hash) {
var h = $(document.location.hash);
if (h && h.length && h.length === 1 && document.location.hash.length > 1)
p = document.location.hash.substring(1);
}
} catch(e) {}
jom.trackEvent('index', 'show', p);
if (p) {
jom.loadFlashObjects();
jom.initWidget( p );
jom.cntOpen( p );
jom.bindMainMenu();
(jom.initFluff())();
} else {
jom.bindMainMenu();
jom.navOpen(function() { (jom.initFluff())(); });
jom.loadFlashObjects();
}
jom.watchLocHash( true );
/*
jom.trackEvent('footnote','go', '?')
jom.trackEvent('footnote','back', '?') //*/
}
};
google.load('jquery', '1.3.2');
google.load('jqueryui', '1.7.2');
google.setOnLoadCallback(jom.initPage);
/* ]]> */
</script>
<script type="text/javascript" src="http://www.archive.org/flow/flowplayer-3.0.3.min.js"></script>
<script type="text/javascript" src="http://www.linkedin.com/js/public-profile/widget-os.js"></script>
<object><noscript><div id="reddoor"><div class="ms">You are facing east, in front of you is a red door.<br />A sign on the door reads:<blockquote class="s" title="javascript is required to view my site/toy.">“Please give the monkey some javascript to enter.”</blockquote></div></div></noscript></object>
<?php echo getGaJavaScript(); ?>
</body>
</html><?php
/**
* retrieve a config value
*
* @param string $k - name of key in the global $cnf array
* @return mixed
*/
function getCnf($k)
{
global $cnf, $env;
if (isset($cnf[$k]))
return $cnf[$k][$env];
return null;
}
/**
* [email address (primarily)] obsfucator using javascript
*
* @param string $s
* @param bool $asMailLink
* @param bool $incNoScript
* @param array $params - assoc array of GET string params for use inconjunction with mail links
*
* @return string
*/
function jsObsfucate($s, $asLink = false, $incNoScript = false, $params = array())
{
if (! ($s = trim($s)))
return '';
// for NOSCRIPT tag
if ($incNoScript && strpos($s, '@') > 0) {
list($user, $dom) = explode('@', $s);
$bits = explode('.', $dom);
foreach ($bits as &$bit)
$bit = strObsfucate($bit);
$noScript = '<object><noscript><div style="display:inline;">'.strObsfucate($user).'<img src="/assets/img/at.gif" alt="[AT]" class="elk" />'.join('<img src="/assets/img/dot.gif" alt="[DOT]" class="elk" />', $bits).'</div></noscript></object>';
} else {
$noScript = '';
}
// for SCRIPT tag
$s = strObsfucate($s);
$chars = array();
$params= is_array($params) && count($params) > 0 ? '?'.str_replace('+', ' ', http_build_query($params, '', '&')) : '';
foreach (str_split($asLink ? '<a class="inturl" href="mailto:'.$s.''.$params.'">'.$s.'</a>': $s) as $char)
$chars[] = ord($char);
return '<span><script type="text/javascript">/* <![CDATA[ */ document.write(String.fromCharCode('.join(',', $chars).')) /* ]]> */</script></span>'.$noScript;
}
/**
* obsfucate a string by using oddball/random numeric html entity encoding
* of individual chars of given string.
*
* @param string $s
* @return
*/
function strObsfucate($s)
{
for ($i = 0, $l = strlen($s), $r = ''; $i < $l; ++$i)
$r .= (mt_rand(0,1) ? '&#x'.sprintf("%X", ord($s{$i})):'&#'.ord($s{$i})).';';
return $r;
}
/**
* tries to determine what time of day it is at the
* place where the request originated.
*
* possible return values are: morning, afternoon, evening, night
*
* @return string
*/
function userIsSurfingDuringThe()
{
global $env; static $res;
if (isset($res))
return $res;
$bip = array("", "127.0.", "10.0.", "172.16.","192.168.");
$ips = array();
foreach (array('HTTP_X_FORWARDED_FOR', 'HTTP_FORWARDED_FOR', 'REMOTE_ADDR') as $key)
if (isset($_SERVER[$key]) && $_SERVER[$key])
$ips = array_merge($ips, explode(',', $_SERVER[$key]));
foreach (array_unique($ips) as $ip)
if ($ip && !in_array(substr($ip, 0, strpos($ip, '.', strpos($ip, '.') + 1) + 1), $bip)) {
$uip = $ip; break;
}
if (!isset($uip)) {
if ($env != 'dev')
return false;
$uip = getCnf('dev_gateway_ip');
}
$rg = geoip_country_code_by_name( $uip );
$tz = geoip_time_zone_by_country_and_region($rg);
$d = new DateTime('now', new DateTimeZone($tz));
$h = $d->format('H');
if ($h > 21 || $h < 6)
return ($res = 'night');
if ($h < 12)
return ($res = 'morning');
if ($h < 18)
return ($res = 'afternoon');
return ($res = 'evening');
}
/**
* niave flash-movie-display related HTML
* generator.
*
* @param string $swf - URL to flash movie
* @param int $w - width
* @param int $h - height
* @param array $params - optional array of key/values - used to generate PARAM tags
* @param int $minV - optional minimum version, default is 6
* @param string $description - optional screen reader description of the flash movie contents
* @param bool $embed - whether to include the EMBED tag, default is FALSE
*
* @return string
*/
function genFlashObjectHTML($swf, $w, $h, $params = null, $minV = null, $description = '', $embed = false)
{
if ($d = trim($description))
$d = tirm(htmlentities($d, ENT_QUOTES));
$v = ($v = (int)$minV) > 6 ? $v : 6;
$w = (int)$w;
$h = (int)$h;
$e = $embed ? '<embed href="'.$swf.'" width="'.$w.'" height="'.$h.'" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer"></embed>' : '';
$p =
$fv = '';
if (is_array($params) && count($params))
foreach ($params as $k => $v)
$p .= '<param name="'.$k.'" value="'.$v.'" />';
if (isset($params['flashvars']))
$fv = '?flashvars='.$params['flashvars'];
$o = <<< EOD
<object
classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=$v,0,0,0"
width="$w" height="$h">
<param name="movie" value="{$swf}{$fv}" />{$p}
<!--[if !IE]> <-->
<object type="application/x-shockwave-flash" data="$swf" width="$w" height="$h">
$p
$d
$e
</object>
<!--> <![endif]-->
<!--[if IE]>$d<![endif]-->
</object>
EOD;
return trim(str_replace(array("\n", ' '), array(' ', ' '), $o));
}
/**
* build 'tag could' data for the funky 3d cloud renderer,
* if the value of a tag's 'url' item is TRUE, the value of the 'name' item will be
* taken for url and assumed to be a domain name
*
* @param array $item - each item of the array must be an array with the key 'name', 'size' and 'url' keys are optional.
*
* @return string - a compatible 'xml' string (for in a PARAM tag value attribute!)
*/
function renderTagCloudXML(array $items)
{
$tagCloud = '';
foreach ($items as $item) {
$url = isset($item['url']) ? ($item['url'] === true ? 'http://'.$item['name'] : $item['url']) : 'http://lmgtfy.com/?q='.urlencode(strpos($item['name'], ' ') !== false ? '"'.$item['name'].'"' : $item['name']);
$size = isset($item['size']) && ($i = (int)$item['size']) > 0 ? $i : '12';
$tagCloud .= "<a dir='ltr' href='{$url}' style='{$size}'>{$item['name']}</a>";
}
return $tagCloud;
}
/**
* retrieve google analytics code.
*
* @return string
*/
function getGaJavascript()
{
$gaKey = getCnf('ga_key');
if (!$gaKey)
return '';
return <<< EOD
<script type="text/javascript">/* <![CDATA[ */document.write(unescape("%3Cscript src='" + (("https:" == document.location.protocol)?"https://ssl.":"http://www.") + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));/* ]]> */</script>
<script type="text/javascript">/* <![CDATA[ */try { var gat = _gat._getTracker("$gaKey"); gat._initData(); gat._trackPageview(); } catch(e) {}/* ]]> */</script>
EOD;
}
/**
* outputs the [complete] source of the site and exits
* (if that is what was requested).
*
* a GET query paramater named 'source' set with a value of '1' is
* used to trigger source output
*
* @return void
*/
function showSiteSourceIfRequested()
{
$YES = isset($_GET['source']) ? (int)$_GET['source'] : null; // filter_input(INPUT_GET, 'source', FILTER_VALIDATE_INT); // version differences
if ($YES === 1) {
$imgCnt = count(array_filter((array)scandir(dirname(__FILE__).'/assets/img'), create_function('$v', 'return strpos($v, ".") > 0;')));
$linCnt = count((array)@file(__FILE__));
echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>I am jochem, nice to meet you - behind the scene.</title>
<style type="text/css">
<!--
body { margin: 0px; padding: 0px; }
.head, .foot { padding: 5px; background-color: #000; color: #ccc; }
.head a { color: #ddd; text-decoration: none; }
.head a:hover { color: #eee; text-decoration: underline; }
.wrap { position: relative; overflow: hidden; }
.body { z-index: 2; margin: 12px 12px 12px 64px; white-space: nowrap; }
.linenum { z-index: 1; margin: 12px; position: absolute; color: #bbb; }
.back { font-size: 1.325em; float: right; }
-->
</style>
</head>
<body>
<div class="head">
<span class="back"><a href="/">back to the site.</a> ></span>
<span>The output below represents the complete source code & content of my site<a href="#foot"><sup>❡</sup></a></span>
</div>
<div class="wrap">
<div class="linenum"><code>', str_replace(' ', ' ', join('<br/>', array_map('str_pad', range(1, $linCnt), array_fill(0, $linCnt, strlen((string)$linCnt)), array_fill(0, $linCnt, ' '), array_fill(0, $linCnt, STR_PAD_LEFT)))), '</code></div>
<div class="body">';
highlight_string(file_get_contents(__FILE__));
echo '
</div>
</div>
<div class="foot">
<a name="foot"><sup>❡</sup></a>
Other than this index.php file, the site also consists of a .htaccess file, a .wav file,
one \'include\' file containing a few configuration values and ', $imgCnt, ' images.<br />
In addition numerous JavaScript resources are loaded from the Google Content Delivery Network
by the page once it loads in the browser.
</div>', getGaJavaScript(), '
<body>
</html>';
exit;
}
}