
12-30-2007, 09:26 PM
|
 |
|
|
Join Date: Aug 2004
Posts: 376
Благодарил(а): 0 раз(а)
Поблагодарили:
0 раз(а) в 0 сообщениях
|
|
Quote:
Originally Posted by vmacedonia
How to select all the text on mouse click for easy coping.
At the beginning of the template find:
HTML Code:
$vbphrase[picture]</title>
</head>
after that code add this one:
HTML Code:
<script type="text/javascript">
function SelectAll(id)
{
document.getElementById(id).focus();
document.getElementById(id).select();
}
</script>
And then replace the original code with this alternated:
HTML Code:
<tr>
<td align="$stylevar[left]"><table width="80%" border="0" class="tborder" align="center" cellpadding="3" cellspacing="0">
<tr>
<td class="alt2" nowrap="nowrap"><div class="smallfont normal">
<div align="right"><strong>Image URL:</strong></div>
</div></td>
<td class="alt2"><div align="center"><span class="smallfont normal">
<input name="textfield2" class="bginput" type="text" id="textfield2" onClick="SelectAll('textfield2');" value="$vboptions[bburl]/picture.php?$session[sessionurl]albumid=$albuminfo[albumid]&pictureid=$pictureinfo[pictureid]" size="50" READONLY>
</span></div></td>
</tr>
<tr>
<td class="alt2" nowrap="nowrap"><div class="smallfont normal">
<div align="right"><strong>BB Code:</strong> </div>
</div></td>
<td class="alt2"><div align="center"><span class="smallfont normal">
<input name="textfield3" class="bginput" type="text" id="textfield3" onClick="SelectAll('textfield3');" value="[img]https://vborg.vbsupport.ru/[/img]" size="50" READONLY>
</span></div></td>
</tr>
<tr>
<td class="alt2" nowrap="nowrap"><div class="smallfont normal">
<div align="right"><strong>Embed Code:</strong> </div>
</div></td>
<td class="alt2"><div align="center"><span class="smallfont normal">
<input name="textfield" class="bginput" type="text" id="textfield" onClick="SelectAll('textfield');" value="<img src='$vboptions[bburl]/picture.php?$session[sessionurl]albumid=$albuminfo[albumid]&pictureid=$pictureinfo[pictureid]' style='border:1px solid #000000;' >" size="50" READONLY>
</span></div></td>
</tr>
</table>
</td>
</tr>
If you want all the text to be select on double mouse click just change the event "onClick=" to "ondblClick=".
|
Installed
|