Changeset 2247
- Timestamp:
- 05/22/08 16:40:18 (6 months ago)
- Files:
-
- alternc/trunk/bureau/admin/adm_add.php (modified) (1 diff)
- alternc/trunk/bureau/admin/adm_doadd.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
alternc/trunk/bureau/admin/adm_add.php
r1653 r2247 92 92 echo "<option value=\"$type\""; 93 93 if($type == 'default') 94 echo " selected ";94 echo " selected=\"selected\""; 95 95 echo ">$type</option>"; 96 96 } 97 97 ?></select> 98 </td> 98 99 </tr> 99 <? if (variable_get('hosting_tld')) { ?> 100 100 101 <tr> 101 <th colspan="2"><label><input type="checkbox" name="create_dom" value="1" /> 102 <?php printf(_("Create the domain <b>username.%s</b>"),variable_get('hosting_tld')); ?></label></th> 103 </tr> 102 <th colspan="2"> 103 <input type="checkbox" name="create_dom" value="1" /> 104 <label><?php printf(_("Create the domain <b>username.%s</b>"),""); ?></label> 105 <select name="create_dom_list"> 106 <?php if (variable_get('hosting_tld')) { ?> 107 <option value="<?php echo variable_get('hosting_tld'); ?>" selected="selected"><?php echo variable_get('hosting_tld'); ?></option> 108 <?php } 109 /* Enumeration des domaines : */ 110 $domain=$dom->enum_domains(); 111 reset($domain); 112 while (list($key,$val)=each($domain)) { ?> 113 <option value="<?php echo $val; ?>" > <?php echo $val?> </option> 114 <?php } ?> 115 </select> 116 </th> 117 </tr> 104 118 <tr> 105 <? } ?>106 119 <td colspan="2"><input type="submit" class="inb" name="submit" value="<?php __("Create a new member"); ?>" /></td> 107 120 </tr> alternc/trunk/bureau/admin/adm_doadd.php
r1872 r2247 60 60 * 1 = force = ne tient pas compte du whois ou des droits de tld 61 61 */ 62 if ($create_dom) { 63 if (variable_get("hosting_tld")) {62 63 if (($create_dom == 1) && !is_null($create_dom_list)) { 64 64 # make sure we don't have multiple dots there 65 65 $dom->lock(); 66 $dom->add_domain($login.".".preg_replace("/^\.\.*/", "", variable_get("hosting_tld")),1,1,1);66 $dom->add_domain($login.".".preg_replace("/^\.\.*/", "", $create_dom_list),1,1,1); 67 67 $dom->unlock(); 68 } else {69 $err->log("no 'hosting_tld' variable defined in `variables` table, not creating domain");70 }71 68 } 69 72 70 $ftp->add_ftp($login,"",$pass,"/"); 73 71 $mem->unsu();
