Solved

Integrate a custom php Backend with WordPress

Posted on 2014-07-18
3
597 Views
Last Modified: 2014-07-18
Customer has existing Wordpress Site. Customer is Medical / Dental practice.

Wants to add features to the site, including:

Check appointment availability
Make an appointment
Change appointment
Cancel appointment (within 30 days)
Make a payment
Schedule a future payment
Cancel a future payment
Add, remove, or modify payment method
Update contact info
Upload / Update / remove documents (images and pdfs)

A different backend will need to be made for the office staff to edit customer info, appointments, and to print reports.

Can I write custom php code to access a different MySQL database (not the WordPress MySQL) on the back end & integrate it with the Word Press site? Or are there existing WordPress "plugins" that provide this kind of functionality?

Thanks
0
Comment
Question by:Richard Korts
  • 2
3 Comments
 
LVL 70

Accepted Solution

by:
Jason C. Levine earned 500 total points
ID: 40205053
The answer to both questions is yes.  The longer answer is that custom code always works (to the ability of the coder).  Plugins exist for all of the desired functions but you may have issues with the details.  In the end, you will probably do a combination of things (custom and plugins).

Check appointment availability
Make an appointment
Change appointment
Cancel appointment (within 30 days)

Look into BirchPress Scheduler, Booking Calendar & Appointment Scheduler, CP Appointment Calendar, and Booking Calendar.  There are free versions of all of these but they also offer paid versions that have more features including payments.

Make a payment
Schedule a future payment
Cancel a future payment

So the first one of these is fairly easy and any number of plugins (including all of the ones above in the pro versions) can do it. Scheduling future payments is less of a plugin function and something more on the gateway side as you won't be storing the payment data locally (at least you shouldn't be to maintain PCI compliance).  So you need to be working with a gateway that supports storing payment data and then the plugin or script needs to know how to trigger a payment.  

I would also seriously investigate the pro versions of the previously listed appointment calendars as it is possible that one of them does all of this for you.

Add, remove, or modify payment method
Update contact info
Upload / Update / remove documents (images and pdfs)

So now you are getting into user management issues and this starts to get significantly more complicated.

Payment methods are tricky because you don't want to store this data in the WordPress database if you can avoid it and instead make the gateway responsible for the security.  So a lot of how you go forward will be determined by your gateway's capabilities.  If they support it (i.e. Authorize.net), I would look for plugins that work with that Gateway before I would write a script using the gateway's API.  Plugins that spring to mind are WooCommerce and Paid Memberships Pro (caveat: not sure if you can use PMP given the rest of the issues).

The upload/update documents is the simplest of all the requirements...all you need is a good form plugin with upload capability (Gravity, Formidable, Ninja can all do it).
0
 

Author Closing Comment

by:Richard Korts
ID: 40205063
I am unclear on how to integrate custom code with WordPress; can a wordpress menu item just access xyz.php? Do I have to "manually" construct the look & feel of the WordPress theme in the "non-WordPress" pages?

Thanks
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 40205078
can a wordpress menu item just access xyz.php

Yes.  Or you can make a new page template in the theme that has the code for xyz.php and that answers the follow-up question.

http://codex.wordpress.org/Page_Templates#Creating_a_Page_Template

Another way to do it is to call WordPress from your custom pages:

<?php
require('../wp-load.php'); // change this to right path, depends on where the custom pages live.  
get_header(); // This gets the Theme's header
?>

Your page content or other code here.

<?php get_footer(); // This gets the footer ?>

Open in new window

0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

WordPress has made it easy to create scalable sites based on their powerful CMS, but as great as WordPress is, there are some SEO issues that haven’t been addressed out of the box.  Fortunately these problems can be solved with a few plugins.  The f…
I annotated my article on ransomware somewhat extensively, but I keep adding new references and wanted to put a link to the reference library.  Despite all the reference tools I have on hand, it was not easy to find a way to do this easily. I finall…
The purpose of this video is to demonstrate how to reset a WordPress password if you are locked out and cannot reset the password. A typical use would be if you cannot access the email to which WordPress would send the password recovery email to…
The purpose of this video is to demonstrate how to Test the speed of a WordPress Website. Site Speed is an important metric of a site’s health. Slow site speed can result in viewers leaving your site quickly and not seeing your content. This…

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now