Plugging in non-Drupal components: PHP and JavaScript TreeGrids and Charts

jeff00seattle - March 7, 2009 - 22:50

Hi

I have already developed some complex components in PHP or JavaScript, outside of Drupal, that do exactly what I need.

I really have found this week using Drupal great!!!

However, I have some (DataGrids, TreeGrids, and Charts) components that I refined over the years and I do not want to redevelop in Drupal.

All are data-driven through direct connection to MySQL, and all are either written either purely in PHP or JavaScript.

So, what is the best approach for me to drop in these components where by there are:

  1. Overall, the Drupal has control of everything within a theme, and even user role access of who may view to my dropped-in components. And Drupal has control of data-driven needs with MySQL.
  2. I maintain my already developed components in either PHP or JavaScript, and I control my data-driven needs with MySQL (maintaining my data-models (complex queries involving stored-procedures).

Thanks for any assistance on how I should best proceed would be greatly appreciated,

Jeff in Seattle

best approach is to build a

sivkannan77 - March 8, 2009 - 02:06

best approach is to build a drupal module to which wraps the drupal functionality like using required hooks _menu etc. and from the call back function call all your components function by including your php file in the module, further if possible or if required you can change the php sql code to drupal sql codes but it is not must. for reference you can also refer some module which have developed in the same way as ur requirement (swfObject_api module)

 
 

Drupal is a registered trademark of Dries Buytaert.