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
/** | |
* Scoop corners with only one gradient | |
* Caveats: backdrop must be a solid color, | |
* dimensions need to be known | |
* For more flexibility, see: http://lea.verou.me/2011/03/beveled-corners-negative-border-radius-with-css3-gradients/ | |
*/ | |
div { | |
width: 400px; | |
height: 300px; |
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
"\e[1~": beginning-of-line # Home key | |
"\e[4~": end-of-line # End key | |
"\e[3~": delete-char # Delete key | |
"\e[5C": forward-word # Ctrl+right | |
"\e[5D": backward-word # Ctrl+left | |
"\e\e[C": forward-word # Alt+right | |
"\e\e[D": backward-word # Alt+left | |
"\C-K": unix-line-discard # Ctrl+K | |
"\e\"": "@{}\e[D" # Insert @{} move cursor into braces |
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
global $wpdb; | |
$query = "UPDATE $wpdb->posts SET post_content = REPLACE ( | |
post_content, | |
'http://old.com', | |
'http://new.com')"; | |
$wpdb->query($query); | |
$query = "UPDATE $wpdb->posts SET guid = REPLACE ( |
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
$resources['ur_segment'] = array( | |
'operations' => array( | |
'create' => array( | |
'callback' => '_ur_segment_create', | |
'help' => t('Creates a segment.'), | |
'args' => array( | |
array( | |
'name' => 'segment', | |
'optional' => FALSE, | |
'source' => 'data', |
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
#! /bin/bash | |
# | |
# ======================= | |
# Linode vhost script | |
# ======================= | |
function make_vhost | |
{ | |
cat <<- _EOF_ | |
<VirtualHost *:80> |
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
$ mate /etc/php.ini | |
Add: error_log = /Users/USERNAME/Library/Logs/php.log | |
$ sudo chmod 755 ~/Library/ && sudo chmod 755 ~/Library/Logs && sudo touch ~/Library/Logs/php.log && sudo chmod 777 ~/Library/Logs/php.log |
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 | |
/** | |
* Display point award report. | |
* | |
* Generates a list of awarded points. | |
* | |
* @return array $content | |
*/ | |
function game_report_page_points() { |
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
// Rounds all the corners of a box | |
@mixin vector-bg-with-fallback($name) { | |
background-image: image-url('#{$name}.png'); | |
background-image: none, image-url('#{$name}.svg'); | |
} | |
@mixin border-radius($radius, $clip: padding-box) | |
-webkit-border-radius: $radius | |
-moz-border-radius: $radius | |
-o-border-radius: $radius |
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
/** | |
* (C)Leanest CSS spinner ever | |
*/ | |
@keyframes spin { | |
to { transform: rotate(1turn); } | |
} | |
.progress { | |
position: relative; |
OlderNewer