Category: Uncategorized
“Winter” in Toronto
Some photos taken on a walk 3 weeks ago (March 11, 2012). We hit 15 C that day, and thought it was warm. Little did we know temperatures would reach the upper 20s soon afterwards, then drop back to the “normal” seasonal range.
WordPress: How to create a page that displays a specific category archive
Quick way to display a “Category archive” as a page in WordPress
- In your wp-content/themes folder, copy the “category.php” file to “template-categorypage-categoryname.php”.
- Edit the template-categorypage-categoryname.php.
- Add
<?php /** * Template Name: CategoryName Category page
to the top of the page.
- After the first
?>
tag, add
<?php query_posts('cat=[categoryid]&posts_per_page='.get_option('posts_per_page')); ?>
Where [categoryid] is your WordPress numeric category ID.
- Create a new page and choose the template “CategoryName Category page” from the page attributes sidebar widget.
Play the music and watch the .gif.
Found on two separate tumblr blogs today in my dashboard.
Image via fromme-toyou
Audio via dailycommunity via samweed
Set up Avahi on Linux to advertise samba (and ssh) servers for Mac and Linux clients
Found this info somewhere on the Web… Don’t remember where exactly.
Anyway:
<?xml version="1.0" standalone='no'?><!--*-nxml-*--> <!DOCTYPE service-group SYSTEM "avahi-service.dtd"> <service-group> <name replace-wildcards="yes">%h</name> <service> <type>_smb._tcp</type> <port>445</port> </service> <service> <type>_ssh._tcp</type> <port>22</port> </service> <service> <type>_sftp-ssh._tcp</type> <port>22</port> </service> <service> <type>_device-info._tcp</type> <port>0</port> <txt-record>model=iPhone3,1</txt-record> </service> </service-group> |
You can change iPhone3,1 to any Mac identifier to change the icon. For example MacBook1,1 is a white MacBook or MacBookPro5,2 is an aluminum MBP.
Bonus info: To correctly display and have WP-Syntax highlight XML code, use
<pre lang="xml" escaped="true"> |
http://wordpress.org/extend/plugins/wp-syntax/other_notes/