<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
  <META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
  <META NAME="GENERATOR" CONTENT="GtkHTML/3.28.1">
</HEAD>
<BODY>
Hey folks,<BR>
<BR>
Could we get names on the forms?&nbsp; I'm trying to fiddle with the matrix using WWW::Mechanize and I'm having to select the form I want to submit by index.&nbsp; If another form is added prior to this one, the code will break.&nbsp; If there were name attributes on the forms, this would keep such problems from happening...<BR>
<BR>
Here, let me put a patch together...<BR>
<BR>
<BLOCKQUOTE>
<PRE>
$ svn diff
Index: customize/deffile.py
===================================================================
--- customize/deffile.py        (revision 9613)
+++ customize/deffile.py        (working copy)
@@ -203,7 +203,7 @@
 HTML_postform = '&lt;/form&gt;'
 
 HTML_uploadpreform = '''
-&lt;form action=&quot;matrix.cgi&quot; method=&quot;post&quot; enctype=&quot;multipart/form-data&quot;&gt;
+&lt;form action=&quot;matrix.cgi&quot; method=&quot;post&quot; enctype=&quot;multipart/form-data&quot; name=&quot;choices_form&quot;&gt;
 '''
 
 HTML_uploadpostform = '&lt;/form&gt;'
</PRE>
</BLOCKQUOTE>
<BR>
<BR>
Hurm... you might want to re-think using HTML_preform as it is currently.&nbsp; It will be difficult to modify the opening form tag this way.&nbsp; I would recommend using <A HREF="http://math.arizona.edu/~kerl/python/sprintf.html">printf-style string interpolation</A>.<BR>
<BR>
In fact, a templating system like <A HREF="http://www.makotemplates.org/">mako</A> or <A HREF="http://docs.djangoproject.com/en/dev/ref/templates/api/">django</A> would probably be a better fit, but will require quite a bit of re-factoring.<BR>
<BR>
Cheers,<BR>
<BR>
C.J.<BR>
<BR>
</BODY>
</HTML>