there are most probably many ways to achieve this. the easiest approach is most probably to subclass WikiForm, redefine in the subclassed form the method update_references like
Class MySpecializedWikiForm -superclass WikiForm
MySpecializedWikiForm instproc update_references {} {
set provided [my submit_link]
next
my submit_link $provided
}
In edit.tcl provide submit_link in the form generation (f1) with a value (.... create ::xowiki::f1 .... -submit_link whatever) and you are done. since update_references is called by new_data and edit_data, this should work ok with the current code. by subclassing the form, you can tailor all of the behavior...
anyhow, allowing the user to export variables seems useful, so i added to to xotcl-core in oacs-5-2. It can be used in edit.tcl like:
::xowiki::f1 generate -export [list [list var1 value1]]