%META:TOPICINFO{author="TWikiContributor" date="1163536597" format="1.0" version="1"}%
%META:TOPICPARENT{name="TagMePlugin"}%
---+!! Tag-me: Rename Tag

%INCLUDE{"TagMeCreateNewTag" section="cleanTagJavascript"}%
%STARTINCLUDE%
<table class="tagmeNavigation" border="0" cellpadding="3" cellspacing="0"><tr>
<td>&nbsp; &nbsp;</td>
<td bgcolor="#F6F4EB">&nbsp; [[TagMeCreateNewTag][Create New Tag]] &nbsp;</td>
<td>&nbsp;</td>
<td bgcolor="#EAE9DE">&nbsp; *Rename Tag* &nbsp;</td>
<td>&nbsp;</td>
<td bgcolor="#F6F4EB">&nbsp; [[TagMeDeleteTag][Delete Tag]] &nbsp;</td>
</tr></table>
<table border="0" cellpadding="5" cellspacing="0" style="width:100%;">
<tr bgcolor="#EAE9DE"><td style="width:100%;"></td></tr>
</table>
%STARTSECTION{"create"}%
<noautolink><form name="renametag" action="%SCRIPTURL{viewauth}%/%BASEWEB%/%BASETOPIC%" method="post" onsubmit="return cleanTag(this.newtag.value);">%TAGME{ tpaction="%URLPARAM{"renameaction" default="renametaginit"}%" oldtag="%URLPARAM{oldtag}%" newtag="%URLPARAM{newtag}%" note="%URLPARAM{renametagnote}%" }%

<div class="twikiFormSteps">
<div class="twikiFormStep">
Tag to rename: %BR%
<select name="oldtag">
<option>%URLPARAM{renametagfrom}%</option>
%TAGME{ tpaction="showalltags" format="<option>$tag</option>" separator="$n" }%
</select>
</div>
<div class="twikiFormStep">
New name for this tag: %BR%
<input type="text" value="%URLPARAM{"renametagto" default="%URLPARAM{renametagfrom}%"}%" name="newtag" id="newtag" class="twikiInputField" size="30" onblur="this.value=cleanTag(this.value)" />
</div>
<div class="twikiFormStep twikiLast">
<input type="submit" class="twikiSubmit" value="%MAKETEXT{"Rename"}%" />
</div>
</div>
<input type="hidden" name="renameaction" value="renametag" />
</form>
</noautolink>
%ENDSECTION{"rename"}%
%STOPINCLUDE%

%BR%
<span class="twikiGrayText">Other tag options: [[TagMeViewAllTags][View all tags]], [[TagMeViewMyTags][View my tags]], [[TagMeSearch][Search tags]]</span>

<script type="text/javascript">
//<![CDATA[
   addLoadEvent(setHandyFocus);
   function setHandyFocus () {
        document.getElementById('newtag').focus();
   }
//]]>
</script>
