Interchange

CVS log for interchange/code/Widget/country_select.widget

[BACK] Up to [Local Repository] / interchange / code / Widget

Request diff between arbitrary revisions


Keyword substitution: kv
Default branch: MAIN


Revision 1.10.2.1: download - view: text, markup, annotated - select for diffs
Fri Jul 18 21:00:27 2008 UTC (5 months, 3 weeks ago) by mheins
Branches: STABLE_5_6-branch
CVS tags: REL_5_6_1, DEB_5_6_1_2
Diff to: previous 1.10: preferred, colored; next MAIN 1.11: preferred, colored
Changes since revision 1.10: +2 -1 lines
* Prevent cross-site scripting problem. Found and fixed by Josh Lavin
  of Perusion.

Revision 1.11: download - view: text, markup, annotated - select for diffs
Fri Jul 18 20:58:35 2008 UTC (5 months, 3 weeks ago) by mheins
Branches: MAIN
CVS tags: REL_5_7_1, HEAD
Diff to: previous 1.10: preferred, colored
Changes since revision 1.10: +2 -1 lines

* Prevent cross-site scripting problem. Found and fixed by Josh Lavin
  of Perusion.

Revision 1.8.2.1: download - view: text, markup, annotated - select for diffs
Sat Mar 31 00:20:19 2007 UTC (21 months, 1 week ago) by pajamian
Branches: STABLE_5_4-branch
CVS tags: REL_5_4_3
Diff to: previous 1.8: preferred, colored; next MAIN 1.9: preferred, colored
Changes since revision 1.8: +8 -3 lines
Fix incorrect license in headers GPL v2 -> GPL v2 "or later".  Update copyrights.

Revision 1.10: download - view: text, markup, annotated - select for diffs
Fri Mar 30 23:40:58 2007 UTC (21 months, 1 week ago) by pajamian
Branches: MAIN
CVS tags: STABLE_5_6-root, REL_5_5_3, REL_5_5_2, REL_5_5_1, DEB_5_5_1_1_1, DEB_5_5_1
Branch point for: STABLE_5_6-branch
Diff to: previous 1.9: preferred, colored
Changes since revision 1.9: +8 -3 lines
Fix incorrect license in headers GPL v2 -> GPL v2 "or later".  Update copyrights.

Revision 1.9: download - view: text, markup, annotated - select for diffs
Wed Aug 2 18:10:29 2006 UTC (2 years, 5 months ago) by mheins
Branches: MAIN
Diff to: previous 1.8: preferred, colored
Changes since revision 1.8: +6 -3 lines
* Add state-size and state-extra parameters to allow some extra control
  of the state text box in the country-select widget* This box is
  generated in the country-select portion, so must be passed there.

    [display
                name=state
                type=state_select
                value="[value state]"
                comment="See country_select widget for other related parameters"
            ]

	 [display name=country type=country_select
                state-size="3"
                state-extra="maxlength=3"
                value="[value country]"]

Revision 1.8: download - view: text, markup, annotated - select for diffs
Sun Sep 11 23:46:39 2005 UTC (3 years, 3 months ago) by docelic
Branches: MAIN
CVS tags: STABLE_5_4-root, REL_5_4_2, REL_5_4_1, REL_5_4_0, REL_5_3_3, REL_5_3_2, DEB_5_3_0_20051028_1, DEB_5_3_0_20051004_1
Branch point for: STABLE_5_4-branch
Diff to: previous 1.7: preferred, colored
Changes since revision 1.7: +4 -0 lines

* Add header and license information

Revision 1.7: download - view: text, markup, annotated - select for diffs
Fri Apr 15 19:18:01 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN
Diff to: previous 1.6: preferred, colored
Changes since revision 1.6: +4 -1 lines
* Update some Description members.

* Add the radio_nbsp Widget variant.

Revision 1.6: download - view: text, markup, annotated - select for diffs
Wed Apr 13 03:14:47 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN
Diff to: previous 1.5: preferred, colored
Changes since revision 1.5: +67 -41 lines
* The variable names in country_select were not necessarily unique. Though
  testing worked with two country variables (country and b_country) this
  would not necessarily be the case with all browsers/javascript implentations.
  Rename all variables to make the code pretty much unique. It could be conflict
  with non_standard variable names, so it may take more thought. This should
  be at least better.

