<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to add onsubmit type functionality to forms? in Alfresco Archive</title>
    <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260947#M214077</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Here is a jira enhancement request to incorporate this functionality into the forms api.&amp;nbsp; Please vote for this enhancement:&amp;nbsp; &lt;/SPAN&gt;&lt;A href="https://issues.alfresco.com/jira/browse/ALF-6052" rel="nofollow noopener noreferrer"&gt;https://issues.alfresco.com/jira/browse/ALF-6052&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 06 Dec 2010 17:36:46 GMT</pubDate>
    <dc:creator>stevegreenbaum</dc:creator>
    <dc:date>2010-12-06T17:36:46Z</dc:date>
    <item>
      <title>How to add onsubmit type functionality to forms?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260942#M214072</link>
      <description>I'm scratching my head a bit here on the best way to add onsubmit-type handling to forms in Share.&amp;nbsp; I have a custom control that is a WYSIWYG editor and I'd like to copy the contents of the editor out to the standard content form field textarea on the inline-edit page before running through the norm</description>
      <pubDate>Tue, 23 Nov 2010 16:40:08 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260942#M214072</guid>
      <dc:creator>fiferyan</dc:creator>
      <dc:date>2010-11-23T16:40:08Z</dc:date>
    </item>
    <item>
      <title>Re: How to add onsubmit type functionality to forms?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260943#M214073</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I think there is another better way you can try, the forms runtime has a function that allows you to get called back just before submission, it gets called after validation has completed however, so it may not work for you.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The function I mentioned is called "doBeforeFormSubmit", there are a few examples of it being used throughout Share just search for it's use across the JS files.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope that helps!&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 30 Nov 2010 10:12:49 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260943#M214073</guid>
      <dc:creator>gavinc</dc:creator>
      <dc:date>2010-11-30T10:12:49Z</dc:date>
    </item>
    <item>
      <title>Re: How to add onsubmit type functionality to forms?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260944#M214074</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Thanks Gavin. I'll try this as it might be good enough. I'll let you know how it goes.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 14:04:11 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260944#M214074</guid>
      <dc:creator>fiferyan</dc:creator>
      <dc:date>2010-12-03T14:04:11Z</dc:date>
    </item>
    <item>
      <title>Re: How to add onsubmit type functionality to forms?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260945#M214075</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;This worked but was slightly difficult to figure out because I was retrieving the Form object instead of having it after I created it. This means that I had to use the ComponentManager to find the form.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For future reference in case somebody else comes across this same problem:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE class="language-none line-numbers"&gt;&lt;CODE&gt;&lt;BR /&gt;// Add an onsubmit to the form&lt;BR /&gt;var editForm = Alfresco.util.ComponentManager.find({id: 'the-id-I-already-had'})[0];&lt;BR /&gt;editForm.formsRuntime.doBeforeFormSubmit =&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;fn: function(form, obj)&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;{&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;// Get the string document from the editor&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var xml = ditaStorm.getXml();&lt;BR /&gt;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;// Get the string document from the editor&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;var textarea = document.getElementById('my-textarea-id');&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;textarea.value = xml;&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;},&lt;BR /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;scope: this&lt;BR /&gt;};&lt;BR /&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 03 Dec 2010 18:33:00 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260945#M214075</guid>
      <dc:creator>fiferyan</dc:creator>
      <dc:date>2010-12-03T18:33:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to add onsubmit type functionality to forms?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260946#M214076</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Glad you sorted it out, yes, I have no doubt that that approach will be useful for others.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Dec 2010 14:42:55 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260946#M214076</guid>
      <dc:creator>gavinc</dc:creator>
      <dc:date>2010-12-06T14:42:55Z</dc:date>
    </item>
    <item>
      <title>Re: How to add onsubmit type functionality to forms?</title>
      <link>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260947#M214077</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Here is a jira enhancement request to incorporate this functionality into the forms api.&amp;nbsp; Please vote for this enhancement:&amp;nbsp; &lt;/SPAN&gt;&lt;A href="https://issues.alfresco.com/jira/browse/ALF-6052" rel="nofollow noopener noreferrer"&gt;https://issues.alfresco.com/jira/browse/ALF-6052&lt;/A&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 06 Dec 2010 17:36:46 GMT</pubDate>
      <guid>https://connect.hyland.com/t5/alfresco-archive/how-to-add-onsubmit-type-functionality-to-forms/m-p/260947#M214077</guid>
      <dc:creator>stevegreenbaum</dc:creator>
      <dc:date>2010-12-06T17:36:46Z</dc:date>
    </item>
  </channel>
</rss>

