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
$states = array( | |
array('Alabama'), | |
array('Alaska'), | |
array('Arizona'), | |
array('Arkansas'), | |
array('California'), | |
array('Colorado'), | |
array('Connecticut'), | |
array('Delaware'), | |
array('District of Columbia'), |
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
$gravityfunction = new Twig_SimpleFunction('displaygform', function ($id, $eventName) { | |
$form = gravity_form($id,false, false, false, array('event_name'=>$eventName)); | |
return $form; | |
}); | |
$twig->addFunction($gravityfunction); |
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
function processPayment($paymentAmount){ | |
$amountDue = 82.50; | |
if($paymentAmount >= $amountDue){ | |
return thankYou($paymentAmount); | |
}else{ | |
return "Thank you for your payment, you still owe $". number_format(($amountDue- $paymentAmount), 2); | |
} | |
} |
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
//Make a file called utilities.php. This is where you'll place all functions you write | |
include 'utilities.php'; | |
//replace the information in $profile2 with your own | |
$profile1 = ["firstName" => "Brent", "middleName" =>"Ryan", "lastName" => "Schultz", "birthYear" => "1985", "age" => 29]; | |
$profile2 = ["firstName" => "", "middleName" =>"", "lastName" => "", "birthYear" => ""]; | |
//Write the functions you'll need into your utilities.php file. checkForAge(), getYearsToRetirement() and compareAge() | |
$profile1 = checkForAge($profile1); |
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 | |
//Use the following arrays for this homework problem | |
$classes = array( | |
'WEB128' => array( | |
'name' => 'php & mysql', | |
'instructor' => 'Brent Schultz', | |
'class_days' => 'R' | |
), | |
'WEB150' => array( |
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
wp migrate-abacus scrape_media_content --post_type=pehub-vc-journal --chunk=7000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=5000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=10000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=15000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=20000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=25000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=30000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-buyouts --chunk=5000 --offset=35000 | |
wp migrate-abacus scrape_media_content --post_type=pehub-digital-edition --chunk=150 |
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 ( ( isset( $_GET['utm_medium'] ) && $_GET['utm_medium'] == 'pc' ) || ( isset( $_SESSION['utm_medium'] ) && $_SESSION['utm_medium'] == 'pc' ) { | |
$my_div = '<div class="A">THIS IS A</div>'; | |
} else { | |
$my_div = '<div class="B">THIS IS B</div>'; | |
} | |
echo $my_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
<form> | |
First name:<br> | |
<input type="text" name="firstname"><br> | |
Last name:<br> | |
<input type="text" name="lastname"> | |
<input type="radio" name="gender" value="male" checked> Male<br> | |
<input type="radio" name="gender" value="female"> Female<br> | |
<input type="radio" name="gender" value="other"> Other | |
<input type="submit" value="Submit"> | |
</form> |
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
function mysite_is_mobile() | |
{ | |
$isMobile = preg_match("#(ipod|iphone|android|opera mini|blackberry|pre/|palm os|palm|hiptop|avantgo|plucker|xiino|blazer|elaine|iris|3g_t|windows ce|opera mobi|windows ce; smartphone;|windows ce; iemobile)#i", $_SERVER['HTTP_USER_AGENT'] ); | |
return $isMobile == 1 ? true : false; | |
} | |
$batcache->unique['mobile'] = mysite_is_mobile(); |
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
<img src="http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-150x150.jpg" srcset="http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-300x200.jpg 300w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-768x512.jpg 768w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-1024x682.jpg 1024w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-465x310.jpg 465w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-670x446.jpg 670w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-230x153.jpg 230w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-440x293.jpg 440w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-145x97.jpg 145w, http://yeahkc.dev/wp-content/uploads/2016/09/517fde84-e2f5-36ae-af1e-c91daaa1ebc4-350x233.jpg 350w, http://yea |
OlderNewer