$searchstring=~ s/\'/\\\'/g;
my @data=split(' ',$searchstring);
my $count=@data;
- my $query="Select tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value from marc_tag_structure where (tagfield like \"$data[0]%\") order by tagfield";
+ my $query="Select tagfield,liblibrarian,libopac,repeatable,mandatory,authorised_value from marc_tag_structure where (tagfield > $data[0]) order by tagfield";
my $sth=$dbh->prepare($query);
$sth->execute;
my @results;
$authorised_value
);
$sth->finish;
- print "Content-Type: text/html\n\n<META HTTP-EQUIV=Refresh CONTENT=\"0; URL=marctagstructure.pl\"></html>";
+ print "Content-Type: text/html\n\n<META HTTP-EQUIV=Refresh CONTENT=\"0; URL=marctagstructure.pl?tagfield=$tagfield\"></html>";
exit;
# END $OP eq ADD_VALIDATE
################## DELETE_CONFIRM ##################################
<tr>
<td width=33%><TMPL_VAR name="previous"></td>
<td width=33%><TMPL_VAR name="next"></td>
- <td width=33%><a href="marctagstructure.pl">Back to Tags</a></td>
+ <td width=33%><a href="marctagstructure.pl?searchfield=<TMPL_VAR name="tagfield">">Back to Tags</a></td>
</tr>
</table>
</TMPL_IF>