Google News
logo
WordPress Interview Questions
WordPress is an Open Source "Content Management System (CMS)" and a blogging tool, based on PHP and MySQL. It is free of cost, and you can use it for any personal and commercial website.
WordPress as an open source of platforms, with lots of security plugins, is safe and still one requires regular updates preventing from hacking and loss of data.
WordPress can be used for e-commerce sites, membership sites, photo galleries and any other type of site you can think. Following are some disadvantages of WordPress:
 
* Using several plugins can make the website heavy to load and run.
* PHP knowledge is required to make modifications or changes in the WordPress website.
* Modifying and formatting the graphic images and tables is difficult.
* Sometimes software needs to be updated to keep the WordPress up-to-date with the current browsers and mobile devices. Updating WordPress version leads to loss of data, so a backup copy of the website is required.
WordPress was initially released on 27th May 2003 by Matt Mullenweg and Mike Little. WordPress was announced as open source in October 2009.
It is one of the benefits of using WordPress; it has inbuilt SEO search engine. Also, you can have an additional plug-in in WordPress to help with SEO and rank on a popular search engine like Google.
Database : MySQL 5.0 +
 
Web Server :
* WAMP (Windows)
* LAMP (Linux)
* XAMP (Multi-platform)
* MAMP (Macintosh)

Operating System : Cross-platform

Browser Support : IE (Internet Explorer 8+), Firefox, Google Chrome, Safari, Opera

PHP Compatibility : PHP 5.2+
Dashboard menu : This component of home screen provides the navigation menu options for posts, media library, pages, and comments on the left side of the screen.

Screen options : This component of the home screen display different types of widgets which can be shown or hidden on some screen. This component also contains the checkboxes to show or hide different screen options and also allow to customize sections on the admin screen.

Welcome : This component of the home page help us to customize WordPress theme by clicking on the customize your site button. Also, the center column provides some of the useful links such as creating a page and view the front end of your web page, creating a blog post. Moreover, the last column contains links to the menus, widgets, settings related to comments.

Quick Draft : This component of the home screen includes a mini post editor which is used to write, save, and publish the post from the admin dashboard. This include title of the draft followed by some notes about the draft and save it as a draft.

Wordpress news : This component of home screen displays the latest news regarding the latest software update of WordPress.

Activity : This component of the home screen shows the latest comments, recent posts published. It also allows you to reply, edit, delete, approve, or disapprove the comments. You can also move comments to spam.

At a Glance : This component of home screen displays an overview of your blog?s posts, number of published posts and pages, and number of comments.
Here :

23 specifies the octal 23
*  x23 determine the hex 23.
The custom field is a meta-data that allows you to store arbitrary information in the WordPress post. Through custom field, extra information can be added to the post.
Few positive aspects of WordPress are :
 
* Easy installation and upgrade
* In-built SEO engine
* Easy theme system
* Flexibility
* Multilingual- available in more than 70 languages
* Own data- no unwanted advert on your website
* Flexibility and Easy publishing option
* Create a unique name
* Create the plugin’s folder
* Create a sub-folder for PHP files,  translations, and assets
* Create the main plug-in file and fill in the header information
* Create activation and de-activation functions
* Create an uninstall script
* Create a readme.txt file
* To detect paths to plugin file use proper constants and functions
WordPress offers a huge variety of plugins for maximum flexibility when it comes to creating a website.
 
You can add spam protection, social networking, complex galleries, calendars, forums, and hundreds of other plugins and features.
The features of WordPress are :
 
* User Management
* Media Management
* Theme System
* Extend with Plugins
* Search Engine Optimized
* Multilingual
* Importers
The disadvantages of WordPress are :
 
  * Using several plugins can make website heavy to load and run.
 
  * PHP knowledge is required to do modification or changes in the WordPress website.
 
  * Sometimes software needs to be updated to keep the WordPress up to date with the current browsers and mobile devices. Updating of WordPress version leads to loss of data so it requires the backup copy of website.
 
  * Modifying and formatting the graphic images and tables is difficult.
Posts and Pages are the two content types in WP.

* Posts are timed and listed in chronological order with the latest posts at the top. Posts are meant to be shared and commented on.
 
