Wp_options stores the option settings you choose for WordPress. This includes theme option settings. Wp_links stores information about your links. The name, URL, and description of links is stored in this table. Wp_comments stores the body of comments that are published on your site, such as the comment content, the date, the status of the comment, etc. Wp_commentmeta stores all comments that are published on your site, as well as metadata such as a comment ID number. When WordPress is installed on your server, eleven tables are added to your database that will store data from your website.
The fact is that you don't have to deal with the database if you don't want. It's only when you're developing a theme, plug-in, or adding code to a WordPress project that you really need skills with MySQL. That doesn't mean you can't become a little more familiar with it, though, so you can gain an understanding of exactly how your site works behind the scenes. That familiarity is what we're going to give you. But add a database to the equation and, all of the sudden, it seems like a programming nightmare best left to professionals. After all, it's fairly easy to build simple websites with a little HTML and CSS thrown in. If you're not a database administrator by trade, it can seem like a scary thing to tackle. Get_info() is the tag function. It grabs the data that will be delivered to your site. What data will be grabbed depends on what tag function is between the two PHP commands.ĭon't be scared of the MySQL database. The first part tells PHP to start. means to stop PHP. This tag tells WordPress that we want to do three things.ġ. Between the tags in PHP is the request that goes to the database that lets WordPress know what data (content) needs to be displayed in a visitor's web browser.Ī template tag – or function – in PHP looks like this: A comparison to this is HTML where a HTML script starts with and ends with. The PHP script is enclosed in tags. These tags start and end PHP. PHP and MySQL are partners in crime, so to speak. They go together. They work together.
The difference is that PHP is used to retrieve information from a MySQL database. PHP is a scripting language that's used to create web pages, much like HTML or CSS. Your content for your site is stored in your MySQL database, which is part of your hosting account. WordPress operates on a PHP/MySQL platform. However, PHP and MySQL are too large of topics to teach in a WordPress article, especially since in-depth knowledge of them is not required.Įarlier in this article, we talked about your MySQL database. That said, this isn't a PHP or MySQL article. We're going to provide an overview of PHP and MySQL so you gain a basic understanding of both in regards to how they function with WordPress. It's the only way to remove all the limitations you may face based on experience, and be able to create the site you want.
WordPress doesn't require you to know how to write CSS, HTML, or PHP. We've said that before, and it's true. However, you need some knowledge of it if you want to create a website that looks exactly as you want it to.