* Add a callback_prescript and callback_postscript hook for widgets to
  use. This allows sending code to an area before the form (prescript)
  or after the form (postscript). To begin with, only country_select
  uses this.

* Add calls to callback_prescript and callback_postscript to
  country_select (if routine is present). This puts the script
  code in a better place and removes the necessity for state_select
  being before country_select.

* Callbacks could be used like:

	[display
		name=country
		type=country_select
		callback_prescript=`sub {
				my $val = shift;
				$Scratch->{meta_header} .= "\n$val";
				return;
			}
			`
		callback_postscript=`sub {
				my $val = shift;
				$Scratch->{some_footer} .= "\n$val";
				return;
			}
			`
		]

Revision 1.5: download - view: text, markup, annotated - select for diffs
Tue Apr 12 19:19:27 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN
Diff to: previous 1.4: preferred, colored
Changes since revision 1.4: +1 -0 lines
* Add descriptions to widgets

Revision 1.4: download - view: text, markup, annotated - select for diffs
Mon Apr 11 16:39:26 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN
Diff to: previous 1.3: preferred, colored
Changes since revision 1.3: +1 -1 lines
* Prevent error on possibly-empty existing state value.

Revision 1.3: download - view: text, markup, annotated - select for diffs
Mon Apr 11 16:35:26 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN
Diff to: previous 1.2: preferred, colored
Changes since revision 1.2: +6 -0 lines
* Fix missing form variable in some situations where we need to go to
  the forms array.

Revision 1.2: download - view: text, markup, annotated - select for diffs
Mon Apr 11 04:25:23 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN
Diff to: previous 1.1: preferred, colored
Changes since revision 1.1: +22 -2 lines
* Add sort order (with metadata support) for state data.

Revision 1.1: download - view: text, markup, annotated - select for diffs
Sun Apr 10 21:37:39 2005 UTC (3 years, 8 months ago) by mheins
Branches: MAIN

* Add country_select widget with the following features:

    - Uses DOM1.x compliant Javascript.

    - Dynamically reads countries from the country table and groups
      them by region (or just alphabetically).

    - When the country is changed on the widget, it adjust the state
      widget automatically to one of three types:

        * Entries for that country in state table -- SELECT with
          states pre-populated plus blank to force selection.

        * No entries in country table, and "no_state" field in
          country table set -- puts "no state required" in a
          text box and sets a hidden variable to ''.

        * No entries in country table, but "no_state" field is
          not set. Puts text box at default Vend::Form size.

    - WARNING: state_select widget must come before country_select
      if it is to reliably work!

    - Handles multiple state, b_state, s_state, h_state, etc. on
      same form automatically without having to adjust variable names
      and element names in metadata.

    - Includes metadata entries to set the following options:

        * only_with_shipping -- only show countries that have
          characters in the "shipmodes" field

        * no_region -- Don't sort by world region, just
          do alphabetical

        * country_sort -- sort fields for country table, usually
          the default works (default changes based on no_region).

        * country_table -- if you use a table besides "country".

        * state_table -- if you use a table besides "state".

        * state_var -- allows you to set name of variable
          if not a typical interchange one (meaning country -> state,
          b_country -> b_state, etc.)

        * state_class, state_style -- set CSS for state message text

        * form_name -- in case it has trouble figureing out which
          form in document. Usually selects first with "country"
          variable.

        * state_element -- set CSS ID for state widget container,
          you normally don't touch this.

* Example would be:

    [display name=state type=state_select]

    [display name=country type=country_select value=US]

  This will output two select boxes (with standard demo) for US countries.
  If you change the second select to "Luxembourg" which should have no_state
  set, the first select widget will disappear and errmsg("no state required")
  will appear.

  If you then change the country select to Canada, a select box with
  Canadian provinces will appear.

Diff request

This form allows you to request diffs between any two revisions of a file. You may select a symbolic revision name using the selection box or you may type in a numeric name using the type-in text box.

Log view options

Interchange CVSweb <info@icdevgroup.org>