mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-26 00:29:18 +01:00
Converted newapplication.php to templates
This commit is contained in:
parent
ca5af4b7fc
commit
e6d27b6166
@ -17,6 +17,10 @@
|
||||
|
||||
$phpgw_flags["currentapp"] = "admin";
|
||||
include("../header.inc.php");
|
||||
$t = new Template($phpgw_info["server"]["template_dir"]);
|
||||
|
||||
$t->set_file(array("form" => "application_form.tpl"));
|
||||
|
||||
if ($submit) {
|
||||
if (! $n_app_name || ! $n_app_title) {
|
||||
$error = lang_admin("You must enter an application name and title.");
|
||||
@ -34,35 +38,19 @@
|
||||
$phpgw->common->navbar();
|
||||
}
|
||||
|
||||
echo "<p>" . lang_admin("Add new application") . "<hr><p>";
|
||||
$t->set_var("lang_header",lang_admin("Add new application"));
|
||||
|
||||
if ($error) {
|
||||
echo "<p><center>$error</center><br>";
|
||||
$t->set_var("error","<p><center>$error</center><br>");
|
||||
} else {
|
||||
$t->set_var("error","");
|
||||
}
|
||||
?>
|
||||
$t->set_var("session_hidden_var",$phpgw->session->hidden_var());
|
||||
$t->set_var("lang_app_name",lang_admin("application name"));
|
||||
$t->set_var("lang_app_title",lang_admin("application title"));
|
||||
$t->set_var("lang_enabled",lang_admin("enabled"));
|
||||
$t->set_var("lang_add",lang_common("add"));
|
||||
|
||||
<form action="newapplication.php">
|
||||
<?php echo $phpgw->session->hidden_var(); ?>
|
||||
$t->pparse("out","form");
|
||||
|
||||
<table border="0" width="35%" align="center">
|
||||
<tr>
|
||||
<td><?php echo lang_admin("application name"); ?></td>
|
||||
<td><input name="n_app_name"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><?php echo lang_admin("application title"); ?></td>
|
||||
<td><input name="n_app_title"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><?php echo lang_admin("enabled"); ?></td>
|
||||
<td><input type="checkbox" name="n_app_enabled" value="1"></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td colspan="2" align="center"><input type="submit" name="submit" value="<?php echo lang_common("Add"); ?>"></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<?php
|
||||
include($phpgw_info["server"]["api_dir"] . "/footer.inc.php");
|
||||
include($phpgw_info["server"]["api_dir"] . "/footer.inc.php");
|
||||
|
Loading…
Reference in New Issue
Block a user