Difference between revisions of "Custom Modules"

From AWBS Wiki
Jump to: navigation, search
(Custom Payment Processors)
Line 1: Line 1:
If you would like to create a module for a payment gateway, hosting control panel or registrar that is currently unsupported (not integrated) in AWBS, you will first need our devkit (available upon request).
+
If you would like to create a module for a payment gateway, hosting control panel or registrar that is currently unsupported (not integrated) in AWBS, you will first need our devkit (available in the download area where you purchased (or lease) AWBS).
  
  
Line 11: Line 11:
 
* Payment gateways (such as paypal)
 
* Payment gateways (such as paypal)
  
== Custom Registrar Module ==
 
  
== Custom Hosting Control Panel Module ==
 
 
=== Built in Variables ===
 
 
Most available $params are set as:
 
 
*$params['uname']= Username for new account (This is the username that will be used by the Hosting Panel)
 
*$params['pass']= Password for new account (This is the password that will be assigned to the above username)
 
*$params['ownerid']= Users AWBS username
 
*$params['userid']= Users ID in users table
 
*$params['term']= Term for new account
 
*$params['seed']= Package identifier (OrderID)
 
*$params['cTld']= TLD
 
*$params['cSld']= SLD
 
*$params['realdomain']= If idn, the encoded domain SLD (you should always use this variable);
 
*$params['idn']= Is IDN ( 1 or 0 )
 
*$params['idnname']= idn name;
 
*$params['idndomain'] = "$idnname.$cTld";
 
*$params['cpid']= Package ID
 
*$params['plan']= Local plan name
 
*$params['realplan']= Server plan name
 
*$params['servernewip']= IP
 
*$params['server']= Server
 
*$params['servertype']= Server type
 
*$params['domain']= Full domain name;
 
*$params['dns1']= dns1
 
*$params['dns2']= dns2
 
*$params['dns3']= dns3
 
*$params['dns4']= dns4
 
*$params['uemail']= Users email;
 
*$params['regtype']= Queue type
 
 
You can also create your own variables and pull information directly from the AWBS Database.  Example: <br />
 
$this_user = sqlarray("select id,fname,lname from users where username='".$params['ownerid']."'");
 
 
=== Starting your Custom Module ===
 
 
Download the V3 devkit from http://www.awbs.com or your authorized reseller.
 
 
For creating a custom hosting module you will need to use the file yourmodulenamev3.php from the /hosting/includes/yourmodulename folder of the zip.
 
 
Save this file somewhere that you can access it.  Rename it to what you would like to name your module.  You '''MUST''' keep the v3 at the end of the file name.  Example: cpanelv3.php
 
 
Open the file for editing.
 
 
You will notice that there is already predefined functions created.  These are ONLY an example and will not work out of the box.
 
 
==== Defined Functions ====
 
 
=== Package Specifics ===
 
 
==== Using Custom Fields in Package Specifics ====
 
 
=== Example Functions ===
 
  
 
== Custom Forum Module ==
 
== Custom Forum Module ==

Revision as of 17:52, February 2, 2009

If you would like to create a module for a payment gateway, hosting control panel or registrar that is currently unsupported (not integrated) in AWBS, you will first need our devkit (available in the download area where you purchased (or lease) AWBS).


Adding/creating a Custom Module

Custom modules can be added for;

  • Domain registrars
  • Hosting control panels
  • Offsite credit card processor (customer is taken to processor for cc information/payment)
  • Onsite credit card processor (customer enters cc information on your website)
  • Payment gateways (such as paypal)


Custom Forum Module

Edit the user_forums.php file in the includes/forum directory with your custom forum account create code.

In the AWBS Configuration area, enter the Forum Setup Configuration page. Select Custom Forum 1 as your Forum Type. Complete all configuration fields as per your forum software/installation.