- Timestamp:
- 09/19/23 10:40:24 (14 months ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/cgi-bin/main.cgi
r939 r944 1357 1357 # collect per-IP rDNS fields. only copy over the ones that actually have something in them. 1358 1358 my %iprev; 1359 foreach (keys %webvar) { 1360 $iprev{$_} = $webvar{$_} if /host_[\d.a-fA-F:]+/ && $webvar{$_}; 1359 foreach (sort keys %webvar) { 1360 # skip all but the host_* fields 1361 next unless /^host_[\d.a-fA-F:]+/; 1362 # propagate the per-IP rDNS if present 1363 $iprev{$_} = $webvar{$_} if $webvar{$_}; 1364 # set the rDNS to be cleared if there was a value before (was_host_* field), 1365 # but there's no value in the matching visible form field now (host_*) 1366 $iprev{$_} = '' if $webvar{"was_$_"} && !$webvar{$_}; 1361 1367 } 1362 1368 -
trunk/templates/edit.tmpl
r938 r944 82 82 <tr> 83 83 <td><TMPL_VAR NAME=r_ip></td> 84 <td><input class="host" name="host_<TMPL_VAR NAME=r_ip>" value="<TMPL_VAR NAME=iphost>"></td> 84 <td><input class="host" name="host_<TMPL_VAR NAME=r_ip>" value="<TMPL_VAR NAME=iphost>"> 85 <TMPL_IF iphost><input type="hidden" name="was_host_<TMPL_VAR NAME=r_ip>" value="1"></TMPL_IF></td> 85 86 </tr> 86 87 </TMPL_LOOP>
Note:
See TracChangeset
for help on using the changeset viewer.