Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Integrate a custom php Backend with WordPress

Posted on 2014-07-18
3
Medium Priority
?
794 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 2000 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

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

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…
In order to have all security and back ups taken care of, WordPress users can sign up for services with WP Engine.
The purpose of this video is to demonstrate how to exclude a particular blog category from the main blog page. This is can be used when a category already has its own tab, or you simply want certain types of posts not to show up on the main blog. …
The is a quite short video tutorial. In this video, I'm going to show you how to create self-host WordPress blog with free hosting service.

963 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