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
/// EXPIRATION DATE | |
function my_pmpro_checkout_level($level) | |
{ | |
$expiration_year = date('Y'); | |
$current_month = date('n'); | |
// IF OCT, NOV, DEC, EXPIRE NEXT YEAR | |
if($current_month >= 10) { $expiration_year++; } | |
$expiration_date = $expiration_year . "-12-31"; | |
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 hg_awesome_weather_bg_ext() | |
{ | |
// 24 HOUR CLOCK: | |
// LESS THAN 8 AM OR GREATER THAN 9 PM | |
if( get_the_time('G') < 8 || get_the_time('21') > 9 ) | |
{ | |
return "night.jpg"; | |
} |
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 if( isset($weather->data['current'])) { ?> | |
<div class="awesome-weather-forecast-day"> | |
<?php if($weather->show_icons) { ?><i class="<?php echo $weather->data['current']['icon']; ?>"></i><?php } ?> | |
<div class="awesome-weather-forecast-day-abbr"><?php echo $weather->t->now; ?></div> | |
<div class="awesome-weather-forecast-day-temp"><?php echo $weather->data['current']['temp']; ?></div> | |
</div> | |
<?php } ?> |
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 hg_awesome_weather_wind_speed( $data, $speed, $direction ) | |
{ | |
$data['speed'] = round($data['speed'] * 1.94384); | |
$data['text'] = " knots"; | |
return $data; | |
} | |
add_filter('awesome_weather_wind_speed', 'hg_awesome_weather_wind_speed', 10, 3); |
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 | |
$where = new stdclass; | |
$where->location = "Dublin"; | |
$where->owm_city_id = 2964574; | |
$where->units = "F"; | |
$weather = get_awesome_weather_openweathermaps( $where ); | |
if( isset($weather->data['current'])) { ?> | |
<div class="awe-weather"> | |
<i class="<?php echo $weather->data['current']['icon']; ?>"></i> | |
<?php echo $weather->data['current']['temp']; ?>° <?php echo $weather->data['current']['description']; ?> |
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 $weather_name = awesome_weather_preset_condition_names_openweathermaps( $weather->data['current']['condition_code']); ?> | |
<style> | |
.awesome-weather-main-content { | |
position: relative; | |
z-index: 10; | |
} | |
.awesome-weather-video-background { | |
position: absolute; | |
top: 0; right: 0; bottom: 0; left: 0; |
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 if( isset($weather->data['current'])) { ?> | |
<div class="awe-weather"> | |
<?php if($weather->show_icons) { ?><i class="<?php echo $weather->data['current']['icon']; ?>"></i><?php } ?> | |
<?php echo $weather->data['current']['temp']; ?>°F / <?php echo awe_f_to_c($weather->data['current']['temp']); ?>°C | |
<?php echo $weather->data['current']['description']; ?> | |
</div> | |
<?php } ?> |
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
/*----------Testimonial Slider Plugin------------ */ | |
.testimonial_rotator .has-image .img img, .testimonial_rotator_single.has-image .img img { | |
width: 100%; | |
max-width: 150px; | |
height: auto; | |
border-radius: 100px; | |
} | |
.testimonial_rotator .has-image .img { |
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
exports.handler = function (event, context) | |
{ | |
try | |
{ | |
if (event.session.application.applicationId !== "YOUR APP ID") | |
{ | |
context.fail("Invalid Application ID"); | |
} |
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
/* | |
DATABASE STRUCTURE | |
CREATE TABLE `alexa_events` ( | |
`id` bigint(33) NOT NULL, | |
`user_id` varchar(255) COLLATE utf8_unicode_ci NOT NULL, | |
`item_id` int(33) NOT NULL, | |
`offsetInMilliseconds` int(33) NOT NULL, | |
`status` varchar(25) COLLATE utf8_unicode_ci NOT NULL | |
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci; |