Xstandard Lite – Javascript Insert Code
I have a some small bits of code that I like to insert in my pages.
Currently I use a small javascript on a button to insert the code at the beginning of the XStandard form
e.g.
In other Code editors you can click to insert code where the cursor is currently positioned. Is this possible in XStandard Lite?
If so how? Please provide me with code if there is any thanks.
Currently I use a small javascript on a button to insert the code at the beginning of the XStandard form
e.g.
Code: |
function insert_PageText(insert_HTML) {
var PageText_Insert = document.getElementById(’PageText_insert’).value; var PageText_Insert = insert_HTML; var PageText_Original = document.getElementById(’editorPageText’).value; document.getElementById(’editorPageText’).value = PageText_Insert + PageText_Original; } |
Code: |
onClick="insert_PageText('<img src=’../images/logo.gif’ />’);" |
In other Code editors you can click to insert code where the cursor is currently positioned. Is this possible in XStandard Lite?
If so how? Please provide me with code if there is any thanks.
This is a feature of the Pro version. A license file transforms Lite into Pro. Point to the license file via a License param tag like this:
Then you can use API like InsertXML() or InsertText() to insert at the cursor position. For example:
FYI, this forum is dedicated to discussions on ways to make the markup generated by the editor more accessible. Feel free to contact XStandard Support for all other issues – you’ll get a faster reponse that way too.
Vlad Alexander
XStandard Development Team
http://xstandard.com
Code: |
<param name="License" value="http://yourserver/license.txt" /> |
Then you can use API like InsertXML() or InsertText() to insert at the cursor position. For example:
Code: |
document.getElementById(’editorPageText’).InsertXML(insert_HTML); |
FYI, this forum is dedicated to discussions on ways to make the markup generated by the editor more accessible. Feel free to contact XStandard Support for all other issues – you’ll get a faster reponse that way too.
Vlad Alexander
XStandard Development Team
http://xstandard.com