var divs = $("div");
var divs = document.querySelectorAll("div");
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
| jQuery(document).ready(function(){ | |
| function randomgen() | |
| { | |
| var rannumber=''; | |
| for(ranNum=1; ranNum<=6; ranNum++){ | |
| rannumber+=Math.floor(Math.random()*10).toString(); | |
| } | |
| $('#verifyNum').html(rannumber); | |
| $('#verifyNumHidden').val(rannumber); | |
| } |
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
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
| <html xmlns="http://www.w3.org/1999/xhtml"> | |
| <head> | |
| <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"/> | |
| <title><?php echo $subject; ?></title> | |
| <style type="text/css"> | |
| #outlook a {padding:0;} | |
| body{width:100% !important; -webkit-text-size-adjust:100%; -ms-text-size-adjust:100%; margin:0; padding:0;} | |
| .ExternalClass {width:100%;} |
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
| <div id="fb-text">Like us on Facebook for the very latest updates, exclusives, offers and competitions!</div> |
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 lang_support() { | |
| return array('en','fr'); // Add your support lang-code (1st place is a default) | |
| } | |
| function rewrite_lang(){ | |
| $langs = lang_support(); | |
| foreach($langs as $lang) { | |
| add_rewrite_endpoint($lang,EP_PERMALINK|EP_PAGES|EP_ROOT|EP_CATEGORIES); | |
| } | |
| } |
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
| // tries to execute the uri:scheme | |
| function uriSchemeWithHyperlinkFallback(uri, href) { | |
| // set up a timer and start it | |
| var start = new Date().getTime(), | |
| end, | |
| elapsed; | |
| // attempt to redirect to the uri:scheme | |
| // the lovely thing about javascript is that it's single threadded. | |
| // if this WORKS, it'll stutter for a split second, causing the timer to be off |
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
| <?php | |
| /* | |
| This function assumes a custom field named 'expiration' with a human friendly date/time. | |
| */ | |
| function is_post_expired($post_ID = null){ | |
| if(!$post_ID) global $post; | |
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
| <?php | |
| if (have_posts()) : | |
| while (have_posts()) : the_post(); ?> | |
| $expirationtime = get_post_custom_values('expiration'); | |
| if (is_array($expirationtime)) { | |
| $expirestring = implode($expirationtime); | |
| } | |
| $secondsbetween = strtotime($expirestring)-time(); | |
| if ( $secondsbetween > 0 ) { |
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
| <?php | |
| /** | |
| * | |
| * Mobile theme switcher code - pulled from Mobile theme switch | |
| * Original URI: http://wordpress.org/extend/plugins/mobile-theme-switcher/ | |
| * Original Author: Jonas Vorwerk, http://www.jonasvorwerk.com/ | |
| * | |
| * | |
| * Bypass this check in any browser by using http://myurl/?mobile=on or http://myurl/?mobile=off This is locally being stored using a cookie. |
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
| <?php | |
| $url = "http://{site_url}/service/v4/rest.php"; | |
| $username = "admin"; | |
| $password = "password"; | |
| //function to make cURL request | |
| function call($method, $parameters, $url) | |
| { | |
| ob_start(); |