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
add_filter( 'woocommerce_currencies', 'add_my_currency' ); | |
function add_my_currency( $currencies ) { | |
$currencies['ABC'] = __( 'Currency name', 'woocommerce' ); | |
return $currencies; | |
} | |
add_filter('woocommerce_currency_symbol', 'add_my_currency_symbol', 10, 2); | |
function add_my_currency_symbol( $currency_symbol, $currency ) { |
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
// Options toggler hanlder | |
// To turn on/off other options base on toggler selection | |
function initOptionToggler() { | |
$(document).delegate('.yk-toggler', 'click', function(){ | |
var toggler_name = $(this).attr("name").replace("option_tree[","").replace("]",""); | |
var toggler_value = $(".yk-toggler[name*="+toggler_name+"]:checked").val(); | |
// Turn off all .yk-toggle-able fields | |
$(".yk-toggle-able[class*="+toggler_name+"]").parents(".format-settings").slideUp(); | |
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
/** | |
* Adds Foo_Widget widget. | |
*/ | |
class Foo_Widget extends WP_Widget { | |
/** | |
* Register widget with WordPress. | |
*/ | |
public function __construct() { | |
$widget_ops = array('classname' => 'foo-widget', 'description' => __('Display Foo_Widget', kopa_get_domain())); |
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
Show hidden characters
{ | |
"bold_folder_labels": true, | |
"caret_style": "phase", | |
"color_scheme": "Packages/Color Scheme - Default/Mac Classic.tmTheme", | |
"font_options": "subpixel_antialias", | |
"fade_fold_buttons": false, | |
"font_face": "Consolas", | |
"font_size": 13.5, | |
"highlight_line": true, | |
"highlight_modified_tabs": true, |
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
if(!function_exists('avia_backend_get_hex_from_rgb')) | |
{ | |
/** | |
* converts an rgb string into a hex value and returns the string | |
* @param string $r red | |
* @param string $g green | |
* @param string $B blue | |
* @return string returns the converted string | |
*/ | |
function avia_backend_get_hex_from_rgb($r=FALSE, $g=FALSE, $b=FALSE) { |
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 | |
/* | |
Plugin Name: Filesystem Tutorial | |
Description: Demo Plugin for http://ottopress.com/2011/tutorial-using-the-wp_filesystem | |
Plugin URL: http://ottopress.com/2011/tutorial-using-the-wp_filesystem | |
Author: otto42 | |
DO NOT USE THIS ON A PRODUCTION SITE. THIS IS DEMONSTRATION CODE ONLY. | |
*/ |
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
general settings: | |
logo | |
favicon | |
header ticker | |
enable/disable responsive layout | |
footer copyright | |
tracking code | |
show/hide breadcrumb | |
enable/disable automatically add home menu item |
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
<a rel="prettyPhoto[<?php echo $this->get_field_id( 'kp-gallery' ); ?>]" href="<?php echo $full_image_src[0]; ?>"><?php echo $thumbnail_image; ?></a> |
OlderNewer