Jump to content



Photo
- - - - -

Enhanced Contact Us for 2.3.1


  • Please log in to reply
63 replies to this topic

#1   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 29 January 2012 - 11:25

This is the support thread for the Enhanced Contact Us modification for OSC 2.3.1

I take no credit for this modification, all I have done is take the Contact-Us page from the Anti-Hacker-account-Mods by Spooks and made it work on 2.3.1.

I hate looking at Contact Us Pages that only contain a web-based enquiry form, I like to know who and where the shop is. This change will provide a more professional look to the stock OSC Contact Us page, with enhanced functions.

What It does:

The Enhanced Contact Us page provides more information to the customer, such as Store Address, Telephone Number, Opening Hours, Anticipated Response Times Etc. (tailor these in the language files)

Also, if the customer is logged in to their account, it pre-populates their email address and allows them to select a previous order to enquire about from a drop-down box.

The email that is sent to the store contains the originators IP address, Date and time etc.

Easy Installation - 1 New File + 2 Language file additions.
Screen shot included.

Please feel free to Improve on this - but please only post Full Packages.

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#2   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 29 January 2012 - 13:33

This is the download location: http://addons.oscommerce.com/info/8323

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#3   altoid

altoid
  • Community Sponsor
  • 1,021 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 29 January 2012 - 22:28

Please feel free to Improve on this - but please only post Full Packages.


Heather, thanks for tackling this update. Spooks did some great work on earlier versions of Osc and I have a lot of them on my 2.2 shops. The Spooks version of Contact Us add on for 2.3.1 was something I wanted to get to.

I installed and tested your version and it worked great with both a registered and non registered customer.

I made some changes to the catalog/contact_us.php file by scrubbing out some residuals from 2.2 coding. I did this using the post by Kymation. My preference is to do away with the Osc gifs such as table_background_contact_us.gif, pixel_trans.gif, etc. so I removed the coding that did that too. Lastly, to get a white background, (again my preference) I had to do some styleseet.css changes as well.

I don't plan to post anything until I let the shop sit for a little while and make sure no surprises came up because of these changes I made on top of what you did. I can only think the stylesheet change might give me some unexpected results but I don't think so. We'll see after a bit of watching how things go.

Thanks again for taking the time to do this. I know it took some time and effort on your behalf.
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#4   Joost Jacobs

Joost Jacobs
  • Members
  • 3 posts

Posted 01 February 2012 - 00:28

I needed to make some small changes, but now it works great, thanks.

#5   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 01 February 2012 - 18:32

Updated version released (V1.1)

Contains code cleanup and removal of old images by Altoid

Also now has an optional recaptch element to protect from automated contact us spam mail - by Mort Lemur

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#6   altoid

altoid
  • Community Sponsor
  • 1,021 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 02 February 2012 - 01:55

Hey Heather, again thank you for taking the initiative on this add on. Adding recaptha to contact us was yet another thing on my to do list and here ya go. Thanks for including that option. All works great. I really appreciate it.
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#7   altoid

altoid
  • Community Sponsor
  • 1,021 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 03 February 2012 - 00:17

Hey Heather, again thank you for taking the initiative on this add on. Adding recaptha to contact us was yet another thing on my to do list and here ya go. Thanks for including that option. All works great. I really appreciate it.


Just was testing the recaptcha...that works in its own right, but something has effected the result in that the body of the received email no longer contains any of this info:

Message from:
Date Sent:
Telephone Number
Client Number:

At IP:

Inquiry:

The message itself shows but none of the above.
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#8   altoid

altoid
  • Community Sponsor
  • 1,021 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 03 February 2012 - 01:28

OK...the following is probably in the ball park for the solution to get all the info returned in the recaptcha version email. Still a bug there but this "mostly" works:

Around line 40 in the "recaptcha" version replace

if (tep_validate_email($email) && ($resp->is_valid)) {
	  tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, EMAIL_SUBJECT, $enquiry, $name, $email);

with

if (tep_validate_email($email) && ($resp->is_valid)) {
	 $enquiry = MESSAGE_FROM . $name . "\n" . $date . "\n" . ($phone ? ENTRY_TELEPHONE_NUMBER .  $phone . "\n" : '' ) . ($customer_id ? MAIL_CLIENT_ID .  $customer_id . "\n" : '')  . ($orders_id ? MAIL_ORDER_ID .  $orders_id . "\n" : '') . "\n" . MAIL_IP . $xipaddress . '.' . "\n\n" . ENTRY_ENQUIRY . "\n" . $enquiry;
	  tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, EMAIL_SUBJECT, $enquiry, $name, $email);

Still needs some work as the "subject" isn't showing.

Note my signature...not a professional coder, so that disclaimer is out there.
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#9   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 03 February 2012 - 16:16

OK,

The fix for this is :

in catalog/contact_us.php find (around line 40)

if (tep_validate_email($email) && ($resp->is_valid)) {
		  tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, EMAIL_SUBJECT, $enquiry, $name, $email);


Replace with:

