Dynamic population via javascript

Last post 10-29-2005, 4:58 PM by EyePulp. 2 replies.
Sort Posts: Previous Next
  •  10-27-2005, 5:41 PM 12060

    Dynamic population via javascript

    We're using the Cute ASP editor on a form that is populated via JavaScript.  Is there a client-side JS call that we can make to properly populate the Cute-based text fields?  The standard document.formname.cutetextfieldname.value = "foo"; doesn't work.  I really don't want to have to dig too deeply into somone else's JS and ASP to do this, if possible.  We need a client-side method, which I can't seem to find on the forums or in the Cute documentation.

    Thanks


    -eyepulp
  •  10-27-2005, 6:41 PM 12061 in reply to 12060

    Re: Dynamic population via javascript

    eyepulp,
     
    Plese check this example:

    http://cutesoft.net/asp/JavaScript-API.asp

     
     
     

    asp.net Chat http://cutesoft.net/ASP.NET+Chat/default.aspx
    Web Messenger: http://cutesoft.net/Web-Messenger/default.aspx
    asp.net wysiwyg editor: http://cutesoft.net/ASP.NET+WYSIWYG+Editor/default.aspx
    asp wysiwyg html editor: http://cutesoft.net/ASP
    asp.net Image Gallery: http://cutesoft.net/ASP.NET+Image+Gallery/default.aspx
    Live Support: http://cutesoft.net/live-support/default.aspx

  •  10-29-2005, 4:58 PM 12116 in reply to 12061

    Re: Dynamic population via javascript

    Thanks - that did the trick for forced population.

    Though now an interesting problem has developed - after forcing in a .innerHTML value to the Cute editor, if I then make some changes within the "Normal" view of the editor (manually editing the text), when I POST the form the changes don't go through.  I.E. if I fill the .innerHTML with "foo" via JS, and then type "Test" in the editor, only "foo" comes through on the posted side.  I can work around this by implementing a js based copy of the innerHTML value back to the original (hidden) textarea that Cute is replacing, but it begs the question of why a manual copy is needed.  Does Cute perform some sort of onsubmit event to make sure edits in the "Normal" window are copied back into the original textarea?  This is using IE 6.0xxx.

    I should mention this form isn't raising the submit event and is getting posted via an asynchronous XMLHTTP request - this would kill any sort of built in onsubmit features Cute is dependant on.

    Thanks for your thoughts.


    -eyepulp
View as RSS news feed in XML