This forum is in READ-ONLY mode.
You can look around, but if you want to ask a new question, please use the new forum.
Home » legacy support » symfony 1.0 » Save the array alue
Save the array alue [message #87504] Wed, 28 October 2009 12:19 Go to next message
kayalvizhi  is currently offline kayalvizhi
Messages: 2
Registered: October 2009
Location: Chennai
Junior Member
I give the input like an array format

A1 A2 A3

B1 B2 B3

C1 C2 C3 ..
How to save this array into database

in template i have input field as

<table align="center">
<?php for($r=0; $r < $noofrows; $r++) { ?>
<tr height="30px">
<?php for ($c=0; $c < $noofcolumns; $c++) { ?>
<td> <?php //echo input_tag('txtSeatno', $sf_params->get('txtSeatno'), array('size' => 4, 'maxlength' => 3, 'class '=> 'tbox', 'id' => 'txtSeatno', 'Value' => 0)); ?>
<input type="text" name="txtSeatno[]" id="txtSeatno" maxlength="3" class="tbox" value="0" size="4"/> </td>
<?php } ?>
<?php } ?>
Re: Save the array alue [message #96751 is a reply to message #87504 ] Sat, 03 April 2010 19:27 Go to previous message
halfer  is currently offline halfer
Messages: 9535
Registered: January 2006
Location: West Midlands, UK
Faithful Member
Are these all for one record, or is it one row of input boxes per one row in the db?

Remember Palestine
Previous Topic:Strange return sfView::NONE behaviour
Next Topic:component and forward
Goto Forum:

powered by FUDforum - copyright ©2001-2004 FUD Forum Bulletin Board Software