-2
<label class="control-label" for="inputEmail">First Name:</label>
<div class="controls">
<input type="text" class="span4" id="inputEmail" name="firstname"  value="<?php echo $row['firstname']; ?>" placeholder="First Name" required>
<input type="hidden" id="inputEmail" name="id" value="<?php echo $get_id;  ?>" placeholder="First Name" required>     
Rizier123
  • 58,877
  • 16
  • 101
  • 156
jean ko
  • 1
  • 1
  • 3
  • What do you want to make readonly? #inputEmail? – Manuel Arwed Schmidt Feb 21 '15 at 10:35
  • What is the question here? How to make an input field / a textarea readonly is well documented. You just have to take a look at the documentation and you have your answer. – arkascha Feb 21 '15 at 10:37
  • This question is somewhat [Already answered](http://stackoverflow.com/questions/16109358/readonly-attribute-syntax-for-input-text) – Saubar Feb 21 '15 at 10:38

2 Answers2

1

Use the readonly attribute if you want to make a textfield readable only.

An example:

<input type="text"value="foo"readonly>

From your code

<label class="control-label" for="inputEmail">First Name:</label>
<div class="controls">
<input type="text" class="span4" id="inputEmail" name="firstname"  value="<?php echo $row['firstname']; ?>" placeholder="First Name"readonly>
<input type="hidden" id="inputEmail" name="id" value="<?php echo $get_id;  ?>" placeholder="First Name" readonly>     
student
  • 64
  • 10
0

If you want to make inputEmail a readonly field, you can use

<label class="control-label" for="inputEmail">First Name:</label>
<div class="controls">
<input type="text" class="span4" id="inputEmail" name="firstname"  value="<?php echo $row['firstname']; ?>" placeholder="First Name" required readonly>
<input type="hidden" id="inputEmail" name="id" value="<?php echo $get_id;  ?>" placeholder="First Name" required>  

Note that I've added the readonly at the end of the input tag in line 3.

Manuel Arwed Schmidt
  • 3,376
  • 2
  • 18
  • 28