to hook in the <head> you would use wp_head. You can read the documentation here.
add_action( 'wp_head', 'meta_example' );
function meta_example() {
echo '<meta name="description" content="Meta Description for this Page." />';
} // End meta_example()
This assumes that your theme has <?php wp_head(); ?> in the <head>.
Related Posts:
- How to display Yoast SEO meta description in archive template for each post instead of the_excerpt()? [closed]
- Get ID of a page containing secondary loop in content
- How to add “time” data this?
- Next and Previous loop
- ACF custom field in [closed]
- Cannot retieve the_content() and the_author() – both returning empty strings
- Output meta into arrays
- value of metadata is null wrong use of if statement
- Sending mail not working correctly
- using update_user_meta to rank users
- get_post_meta printing empty fields, but it shouldn’t be
- Check value of post meta within IF statement
- Best way to check if a post with specific meta exists
- WP update_post_meta link loop
- Humanmade | Custom meta box class: How to display a repeatable meta box group?
- Display articles related to a custom field on a page
- Jquery Slider for profile template
- Get excerpt using get_the_excerpt outside a loop
- how to upload image using wp_handle_upload
- Avoiding using a loop to access a single post
- Adding ‘current_post_item’ class to current post in the loop
- wp_list_categories: get latest featured_image of category
- WordPress Alphabetical Glossary close div in loop
- Landing Page – Redirect Loop?
- How to make multiple Column in archive Page?
- Sort Popular Posts by Views for the Last Week
- category__not_in — anyway to use category name instead of id?
- Filtering posts by multiple taxonomies
- Is it possible to display previous post revision?
- Why do I get `Call to a member function have_posts() on a non-object `? [closed]
- Help with Changing loop.php?
- Adding shortcode closing tag after a loop
- Get Pagination (WP-PageNavi) not to work
- Filtering The Loop For Single Page and Blog Page
- Removing the_content() from the page
- Category Ajax call
- Change front-page layout after x amount of posts ( while in the same loop)
- Transient loop issue
- popular post weekly and monthly
- How can i use the same template file with a widget and category loop?
- WordPress Loop inside Loop?
- Filter the loop by categories using checkbox form
- Duplicated posts on category page
- WordPress loop: exclude if it is the latest post
- angularjs not displaying all posts
- Update status of all posts in a category
- is_active-sidebar loop
- Unable to change the “Read more” text inside the_excerpt
- Display Post Author Link above the loop
- Enabling users to control custom loop’s query
- Conditional: IF current user has NOT commented on current post (not including post author)
- Change post order by meta key, per post basis
- Loop Problem: Displays same set of post for all categories
- Query Nopaging action not having effect
- display post format text in loop
- How do i find and restore a sidebar that i accidentally deleted? [closed]
- Posts not showing
- Inserting CPT and static content at every X post, is this possible?
- Use BuddyPress data in loop (mkdir)
- Wrap every four posts within a div [duplicate]
- Get most recent post for every term in a given taxonomy type
- loop through posts and display inserted media and post title as a link
- Can’t grab author info outside of the loop
- How to tell if all posts are only in one category?
- How to get post category and author name for cusmot API?
- How do I set the Stewart Search Template to return only published posts in the result
- How to add Default Level-0 parent and Level-1 class in WordPress Category in li element?
- WordPress posts in the loop not stacking side by side
- How to separate post titles with a comma in the loop?
- Trying to get property ‘post_content’ of non-object
- WordPress loop : how to exclude some posts with their status?
- update_post_meta() not updating
- Include only one category but Exclude if is in a category from loop
- Create an archive page(loop) for edd products (music files) with an audio player?
- WordPress Pages in an Array
- the_content() keeps repeating itself
- Show different Google Map markers for different post_meta values
- numberposts not responding to wp_reset_postdata()
- Foundation modal in wordpress php loop
- My loop of random posts drags in comments of said random post
- Why my title change the last post title in my loop?
- Where should get_post_meta() go to get $post->ID get_post_meta() is empty and $post->ID & get_the_id() are working
- Get child taxonomies in loop
- Have multiple loops on a page appear after/between page content
- How to fix pagination for custom loops?
- Get gallery and product gallery images full size
- Loop not showing up on page template
- One loop for sticky, one for all the rest – how, without specifying category?
- Using in_category for non standard loops
- Use Loop or direct database query?
- How to end this loop properly?
- Creating mulitple loops in a sub-category page
- Custom Post Type archive above Single Post in single.php (same author)
- Custom Page Template and Category Exclusion
- Display Featured Image
- AJAX in wordpress theme loop
- Duplicate post problem
- Loop that displays all posts by logged in user, with Post Edit link
- How to store wordpress title in a variable
- How to split the loop every 2 and 5 results? [closed]