with Lara Schenck
Not super important but I'd do it like this:
<?php if($author = get_field('author_name')): ?> <p>Author: <?php echo $author; ?></p><?php endif; ?>
Assign the variable and check if it's true in one go. Slightly more efficient because you're only getting the field once, especially if those functions hit the database (don't know if they do).
What the name of you sublime theme?
I liked the pairing screencast – the knowledge pool is twice as big
In the event a child theme is being used, get_stylesheet_uri and get_stylesheet_directory_uri functions will return the child theme's stylesheet or directory URI. Use get_template_directory_uri() to avoid being overridden by a child theme ( that's what wp_enqueue_scripts uses in twentysixteen). This is also the reason why you don't need to enqueue child theme's stylesheet (because that's handled by parent theme). More info at http://codex.wordpress.org/Function_Reference/get_stylesheet_directory_uri
This vid helped me a lot with my current contract on Upwork. Thanks!
Your email address will not be published. Required fields are marked *