Skip to content

Commit

Permalink
Fixed issue #10530: HTML for radio button form items inconsistent
Browse files Browse the repository at this point in the history
  • Loading branch information
LouisGac committed Mar 4, 2016
1 parent 288ba43 commit e8d1020
Show file tree
Hide file tree
Showing 5 changed files with 46 additions and 48 deletions.
Expand Up @@ -9,16 +9,16 @@
?>
<!-- 5 point choice no answer -->
<div class="col-xs-2 answer-item radio-item noanswer-item">
<input
class="radio"
type="radio"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1]; ?>NANS"
value=""
<?php echo $checkedState; ?>
onclick="<?php echo $checkconditionFunction; ?>(this.value, this.name, this.type);"
/>
<label for="answer<?php echo $ia[1];?>NANS" class="answertext radio-label">
<input
class="radio"
type="radio"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1]; ?>NANS"
value=""
<?php echo $checkedState; ?>
onclick="<?php echo $checkconditionFunction; ?>(this.value, this.name, this.type);"
/>
<?php echo gT('No answer'); ?>
</label>
</div>
18 changes: 9 additions & 9 deletions application/views/survey/questions/5pointchoice/item_row.php
Expand Up @@ -10,16 +10,16 @@
?>
<!-- 5 point choice item -->
<div class="col-xs-2 answer-item radio-item">
<input
class="radio"
type="radio"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1].$fp; ?>"
value="<?php echo $fp;?>"
<?php echo $checkedState; ?>
onclick="<?php echo $checkconditionFunction; ?>(this.value, this.name, this.type)"
/>
<label for="answer<?php echo $ia[1].$fp; ?>" class="answertext radio-label">
<input
class="radio"
type="radio"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1].$fp; ?>"
value="<?php echo $fp;?>"
<?php echo $checkedState; ?>
onclick="<?php echo $checkconditionFunction; ?>(this.value, this.name, this.type)"
/>
<?php echo $fp; ?>
</label>
</div>
Expand Up @@ -12,16 +12,16 @@
*/
?>
<li class="answer-item radio-item <?php if(isset($li_classes)){echo $li_classes;}?>">
<input
type="radio"
name="<?php echo $name; ?>"
id="<?php echo $id; ?>"
value="<?php echo $value; ?>"
class="radio"
<?php $check_ans; ?>
onclick="<?php echo $checkconditionFunction; ?>"
/>
<label for="<?php echo $id; ?>" class="answertext radio-label">
<input
type="radio"
name="<?php echo $name; ?>"
id="<?php echo $id; ?>"
value="<?php echo $value; ?>"
class="radio"
<?php $check_ans; ?>
onclick="<?php echo $checkconditionFunction; ?>"
/>
<?php echo $labeltext;?>
</label>
</li>
22 changes: 10 additions & 12 deletions application/views/survey/questions/listradio/item_noanswer_row.php
Expand Up @@ -9,19 +9,17 @@
?>
<div class="col-sm-12">
<div class="form-group answer-item radio-item no-anwser-item">
<input
class="radio"
type="radio"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1]; ?>NANS"
value=""
<?php echo $check_ans; ?>
onclick="if (document.getElementById('answer<?php echo $ia[1];?>othertext') != null) document.getElementById('answer<?php echo $ia[1]; ?>othertext').value='';<?php echo $checkconditionFunction; ?>(this.value, this.name, this.type)"
/>
<label for="answer<?php echo $ia[1]; ?>NANS" class="answertext control-label label-radio">
<input
class="radio"
type="radio"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1]; ?>NANS"
value=""
<?php echo $check_ans; ?>
onclick="if (document.getElementById('answer<?php echo $ia[1];?>othertext') != null) document.getElementById('answer<?php echo $ia[1]; ?>othertext').value='';<?php echo $checkconditionFunction; ?>(this.value, this.name, this.type)"
/>
<span>
<?php echo eT('No answer'); ?>
</span>
<?php echo eT('No answer'); ?>
</label>
</div>
</div>
18 changes: 9 additions & 9 deletions application/views/survey/questions/listradio/item_row.php
Expand Up @@ -14,16 +14,16 @@
?>
<div class="col-sm-12">
<div id='javatbd<?php echo $myfname; ?>' class='form-group answer-item radio-item' <?php echo $sDisplayStyle; ?> >
<input
class="radio"
type="radio"
value="<?php echo $ansrow['code']; ?>"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1].$ansrow['code']; ?>"
<?php echo $checkedState;?>
onclick="if (document.getElementById('answer<?php echo $ia[1]; ?>othertext') != null) document.getElementById('answer<?php echo $ia[1]; ?>othertext').value='';checkconditions(this.value, this.name, this.type)"
/>
<label for="answer<?php echo $ia[1].$ansrow['code']; ?>" class="control-label radio-label">
<input
class="radio"
type="radio"
value="<?php echo $ansrow['code']; ?>"
name="<?php echo $ia[1]; ?>"
id="answer<?php echo $ia[1].$ansrow['code']; ?>"
<?php echo $checkedState;?>
onclick="if (document.getElementById('answer<?php echo $ia[1]; ?>othertext') != null) document.getElementById('answer<?php echo $ia[1]; ?>othertext').value='';checkconditions(this.value, this.name, this.type)"
/>
<?php echo $ansrow['answer']; ?>
</label>
</div>
Expand Down

0 comments on commit e8d1020

Please sign in to comment.