NorthWind Posted May 17, 2006 Share Posted May 17, 2006 [code]$num=0; while ($row = @mssql_fetch_array($result3)) { $num++; $itemCode=$row["itemCode"]; $description_query = "SELECT * FROM Inventory where itemCode = '$itemCode'"; $description_result = mssql_query($description_query, $link); $description_row = @mssql_fetch_array($description_result); $description=$description_row["description"];$serial=$row["serial"];echo "<tr align='left'>";echo" <td><input name='no[]' type='text' id='no1' size='3' value=$num></td>"; echo" <td><input name='description[]' type='text' id='description' size='70' value=$description></td>"; echo" <td><input name='serial[]' type='text' id='serial' value=$serial></td>";[/code]ok this is my code. the problem is, im pulling stuff off the db and listing them 1 by 1 in text boxes. so i used txtbox arrays. the problem is when i try to pull and list data which has two or more words in it (like field name has John Doe), the code just shows John. The array doesnt get the whole thing.Is there a way to make the array show all? Thanks Link to comment https://forums.phpfreaks.com/topic/9835-textbox-array-problem/ Share on other sites More sharing options...
samshel Posted May 17, 2006 Share Posted May 17, 2006 try value="$num"instead of value=$numin textbox tagsimilarly for all textboxes...hth Link to comment https://forums.phpfreaks.com/topic/9835-textbox-array-problem/#findComment-36529 Share on other sites More sharing options...
NorthWind Posted May 17, 2006 Author Share Posted May 17, 2006 thank u Samuel it worked like magic ;)[!--quoteo(post=374580:date=May 17 2006, 02:56 PM:name=samshel)--][div class=\'quotetop\']QUOTE(samshel @ May 17 2006, 02:56 PM) [snapback]374580[/snapback][/div][div class=\'quotemain\'][!--quotec--]try value="$num"instead of value=$numin textbox tagsimilarly for all textboxes...hth[/quote] Link to comment https://forums.phpfreaks.com/topic/9835-textbox-array-problem/#findComment-36531 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.