How WordPress Works WP Behind the Scenes

WordPress is a Content Management System (CMS) that powers 63.3% of all websites that use CMSs, and a quarter of all websites in the world, not to mention 48% of Technorati's Top 100 Blogs. This article is for people who are new to WordPress or even as long-time users are looking to understand more about how WordPress works behind the scenes to make your website function the way you way.

Also read: A Quick Lesson in WordPress Vocabulary

WordPress needs two components to work on your webserver: PHP and MySQL. Before we dig into what that means and what it's for, here's a simplified context of how the web works:

When you type a domain name into your browser's address bar, it looks up the address of the server on which the domain name lives. (This is known as an IP address, all machines connected to the internet have one, including your computer right now.) Then it connects to that server and requests the path specified after the domain name. So if you enter http://www.example.com, the path name is '/', and if you enter http://www.freshwpthemes.com/collections, the path is /collections, and so on.

Now, these paths can be folders, or they can be files, or, if the information listed in that path is dynamic (that is, it doesn't stay the same over time), it can be accessed and built from a database according to certain criteria whenever the path is requested.

Today nearly all pages on the web are dynamic. You might think that your article is static content, but what about comments on it? What about the sidebar or header? All these elements require dynamic rendering, and that's where a CMS like WordPress comes in.

PHP (PHP Hypertext Preprocessor) is the language WordPress is written in, and it is what makes WordPress dynamic. PHP is a server-side language, that is, it runs on your web server before a page is server to the browser/client, and is one of the most popular languages on the web today, in part due to the popularity of WordPress itself! PHP is great at adding information to databases and extracting information from them based on given criteria, and can then be used to insert that information into an HTML page.

MySQL is an open-source relational database management system (RDBMS), which, just to keep things simple, can be imagined as working like a complex spreadsheet which files data under multiple related headings. The database has users which have access to the data, and data of all kinds can be created, updated, read and deleted (CRUD) on the database. MySQL is the second most used RDBMS in the world, and is extremely fast at responding to queries even over millions of items.

WordPress is a CMS that works on three levels: 

1.    It provides an easy interface (known as dashboard) for website owners to manage their content database (without even having to know that this is what they are doing!)

2.    It creates MySQL queries for the database, receives the information and publishes the page containing the required data on the path when it is requested by a browser.

3.    It provides additional capability in the form of themes, plugins and shortcodes so that features that are not built into WordPress but desired by a website owner can be added by anyone who knows PHP and studies WordPress code.

To accomplish this, WordPress can be accessed on three levels as well:

1.    The user-facing website that is accessed whenever someone visits a path handled by WordPress, be it a blog, a page or a list.

2.    The admin area – also known as Dashboard. This is accessible whenever you log-in to WordPress as an administrator.

3.    WordPress's own files on the server – these contain the files with the actual WordPress code (known as the Core) lives, along with theme files, plugin files, CSS etc.

Congratulations, you just graduated from being a WordPress newbie to knowing what functions WP is performing behind the scenes to make your website work. To learn more, install WordPress on your computer and start playing!

 

Share:

Post Comment

Tags allowed: <a>,<strong>, <blockquote>.