|
INTERVIEW QUESTIONS
CONTENT MANAGEMENT SYSTEM
WORDPRESS
DETAILS
Question: What are Hooks and define types of Hooks in WordPress ?
Answer: Hooks are provided by WordPress to allow your plugin to ‘hook into’ the rest of WordPress; that is, to call functions in your plugin at specific times, and thereby set your plugin in motion. There are two kinds of hooks:
Actions Hooks: Actions hooks are the hooks that the WordPress core launches at specific points during execution, or when specific events occur. Your plugin can specify that one or more of its PHP functions which are executed at these points, using the Action API.
Filters Hooks: Filters hooks are the hooks that WordPress launches to modify text of various types before adding it to the database or sending it to the browser screen. Your plugin can specify that one or more of its PHP functions which are executed to modify specific types of text at these times, using the Filter API.
Actions Functions: has_action() add_action() do_action() do_action_ref_array() did_action() remove_action() remove_all_actions()
Filter Functions: has_filter() add_filter() apply_filters() apply_filters_ref_array() current_filter() merge_filters() remove_filter() remove_all_filters()
|
|
|
Category |
WordPress Interview Questions & Answers -
Exam Mode /
Learning Mode
|
Rating |
(0.3) By 6524 users |
Added on |
8/11/2016 |
Views |
70283 |
Rate it! |
|
|
Question:
What are Hooks and define types of Hooks in WordPress ?
Answer:
Hooks are provided by WordPress to allow your plugin to ‘hook into’ the rest of WordPress; that is, to call functions in your plugin at specific times, and thereby set your plugin in motion. There are two kinds of hooks:
Actions Hooks: Actions hooks are the hooks that the WordPress core launches at specific points during execution, or when specific events occur. Your plugin can specify that one or more of its PHP functions which are executed at these points, using the Action API.
Filters Hooks: Filters hooks are the hooks that WordPress launches to modify text of various types before adding it to the database or sending it to the browser screen. Your plugin can specify that one or more of its PHP functions which are executed to modify specific types of text at these times, using the Filter API.
Actions Functions: has_action() add_action() do_action() do_action_ref_array() did_action() remove_action() remove_all_actions()
Filter Functions: has_filter() add_filter() apply_filters() apply_filters_ref_array() current_filter() merge_filters() remove_filter() remove_all_filters()
Source: CoolInterview.com
If you have the better answer, then send it to us. We will display your answer after the approval.
Rules to Post Answers in CoolInterview.com:-
- There should not be any Spelling Mistakes.
- There should not be any Gramatical Errors.
- Answers must not contain any bad words.
- Answers should not be the repeat of same answer, already approved.
- Answer should be complete in itself.
|
|
Related Questions |
View Answer |
|
What are the rules that you have to follow for wordpress plugin development?
|
View Answer
|
|
Why does WordPress use MySQL?
|
View Answer
|
|
What is the prefix of wordpress tables by default?
|
View Answer
|
|
What is WordPress loop?
|
View Answer
|
|
What are the steps you can take if your WordPress file is hacked?
|
View Answer
|
|
In what case you don’t see plugin menu?
|
View Answer
|
|
What are the plugins you can use to create contact form in WordPress?
|
View Answer
|
|
What are the cases where we cannot recommend WordPress to our client?
|
View Answer
|
|
What are the essential features you look for a theme?
|
View Answer
|
|
How you can create a static page with WordPress?
|
View Answer
|
|
Which is the best multi-lingual plugin for wordpress?
|
View Answer
|
|
Is there any way to write series in WordPress?
|
View Answer
|
|
What is the use of Mail Server in Wordpress Writing setting?
|
View Answer
|
|
What is Wordpress Dashboard?
|
View Answer
|
|
Which is the PHP compatibility used for Wordpress?
|
View Answer
|
|
Mention the steps to optimize your Wordpress?
|
View Answer
|
|
What is Widget Management?
|
View Answer
|
|
What is a Moderate comment?
|
View Answer
|
|
What is Tag in Wordpress?
|
View Answer
|
|
What are pages in Wordpress?
|
View Answer
|