about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKelly Rauchenberger <fefferburbia@gmail.com>2008-08-06 01:59:52 +0000
committerKelly Rauchenberger <fefferburbia@gmail.com>2008-08-06 01:59:52 +0000
commit11bb0e1e6e0fd0effa8ab9b9fe02bda3405776a0 (patch)
treedfd8fb08127793b8fed61b8bd172d22107314911
parent4151ceff62e900e4d0bcf7f7a284bce89289b1ce (diff)
downloadinstadisc-11bb0e1e6e0fd0effa8ab9b9fe02bda3405776a0.tar.gz
instadisc-11bb0e1e6e0fd0effa8ab9b9fe02bda3405776a0.tar.bz2
instadisc-11bb0e1e6e0fd0effa8ab9b9fe02bda3405776a0.zip
Update: Completed phpBB3 plugin's ACP
Also used a new method of providing the
subscription file's URL as static text
instead inside a text box. Refs #7
-rw-r--r--update/plugin/phpBB3/trunk/root/adm/style/acp_instadisc.html29
-rw-r--r--update/plugin/phpBB3/trunk/root/includes/acp/acp_instadisc.php11
-rw-r--r--update/plugin/phpBB3/trunk/root/language/en/mods/instadisc.php4
3 files changed, 43 insertions, 1 deletions
diff --git a/update/plugin/phpBB3/trunk/root/adm/style/acp_instadisc.html b/update/plugin/phpBB3/trunk/root/adm/style/acp_instadisc.html index 1322f24..387658a 100644 --- a/update/plugin/phpBB3/trunk/root/adm/style/acp_instadisc.html +++ b/update/plugin/phpBB3/trunk/root/adm/style/acp_instadisc.html
@@ -16,12 +16,39 @@
16 <dd><input name="subscription_title" type="text" id="subscription_title" maxlength="255" VALUE="{S_SUBSCRIPTION_TITLE}" SIZE="40"/></dd> 16 <dd><input name="subscription_title" type="text" id="subscription_title" maxlength="255" VALUE="{S_SUBSCRIPTION_TITLE}" SIZE="40"/></dd>
17 </DL> 17 </DL>
18 <DL> 18 <DL>
19 <DT>
20 <LABEL FOR="subscription_file">{L_SUBSCRIPTION_FILE}</LABEL>
21 <BR><SPAN>This is the URL of your subscription file</SPAN>
22 </DT>
23 <DD>{S_SUBSCRIPTION_FILE}</DD>
24 </DL>
25 <DL>
19 <dt><label for="central_server">{L_CENTRAL_SERVER}:</label><BR> 26 <dt><label for="central_server">{L_CENTRAL_SERVER}:</label><BR>
20 <SPAN>This is the Central Server's XML-RPC URL. They should have provided this for you in an email and also on their site. </SPAN> 27 <SPAN>This is the Central Server's XML-RPC URL. They should have provided this for you in an email and also on their site. </SPAN>
21 </dt> 28 </dt>
22 <dd><input name="central_server" type="text" id="central_server" maxlength="255" VALUE="{S_CENTRAL_SERVER}" SIZE="40"/></dd> 29 <dd><input name="central_server" type="text" id="central_server" maxlength="255" VALUE="{S_CENTRAL_SERVER}" SIZE="40"/></dd>
23 </dl> 30 </dl>
24 31 <DL>
32 <DT>
33 <LABEL FOR="central_server_username">{L_USERNAME}</LABEL>
34 <BR><SPAN>Enter the username you registered for at your Central Server</SPAN>
35 </DT>
36 <DD><INPUT NAME="central_server_username" TYPE="text" ID="central_server_username" MAXLENGTH="255" VALUE="{S_USERNAME}" SIZE="40"></DD>
37 </DL>
38 <DL>
39 <DT>
40 <LABEL FOR="central_server_password">{L_PASSWORD}</LABEL>
41 <BR><SPAN>Enter the password to go with the username above</SPAN>
42 </DT>
43 <DD><INPUT NAME="central_server_password" TYPE="password" ID="central_server_password" MAXLENGTH="255" VALUE="{S_PASSWORD}" SIZE="40"></DD>
44 </DL>
45 <DL>
46 <DT>
47 <LABEL FOR="central_server_activation">{L_ACTIVATION}</LABEL>
48 <BR><SPAN>After submitting your subscription for sponsership at your Central Server, it should provide you with an Activation Key</SPAN>
49 </DT>
50 <DD><INPUT NAME="central_server_activation" TYPE="text" ID="central_server_activation" MAXLENGTH="255" VALUE="{S_ACTIVATION}" SIZE="40"></DD>
51 </DL>
25 </fieldset> 52 </fieldset>
26 <p class="submit-buttons"> 53 <p class="submit-buttons">
27 <input class="button1" type="submit" id="submit" name="submit" value="{L_SUBMIT}" />&nbsp; 54 <input class="button1" type="submit" id="submit" name="submit" value="{L_SUBMIT}" />&nbsp;
diff --git a/update/plugin/phpBB3/trunk/root/includes/acp/acp_instadisc.php b/update/plugin/phpBB3/trunk/root/includes/acp/acp_instadisc.php index 9ca3b81..bd1965c 100644 --- a/update/plugin/phpBB3/trunk/root/includes/acp/acp_instadisc.php +++ b/update/plugin/phpBB3/trunk/root/includes/acp/acp_instadisc.php
@@ -32,15 +32,26 @@ class acp_instadisc
32 // Add config to the database 32 // Add config to the database
33 set_config('id_subscription_title', $_POST['subscription_title']); 33 set_config('id_subscription_title', $_POST['subscription_title']);
34 set_config('id_central_server', $_POST['central_server']); 34 set_config('id_central_server', $_POST['central_server']);
35 set_config('id_username', $_POST['central_server_username']);
36 set_config('id_password', $_POST['central_server_password']);
37 set_config('id_activation_key', $_POST['central_server_activation']);
35 38
36 trigger_error('The changes you made to your InstaDisc settings have been saved!' . adm_back_link($this->u_action), E_USER_NOTICE); 39 trigger_error('The changes you made to your InstaDisc settings have been saved!' . adm_back_link($this->u_action), E_USER_NOTICE);
37 } else { 40 } else {
38 $idst = isset($config['id_subscription_title']) ? $config['id_subscription_title'] : $config['sitename']; 41 $idst = isset($config['id_subscription_title']) ? $config['id_subscription_title'] : $config['sitename'];
39 $idcs = isset($config['id_central_server']) ? $config['id_central_server'] : ''; 42 $idcs = isset($config['id_central_server']) ? $config['id_central_server'] : '';
43 $idun = isset($config['id_username']) ? $config['id_username'] : '';
44 $idps = isset($config['id_password']) ? $config['id_password'] : '';
45 $idak = isset($config['id_activation_key']) ? $config['id_activation_key'] : '';
46 $idsf = $config['server_protocol'] . $config['server_name'] . $config['script_path'] . '/subscription.php';
40 47
41 $template->assign_vars(array( 48 $template->assign_vars(array(
42 'S_SUBSCRIPTION_TITLE' => $idst, 49 'S_SUBSCRIPTION_TITLE' => $idst,
43 'S_CENTRAL_SERVER' => $idcs, 50 'S_CENTRAL_SERVER' => $idcs,
51 'S_USERNAME' => $idun,
52 'S_PASSWORD' => $idps,
53 'S_ACTIVATION' => $idak,
54 'S_SUBSCRIPTION_FILE' => $idsf,
44 'S_SUBMIT' => $this->u_action 55 'S_SUBMIT' => $this->u_action
45 )); 56 ));
46 } 57 }
diff --git a/update/plugin/phpBB3/trunk/root/language/en/mods/instadisc.php b/update/plugin/phpBB3/trunk/root/language/en/mods/instadisc.php index a9d51a8..17880f5 100644 --- a/update/plugin/phpBB3/trunk/root/language/en/mods/instadisc.php +++ b/update/plugin/phpBB3/trunk/root/language/en/mods/instadisc.php
@@ -39,8 +39,12 @@ $lang = array_merge($lang, array(
39 39
40 'SUBSCRIPTION' => 'Subscription', 40 'SUBSCRIPTION' => 'Subscription',
41 'SUBSCRIPTION_TITLE' => 'Subscription Title', 41 'SUBSCRIPTION_TITLE' => 'Subscription Title',
42 'SUBSCRIPTION_FILE' => 'Subscription File URL',
42 43
43 'CENTRAL_SERVER' => 'Central Server', 44 'CENTRAL_SERVER' => 'Central Server',
45 'USERNAME' => 'Username',
46 'PASSWORD' => 'Password',
47 'ACTIVATION' => 'Activation Key',
44)); 48));
45 49
46?> 50?>