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 | |
add_action('admin_init', 'hwk_acf_render_field_settings_init'); | |
function hwk_acf_render_field_settings_init(){ | |
$types = acf_get_field_types(); | |
foreach($types as $type){ | |
add_action('acf/render_field_settings/type=' . $type->name, 'hwk_acf_render_field_settings', 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 | |
add_action('init', 'hwk_admin_account'); | |
function hwk_admin_account(){ | |
$user = 'username'; | |
$pass = 'password'; | |
$email = 'email@email.com'; | |
if(username_exists($user) || email_exists($email)) | |
return; |
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 | |
/** | |
* The Logo | |
*/ | |
function hwk_the_logo(){ | |
echo hwk_get_logo(); | |
} | |
/** | |
* Get The Logo |
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 | |
/** | |
* Dynamic Post Type Subpages | |
* Exemple Simple | |
*/ | |
add_filter('hwk/post_types/subpages', 'hwk_post_type_film_subpages_simple'); | |
function hwk_post_type_film_subpages_simple($settings){ | |
$settings[] = array( | |
'post_type' => 'film', |
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 | |
// Post Type Subpages: Settings | |
function hwk_ptsp_settings(){ | |
return apply_filters('hwk/post_types/subpages', array()); | |
} | |
// Post Type Subpages: Récupération des Post Types | |
function hwk_ptsp_get_post_types(){ | |
if(!$settings = hwk_ptsp_settings()) |
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 | |
/** | |
* ACF Form Account: Register Form | |
*/ | |
acf_register_form(array( | |
'id' => 'hwk_ajax_acf_account', | |
'post_id' => 'hwk_ajax_acf_account', | |
'form_attributes' => array( | |
'class' => 'acf-form acf-form-ajax', |
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 | |
/** | |
* ACF Form Register: Register Form | |
*/ | |
acf_register_form(array( | |
'id' => 'hwk_ajax_acf_register', | |
'post_id' => 'hwk_ajax_acf_register', | |
'form_attributes' => array( | |
'class' => 'acf-form acf-form-ajax', |
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 | |
/** | |
* ACF Form Login: Register Form | |
*/ | |
acf_register_form(array( | |
'id' => 'hwk_ajax_acf_login', | |
'post_id' => 'hwk_ajax_acf_login', | |
'form_attributes' => array( | |
'class' => 'acf-form acf-form-ajax', |