Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Modify a text field into a textarea field


ninjadile

Recommended Posts

Hi everybody,

 

I am trying to customize the account_create.php file and I would like to change the suburb text field into a textarea field, with a least 3 rows.

 

I don't know what part ofthe code to modify in order to do that.

 

I identified the tep_draw_input_field in the html_output.php file but I wonder if I need to modify this one in order to draw a textarea

 

Can anybody help me with this? Did somebody do that already?

Link to comment
Share on other sites

no you need to modify the catalog\create_account.php and add the extra entries there. Search for:

 

<td class="main"><?php echo ENTRY_SUBURB; ?></td>

 

and duplicate the rows/cell for the extra suburb fields. Afterwards you need to handle the user input in the action switch at the beginning of the file.

Link to comment
Share on other sites

You will also have to edit the customers table in the database to accept the new fields.

 

Also, you will have to edit any other pages where the new customer info appears, not just the create_account.php file, for example the account_edit.php, and the checkout_confirmation.php pages.

Link to comment
Share on other sites

You will also have to edit the customers table in the database to accept the new fields.

 

Also, you will have to edit any other pages where the new customer info appears, not just the create_account.php file, for example the account_edit.php, and the checkout_confirmation.php pages.

no you don't have to. Because you can concatenate all the suburb fields into one and use the same database column and just extend the entry_suburb column to accomodate longer strings.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...