QUOTE(deltacode @ Dec 23 2004, 01:16 PM)
Well you know what youre talking about so would yo able to tell me how to do the following using this script?:
CODE
<html>
<script type="text/javascript" language="javascript">
function saveCaret(elem) {
if ( elem.isTextEdit )
elem.caretPos = document.selection.createRange();
}
function insertText(elem, wordInsert) {
if ( elem.isTextEdit && elem.caretPos ) {
var bookmark = wordInsert;
var caretPos = elem.caretPos;
caretPos.text = bookmark;
function Bold() {
var formData = document.selection.createRange().text;
if (formData != '') {
document.selection.createRange().text = '<b>'+formData+'</b>';
</script>
<INPUT onclick=Bold() type=button class=but value=bold ><br><TEXTAREA class=area name=message rows=20 cols=60 value="text" ></TEXTAREA>
</html>
This works but what i want it to do is, instead of using a button could i use a drop down menu to inser text?
[right][snapback]20858[/snapback][/right]
Firstly, you are missing a closing brace in your
Bold() function... And yes, you can use a dropdown menu by passing the value as an arguement to the function...
But, you have me completely confused here... What does this script have to do with
saving and opening files on a local drive which is what this thread is about...
If you wish to discuss another script please start another thread to keep from confusing things further...
.....Willy