This file contains hidden or 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 foreach(Attachments::getPosts() as $post) { ?> | |
| <ul> | |
| <?php foreach(Attachments::get($post) as $file) { ?> | |
| <li><a href="<?php echo $file->url ?>"><?php echo apply_filters('the_title', $post->post_title) ?></a></li> | |
| <?php } ?> | |
| </ul> | |
| <?php } ?> |
This file contains hidden or 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
| # install git | |
| sudo apt-get install g++ curl libssl-dev apache2-utils | |
| sudo apt-get install git-core | |
| # download the Node source, compile and install it | |
| git clone https://github.com/joyent/node.git | |
| cd node | |
| ./configure | |
| make | |
| sudo make install | |
| # install the Node package manager for later use |
This file contains hidden or 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
| /* | |
| The simplest possible database toolkit for Appcelerator Mobile. | |
| Copyright (C)2011 Fat Panda, LLC. | |
| Aaron Collegeman [email protected] | |
| This program is free software; you can redistribute it and/or | |
| modify it under the terms of the GNU General Public License | |
| as published by the Free Software Foundation; either version 2 | |
| of the License, or (at your option) any later version. |
This file contains hidden or 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 | |
| $postDate = strtotime( $post->post_date ); | |
| $oldDate = strtotime( '2011-06-29' ); | |
| if ( $postDate > $oldDate ) { | |
| echo 'do the new thing'; | |
| } else { | |
| echo 'do the old thing'; | |
| } |
This file contains hidden or 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 | |
| /* | |
| WordPress Force Upgrade Script | |
| Copyright (C) 2006 Mark Jaquith | |
| This program is free software; you can redistribute it and/or | |
| modify it under the terms of the GNU General Public License | |
| as published by the Free Software Foundation; either version 2 | |
| of the License, or (at your option) any later version. |
This file contains hidden or 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 | |
| $apis = clApi::exec(array( | |
| 'http://api.twitter.com/1/statuses/user_timeline.xml?screen_name=squidoo', | |
| 'http://api.twitter.com/1/statuses/user_timeline.xml?screen_name=github', | |
| )); | |
| $statuses = clApi::grep($apis, 'status', 'date,desc:created_at'); |
This file contains hidden or 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 | |
| /* | |
| KOIVI HTML Form to FDF Parser for PHP (C) 2004 Justin Koivisto | |
| Version 1.1 | |
| Last Modified: 2010-02-17 | |
| This library is free software; you can redistribute it and/or modify it | |
| under the terms of the GNU Lesser General Public License as published by | |
| the Free Software Foundation; either version 2.1 of the License, or (at | |
| your option) any later version. |
This file contains hidden or 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 | |
| /** | |
| * Copyright 2011 Facebook, Inc. | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); you may | |
| * not use this file except in compliance with the License. You may obtain | |
| * a copy of the License at | |
| * | |
| * http://www.apache.org/licenses/LICENSE-2.0 | |
| * |
This file contains hidden or 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 | |
| $vids_config = array( | |
| 'http://youtube.com/?v=whatever This is my first title', | |
| 'http://youtube.com/?v=whatever This is my second title', | |
| 'http://youtube.com/?v=whatever This is my third title | |
| ); | |
| foreach($vids_config as $vid) { | |
| $parts = explode(' ', $vid); | |
| $url = array_shift($parts); |
This file contains hidden or 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 | |
| require('wordpress-oauth-support.php'); | |
| class YourPluginNamespace extends YourPluginNamespace_WordPressOAuthSupport { | |
| function __construct() { | |
| add_action('init', array($this, 'init')); | |
| } | |
| function init() { |