WordPress Interview questions

WordPress interview questions, For both freshers and experiences. WordPress is a very robust CMS in software market.

Q: Define WordPress and what are the feaṭures?

1:   Wordpress is a perfect open-source CMS (content management system).
2:  This is used to develop dynamic websites and blogs.
3:  WordPress is based on PHP/MySql.
  These are the features of WordPress:

  • 1: Theme System
  • 2: Extend with Plugins
  • 3: Importers
  • 4: Multilingual
  • 5: Media Management
  • 6: User Management

Q: What are the limitations of WordPress?

Ans: These are the limitations of WordPress:
1: Make the website heavy and load to run, using different plugins.
2: We have to require knowledge on PHP to do any modifications on the website.
3: Sometimes a software update is required to maintain WordPress up-to-date with the current browsers and mobile devices.
4: Updating WordPress version have to loss of data, so needs the backup of the websites.
5: It is very difficult to modify and format the graphic images of the tables.

Q: How many types of gadgets are present in the wordpress dashboard and define all the gadgets?

Ans: These are the list of gadgets are present in the WordPress dashboard:
1: Welcome->It includes the customize site button that allows customizing the WordPress theme.
->The middle column gives some useful links such as creating a page, creating a blog post and view the front end of the website.
2: Quick Draft->It is called as a mini post editor.
->It allows publishing, saving and writing a post from the admin dashboard.
3: Activity->It includes latest comments on a blog, recent posts and recently published posts.
->It allows replying,edit, delete, approve or disapprove a comment and also to move a comment to spam.
4: At a Glance->It provides an overview of blog’s posts, number of published posts and pages, and number of comments.
->It shows the current version of running WordPress along with the currently running theme on the site.
5: Dashboard Menu->It keeps navigation menu, which contains a few menu options such as posts, media library, plugins, users, tools, pages, comments, appearance options and settings on the left side.
6: Screen Options->It contains checkboxes to show or hide screen options and also grants to customize sections on the admin screen.
7: WordPress News->It shows the latest news such as the latest software version, alerts, updates, news regarding the software from the official WordPress blog.

Q: In WordPress, define the reading setting?

Ans: Using reading setting, to set the content related to the front page.
In wordpress, it is used to set the many numbers of post to be displayed on the main page.

Q: In the WordPress PHP file, how to write the shortcode?

Ans:Inside a php echo tag,we can write do_shortcode() method.
Example:<?php do_shortcode(“[shortcode]”); ?>
In wordpress php file short code is used in post,page and text box widget.

Q: In WordPress, define the template tags and what are those?

Ans: In WordPress, using template tags to “do” or “get” something.
Example: In header.php file, to get the site title using bloginfo(‘name’) template tag.
These are the template tags which are given below:
1:the_title()->This template tag is used to display the post title.
2:wp_list_cats()->This template tag is for display categories.
3:get_header()->This is used for getting header.
4:get_sidebar()->this is used for display the sidebar on page.
5:get_footer()->This is used for get the footer content on page.

Q: In WordPress, how to create a custom post type?

Ans: In WordPress, a new post type is called a custom post type. By using register_post_type() methods, custom post type can be added to WordPress.

Q: Define hooks and what are the types of hooks in WordPress?

In WordPress, hooks are functions which can be converted by theme and plugin. It allows developers to change the default WordPress functionality.
There are two types of hooks, which is given below:
1: Action hooks->When some specific events occur, actions hooks are executed.
Actions functions are:






2:Filter hooks->It allow to modify text of various types before adding it to the database.
Filters functions are:








Q:What is the method to find out the number of parameters passed into function?

Ans: func_num_args() function returns the number of parameters passed in.

Q: Mention the ternary conditional operator in PHP?

Ans: Expression preceding the ? is evaluated, if it’s true, then the expression preceding the: is executed, otherwise, the expression following: is executed.

Q: In WordPress, what are the rules follow in the plugin development?

Ans: Following are the rules in plugin development:
1: Find a unique name
2: Setup a prefix
3: Create the plugin’s folder
4: Create sub-folders for PHP files, assets, and translations
5: Create the main plugin file and fill in the obligatory header information
6: Create a readme.txt file
7: Use proper constants and functions to detect paths to plugin files
8: Create additional PHP files and include them inside the main one
9: Create activation and deactivation functions
10: Create an uninstall script

Q: In WordPress, what are the default tables?

Ans:There are 11 default tables in wordpress

13.Q:In wordpress writing setting,what is the use of mail server?

Ans: In WordPress, mail server allows to reading the emails and store them for retrieval. To reading the email we have to POP3 compatible mail server and should have URL address.

Q: Define WordPress taxonomy and what are those?

Ans: In WordPress, it is a grouping mechanism for some custom post type.
In WordPress, there are 4 types of default taxonomies are available:
1: Link Category
2: Post Formats
3: Tag
4: Category

Q: In WordPress, how to disable comments?

Ans: In options > Discussion panel, we have to unchecked allow people to post the comments in the article.By unchecking it will disable comments on future posts.
Then for complete disable comments, from the write post we have sub-panel to edit each past post and uncheck allow comments.
On a shell account or by using phpmyadmin, we could run this MySQL query in the command line UPDATE WP_posts SET comment-status=” closed”;
For permanently disable comments we should delete wp_comments-posts.php files also.

Q: List the Positive aspects of WordPress?

Ans: These are the following Positive aspects of WordPress:
1: In-built SEO system
2: Flexibility
3: Community
4: Easy theme system
5: Easy installation and upgrade
6: Easy and flexible publishing option
7: Multilingual is available in about more than 70 languages
8: Own data full control and no unwanted advert on your personal or commercial website.

Q: Is WordPress helpful from Seo point of view? Will it show the Website on Google?

Ans: It is one of the advantages of using WordPress, it has an inbuilt SEO search engine and also it has an additional plugin to help with SEO and rank on a popular search engine like Google.

Q: In WordPress, define custom field?

Ans: It is metadata which allows storing random information to the WordPress post. Using a custom field, additional information can be added to the post.

Q: In which situation We cannot recommend WordPress to our Client?

Ans: We cannot recommend WordPress in the following cases:
1: In the case of an enterprise intranet solution.
2: If the site wants complex or innovative e-commerce.
3: Sites requiring custom scripting solutions.
4: If the client is working on a non-CMS based project.

Q: What is default table prefix for WordPress?

Ans: The default table prefix for WordPress is wp_.