It can be used for much about anything that requires php…
You’d only use hooks if you don’t want to execute the php logic immediately. This is usually the case, but not always.
Likewise, you’d typically use the WP API. But not always either…
Related Posts:
- Is it ok to use a function to output the text domain name in a wordpress theme
- Issue with wp_get_attachment_image() and SVG file type
- How to override a function when isn’t at functions.php
- deregister scripts on certain page
- contactform7 remove tags with “wpcf7_autop false” from functions.php
- How to count number of functions attached to an action hook?
- Show modified time if post is actually modified
- ajax live search for post title
- How to get an array of menu items from the toolbar?
- Using get_terms for custom taxonomy in functions.php
- Fatal error: Call to undefined function add_action() – an untouched problem
- echo or print_r in an admin function
- Hide some items from Screen options in dashboard for products
- Editing or filtering the output of the Genesis navigation
- Query children and parent title
- How to make unique add_filter to the_content of specific page template files – so each template gets its own addition
- Hide the Private prefix on one specific page
- Creating loop within functions.php
- Limit filter upgrader_post_install to a single plugin
- How to test for Super Admin
- Adding a class to tag list in a function
- creating shortcode to pull json array
- Pass Shortcode Attribute to footer Script
- echo get_post_meta()
- Replace menu links with # and add name to its li
- Variable if post is sticky in functions.php
- Retrieve tags data in post body
- Remove H1 / title / Underscore – without CSS
- Change template on the fly based on post parent selection
- Current path on page in functions.php
- How do you publish a draft on WordPress
- How can I recompile js file in dist folder?
- Show Primary Category first when I display post categories
- Wp_query function to search from product_title ‘OR’ product tags name
- Create a new query in function.php to filter blog posts
- Remove the product category module block from the Woocommerce product page
- Setting youtube size in functions.php
- How to get correct URLs in network wide menu (Multisite)?
- wp_get_archives custom function broken since upgrading to WP 3.7.1
- Remove category from url
- ‘Attempt to modify property of non-object’ warning
- Conditional functions.php on page template
- Optimizing a WordPress site
- different style sheet for just one page template
- Problem with comments_number()
- Functions when woocommerce isn’t installed
- How to target post and pages and not all post types in admin?
- How to get correct value from checked()?
- Dequeue script to prevent javascript event conflict on wordpress child theme
- While loop with an exception after a count is reached
- Return child theme url
- Redefine function arguments before rendering
- Passing global variable from header.php to functions.php
- How is $current_page passed in woocommerce_account_orders function?
- Upgraded server now class My_Walker_Nav_Menu extends Walker_Nav_Menu not working
- Functions php shortcode for displaying main menu with no child items
- How to include any template using Shortcode fuction?
- display a div on ervery site but not frontpage?
- first paragraph of the_content as meta description
- get_terms (or tax_query) for term of current post?
- Do we need to change our child function.php to require/include child dir files when we add an over-riding file.php into the child theme
- Replace header image on all other pages but home – URL issue
- Child theme functions.php
- How to echo Widget Title in Custom Frontend-Template Box
- Redirect to post after publish or update a published post
- Page Template Won’t Load Correct CSS File
- Getting images from media library and get_the_date() not working
- WordPress show bad the php hour and date
- Using add_image_size in functions.php to get original uploaded file
- show all the posts thumbnails
- the_excerpt function not showing image
- How to display this meta data (an array) in form of a function (created with a custom write panel)?
- Use a filter for wp_robots to block CPT/feed/
- Trigger email alert if file downloaded
- Completely Disable WordPress RSS Feeds
- How do I change where “You must be logged in to comment” directs users?
- Login cookies blocked after customizing hashing method
- Order column custom date using pre_get_posts
- query_vars treat as single var from URL
- Running javascript without hooking wp_head
- Remove text after a dot and a colon in Woocommerce product title
- Enable CORS Request for hostname using IP address
- Change default color scheme in twentyfifteen child theme?
- Restrict access if logged out except for homepage
- Add meta data in head from theme
- what is `get_section()` and how to use it?
- DISABLE wordpress upgrade page
- How to echo the translated custom field?
- Only Show One Category Name Per Post
- Moving CDN jQuery to footer does not work?
- Pass max posts to Javascript
- Register a widget area when a theme option has been saved?
- Blank child theme – functions.php problem
- update_usermeta don’t work
- WP supersize not displaying when different languages flags are selected
- Hiding Google Analytics code based on theme options
- How do I make my child theme’s CSS update when I save it?
- Bulk set Post Title as Tag where Tag is Empty Function
- Is storing in a variable the result of a fonction a most powerful way to code an if structures in WordPress?
- woocommerce_sort_product_tabs() expects an array