Uploaded image for project: 'Stripes'
  1. STS-790

URI parameter is present with null value even when not specified

    Details

    • Sprint:

      Description

      This is perhaps best illustrated by example. Say you have an ActionBean with @UrlBinding("/foo/

      {a}

      /

      {b}

      "). A request to /foo should have no parameters present, /foo/bar should have only a=foo present, and /foo/bar/baz should have a=bar and b=baz. Instead, when a parameter value is omitted from the URI, the parameter is actually present in the request with a null value.

      The difference seems negligible, but it's not. It has a direct impact on form population. In this example, a form with <s:hidden name="a" value="blah" /> rendered with a request to /foo would render the hidden input with a value="" because the request parameter is actually present. Instead, since the value was omitted from the URI, the parameter should be absent and the input's value should be "blah".

        Attachments

          Activity

            People

            • Assignee:
              bengunter BenB
              Reporter:
              bengunter BenB
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: