Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Interchange: cvs

[SCM] Interchange branch, master, updated. REL_5_7_2-14-ga31302b

 

 

Interchange cvs RSS feed   Index | Next | Previous | View Threaded


interchange-cvs at icdevgroup

Oct 27, 2009, 8:51 AM

Post #1 of 1 (28 views)
Permalink
[SCM] Interchange branch, master, updated. REL_5_7_2-14-ga31302b

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "Interchange".

The branch, master has been updated
via a31302b0bea881534c807fed54e5e86bd6b37e45 (commit)
from 52500fbdd62f89bc666492d349bc0b97e304573c (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit a31302b0bea881534c807fed54e5e86bd6b37e45
Author: Josh Lavin <josh[at]perusion.com>
Date: Fri Oct 23 15:06:14 2009 -0500

Update Form.pm to support id attribute on form elements

Allows use of id="your-id" in [display] tag, which will output to form element as "id" attribute and <label> tag as "for" attribute. By Mike Heins.

-----------------------------------------------------------------------

Summary of changes and diff:
lib/Vend/Form.pm | 33 ++++++++++++++++++++++++++++++---
1 files changed, 30 insertions(+), 3 deletions(-)

diff --git a/lib/Vend/Form.pm b/lib/Vend/Form.pm
index f1ec9b4..a08fd91 100644
--- a/lib/Vend/Form.pm
+++ b/lib/Vend/Form.pm
@@ -77,6 +77,8 @@ my $Tag = new Vend::Tags;
.
qq({DISABLED?} disabled{/DISABLED?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({MULTIPLE?} multiple{/MULTIPLE?})
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
@@ -101,6 +103,8 @@ my $Tag = new Vend::Tags;
.
qq({TTITLE?} title="{TTITLE}"{/TTITLE?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({WRAP?} wrap="{WRAP}"{/WRAP?})
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
@@ -114,6 +118,8 @@ my $Tag = new Vend::Tags;
.
qq({COLS?} size="{COLS}"{/COLS?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({MAXLENGTH?} maxlength="{MAXLENGTH}"{/MAXLENGTH?})
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
@@ -125,6 +131,8 @@ my $Tag = new Vend::Tags;
.
qq({TTITLE?} title="{TTITLE}"{/TTITLE?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({COLS?} size="{COLS}"{/COLS?})
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
@@ -136,6 +144,8 @@ my $Tag = new Vend::Tags;
.
qq({TTITLE?} title="{TTITLE}"{/TTITLE?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({COLS?} size="{COLS}"{/COLS?})
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
@@ -149,6 +159,8 @@ my $Tag = new Vend::Tags;
.
qq({TTITLE?} title="{TTITLE}"{/TTITLE?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({DISABLED?} disabled{/DISABLED?})
.
qq({MAXLENGTH?} maxlength="{MAXLENGTH}"{/MAXLENGTH?})
@@ -162,6 +174,8 @@ my $Tag = new Vend::Tags;
hidden =>
qq({PREPEND}<input type="hidden" name="{NAME}" value="{ENCODED}")
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({EXTRA?} {EXTRA}{/EXTRA?})
.
qq(>{APPEND})
@@ -178,13 +192,15 @@ my $Tag = new Vend::Tags;
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({TTITLE?} title="{TTITLE}"{/TTITLE?})
.
qq({DISABLED?} disabled{/DISABLED?})
.
qq({SELECTED?} checked{/SELECTED?})
.
- qq(>&nbsp;{TTITLE?}<span title="{TTITLE}">{/TTITLE?}{TLABEL}{TTITLE?}</span>{/TTITLE?})
+ qq(>&nbsp;{TTITLE?}<span title="{TTITLE}">{/TTITLE?}{TEXTID?}<label for="{TEXTID}">{/TEXTID?}{TLABEL}{TEXTID?}</label>{/TEXTID?}{TTITLE?}</span>{/TTITLE?})
,
boxnbsp =>
qq(<input type="{VARIANT}" name="{NAME}" value="{TVALUE}")
@@ -197,14 +213,14 @@ my $Tag = new Vend::Tags;
.
qq({SELECTED?} checked{/SELECTED?})
.
- qq(>&nbsp;{TTITLE?}<span title="{TTITLE}">{/TTITLE?}{TLABEL}{TTITLE?}</span>{/TTITLE?}&nbsp;&nbsp;)
+ qq(>&nbsp;{TTITLE?}<span title="{TTITLE}">{/TTITLE?}{TEXTID?}<label for="{TEXTID}">{/TEXTID?}{TLABEL}{TEXTID?}</label>{/TEXTID?}{TTITLE?}</span>{/TTITLE?}&nbsp;&nbsp;)
,
boxlabel =>
qq(<td{TD_LABEL?} {TD_LABEL}{/TD_LABEL?}{TTITLE?} title="{TTITLE}"{/TTITLE?}>)
.
qq({FONT?}<font size="{FONT}">{/FONT?})
.
- qq({TLABEL}{FONT?}</font>{/FONT?})
+ qq({TEXTID?}<label for="{TEXTID}">{/TEXTID?}{TLABEL}{TEXTID?}</label>{/TEXTID?}{FONT?}</font>{/FONT?})
.
qq(</td>)
,
@@ -215,6 +231,8 @@ my $Tag = new Vend::Tags;
.
qq({TTITLE?} title="{TTITLE}"{/TTITLE?})
.
+ qq({TEXTID?} id="{TEXTID}"{/TEXTID?})
+ .
qq({DISABLED?} disabled{/DISABLED?})
.
qq({EXTRA?} {EXTRA}{/EXTRA?})
@@ -1012,6 +1030,11 @@ sub box {

$opt->{ttitle} = $help;

+ if($opt->{id}) {
+ $opt->{textid} = $opt->{id} . ($value eq '' ? 0 : $value);
+ $opt->{textid} =~ s/[^-\w]+//g;
+ }
+
$run .= attr_list($template, $opt);
$run .= '</tr>' if $inc && ! ($i % $inc);
}
@@ -1322,6 +1345,10 @@ if($opt->{debug}) {
$opt->{value} = $def if defined($def);
}

+ if($opt->{id}) {
+ $opt->{textid} = $opt->{id};
+ }
+
$opt->{value} = $opt->{default} if ! defined $opt->{value};

if(length($opt->{blank_default}) and ! length($opt->{value}) ) {


hooks/post-receive
--
Interchange

_______________________________________________
interchange-cvs mailing list
interchange-cvs[at]icdevgroup.org
http://www.icdevgroup.org/mailman/listinfo/interchange-cvs

Interchange cvs RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact lists@gossamer-threads.com
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.