Community Add-Ons

Maintainers: comclusive
Add file to this package
Top » Features

Home or Business Customer
for osCommerce Online Merchant v2.2

This is my first full mod. I hope you like it.

This mod adds a business or home user function when creating an account. Once created, the customer cannot change the type of account themselves, it has to be requested and done through the admin panel.

I have also included an optional section in this contrib, which will allow different maximum addresses for home and business customers. This is set through the admin panel, so a home user could be given 2 addresses and a business user could be given 5, for example.

The requirement for entering home or business user can be turned on and off via the admin panel, and if the extra addresses part has been installed and the requirement turned off, the max addresses defaults to the home user setting.

Screenshots Included

If you have any issues or updates, please use the forum

The forum for this contrib is

http://forums.oscommerce.com/index.php?showtopic=233891

Legend:  Download   Report
Expand All / Collapse All
Activate/desactivate the field COMPANY when choosing between HOME or BUSINESS usertype DuFF1 28 Jan 2009  

You can activate/desactivate the field COMPANY when choosing between HOME or BUSINESS usertype.


In file /catalog/create_account.php:


Replace this line:
------------------

<td class="main"><?php echo tep_draw_radio_field('usertype', 'h') . '&nbsp;&nbsp;' . HOME . '&nbsp;&nbsp;' . tep_draw_radio_field('usertype', 'b') . '&nbsp;&nbsp;' . BUSINESS . '&nbsp;' . (tep_not_null(ENTRY_USERTYPE_TEXT) ? '<span class="inputRequirement">' . ENTRY_USERTYPE_TEXT . '</span>': ''); ?></td>

With:
-----

<td class="main"><?php echo tep_draw_radio_field('usertype', 'h', '', 'onclick=company.disabled=true') . '&nbsp;&nbsp;' . HOME . '&nbsp;&nbsp;' . tep_draw_radio_field('usertype', 'b', '', 'onclick=company.disabled=false') . '&nbsp;&nbsp;' . BUSINESS . '&nbsp;' . (tep_not_null(ENTRY_USERTYPE_TEXT) ? '<span class="inputRequirement">' . ENTRY_USERTYPE_TEXT . '</span>': ''); ?></td>


Replace this line:
------------------

<td class="main"><?php echo tep_draw_input_field('company') . '&nbsp;' . (tep_not_null(ENTRY_COMPANY_TEXT) ? '<span class="inputRequirement">' . ENTRY_COMPANY_TEXT . '</span>': ''); ?></td>


With:
-----

<td class="main"><?php echo tep_draw_input_field('company', '', 'disabled') . '&nbsp;' . (tep_not_null(ENTRY_COMPANY_TEXT) ? '<span class="inputRequirement">' . ENTRY_COMPANY_TEXT . '</span>': ''); ?></td>


-------------------------------------------

DuFF1!

Home or Business Fixed, V1.3 LED-Store 3 Feb 2008  
You Need To Add More To SQL File kustomjs 7 Oct 2007  
Home or Business Fixed... Again! comclusive 28 Oct 2006  
Home or Business Fixed comclusive 27 Oct 2006  
Home or Business Customer comclusive 26 Oct 2006