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
| # first cd into aheadworks or mageworx extension dir | |
| # (this assumes it's been unzipped into magento's root dir) | |
| for x in `find step_*`; do | |
| y=`echo $x | awk '{ sub("step_[0-9]+/", ""); print "../"$0; }'`; | |
| if [ -d "$x" ] && ! [ -e "$y" ] ; then mkdir -p $y; fi; | |
| if [ -f "$x" ]; then cp $x $y; fi; | |
| done |
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
| /* | |
| * touch handler for openlayers maps on mobile | |
| * see: http://www.openlayers.org/ | |
| */ | |
| var map = {} // dummy object -> create & init an openlayers map | |
| Touch = (function() { return { | |
| startX: 0, | |
| startY: 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
| #!/usr/bin/env python | |
| # inspired by this post: | |
| # http://www.bluebox.net/news/2009/07/mysql_encoding | |
| import MySQLdb | |
| DB_NAME="example" | |
| DB_USER="root" | |
| DB_HOST="locahost" |
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
| set expandtab | |
| set nocompatible | |
| set autoindent | |
| set smartindent | |
| set tabstop=4 | |
| set shiftwidth=4 | |
| set showmatch | |
| set guioptions-=T | |
| set vb t_vb= | |
| set ruler |
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 | |
| /* | |
| Plugin Name: redirect/routes test | |
| Plugin URI: http://blog.enru.co.uk/2011-11-04-wordpress-plugin-with-own-url.html | |
| Description: An example of how to give a WordPress plugin it's own URL/route | |
| Version: 0.1 | |
| Author: Neill Russell | |
| Author URI: http://www.enru.co.uk | |
| License: Beerware | |
| */ |
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
| #!/bin/bash | |
| c=0; for i in *.JPG; do mv "$i" "`printf %05d $c`.jpg"; c=$((c+1));done | |
| ffmpeg -r 6 -b 2000 -i %05d.jpg -vcodec libx264 -vpre hq -vpre ipod640 -an -threads 0 -b 5000k video.mp4 |
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
| <project name="PhoneGapCopy" default="init" basedir="."> | |
| <description> | |
| sets up phonegap in a new android app | |
| usage: ant -f phonegapcopy.xml -DPHONEGAP_HOME=/home/enru/phonegap-9f0856d | |
| </description> | |
| <property name="PHONEGAP_HOME" value=""/> | |
| <target name="init"> | |
| <copy todir="./libs/"> | |
| <fileset dir="${PHONEGAP_HOME}/Android/"> | |
| <include name="phonegap-*.jar"/> |
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
| INSERT INTO `eav_attribute` (`entity_type_id`, | |
| `attribute_code`, | |
| `attribute_model`, | |
| `backend_model`, | |
| `backend_type`, | |
| `backend_table`, | |
| `frontend_model`, | |
| `frontend_input`, | |
| `frontend_input_renderer`, | |
| `frontend_label`, |
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 | |
| /* | |
| * Created on Sep 28, 2009 | |
| * @author Neill Russell <n@enru.co.uk> | |
| */ | |
| if($argc < 2) die(sprintf("Usage: %s <MAGENTO_ROOT>\n", $_SERVER['SCRIPT_FILENAME'])); | |
| define('MAGENTO_DIR', realpath($argv[1])); |
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
| select * from wp_term_taxonomy tt | |
| left join wp_terms t on tt.term_id = t.term_id | |
| where tt.taxonomy = 'product_cat' and tt.parent = 0; |
OlderNewer