0
<HTML><HEAD>
<?php
$ids = ("number.txt");
$id = file($ids);
   echo  $id[0]
 ?>
  <INPUT value=("$id[0]")  name="number"> 
</HEAD><BODY>
 
</BODY></HTML>

How come <INPUT value=("$id[0]") dos not = the out put 5 or what ever ("number.txt") is ?

it should be in a read only text box id = number.

2
Contributors
2
Replies
7
Views
6 Years
Discussion Span
Last Post by Kniggles
0
<html>
<head>
</head>
<body>
<?php
$ids = ("numbers.txt");//make sure the file is in the same directory as the php script
$id = file($ids);
?>
<input value="<?php echo $id[0];?>" name="number" readonly="readonly" />
</body>
</html>

I hope this help, else please state your objective clearly

0
<html>
<head>
</head>
<body>
<?php
$ids = ("numbers.txt");//make sure the file is in the same directory as the php script
$id = file($ids);
?>
<input value="<?php echo $id[0];?>" name="number" readonly="readonly" />
</body>
</html>

I hope this help, else please state your objective clearly

<html>
<head>

<?php
$ids = ("numbers.txt");//make sure the file is in the same directory as the php script
$id = file($ids);
?>
<input value="<?php echo $id[0];?>" name="number" readonly="readonly" />


</head>
<body>

</body>
</html>

thank you very much saadsaidi , had to move it to the head and it seems to work very well, thank you again. :)

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.