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
<!doctype html> | |
<html> | |
<head> | |
<title>Testing</title> | |
<style type="text/css"> | |
/* Begin Photoshop Copy/Paste */ | |
.Rounded_Rectangle_1 { | |
border-style: solid; | |
border-width: 1px; |
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
<div class="vfd-donor-ticker"> | |
<div class="vfd-donor-ticker-wrap"> | |
<ul> | |
<li> | |
<span class="name"> | |
Elvis Presley | |
</span> | |
<span class="amount red-text"> | |
$200 | |
</span> |
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 | |
add_shortcode( 'format_test', 'test_shortcode' ); | |
function test_shortcode( $atts ) | |
{ | |
// ignore $atts | |
return "<div class='test'>This\ntext\n\nshould all appear\n\n\n\non one line if shortcode output is untouched.</div>"; | |
} |
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 | |
$obj = new stdClass(); | |
echo 'Object in var: '; | |
var_dump( $obj == true ); | |
echo '<hr>'; | |
echo 'Non-existent var: '; | |
@var_dump( $nonexistent_obj == 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
-- | |
-- Basic update for site URL, does not update hard-coded content URLs but | |
-- should update properly generated permalinks and the basic site settings. | |
-- | |
UPDATE wp_options | |
SET option_value = REPLACE( option_value, 'http://www.oldhostname.com', 'http://www.newhostname.com' ) | |
WHERE option_value LIKE 'http://%'; |
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
<div class="col-sm-6 col-md-4"><div class="thumbnail" style=" | |
background: red; | |
border: 0; | |
"><div class="caption" style=" | |
background: #fff; | |
padding: 0; | |
min-height: 318px; | |
margin: 0 3px; | |
"><h3 style=" | |
color: #fff; |
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
-- Update options (site url, home) | |
-- | |
UPDATE wp_options | |
SET option_value = REPLACE( option_value, 'http://url1', 'http://url2' ) | |
WHERE option_value LIKE 'http://%'; | |
-- Update post content | |
-- | |
UPDATE wp_posts | |
SET post_content = REPLACE( post_content, 'http://url1', 'http://url2' ); |
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
# Download, extract, move and delete WordPress source. | |
cd /path/to/project/docroot/ | |
wget http://wordpress.org/latest.tar.gz | |
tar zxvf latest.tar.gz | |
mv wordpress/* ./ | |
rm -rf latest.tar.gz wordpress | |
# now hit the URL in your browser and install ;] |
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
# assume: /path/to/sql/file/mydb.sql | |
cd /path/to/sql/file/ | |
mysql -u root -p | |
# passord | |
> use mydb; | |
> \. mydb.sql |
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 | |
add_filter( 'gform_pre_render_1', 'szbl_gform_render_test' ); | |
function szbl_gform_render_test( $form ) | |
{ | |
foreach ( $form['fields'] as $key => $field ) | |
{ | |
if ( 'select' == $field->type ) | |
{ | |
if ( 5 == $field->id ) |
OlderNewer