{"id":203,"date":"2017-07-22T22:07:42","date_gmt":"2017-07-22T20:07:42","guid":{"rendered":"https:\/\/asdw.de\/speichern-button-an-beliebiger-stelle-auf-forms\/"},"modified":"2017-07-22T22:21:11","modified_gmt":"2017-07-22T20:21:11","slug":"add-new-save-button-anywhere-on-scriptcase-form","status":"publish","type":"post","link":"https:\/\/asdw.de\/en\/add-new-save-button-anywhere-on-scriptcase-form\/","title":{"rendered":"Add new save button anywhere within a Scriptcase form"},"content":{"rendered":"<h2>Place a new &#8216;save&#8217; button anywhere on a Scriptcase form<\/h2>\n<p>There are projects, where it is necessary to place a &#8216;save&#8217; button not on the top or the bottom toolbar of a form but within a form, i.e. near a input field.<\/p>\n<p>&nbsp;<\/p>\n<p>Add a new field of type &#8216;Label&#8217; and place it at the right position on the form.<\/p>\n<p>Leave the description of the lable-field empty.<\/p>\n<p>Use the &#8216;OnLoad&#8217; event of the form to assign the content of the field: Javascript command to save the data on the form.<\/p>\n<p>&nbsp;<\/p>\n<p>Example:<\/p>\n<p>If the Label field is named &#8216;save_it&#8217; the following line has to be added in the OnLoad-event:<\/p>\n<pre class=\"lang:php decode:true\" title=\"Speichern Button an beliebiger Stelle\">{save_it} = '&lt;a href=\"javascript: nm_atualiza (\\'alterar\\');\" id=\"sc_b_upd_t\" onclick=\"nm_atualiza (\\'alterar\\');; return false;\" class=\"scButton_default\" title=\"Update record\" style=\"vertical-align: middle; display:inline-block;\"&gt;Click to save&lt;\/a&gt;';<\/pre>\n<p>This generates the new button:<\/p>\n<p><a href=\"https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210.jpg\"><img decoding=\"async\" loading=\"lazy\" class=\"aligncenter size-full wp-image-201\" src=\"https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210.jpg\" alt=\"Add a new save button anywhere within a Scriptcase form\" width=\"441\" height=\"210\" srcset=\"https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210.jpg 441w, https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210-300x143.jpg 300w, https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210-100x48.jpg 100w, https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210-150x71.jpg 150w, https:\/\/asdw.de\/wp-content\/uploads\/2017\/07\/scriptcase_button_save-441x210-200x95.jpg 200w\" sizes=\"(max-width: 441px) 100vw, 441px\" \/><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>Place a new &#8216;save&#8217; button anywhere on a Scriptcase form There are projects, where it is necessary to place a &#8216;save&#8217; button not on the top or the bottom toolbar of a form but within a form, i.e. near a<span class=\"ellipsis\">&hellip;<\/span><\/p>\n<div class=\"read-more\"><a href=\"https:\/\/asdw.de\/en\/add-new-save-button-anywhere-on-scriptcase-form\/\">Read more &#8250;<\/a><\/div>\n<p><!-- end of .read-more --><\/p>\n","protected":false},"author":2,"featured_media":201,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[55],"tags":[57,59,42,58],"_links":{"self":[{"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/posts\/203"}],"collection":[{"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/comments?post=203"}],"version-history":[{"count":4,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/posts\/203\/revisions"}],"predecessor-version":[{"id":207,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/posts\/203\/revisions\/207"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/media\/201"}],"wp:attachment":[{"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/media?parent=203"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/categories?post=203"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/asdw.de\/en\/wp-json\/wp\/v2\/tags?post=203"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}