Jump to content

java script + form box positioning


ixcese

Recommended Posts

hello , im building right now an replay box which is suppose to serve the user to write a post.

 

now , i have one question ,

 

i want to make buttons for smiley's :) so the poster can add smiley's :) where ever he want in hes post , so i created an function what suppose to add smiley and here is the code:

 

function addSmiley(){
    document.getElementById('ID').value = document.getElementById('ID').value+"";
}

 

the problem is , if the poster want to add the smiley in the middle of the post it can't be.

 

so my question is how i can get the position of the pointer so i can add the smiley in it's place.

 

regards , Mor.

Link to comment
https://forums.phpfreaks.com/topic/234765-java-script-form-box-positioning/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.