This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// create the tomboy icon | |
var f = new Gtk.IconFactory(); | |
f.add('tomboy', new Gtk.IconSet.from_pixbuf( | |
new GdkPixbuf.Pixbuf.from_file('/usr/share/icons/hicolor/scalable/apps/tomboy.svg') | |
)); | |
f.add_default(); | |
// Create the action and group to add to menubar | |
var action = new Gtk.Action({ | |
name: 'TomboyNote', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Prototype | |
{ | |
protected static $prototype_methods = array(); | |
protected static $prototype_properties = array(); | |
protected $prototype_obj_properties = array(); | |
public static function add_method() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# setup tmp files from tar.gz's | |
cd /home/matt/habari-locales/bzr/ | |
bzr merge | |
bzr add locale/* | |
bzr commit -m "lp sync" | |
cd ../ | |
# check fo .po |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function onDoWeather($where, $day = null) | |
{ | |
$target = $this->event->getNick(); | |
$opts = array( | |
'http' => array( | |
'timeout' => 3.5, | |
'method' => 'GET', | |
'user_agent' => 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.12) Gecko/20080201 Firefox/2.0.0.12' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function add_template_vars() | |
{ | |
if ( isset($this->posts) && count($this->posts) ) { | |
$post = $this->post instanceof Post ? $this->post : $this->posts[0]; | |
if ( $this->post instanceof Post && count($this->posts) == 1 ) { | |
$this->set_title( $post->title ); | |
if ( $post->typename == 'entry' ) { | |
$this->assign( 'next', $post->ascend() ); | |
$this->assign( 'previous', $post->descend() ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
object(Terms)#18 (1) { | |
["storage":"ArrayObject":private]=> | |
object(Terms)#171 (1) { | |
["storage":"ArrayObject":private]=> | |
array(1) { | |
[0]=> | |
object(Term)#11 (5) { | |
["inforecords":protected]=> | |
NULL | |
["fields":protected]=> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
array(1) { | |
[0]=> | |
object(Term)#11 (5) { | |
["inforecords":protected]=> | |
NULL | |
["fields":protected]=> | |
array(6) { | |
["id"]=> | |
string(3) "218" | |
["term"]=> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I'm Matt Read, a 32 year old male from Ottawa, Canada. That's the capital of Canada for all you who don't know that already. I enjoy skateboarding, playing hockey and soccer, and working on my website. | |
<img src="/user/themes/greeny/images/BigJibby.jpg" alt="A picture of me" style="float:right;" /> My favourite TV show of all time is MacGyver, and Good Will Hunting is my favorite movie. I program in PHP, MySQL, Javascript, and Bash Scripting, and I love playing with Python. I'm a bit pedantic about producing **semantic** (X)HTML (and no, valid does not mean semantic). | |
### About This Site | |
This site is my personal website since June 2003. This site is powered by Habari. It contains my (almost) daily web log about my life and stuff I find on the Internet. For more information and help in browsing this site, visit the links below. | |
- [Frequently Asked Questions](/faq) | |
- [Accessibility Statement](/accessibility) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function filter_post_content_out_1($content, $post) { | |
if (strpos($content, '<!--break-->') !== false){ | |
$pages = explode('<!--break-->', $content); | |
$page = Controller::get_var('page', 1) - 1; | |
if ( array_key_exists($page, $pages) ) { | |
return $pages[$page]; | |
} | |
} | |
return $content; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class Providers extends Plugin { | |
/** | |
* | |
*/ | |
public function filter_admin_access( $access, $page, $post_type ) { | |
if ( $page != 'providers' ) { | |
return $access; |
OlderNewer