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

  • SEARCH
  • Home
  • 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 8608979
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T03:45:28+00:00 2026-06-12T03:45:28+00:00

I have 2 condition to check true or false and take a certain action.

  • 0

I have 2 condition to check true or false and take a certain action.

Here is my code.

<xsl:variable name="hac" select="Hac1"/>



<xsl:choose>
    <xsl:when test="$hac= 'false'">
    <p style="display:inline">Hac1: </p><input type="checkbox" disabled="disabled" >
</xsl:when>
<xsl:otherwise>
    <p>HACCP: </p><input type="checkbox" disabled="disabled" checked="checked">
</xsl:otherwise>
</xsl:choose>

<xsl:variable name="glo1" select="Gloves"/>
    <xsl:choose>
    <xsl:when test1="$glo1= 'false'">
    <p style="display:inline">Gloves: </p><input type="checkbox" disabled="disabled" >
</xsl:when>
<xsl:otherwise>
    <p>Gloves: </p><input type="checkbox" disabled="disabled" checked="checked">
</xsl:otherwise>
</xsl:choose>

This only displays my Hac1 and not my Gloves, and i don’t know what seems to be the problem.

  • 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-06-12T03:45:29+00:00Added an answer on June 12, 2026 at 3:45 am

    Assuming this is a direct copy/paste from your XSLT, you have several errors, so I’m amazed you actually get anything.

    All four of the <input> tags are missing their closure, so change the final part from > to /> on each one… for example…

    <input type="checkbox" disabled="disabled" />
    

    Then you have <xsl:when test1=... which is incorrect. It should be <xsl:when test=... (note the lack of the 1)…

     <xsl:when test="$glo1= 'false'">
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have this code: if (condition){ //number1 if (condition){ //number2 action } } else{
I have thread 1 executing the following code: unique_lock<mutex> ul(m); while(condition == true) cv.wait(ul);
Sometimes I have to check for some condition that doesn't change inside a loop,
Possible Duplicate: php false place in condition I have noticed that a lot of
Is it possible to have a class object return a true/false value, so I
I have a activity am using a boolean condition to check some thing .if
I have the following code: <table id=myTable> <th>Date</th> <th>Action</th> </table> and var $table =
I need to control a CheckBoxPreference manually; I have to check a condition in
how to recognize selected radiobutton value or check condition. i have been developing some
I have a code check the checkedlistbox checkboxes in asp.net/c#. foreach (ListItem item in

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.