Welcome Guest. Please Login or Register  


You are here: Index > Softaculous Auto Installer > General Support > Topic : Storing custom values?



Threaded Mode | Print  

 Storing custom values? (3 Replies, Read 10504 times)
njolin
Group: Member
Post Group: Newbie
Posts: 5
Status:
Is there a way to store the values being created in a custom script?

In my install.xml I have the following:
<input type="text" name="second_email" size="30" value="" >
    <head>Optional - Second Email Address</head>
</input>

and in my edit.xml:
<input type="text" name="second_email" size="30" value="" >
    <head>Optional - Second Email Address</head>
        <optional>true</optional>
</input>

After the install, if I go to edit the installation details, the edit screen doesn't show my custom value.

I would like to be able to store this value, have it editable, and have it able to be delivered via API when calling for installations (&act=installations).

Is this possible?

Thanks much!
Nick

IP: --   

Storing custom values?
Brijesh
Group: Softaculous Team
Post Group: Super Member
Posts: 5647
Status:
Hi Nick,

You will need to create a custom script for that because if you modify the existing package when there is an update in the script this package will be replaced.

You can use the variables with
Code
[[variable_name]]
in the SQL file if you want to save it in the database. Here variable_name refers to the name of your input tag. In you case it should be
Code
[[second_email]]


You will also get the variable in the
Code
$__settings['second_email']
variable in install.php if you would like to store it in a file.

In order to save this variable in Softaculous records you will need to add the following to your input tag :
Code
save="true"


So your input tag should be :
<input type="text" name="second_email" size="30" value="" save="true">
    <head>Optional - Second Email Address</head>
</input>

In order to edit the value from the edit installation page you will need to modify the edit.php to fetch the value posted and update the required entries. Again you can get the value in the
Code
$__settings['second_email']
variable in edit.php

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

Storing custom values?
njolin
Group: Member
Post Group: Newbie
Posts: 5
Status:
Great!  Thanks for the reply.  I will give this a shot.
IP: --   

Storing custom values?
nikhil89
Group: Softaculous Team
Post Group: Elite Member
Posts: 467
Status:
Hi,

Please let us know if you need any further information.
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 18, 2024, 1:47 pm.

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