X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Urgent help needed. (https://forum.x-cart.com/showthread.php?t=45599)

CollectiveInk 02-15-2009 09:13 PM

Urgent help needed.
 
I have been searching and trying to find a way to change the labels in the customer help: contact us form.
I have tried modifying the language - no luck.
I have edited the contactus.tpl - no luck.

In searching I see people have been having this same issue for a few years now. Is there no way of actually doing this?

Any help would be greatly appreciated.

Thanks,

(This is in version 4.1.9 Gold)

ARW VISIONS 02-15-2009 10:49 PM

Re: Urgent help needed.
 
which labels specifically?

ARW VISIONS 02-15-2009 10:51 PM

Re: Urgent help needed.
 
moving to template editing.

CollectiveInk 02-16-2009 05:34 AM

Re: Urgent help needed.
 
Quote:

Originally Posted by Ashley
which labels specifically?


http://i222.photobucket.com/albums/dd44/wright_family_album/misc/departments.jpg

These labels.

Needing to replace with these (below):

  1. Customer Service
  2. Retail Store Sales
  3. Online Store Sales
  4. Non-Profit Sales
  5. Marketing & Advertising
  6. Product Sourcing
Also, getting numbers 1-4 going to one address, 5 to another, and 6 to a third, how hard is that?

Any help is appreciated.

Thanks,
Tim

Gold v4.1.9

robertswww 02-16-2009 05:55 AM

Re: Urgent help needed.
 
Hi Tim,

To add additional "Departments", you will need to edit the file:
skin1/help/contactus.tpl

Additional details...

NOTE: To get the additional departments to show, you may need to comment out the 2 IF statements around Line 240 and Line 244:
{* {if $default_fields.department.avail eq 'Y'} *}
{* {if $default_fields.department.required eq 'Y'} *}

and the 2 closing IF statements around Line 246 and Line 260:
{* {/if} *}
{* {/if} *}

Then, just insert your additional departments into a new option around Line 250, for example to add Advertising to the drop-down:
<option value="Advertising">{$lng.lbl_advertising}</option>

You will probably want to create your own labels.

Robert

CollectiveInk 02-16-2009 08:51 AM

Re: Urgent help needed.
 
Quote:

Originally Posted by robertswww
Hi Tim,

To add additional "Departments", you will need to edit the file:
skin1/help/contactus.tpl

Additional details...

NOTE: To get the additional departments to show, you may need to comment out the 2 IF statements around Line 240 and Line 244:
{* {if $default_fields.department.avail eq 'Y'} *}
{* {if $default_fields.department.required eq 'Y'} *}

and the 2 closing IF statements around Line 246 and Line 260:
{* {/if} *}
{* {/if} *}

Then, just insert your additional departments into a new option around Line 250, for example to add Advertising to the drop-down:
<option value="Advertising">{$lng.lbl_advertising}</option>

You will probably want to create you own labels.

Robert


First off, thanks for your help Robert.

Ok, I added the comment out markings, and the previous changes were visible. I added the additional names and they all disappeared. 8O

Here is the code I currently have (red bold is what I added to comment out):

{* {if $default_fields.department.avail eq 'Y'} *}
<tr valign="middle">
<td class="FormButton">{$lng.lbl_department}</td>
<td> {* {if $default_fields.department.required eq 'Y'} *}<font class="Star">*</font>{* {/if} *}</td>
<td nowrap="nowrap">
<select id="department" name="department">
<option value="All" {if $smarty.get.type eq ""}selected="selected"{/if}>{$lng.lbl_all}</option>
<option value="Customer Service">{$lng.lbl_cs}</option>
<option value="Retail Store Sales" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_retail}</option>
<option value="Online Store Sales" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_onlinestore}</option>
<option value="Non-Profit Sales">{$lng.lbl_npsales}</option>
<option value="Marketing & Advertising">{$lng.lbl_markad}</option>
<option value="Product Sourcing">{$lng.lbl_sourcing}</option>
</select>
</td>
</tr>
{* {/if} *}

----------------
So now I need to go under languages, and create labels (lbl_cs, lbl_retail, etc.) right?

Is there a place to direct each of those to particular emails? (as with traditional html/php forms)

robertswww 02-16-2009 09:43 AM

