Update of /cvsroot/ispman/ispman/ispman-web/cgi-bin/tmpl/vhosts
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2568/ispman-web/cgi-bin/tmpl/vhosts
Modified Files:
edit_header.tmpl
Log Message:
removed redundant CSS link
added check function
some cosmetic changes
Index: edit_header.tmpl
===================================================================
RCS file: /cvsroot/ispman/ispman/ispman-web/cgi-bin/tmpl/vhosts/edit_header.tmpl,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -d -r1.4 -r1.5
--- edit_header.tmpl 12 Jun 2003 17:47:38 -0000 1.4
+++ edit_header.tmpl 13 Feb 2004 20:41:34 -0000 1.5
@@ -1,4 +1,5 @@
-<script>
+<script type="text/javascript" language="JavaScript">
+<!--
function Delete(){
if (confirm("Are you sure you want to permanently delete this virtualhost?"))
self.location="<perl>$r->url</perl>?mode=deleteVhost&ispmanDomain=<perl>$r->param("ispmanDomain")</perl>&ispmanVhostName=<perl>$r->param("ispmanVhostName")</perl>";
@@ -19,16 +20,54 @@
function gotoSubSection(section){
self.location="<perl>$r->url</perl>?mode=editVhost&ispmanDomain=<perl>$r->param("ispmanDomain")</perl>&ispmanVhostName=<perl>$r->param("ispmanVhostName")</perl>§ion="+section;
}
+
+ function check_input(){
+ homedir = document.addvhost.homeDirectory.value;
+ docroot = document.addvhost.ispmanVhostDocumentRoot.value;
+ scriptdir = document.addvhost.ispmanVhostScriptDir.value;
+ logdir = document.addvhost.ispmanVhostLogdir.value;
+ statdir = document.addvhost.ispmanVhostStatdir.value;
+
+ rc = true;
+
+ if (homedir==""){
+ alert('<perl>_("vhost homedirectory is empty!")</perl>');
+ rc = false;
+ }
+
+ if (docroot==""){
+ alert('<perl>_("DocumentRoot is empty")</perl>');
+ rc = false;
+ }
+
+ if (scriptdir==""){
+ alert('<perl>_("ScriptDirectory is empty")</perl>');
+ rc = false;
+ }
+
+ if (logdir==""){
+ alert('<perl>_("LogDirectory is empty")</perl>');
+ rc = false;
+ }
+
+ if (statdir==""){
+ alert('<perl>_("StatDirectory is empty")</perl>');
+ rc = false;
+ }
+
+ return rc;
+ }
+//-->
</script>
-<LINK HREF="<perl>$ispman->getConfig('ispmanUrlPrefix')</perl>/ispman.css" REL="stylesheet" TYPE="text/css">
+
+Editing vhost: <perl>join '.', ($ispman->{'vhost'}->{'ispmanVhostName'}, $ispman->{'vhost'}->{'ispmanDomain'})</perl>
+(<b><perl>($ispman->{'vhost'}{'ispmanStatus'} eq "suspended")?"<font color=red>suspended</font>": "<font color=green>active</font>"</perl></b>)
+
<br>
<form>
-<table border=0>
-<tr><td colspan=2>
- Editing
- <select onChange="gotoSubSection(this.options[this.selectedIndex].value)">
+ <select onChange="gotoSubSection(this.options[this.selectedIndex].value)">
<perl>
$options={
"" => "General Info",
@@ -36,22 +75,14 @@
"acls" => "Access controls",
"aliases" => "Website Aliases",
};
- for (keys %$options) {
+ for (sort keys %$options) {
$text.= sprintf("<option value='%s' %s>%s</option>" , $_, ($r->param("section") eq $_)?" selected " :"" , $options->{$_});
}
$text
</perl>
</select>
- for
- VirtualHost
-
- <perl>join '.', ($ispman->{'vhost'}->{'ispmanVhostName'}, $ispman->{'vhost'}->{'ispmanDomain'})</perl>
-
-<br>
-<b><perl>($ispman->{'vhost'}{'ispmanStatus'} eq "suspended")?"<font color=red>This Vhost is suspended</font>": "<font color=green>This Vhost is Active</font>"</perl></b>
- <br><hr noshade></td></tr>
-</table>
+ <hr noshade></td></tr>
</form>
-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
lmpx.com only provides a reader for public news (NNTP) servers. It is not
affiliated with the servers or forums shown here and is not responsible for
the content of articles, which is written by their respective authors.