* Pages are static are static content, so an about us, contact us page etc. They are permanent and timeless entries.
One of the major differences between wordpress.com and wordpress.org is who is hosting the website. i.e., in WordPress.org, a user can host their own blog or website. There is free WordPress software in WordPress.org that can be downloaded and installed on your own web server. But in WordPress.com, it takes care of all of the hosting parts, meaning the user needs not to have to download software, manage a web server, or pay for hosting.
 
* A developer will get a full domain on WordPress.org but only a sub-domain using WordPress.com.
* WordPress.com has many limitations compared to WordPress.org.
* Its user does not own content on WordPress.com, but the content will be own when using WordPress.org.
* People consider them more seriously when they use WordPress.org than WordPress.com.
WordPress Plugins are a bit of code that contains at least one capacities written to stretch out and add to the usefulness of a current WordPress site.
 
WordPress development plugins are the key highlights for developers while building up the WordPress sites, these plugins assume an imperative job in configuration reason, realistic reason, nearly in each angle. WordPress offers free, premium plugins.
 
The center of WordPress is intended to be lean and lightweight, to augment adaptability and limit code swell. Plugins at that point offer custom capacities and highlights so every client can tailor their site to their particular needs.
 
The following is the rundown of plugins that accompanies WordPress establishment.
 
* Akismet
* JetPack
* Yoast SEO
* Social media sharing plugins
* iThemes
* All In One SEO
* Contact form 7
* Posts and Pages
* Sliders and Widgets plugins
* User Registration
* WooCommerce
* W3 Total Cache
Hooks enable users to create WordPress themes or plug-ins with shortcode without changing the original files.
 
There are two types of hooks :
 
Action hooks : Action hooks facilitate you to insert an additional code from an outside resource.
 
Filter hooks : Filter hooks facilitate you to add content or text at the end of the post.
Following are the reasons to use MySQL with WordPress :
 
* Open source
* Extremely fast
* A widely available database server
* Supported by low-cost Linux hosting
At present version, there are about 11 tables in WordPress by default. You can check the number of tables in WordPress by phpMyAdmin.
 
* wp_commentmeta
* wp_comments
* wp_links
* wp_options
* wp_postmeta
* wp_posts
* wp_terms
* wp_term_relationships
* wp_term_taxonomy
* wp_usermeta
* wp_users
The Quick Draft is a mini post editor allows writing, saving and publishing post from admin dashboard. It includes the title for the draft, some notes about your draft and save it as a Draft.
The WordPress News widget displays the latest news such as latest software version, updates, alerts, news regarding the software etc from the official WordPress blog.
This section gives overview of your blog's posts, number of published posts and pages, number of comments. When you click on these links, you will be taken to the respective screen. It displays the current version of running WordPress along with currently running theme on the site.
The Activity widget includes latest comments on your blog, recent posts and recently published posts. It allows you to unapprove or approve the comment, reply to the comment, editing the comment or you can delete the comment or move it to spam.
Yes, WordPress does use cookies. These cookies serve to verify the users who log into your website. Therefore, with WordPress, you will have the option to link Google Analytics to the web domain in order to collect data about the traffic coming to your website which you can subsequently analyze, using that information to make informed decisions about the future of your website.
While in all likelihood by now the candidate would have made mention of this, the question serves to guarantee that the person you are interviewing is clear on the technicalities of certain metadata functions in WordPress.
 
A meta tag is defined as keywords or descriptions whose primary purpose is to display information that orients a user on what a website or page is for.
A parent theme is one that constitutes a larger, more developed WordPress theme. They are equipped with a host of web design characteristics and functionalities.
A child theme refers to a parent theme whose functionalities, style, and design has been modified.
In simple terms, a WordPress template tag is a code that instructs WordPress to carry out an action. This may take the shape of retrieving a batch of information from a particular WordPress database source or any other type of action that you may require from the CMS.
You can call a constructor for a parent class by this way :
Parents:: constructor($value)
These are some situations when WordPress is not recommended:
 
* If the client is working on the non-CMS based project.
* For sophisticated and innovative e-commerce sites.
* Sites which require custom scripting solutions.
No doubt WordPress is good CMS, but Drupal and Joomla are considered better CMS than WordPress to work.
The simplest way to describe a taxonomy when speaking about WordPress technical interview questions is by saying that it is a way to group things together.
 
Default taxonomies in WordPress are Category, Tag, Link Category, Post Formats.
 
