Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteRule ^index\.php$ - [L] | |
RewriteRule (.*) ./index.php?id=$1 [L] | |
</IfModule> |
<?php | |
//http://www.webhostingtalk.com/showthread.php?t=218863 | |
$start_dir = 'whatever'; // Starting directory no trailing slashes. | |
$perms['file'] = 0644; // chmod value for files don't enclose value in quotes. | |
$perms['folder'] = 0755; // chmod value for folders don't enclose value in quotes. | |
function chmod_file_folder($dir) { | |
global $perms; | |
$dh=@opendir($dir); |
Attention: the list was moved to
https://github.com/dypsilon/frontend-dev-bookmarks
This page is not maintained anymore, please update your bookmarks.
<?php | |
defined( 'ABSPATH' ) OR exit; | |
/** | |
* Plugin Name: (WCM) PHPMailer Exceptions & SMTP | |
* Description: WordPress by default returns <code>FALSE</code> instead of an <code>Exception</code>. This plugin fixes that. | |
*/ | |
add_action( 'phpmailer_init', 'WCMphpmailerException' ); | |
function WCMphpmailerException( $phpmailer ) | |
{ |
<?php | |
function pw_edd_remove_default_fields() { | |
remove_action( 'edd_after_cc_fields', 'edd_default_cc_address_fields' ); | |
} | |
add_action( 'init', 'pw_edd_remove_default_fields' ); | |
function pw_edd_custom_country_fields() { | |
ob_start(); ?> | |
<fieldset id="edd_cc_address" class="cc-address"> |
var screenWidth = window.innerWidth; | |
var visibleElements = jQuery(":visible"); | |
visibleElements.each(function(){ | |
var $this = jQuery(this); | |
if($this.width() > screenWidth){ | |
$this.css("border", "1px solid green"); | |
console.log("Screen width is " + screenWidth + " and the following element is " + $this.width(), $this); | |
} | |
}); |
If $foo is an object such as: | |
` | |
stdClass Object | |
( | |
[something] => 279 | |
[something_2] => 1 | |
) | |
` |
<?php | |
$slider = new RevSlider(); | |
$arrSliders = $slider->getArrSliders(); | |
$addNewLink = self::getViewUrl(RevSliderAdmin::VIEW_SLIDER); | |
require self::getPathTemplate("sliders"); | |
?> |
<?php | |
/** | |
* Plugin Name: WooCommerce - List Products by Attributes | |
* Plugin URI: http://www.remicorson.com/list-woocommerce-products-by-attributes/ | |
* Description: List WooCommerce products by attributes using a shortcode, ex: [woo_products_by_attributes attribute="colour" values="red,black" per_page="5"] | |
* Version: 1.0 | |
* Author: Remi Corson | |
* Author URI: http://remicorson.com | |
* Requires at least: 3.5 | |
* Tested up to: 3.5 |
#!/usr/bin/env bash | |
echo "Running boostrap.sh..." | |
echo "+---------------------------------------------------+" | |
echo "| Update apt-get |" | |
echo "+---------------------------------------------------+" | |
apt-get update | |