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 | |
function misopciones($name) { | |
return $name . 'mi cadena de opciones'; | |
} |
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
$posts_ids = get_posts('post_type=post&posts_per_page=-1&fields=ids'); | |
// $posts_ids is now an array of IDs | |
foreach( $posts_ids as $post_id ) { | |
save_index( $post_id ); | |
} |
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 | |
/** | |
* Product url key attribute backend | |
* | |
* @category Mage | |
* @package Mage_Catalog | |
* @author Magento Core Team <core@magentocommerce.com> | |
*/ | |
class Module_Catalog_Model_Product_Attribute_Backend_Urlkey extends Mage_Catalog_Model_Product_Attribute_Backend_Urlkey | |
{ |
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
# Wordpress Fabfile, for migrating the database, and deploying w/ git. | |
# For background: "My New & Improved Fabfile for Deploying WordPress" | |
# http://wp.me/p2a3Vy-1b | |
# | |
# This fabfile is specifically-geared for our unique setup, which consists | |
# of 2 servers (local, remote), and 3 sites (local, dev, and prod). Dev and | |
# prod sites both live on the remote server. | |
# | |
# In general, a little bit of the programming happens on a local site, | |
# but the database updates and file uploads (both in Wordpress, and edits |
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
#!/usr/bin/env ruby | |
# DESCRIPTION: Tries to do something with unrecognized shell input. | |
# See the case statement for descriptions and examples. | |
require 'rubygems' unless defined? Gem # rubygems is only needed in 1.8 | |
require 'term/ansicolor' | |
include Term::ANSIColor | |
# Use all arguments |
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
#!/usr/bin/env bash | |
##################################################################### | |
# Program: log | |
##################################################################### | |
# Version: 1.0 | |
# Date: 18.10.2011 | |
# Author: (c) by Alex Sancho - <alex@alexsancho.name> | |
# | |
# Notes: Display a message. | |
##################################################################### |
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
#!/usr/bin/env bash | |
##################################################################### | |
# after_cd_push_pwd | |
##################################################################### | |
# | |
# rvm after_cd hook that adds current path to directory stack. | |
# It limits the stack size to MAX value and removes duplicated | |
# dirs. | |
# | |
# rvm overwrites the default popd command and by unknown reasons changes |