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
/* | |
* Custom CSS to make videos responsive | |
* Original code from: https://avexdesigns.com/responsive-youtube-embed/ | |
*/ | |
.ld-video { | |
position: relative; | |
padding-bottom: 56.25%; | |
padding-top: 30px; height: 0; | |
overflow: hidden; |
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
/* | |
* Temporary function to hide the license key entered for LearnDash LMS | |
* Add the below to your child theme's functions.php file or as a code snippet using a third party plugin such as: https://en-ca.wordpress.org/plugins/code-snippets/ | |
*/ | |
function ld_hide_license_key() { | |
echo '"<script type="text/javascript">jQuery( "#nss_plugin_license_sfwd_lms" ).val( "**********" );</script>"'; | |
} | |
add_action('admin_footer', 'ld_hide_license_key'); |
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
// Add your own function to filter the fields | |
add_filter( 'job_manager_job_listing_data_fields', 'custom_job_manager_job_listing_data_fields' ); | |
// This is your function which takes the fields, modifies them, and returns them | |
// You can see the fields which can be changed here: https://github.com/mikejolley/WP-Job-Manager/blob/master/includes/admin/class-wp-job-manager-writepanels.php | |
function custom_job_manager_job_listing_data_fields( $fields ) { | |
// Here we target one of the job fields (location) and change it's placeholder | |
$fields['job']['opentable']['label'] = "OpenTable Embed"; |
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
// Add your own function to filter the fields | |
add_filter( 'submit_job_form_fields', 'custom_submit_job_form_fields' ); | |
// This is your function which takes the fields, modifies them, and returns them | |
// You can see the fields which can be changed here: https://github.com/mikejolley/WP-Job-Manager/blob/master/includes/forms/class-wp-job-manager-form-submit-job.php | |
function custom_submit_job_form_fields( $fields ) { | |
// Here we target one of the job fields (job_title) and change it's label | |
$fields['job']['opentable']['label'] = "OpenTable Embed"; // Notice I changed this to open table field. |
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 | |
/** | |
* The template for displaying job listings (in a loop). | |
* | |
* @package Listify | |
*/ | |
?> | |
<li itemscope itemtype="http://schema.org/LocalBusiness" id="job_listing-<?php the_ID(); ?>" <?php echo apply_filters( 'listify_job_listing_data', '', false ); ?>> |
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 | |
/** | |
* The Template for displaying all single posts. | |
* | |
* @package Listify | |
*/ | |
get_header(); ?> | |
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 | |
/** | |
* Plugin Name: Listify - Custom Single Listing Hero Button | |
*/ | |
function custom_listify_single_job_listing_actions_after() { | |
global $post; | |
$url = get_post_meta( $post->ID, 'your_custom_meta_key', true ); | |
if ($url != "") { |
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
<script id="tmpl-infoBubble" type="text/template"> | |
<a href="{{{ data.link }}}"> | |
<# if ( typeof( data.thumb ) != 'undefined') { #> | |
<span style="background-image: url({{{ data.thumb }}})" class="list-cover has-image"></span> | |
<# } #> | |
<# if ( typeof( data.title ) != 'undefined') { #> | |
<h1>{{{ data.title }}}</h1> | |
<# } #> |
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
/** | |
* Redirect users to custom URL based on their role after login | |
* | |
* @param string $redirect | |
* @param object $user | |
* @return string | |
*/ | |
function wc_custom_user_redirect( $redirect, $user ) { | |
// Get the first of all the roles assigned to the user | |
$role = $user->roles[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 if ( $apply = get_the_job_application_method() ) : | |
wp_enqueue_script( 'wp-job-manager-job-application' ); | |
?> | |
<div class="job_application application"> | |
<?php do_action( 'job_application_start', $apply ); ?> | |
<?php if ( 'url' == $apply->type ) : ?> | |
<a class="button" href="<?php echo esc_url( $apply->url ); ?>" target="_blank" rel="nofollow" style="padding:1em;">Apply for job</a> | |
<?php else : ?> | |
<input type="button" class="application_button button" value="<?php _e( 'Apply for job', 'wp-job-manager' ); ?>" /> |