function example_function() { if ( is_user_logged_in() ) { // code } } add_action(‘init’, ‘example_function’);
// get posts $posts = get_posts(array( ‘post_type’ => ‘event’, ‘posts_per_page’ => -1, ‘meta_key’ => ‘start_date’, ‘orderby’ => ‘meta_value’, ‘order’ => ‘DESC’ ));
$address = get_field(‘company_address’, ‘option’); // bezoekadres
if ( post_password_required() ) { echo get_the_password_form(); return; } of:
Example debug config: // Enable WP_DEBUG mode define( ‘WP_DEBUG’, true ); // Enable Debug logging to the /wp-content/debug.log file define( ‘WP_DEBUG_LOG’, true ); // Disable display of errors and warnings define( ‘WP_DEBUG_DISPLAY’, false ); @ini_set( ‘display_errors’, 0 ); // Use dev versions of core JS and CSS files (only needed if you are modifying these […]
define( ‘ALTERNATE_WP_CRON’, true ); define( ‘WP_CRON_LOCK_TIMEOUT’, 1 );