However, you don’t have to limit yourself to default taxonomies; you are free to create custom ones as well.
The writing settings controls WordPress writing experience and provides options for customizing WordPress site. These settings control WordPress's features in the adding and editing posts, Pages, and Post Types, as well as the optional functions like Remote Publishing, Post via e-mail, and Update Services.
With the help of tags, similar posts can be grouped. Hence, it makes more comfortable for the users to search for a particular post. Tags are similar to categories but still different.
You should follow these steps :
 
* Install security plugins like WP security
* Re-install the latest version of WordPress
* Change password and user-ids for all your users
* Check your themes and plug-ins are up to date
To disable comments in WordPress, Please follow below steps
 
Step 1 : Login to your WordPress admin panel.
Step 2 : Go to the Settings menu.
Step 3 : Under Settings menu click on Discussion.
Step 4 : Uncheck Allow people to post comments on new articles. checkbox
Step 5 : Click on save changes button, you done
You can edit WordPress comment using the dashboard. From the panel, under the Comments option, select edit to edit a comment.
Comments by visitors on a post are not published directly unless the admin provides it. It is called moderation. To change comment moderation setting, select Settings option from the dashboard and check the option "Comment must be manually approved."
WordPress Categories are broad-ranging. It helps a user to identify about a blog. It is possible for a post to have more than one category. A post must have at least one category.
 
WordPress Tags are like categories, but they are used to describe a post more specifically. Tags are not necessary for every post.
WordPress user role determines access permission to the users of a WordPress site.
 
Administrator : They have full rights over a site.

Editor :
They deal with the content section of a website.

Author :
They only deal with their posts. They can delete their post even after publishing.

Contributor :
A contributor doesn't have the right to publish their post or page. They need to send it to the administrator for review.

Subscriber :
Users who are subscribed to your site can log in and update their profile.

Follower :
They don't have any right. They can only read and comment on your post.

Viewer :
They can only read and comment on a post.
In WordPress, Importers are plugins that provide the functionality to import a bulk XML file with any number of records. It enables to import Posts, Page, Custom Posts and Users data in an XML file.
Below are list of some Filter hooks functions :
* has_filter()
* add_filter()
* apply_filters()
* apply_filters_ref_array()
* current_filter()
* remove_filter()
* remove_all_filters()
* doing_filter()

Below are list of some Action hooks functions :
* has_action()
* add_action()
* do_action()
* do_action_ref_array()
* did_action()
* remove_action()
* remove_all_actions()
* doing_action()
With the help of a WordPress theme, you can design the layout and appearance of your website in the front-end.
WordPress theme should complement your site. It can be either free or paid. An ideal theme should have qualities like simple, responsive, supports plugins, SEO friendly.
Custom themes are very straightforward to format. You don't need much technical knowledge to change in the coding part. The custom theme allows for SEO search, but with an SEO plugin available it would not make much difference to a normal theme.
Free and premium WordPress themes are different in many ways. With free themes, you have to compromise with the quality as many other sites using the same theme. Problems in premium themes solved more quickly than in free themes.
Some WordPress users want their WordPress installation to be more than a blog site. To give their page a look more like a real website page some users use static front page.
To create a contact form in WordPress, you can use a plugin like Gravity forms or also you can use a free plugin contact form 7.
While using a widget, you have to ensure whether your theme supports the widget and if it does then, it must show the sidebar.  If in any case if it happens that you don’t see the sidebar, then it might be missing the “function.php” file or file similar to that.  This can also happen if you have forgotten to save the changes in the widget or to refresh the older display of the page.
No, de-activated plugins cannot slow down the WordPress site.  Wordpress only loads the active plugins and ignores everything else.
We cannot recommend WordPress in the following situation :
 
* If the client is working on a non-CMS base project
* If a site wants complex or innovative e-commerce
* In case of enterprise intranet solution
* Sites are requiring custom scripting solutions.
This option uses email address to create post for you and publishes posts on your blog by email. To use this, you'll need to set up a secret e-mail account with a POP3 access, and any mail received at this address will be posted.
In WordPress template tags are PHP functions that are used to display information dynamically or customize blog template.Below are the list of some generally used template tags in WordPress :