Re: Urgent help needed.
 
Hi Tim,

Yes, you will need to create new language labels for your new departments or alternately hard-code them in.

Your updated code looks similar to what we are using, but we do not have the if $smarty conditions (so you may need to remove them if they cause a problem)...

Here's a sample of our code:
Code:

{* {if $default_fields.department.avail eq 'Y'} *}
<tr valign="middle">
<td class="FormButton">{$lng.lbl_department}</td>
<td>
{* {if $default_fields.department.required eq 'Y'} *}
<font class="Star">*</font>
{* {/if} *}
</td>
<td nowrap="nowrap">

<select id="department" name="department">
<option value="All" selected="selected">{$lng.lbl_all}</option>
<option value="Advertising">{$lng.lbl_advertising}</option>
<option value="Sales">{$lng.lbl_sales_dept}</option>
<option value="Webmaster">{$lng.lbl_webmaster}</option>
</select>
</td>
</tr>
{* {/if} *}


You may also need to Clear your Templates Cache and/or Force Cache Generation from your Admin --> Summary --> Tools screen.

---

The emails will be sent to whatever you put as your Help/Support department e-mail address in your Admin --> Company Options. We have not had the need to send to different emails, but you could possibly do this one of two ways:

1. Have the "Department" added to the Subject line of the email and then use an email rule or filter to sort and/or forward the email.

2. Try to make a mod that would do what you are asking... look at the thread "Multiple email notifications" for some ideas:
http://forum.x-cart.com/showthread.php?t=19973

Robert

CollectiveInk 02-16-2009 10:00 AM

Re: Urgent help needed.
 
Robert,

You are truly helpful, thank you.

I added the labels and eventually got the names to display.
http://i222.photobucket.com/albums/dd44/wright_family_album/misc/departments2.jpg

I did have to comment out a different section first and add a subsequent {if} statement for the last three labels:

{* {if $default_fields.department.avail eq 'Y'} *}
<tr valign="middle">
<td class="FormButton">{$lng.lbl_department}</td>
<td> {* {if $default_fields.department.required eq 'Y'} *}<font class="Star">*</font>{* {/if} *}</td>
<td nowrap="nowrap">
<select id="department" name="department">
{* <option value="All" {if $smarty.get.type eq ""}selected="selected"{/if}>{$lng.lbl_all}</option> *}
<option value="Customer Service">{$lng.lbl_cs}</option>
<option value="Retail Store Sales" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_retail}</option>
<option value="Online Store Sales" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_onlinestore}</option>
<option value="Non-Profit Sales" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_npsales}</option>
<option value="Marketing & Advertising" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_markad}</option>
<option value="Product Sourcing" {if $smarty.get.type eq "whole"}selected="selected"{/if}>{$lng.lbl_sourcing}</option>
</select>
</td>
</tr>
{* {/if} *}

______

My client is wanting the three different email notifications (different departments). Where would I add the "department" to the subject line? I know their IT should be able to filter it based on that.

Thanks again.

Tim

robertswww 02-16-2009 10:58 AM

Re: Urgent help needed.
 
Quote:

Originally Posted by CollectiveInk
My client is wanting the three different email notifications (different departments). Where would I add the "department" to the subject line? I know their IT should be able to filter it based on that.

Hi Tim,

Glad I could be of help. Since you are asking for it, I decided to add on the Department to the email subject line to our company emails as well. I just tested the code below, and it works...

Original Fle: skin1/mail/help_contactus_subj.tpl
{config_load file="$skin_config"}{ $config.Company.company_name }: {$lng.eml_contact_us_subj}

You can see above that it pulls your Company Name and then the value of the email label eml_contact_us_subj into the Subject Line of the email.

So, we just need to add on the Department variable, {$contact.department}, as follows:

Code:

{config_load file="$skin_config"}{ $config.Company.company_name }: {$lng.eml_contact_us_subj} - {$contact.department}

You can move the department variable somewhere else in the subject line if you prefer.

Cheers!

Robert

CollectiveInk 02-16-2009 11:30 AM

Re: Urgent help needed.
 
You truly have been very helpful!

My hats off to you. :D/

Thank you again.


All times are GMT -8. The time now is 07:13 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.