Welcome Guest. Please Login or Register  


You are here: Index > Softaculous Auto Installer > General Support > Topic : Problem with custom script auto install in whmcs



Threaded Mode | Print  

 Problem with custom script auto install in whmcs, Cannot auto install custom script in whmcs (5 Replies, Read 4658 times)
creas
Group: Member
Post Group: Newbie
Posts: 3
Status:
Hi,
I created a basic package which is expected to install a php file. I have zipped its custom script folder and attached in this post and the softaculous_extra.php file.

I follow all step by step in these addresses:

http://www.softaculous.com/docs/Making_Custom_Package
http://www.softaculous.com/docs/Adding_Custom_Scripts
http://www.softaculous.com/docs/WHMCS_Auto_Install_Module

but cannot succeed.

Packages by Softaculous work fine in the system. Everything is OK. I should miss something about custom packaging.

Sincerely...
IP: --   

Problem with custom script auto install in whmcs
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

The <settings> tag in the install.xml was missing. We need to add atleast some dummy data to the settings tag in the install.xml to execute the install.php which imports the database. I have added it and attached the install.xml here.

Make sure that the package is unzipped in the scripts folder itself and not in the sub-directory. Eg :
/var/softaculous/abc/abc.zip

And regarding the WHMCS auto install module please make sure that the custom script field name for WHMCS product are exactly "Script", "Admin Name", "Admin Pass" and "Directory". If you are using any other field name you will have to add it to the softaculous_extra.php

Also please confirm that the custom script was added from the WHM where you are creating the account via WHMCS.  Verify that the port 2083 is open.

You can also upload the softaculous_debug.php and post the logs from WHMCS -> Utilities -> Logs -> Activity Logs


-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

Problem with custom script auto install in whmcs
creas
Group: Member
Post Group: Newbie
Posts: 3
Status:
Thank you for your clear guide. I tried what you said, but still have problems. Let me explain it:

1) Wordpress, phpBB and others are being perfectly installed by WHMCS-Softaculous Auto Install. Everything is fine.

2) I uploaded the custom package under /var/softaculous/abc as:

Code

root@server [/var/softaculous]# ls -l  /var/softaculous/abc
total 44
drwxr-xr-x. 3 root root  4096 Feb 24 11:28 ./
drwxr-xr-x. 8 root root 12288 Feb 24 10:39 ../
-rw-r--r--. 1 root root  298 Feb 24 11:28 abc.sql
-rw-r--r--. 1 root root  149 Feb 24 11:28 abc.zip
-rw-r--r--. 1 root root    9 Feb 24 11:28 fileindex.php
drwxr-xr-x. 2 root root  4096 Feb 24 11:28 images/
-rw-r--r--. 1 root root  697 Feb 24 11:28 info.xml
-rw-r--r--. 1 root root  102 Feb 24 11:28 install.php
-rw-r--r--. 1 root root  249 Feb 24 11:28 install.xml


3) abc.zip includes just: index.php (After extraction, there is no folder "abc").

PHP Code

 echo "Hello Softaculous!"



4) abc.sql is:

Code

SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
SET time_zone = "+02:00";

CREATE TABLE IF NOT EXISTS `abc` (
  `id` int(11) NOT NULL AUTO_INCREMENT,
  `abc` varchar(127) COLLATE utf8_unicode_ci NOT NULL,
  PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=1 ;


5) fileindex.php is:

Code

index.php


6) info.xml is:

Code

<soft xmlns="http://www.softaculous.com">
    <overview>
        <img src="abc.png" style="float:right;margin:10px;" alt="" />{{overview}}
    </overview>
    <demo>
        http://www.example.com.tr
    </demo>
    <space>
        10000000
    </space>
    <support>
        http://www.example.com.tr
    </support>
    <version>
        0.1.0
    </version>
    <release_date>01-02-2014</release_date>
    <softversion>
        4.4.4
    </softversion>
    <languages>
        <english-overview>
            ABC CMS
        </english-overview>       
        <english-features>
            <ul>
                <li>Simple CMS</li>
            </ul>
        </english-features>
    </languages>
</soft>


7) install.php is:

PHP Code

 function __install() {
    global 
$software;
    
sdb_import($software['softname'] . '.sql');




8) install.xml is:

Code

<softinstall xmlns="http://www.softaculous.com">
    <settings>   
        <group>
            <heading>hidden</heading>
            <input type="hidden" name="dummy" value=""></input>
        </group>
    </settings>
    <db>mysql</db>
</softinstall>


9) cscripts.php says:

PHP Code

 $cscripts = array(10001 => array('name' => 'ABC',
                            
'softname' => 'abc',
                            
'desc' => 'ABC - Test',
                            
'ins' => 1,
                            
'cat' => 'others',
                            
'type' => 'php',
                            
'ver' => '0.1.0'
                            
)
            ); 





10) softaculous_extra.php is:

PHP Code

 $softaculous_conf['protocol'] = 'http://www.';
$softaculous_conf['user_mod_dir'] = 0//Set this to 1 if you want to use User MOD Dir. If enabled the script will be installed at http://IP/~username
$softaculous_conf['overwrite_existing'] = 0//Set this to 1 if you want to overwrite the files and install the script forcefully. If enabled the script will be installed even if the files already exists
$softaculous_conf['use_special_chars'] = 0// Set this to 1 if you wish to use special characters for randomly generated usernames and passwords

$add_softaculous_scripts = array(10001 => array('name' => 'ABC',
                            
'softname' => 'abc',
                            
'desc' => 'ABC - Test',
                            
'ins' => 1,
                            
'cat' => 'others',
                            
'type' => 'php',
                            
'ver' => '0.1.0'
                            
)
            ); 




11) Port 2083 is open.

12) "Script", "Admin Name", "Admin Pass" and "Directory" are OK.

13) With softaculou_debug.php file, there are no errors in the logs as you mentioned,  WHMCS -> Utilities -> Logs -> Activity Logs. It says, "Module Create Successful" as regularly.

And finally,
the directory of the product domain is empty. There is no "index.php" or no database is created.


Sincerely...

IP: --   

Problem with custom script auto install in whmcs
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

Can you please provide the WHMCS admin account details and the FTP details via Support ticket we will check it for you.

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

Problem with custom script auto install in whmcs
creas
Group: Member
Post Group: Newbie
Posts: 3
Status:
Thank you.
I have just opened the ticket with necessary credentials.
IP: --   

Problem with custom script auto install in whmcs
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5652
Status:
Hi,

We have replied to your ticket and as your confirmed the issue was resolved.

The issue was due to the variables not being passed when the softaculous_extra.php is included.
Downloading the latest files should resolve the issue :
http://www.softaculous.com/docs/WHMCS_Auto_Install_Module#Download_and_Upload

-----------------------
Webuzo - Multi User Hosting Control Panel
AMPPS - Best WordPress/PHP/MySQL development tool
IP: --   

« Previous    Next »

Threaded Mode | Print  



Jump To :


Users viewing this topic
1 guests, 0 users.


All times are GMT. The time now is April 24, 2024, 2:15 am.

  Powered By AEF 1.0.8 © 2007-2008 Electron Inc.Queries: 11  |  Page Created In:0.031