I currently just have these 3 files installed
root/application.php
Code: Select all
<?php
/**
* @package application.php
* @copyright (c) JimA http://beta-garden.com 2009
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
define('IN_PHPBB', true);
$phpbb_root_path = (defined('PHPBB_ROOT_PATH')) ? PHPBB_ROOT_PATH : './';
$phpEx = substr(strrchr(__FILE__, '.'), 1);
include($phpbb_root_path . 'common.' . $phpEx);
// Start session management
$user->session_begin();
$auth->acl($user->data);
$user->setup('mods/application');
// You need to login before being able to send out an application
if ($user->data['user_id'] == ANONYMOUS)
{
login_box('', $user->lang['LOGIN_APPLICATION_FORM']);
}
include($phpbb_root_path . 'includes/functions_posting.' . $phpEx);
// Let's set the configuration, this is the ID of the forum where the post goes to
$forumid_send = 3;
$submit = (isset($_POST['submit'])) ? true : false;
if ($submit)
{
// Setting the variables we need to submit the post to the forum where all the applications come in
$apply_subject = sprintf($user->lang['APPLICATION_SUBJECT'], utf8_normalize_nfc(request_var('lastname', '', true)));
$apply_post = sprintf($user->lang['APPLICATION_MESSAGE'], $user->data['username'], utf8_normalize_nfc(request_var('firstname', '', true)), utf8_normalize_nfc(request_var('lastname', '', true)), utf8_normalize_nfc(request_var('playerid', '', true)), utf8_normalize_nfc(request_var('age', '', true)), utf8_normalize_nfc(request_var('past', '', true)), utf8_normalize_nfc(request_var('detail', '', true)), request_var('mos', '', true), utf8_normalize_nfc(request_var('reason', '', true)), utf8_normalize_nfc(request_var('findout', '', true)), utf8_normalize_nfc(request_var('confirm', '', true)));
// variables to hold the parameters for submit_post
$poll = $uid = $bitfield = $options = '';
generate_text_for_storage($apply_post, $uid, $bitfield, $options, true, true, true);
$data = array(
'forum_id' => $forumid_send,
'icon_id' => false,
'enable_bbcode' => true,
'enable_smilies' => true,
'enable_urls' => true,
'enable_sig' => true,
'message' => $apply_post,
'message_md5' => md5($apply_post),
'bbcode_bitfield' => $bitfield,
'bbcode_uid' => $uid,
'post_edit_locked' => 0,
'topic_title' => $apply_subject,
'notify_set' => false,
'notify' => false,
'post_time' => 0,
'forum_name' => '',
'enable_indexing' => true,
);
// Sending the post to the forum set in configuration above
submit_post('post', $apply_subject, '', POST_NORMAL, $poll, $data);
$message = $user->lang['APPLICATION_SEND'];
$message = $message . '<br /><br />' . sprintf($user->lang['RETURN_INDEX'], '<a href="' . append_sid("{$phpbb_root_path}index.$phpEx") . '">', '</a>');
trigger_error($message);
}
page_header($user->lang['APPLICATION_PAGETITLE']);
$template->assign_vars(array(
'PROCESS_APPFORM' => append_sid("{$phpbb_root_path}application.$phpEx"),
));
$template->set_filenames(array(
'body' => 'appform_body.html',
));
page_footer();
?>
root/language/en/mods/application.php
Code: Select all
<?php
/**
*
* application [English]
*
* @package language
* @copyright (c) Jim http://beta-garden.com 2009
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
*
*/
/**
* DO NOT CHANGE
*/
if (!defined('IN_PHPBB'))
{
exit;
}
if (empty($lang) || !is_array($lang))
{
$lang = array();
}
// DEVELOPERS PLEASE NOTE
//
// All language files should use UTF-8 as their encoding and the files must not contain a BOM.
//
// Placeholders can now contain order information, e.g. instead of
// 'Page %s of %s' you can (and should) write 'Page %1$s of %2$s', this allows
// translators to re-order the output of data while ensuring it remains correct
//
// You do not need this where single placeholders are used, e.g. 'Message %d' is fine
// equally where a string contains only two placeholders which are used to wrap text
// in a url you again do not need to specify an order e.g., 'Click %sHERE%s' is fine
$lang = array_merge($lang, array(
'LOGIN_APPLICATION_FORM' => 'You need to login before you can send out an application.',
'APPLICATION_SUBJECT' => '%s Application',
'APPLICATION_MESSAGE' => '[b]Last Name, First Name:[/b] %2$s,%1$s<br />[b]ArmA III Player ID:[/b] %3$s<br />[b]Age:[/b] %4$s<br /><br />[b]Have you served in a realism unit?:[/b] %5$s<br />[i]If so detail which unit, time in service, rank, billet:[/i] %6$s<br /><br />[b]Desired Duty:[/b] %7$s<br />[b]Why are you applying to join 4th MRB?:[/b] %8$s<br /><br />[b]How did you find out about the 4th MRB?:[/b] %9$s<br /><br />[b]Confirm you understand the 4th MRB is an immersion-orientated, role-playing realism unit:[/b]<br /> %10$s',
'APPLICATION_SEND' => 'Your application has been sumbitted.',
'APPLICATION_PAGETITLE' => '4th MRB Realism Unit Application',
'APPLICATION_FIRSTNAME' => 'First Name',
'APPLICATION_LASTNAME' => 'Last Name',
'APPLICATION_PLAYERID' => 'ArmA III Player ID',
'APPLICATION_AGE' => 'Age',
'APPLICATION_PAST' => 'Have you served in a realism unit?',
'APPLICATION_DETAIL' => 'If so detail which unit, time in service, rank, billet',
'APPLICATION_MOS' => 'Desired Duty Assignment',
'APPLICATION_0372' => '0372 Critical Skills Operator (CSO)',
'APPLICATION_3531' => '3531 Motor Vehicle Operator',
'APPLICATION_3533' => '3533 Logistics Vehicle System Operator',
'APPLICATION_8071' => '8071 Special Operations Capabilities Specialist (SOCS)',
'APPLICATION_8427' => 'HM-8427 Fleet Marine Force Reconnaissance Corpsman (SARC)',
'APPLICATION_152C' => '152C OH-6 Pilot',
'APPLICATION_153A' => '153A Rotary Wing Aviator',
'APPLICATION_153E' => '153E MH-60 Pilot',
'APPLICATION_154E' => '154E MH-47 Pilot',
'APPLICATION_11S1J' => '11S1J Special Operations Pilot, CV-22 Student',
'APPLICATION_11S1P' => '11S1P Special Operations Pilot, MC-130J Student',
'APPLICATION_11U1B' => '11U1B Unmanned Aircraft Systems, MQ-9 Student',
'APPLICATION_REASON' => 'Why are you applying to join 4th MRB?',
'APPLICATION_FINDOUT' => 'How did you find out about the 4th MRB?',
'APPLICATION_CONFIRM' => 'Confirm you understand the 4th MRB is an immersion-orientated, role-playing realism unit?',
));
?>
root/styles/prosilver/template/appform_body.html
Code: Select all
<!-- INCLUDE overall_header.html -->
<div class="panel">
<div class="inner">
<span class="corners-top">
<span></span>
</span>
<div class="content">
<h2>{L_APPLICATION_PAGETITLE}</h2>
<form method="post" action="{PROCESS_APPFORM}" id="appform">
<table width="80%" border="0" cellspacing="0" cellpadding="0" class="tborder" align="center">
<tbody>
<tr>
<td>
<table border="0" cellspacing="0" cellpadding="4" width="100%">
<tbody>
<tr>
<td colspan="3"><h2>{L_APPLICATION_PAGETITLE}</h2></td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="firstname">{L_APPLICATION_FIRSTNAME}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="firstname">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="lastname">{L_APPLICATION_REALNAME}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="last_name">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="aIII_playerid">{L_APPLICATION_aIII_playerid}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="aIII_playerid">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="age">{L_APPLICATION_AGE}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="age">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="past">{L_APPLICATION_PAST}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="past">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="detail">{L_APPLICATION_DETAIL}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="detail">
</td>
</tr>
<tr>
<td></td>
<td valign="top"><label for="mos">{L_APPLICATION_MOS}</label></td>
<td width="50%">
<select name="mos">
<option value="{L_APPLICATION_0372}">{L_APPLICATION_0372}</option>
<option value="{L_APPLICATION_3531}">{L_APPLICATION_3531}</option>
<option value="{L_APPLICATION_3533}">{L_APPLICATION_3533}</option>
<option value="{L_APPLICATION_8071}">{L_APPLICATION_8071}</option>
<option value="{L_APPLICATION_8427}">{L_APPLICATION_8427}</option>
<option value="{L_APPLICATION_152C}">{L_APPLICATION_152C}</option>
<option value="{L_APPLICATION_153A}">{L_APPLICATION_153A}</option>
<option value="{L_APPLICATION_153E}">{L_APPLICATION_153E}</option>
<option value="{L_APPLICATION_154E}">{L_APPLICATION_154E}</option>
<option value="{L_APPLICATION_11S1J}">{L_APPLICATION_11S1J}</option>
<option value="{L_APPLICATION_11S1P}">{L_APPLICATION_11S1P}</option>
<option value="{L_APPLICATION_11U1B}">{L_APPLICATION_11U1B}</option>
</select>
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="reason">{L_APPLICATION_REASON}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="reason">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="findout">{L_APPLICATION_FINDOUT}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="findout">
</td>
</tr>
<tr>
<td></td>
<td valign="top">
<label for="confirm">{L_APPLICATION_CONFIRM}</label>
</td>
<td width="50%">
<input type="text" size="50%" name="confirm">
</td>
</tr>
<tr>
<td colspan="3" style="text-align:center;"> * Required Fields</td>
</tr>
<tr>
<td colspan="3" align="center" valign="middle">
<input type="submit" name="submit" id ="submit" value="{L_SUBMIT}" class="button1" />
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</div>
<span class="corners-bottom">
<span></span>
</span>
</div>
</div>
<!-- INCLUDE overall_footer.html -->