My First PHP/WordPress Hybrid


My Capstone project for my Master’s degree is called Car-Mds. It stands for Car Doctors. It is a website that I eventually plan to make money from. I designed it from an SEO/Business-building standpoint. I wanted the comfort of regular PHP, but also add some WP elements. I found that there isn’t alot of hybridization going on with WP and regular PHP pages (also called non-WP pages). I found that I was treading on new ground.

I came across a problem I had with attempting to create a login system. I wanted to have one login control every aspect of the website, so a user can post on the blog/forum as well as view the “protected” content only viewable by users with an account. I built an awesome PHP login and made the tables in MySQL using regular PHP.

I soon realized that I had a dilemma. I could log in to the site and view the protected content, but I couldn’t create a user for wordpress at the same time. I would have had to create some functionality that checked credentials against both the website’s login, as well as the WP users. It became a headache to try to wrap my head around. After many trials and tribulations, I settled on using WordPress’ session/cookie credentials for the entire site. I found that I could easily make non-WP pages post credentials, protect pages, and allow users to sign in via WP. I even found a plugin that would allow users to sign up using their social media credentials (which was my ultimate goal)!

, ,

Leave a Reply

Your email address will not be published. Required fields are marked *