Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 900485
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T15:23:44+00:00 2026-05-15T15:23:44+00:00

I have form1 passing a query string parameter(param1) to form2. I pass param1=true from

  • 0

I have form1 passing a query string parameter(param1) to form2. I pass param1=true from form1. In form 2, I am trying to set the value of the param1 into a local instance. If I DO NOT pass param1 from form 1, I want form2 to take the value of param1 to be false. Here is my instance.

<xforms:instance id="querystring-instance">
    <query-string>
        <param1></param1>
    </query-string>
</xforms:instance>

I am using the following line to set the value of param1 by fetching it from the query string. If query string does not have param1, I want to use the default value of false.

<xforms:bind nodeset="instance('querystring-instance')/param1" calculate="xxforms:get-request-parameter('param1')" xxforms:default="false()" />

This does not work. If param1 is present it works and sets the in querystring-instance to true. If param1 is not present, it sets to nothing. I want it to be set to false. How do I do this?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-15T15:23:44+00:00Added an answer on May 15, 2026 at 3:23 pm

    You probably want to set the parameter upon initialization only, so use xxforms:default instead of calculate. calculate will be evaluated at each XForms recalculate, and that will fail because xxforms:get-request-parameter() is only available during XForms initialization.

    You can implement the condition in XPath.

    xxforms:get-request-parameter() returns and empty sequence if the parameter is missing. This should work:

    <xforms:bind nodeset="instance('querystring-instance')/param1"
                 xxforms:default="(xxforms:get-request-parameter('param1'), 'false')[1]"/>
    

    What this does is that if xxforms:get-request-parameter() returns an empty sequence, then the first value of the sequence will be ‘false’, and that’s what will be used to set the value.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 515k
  • Answers 515k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer I would recommend using a customvalidator, which gives you complete… May 16, 2026 at 6:39 pm
  • Editorial Team
    Editorial Team added an answer Before sending email or sms on iOS you have to… May 16, 2026 at 6:39 pm
  • Editorial Team
    Editorial Team added an answer Take a look at Plone (http://plone.org/), I think it fits… May 16, 2026 at 6:39 pm

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Related Questions

I have page with a simple table and advanced search form. I pass List<Customers>
I have a search form with a DateTime search criterion, plus some other criteria:
hello friends following is my query where displaylist is object if stringBuilder which have
I have a PHP generated form which consists of a list of items, each
I have a global multidimensional array, g_iAllData[MAX_LEN][MAX_WIDTH] being used in a Form. When I
Lets say i have a form which have the following : Name:TextBox Email:TextBox Age:TextBox
I have a sequence of forms that follows the following algorithm: Form #1 Prompt
I have a Crystal Report set up to run with my windows forms application.
The following WMI query throws an exception at serverProtocolsManagement.Get() when sqlHost is an invalid
I have a ASP.NET web service decorated with System.Web.Script.Services.ScriptService() so it can return json

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.