* get_header()
* wp_register()
* get_sidebar()
* wp_title()
* wp_enqueue_script()
* get_the_author()
* wp_list_authors()
* category_description()
* get_bookmarks()
A theme is an external effect of a website's presentation and designing. Whereas, a plugin is an interior effect which adds or remove some functions to a site.
 
You can customize some functionality in themes instead of installing the plugin, but plugins can't replace themes.
You should always update your site to the latest version of WordPress. Whenever there is a new WordPress version, you receive an update message on your admin screen.
 
There are two methods to update a WordPress site :
 
* One-click update
* Manually update
Security in a WordPress site is essential as these websites are favorite targets for hackers. A site can't be perfectly secured, but one can at least reduce the risk by applying different security measures.
 
Some of the measures to secure a WordPress site are given below :
 
* Choosing a host
* Strong password
* 2 step login authentication
* Limit number of login attempts
* Use SSL
* Keep site updated
If you forget or lost the password of your account, WordPress gives you an option to reset it through different methods.
 
There are four ways to reset WordPress password :
 
* Change password from the dashboard
* Reset password via email
* Manually reset the password through database via PhpMyAdmin
* Using emergency password reset script
Optimization increases the speed of your site and gives the best possible outcome. It improves the ranking of a website.
 
There are many tricks to optimize a WordPress site. Some of them are given below :
 
* Use CDN
* Use a caching plugin
* Use a simple theme/framework
* Keep site updated
* Split long posts into smaller pages
Meta-tags are keyword and description used to display website or page information.
The user metafunction is used to retrieve the metadata of users. It can return a single value or an array of metadata.
 
Syntax is : get_user_meta( int $user_id, string $key = '', bool $single = false )
 
User id is the required user id parameter
 
Key is the optional parameter which is the meta key to retrieve. By default, it returns data for all key values.
 
Single is an optional parameter that tells whether the single value will return. By default, it is false.
Permalink is a permanent link to a particular blog post or category. It allows setting the default permalink structure. These settings are used to add permalinks to your posts in Wordpress.
A backup is just the copy of your original site through which you can restore your original site if anything goes wrong. Keeping a backup on the safe side is always advisable.
 
A site is generally made up of two parts. One is all the installed themes/plugins, media and other is Database which stores all your blogs, posts, and comments. Without files, there is no site, and without the database, there is no data. Hence both of them is important and need a backup.
Backup allows you to retrieve your site back if something goes wrong or if your site breaks. There could be many reasons for this like external attack, hacking, server down.
 
You can lose everything from data to all the posts on your site. The backup is essential to avoid it.
 
Securing your backup is also an important issue. Make sure to update your plugins and themes regularly or in a specified interval. Use strong Username and Password. Database name should also be uncommon.
There are many files in your WordPress directory. These files can be downloaded back from wordpress.org site. Some of them can be retrieved back but some can't.
 
The wp-content directory contains all your installed themes and plugins including all your media files like images, audio or video files which you uploaded on your site. Hence, it makes it personal and unique.
 
The wp-config.php file consists of your Database and other personnel options which make it also a unique file.
 
Both the above files can't be replaced by other default files. Hence, they need to be backed up.
In the database, all your posts, media files, comments, and metadata stored. It also contains user's information and all your plugin settings. All these information are personal and unique. If you lose them, they are gone permanently. Select your WordPress database (which you created during the installation of WordPress).
 
* Click on Export.
* Quick is used when the database is small. Custom is used when the database is large. Suppose we are choosing Custom.
* After choosing Custom, a table appears. Select all the tables.
* Now come to the Output section.
* Choose SQL from the Format drop-down menu.
* Check "Add drop table." It is useful for overwriting an existing table.
* Check "If not exists." It prevents errors when tables are already there.
* Now click Go. Your data will be saved in your system.
67 .
GNU is a General Public License (GPL). This comes with some terms and conditions for copying, modifying, and distributing the software licensed under its name. GNU ensures that any software source code licensed under it has to make originating source code open and freely available to all its users. However, freely here means that it is freely available to users for distributing and modifying the code, but they can't impose any restrictions on further distribution, the source code has to be made available.
For enabling debug mode in WordPress, developers have to edit the wp-config.php file and modify the WP_DEBUG constant value to true condition. For enabling debug mode in WordPress, developers have to edit the wp-config.php file and modify the WP_DEBUG constant value to true condition.