if (tep_validate_email($email) && ($resp->is_valid)) {
    $enquiry = MESSAGE_FROM . $name . "\n" . $date . "\n" . ($phone ? ENTRY_TELEPHONE_NUMBER .  $phone . "\n" : '' ) . ($customer_id ? MAIL_CLIENT_ID .  $customer_id . "\n" : '')  . ($orders_id ? MAIL_ORDER_ID .  $orders_id . "\n" : '') . "\n" . MAIL_IP . $xipaddress . '.' . "\n\n" . ENTRY_ENQUIRY . "\n" . $enquiry;
	  tep_mail(STORE_OWNER, STORE_OWNER_EMAIL_ADDRESS, $subject, $enquiry, $name, $email);

I have tested this several times and it works on my site.

I will post an update in due course.

My signature should read " I really dont have a clue what Im doing - Im just stumbling along"

Thanks

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#10   altoid

altoid
  • Community Sponsor
  • 1,021 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 04 February 2012 - 14:31

I have tested this several times and it works on my site.


Same here. Thank you.
I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.

#11   Billybill

Billybill
  • Members
  • 5 posts
  • Real Name:Bilal Hussain

Posted 22 February 2012 - 22:28

Hi I am trying to add my address and contact number on my contact us page and Iv tried to change it on includes/language/english/contact_us.php and nothing seems to happen.

Can someone please help

#12   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 24 February 2012 - 21:39

Hi I am trying to add my address and contact number on my contact us page and Iv tried to change it on includes/language/english/contact_us.php and nothing seems to happen.

Can someone please help


Hi,

This contribution plucks the address from the store address in Admin/configuration settings, just add your address and phone number there.

Thanks

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#13   oxwivi

oxwivi
  • Members
  • 250 posts
  • Real Name:Oxwivi Oxwil

Posted 12 March 2012 - 15:43

A little theming issue. I'm using my own jQuery UI theme, and I've attached a screen shot of how it looks. Please help!

Attached Files

  • Attached File  ECU.png   17.91KB   36 downloads


#14   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 13 March 2012 - 21:23

The contact us page is driven by catalog/stylesheet.css

Backup first then make changes to the colours called up in infobox lines until you get the result you need.

Maybe someone will update the contribution at sometime so that it works with the themeswitcher

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#15   oxwivi

oxwivi
  • Members
  • 250 posts
  • Real Name:Oxwivi Oxwil

Posted 13 March 2012 - 21:42

Backup first then make changes to the colours called up in infobox lines until you get the result you need.

Those are? I did not find anything incompatible with the jQuery UI theme before, and din't have to mess with stylesheet.css. What exactly am I looking for in there?

#16   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 13 March 2012 - 22:09

OK this contribution is a quick and dirty fix of pat of a 2.2 modification to work with 2.3.1 - it is still table driven.

You need to modify the hex code in stylesheet css to add the hex code of the colours you require. the colour is controlled by this line:

.infoBox {
  background: #ffffff;
}

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#17   Ninety-one Maro

Ninety-one Maro
  • Members
  • 49 posts

Posted 15 March 2012 - 01:33

Ok, I love this upgrade to the site. However I have 2 issues right now.

1. I did this upgrade cause I am not receiving customer emails. After doing the upgrade, I am still not receiving any emails from anyone.

2. How do I get rid of the grey background. I would like to make the background transparent.

www.RonisRingsNThings.com if you want to see what I am talking about. I have not changed any of the wording or anything yet, but just want to get it working. Other than that, the site is fully up and running. Just realized I was not getting any emails. Please help.

#18   Mort-lemur

Mort-lemur
  • Members
  • 1,964 posts
  • Real Name:Heather
  • Gender:Female
  • Location:UK

Posted 15 March 2012 - 07:29

The background is white on my screen (in Mozilla)

Check your email settings in admin-config are set to send emails

Edited by Mort-lemur, 15 March 2012 - 07:30.

Now running on a fully modded 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.


#19   Ninety-one Maro

Ninety-one Maro
  • Members
  • 49 posts

Posted 15 March 2012 - 10:41

Checked, and it was set to True. Not sure why we are not receiving customer's emails from the site. Don't know how long this has been going on for. As I stated above, I downloaded this upgrade, but it didn't fix the issue. Plus the wife didn't like the grey background (which we use Mozilla also). She ended up wanting to go back to the original for now, till we can figure it all out.

#20   altoid

altoid
  • Community Sponsor
  • 1,021 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Hollidaysburg, Pennsylvania

Posted 15 March 2012 - 12:22

@Ninety-one Maro

Hi there, I see you've made some other posts regarding email problems. I'm not a coder (see my sig) but as a suggestion since you don't know when this started considering looking back to any mods you have made that may have effected email function in osC.

Somewhile ago I was having an email problem and had to do some digging through various threads here on osC to figure out where the problem may be. I think you'll find some threads dedicated to email problems.

Another thing to consider is that sometimes the emailing issue is due to your site host set up. I think this is mentioned in some of those threads.

Anyway...I wish I could point something more specific to help you out, but I'd start with basic email functionality issues first, get those resolved, then move onto email upgrades (such as the enhanced contact, etc.) and other email tweaks.

Good luck

Edited by altoid, 15 March 2012 - 12:24.

I am not a professional webmaster or PHP coder by background or training but I will try to help as best I can.
I remember what it was like when I first started with osC. It can be overwhelming.
However, I strongly recommend considering hiring a professional for extensive site modifications, site cleaning, etc.
There are several good pros here on osCommerce. Look around, you'll figure out who they are.