This file contains hidden or 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 IE]> | |
<script type="text/javascript" src="https://getfirebug.com/firebug-lite.js"></script> | |
<![endif]--> |
This file contains hidden or 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 median($numbers){ | |
//loop through each value in the array and if it is a number add it to a new array | |
foreach ($numbers as $num) { | |
if(is_numeric($num)){ | |
$num_array[]=$num; | |
} | |
} | |
rsort($num_array); //sort the array for our operation |
This file contains hidden or 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
// display content to logged in users via shortcode | |
function member_only($atts, $content = null) { | |
if (is_user_logged_in()) | |
return '<div class="memberContent">' . do_shortcode($content) . '</div>'; | |
return ''; | |
} | |
add_shortcode('member_only', 'member_only'); | |
// display content to logged out users via shortcode | |
function non_member($atts, $content = null) { |
NewerOlder