Want a free year on Tuts+ (worth $180)? Start an InMotion Hosting plan for $3.49/mo.
In this video tutorial, we'll be building a custom Content Management System (CMS) using PHP and MySQLi. We'll start off by pulling our content from a MySQL database and then build a CMS admin panel to manage our content. For easy content management, we will be using TinyMCE as our editor. I hope you enjoy the screencast.
- So we started out with a simple HTML layout
- We put all our content in a MySQL database
- We pulled our content from the database into our website using some PHP
- We built a custom CMS with the help of TinyMCE to edit our content
- We made our CMS functional
- We are done! Congrats!
I realized that in the preview at the beginning of the tutorial, the sidebar also had some user controls - including "Preview Website" and "Log Out". The code for that is below:
<?php echo "<h4>User Controls</h4>"; echo "<ul>"; echo "<li><a href='index.php' target='_blank'>Preview Website</a></li>"; echo "<li><a href='login.php?status=loggedout'>Log Out</a></li>"; echo "</ul>"; ?>
Another configuration option for TinyMCE you might be interested in is:content_css: "sources/styles.css"
Add that inside your TinyMCE configuration and set the value to your stylesheet. With that, all the HTML that gets loaded in the TinyMCE editor will use your stylesheet. SO if your background color is black, the editor will display a black background as opposed to the default, white. It's just an easier way for you to see and edit your content.