-
Re: Can't get "referrals " mod working
Yeah i actually just fixed it by changing it to what you had on my own.
Basically: if ( zen_not_null($referrals['sources_name']) ) {
had to be changed to: if ( zen_not_null($referrals->fields['sources_name']) ) {
I did have one more question though - on the customer account creation for the referals dropdown it appears to be pulling Please choose your country for the default selection of the dropdown list, underwhich my input referral sources are located. Any thoughts on how to change this?
Thanks again and ranger lp you're awesome :)
-
Comments on the "referrals " mod
I just finished adding this mod to my ZenCart 1.38a site.
1. Before installing I checked all of the files which might exist in my site with WinMerge. Obviously there would not be any problems with any of the "referral" files since they only exist in the mod. The ones to check for possible confilcts with other mods you may have are:
admin/customers.php
admin/orders.php
includes/modules/create_account.php
includes/templates/YOUR_TEMPLATE/templates/tpl_modules_create_account.php
2. The database update was done by pasting the contents of the install_referrals.sql file into Admin>Tools>Install SQL Patches. It is useful and informatiive to use phpMyAdmin to verify the changes to the database.
3. Since I plan to use both this mod and the Discount Coupon Referral feature in ZenCart, I modified the language files to change the headers. The title for the upper box for this mod now reads "How Did You Hear About Us?" and the lower box for the coupon is now titled "Do You Have A Discount Coupon?". This is less confusing for the customer.
4. I have Admin>Configuration>Customer Details>Require Referral = FALSE and Admin>Configuration>My Store>Display "Other" Referral option = TRUE. The less information that is REQUIRED, the more likely that the customer will complete the registration. Better to use a carrot (like the discount coupon) than a stick.
5. When I create a customer and enter a Referral Source, the source is shown in BOTH Admin>Customers>Customers>"Referred By" AND in Admin>Extras>Referral Sources.
6. When I enter a discouint coupon code ONLY, the "Referred By" column reads "--none--". The couipon code is shown in the side box under "1st Discount Coupon" when you select the customer. The coupon does NOT show up in Admin>Reports>Customers Referral until AFTER the coupon is applied to a purchase.
7. Admin>Extras>Referred Sources counts BOTH those customers who listed "Other" as the referral source and those who did NOT enter any referral source as "Other". When you double click on the "Others" it displays only those who listed an "Other" source. I haven't found where this field is populated to see if I can correct it. NOTE: "Other" has a code of "9999" in the database and the default value for those with NO referral source is "0".
I think this mod will be very useful for market tracking, but there are still odd glitch or two to fix. :cool:
-
Re: Can't get "referrals " mod working
Ah in reference i found the default language it was pulling in my english file. Seems silly that it references a generic default drop down option for any menu for a specific dropdown such as country - but it's been replaced.
-
Re: Can't get "referrals " mod working
Hi all,
I installed:
Zen Cart™ Version: v1.3.8
Version: 1.3.8.a
Last Updated: Dec 30 2007
Author: CnTGifts
The "how do you hear about us" does appear on the log in page. However, the information the customers posts does not appear in Admin/customers or Admin/extras/referel sources. Admin/customers shows (referered by is --none--) and
Admin/extras/referel sources shows (other............2).Once i click on it, it disappears, nothing else happens. Also, even if i state that the referrals by customers is required, customers can still carry on without entering anything.
I did the following:
1) Unpack the zip file to a temporary directory on my hard drive.
2)Changed the name of the folder "YOUR-TEMPLATE" to my own templatename. This folder is found in the includes/templates folder.
3)Upload through FTP the includes and admin folders into my web server.
4)Run install_referrals.sql in Zen cart Install SQL patch.
I can't seem to figure out why its not fully functioning even though i follow exactly the instructions. Also read all the threads in here and somehow see some similar issues faced but still not able to figure out. Really need my fellow zenners assistance.:blush:
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
fakesharksfinsoup
Hi all,
I did the following:
1) Unpack the zip file to a temporary directory on my hard drive.
2)Changed the name of the folder "YOUR-TEMPLATE" to my own templatename. This folder is found in the includes/templates folder.
3)Upload through FTP the includes and admin folders into my web server.
4)Run install_referrals.sql in Zen cart Install SQL patch.
One thing to watch out for...Don't install the SQL patch by executing the file from the patch tool. Open the install_referrals.sql file with a text editor like Notepad and copy the instructions and then PASTE them into the SQL query window. Personally I prefer to use phpMyAdmin instead of the SQL Patch tool because after the script finishes I check the database to see that the expected tables have been installed. But either should work. It should have installed 2 tables, SOURCES and SOURCES_OTHER. If you are seeing the drop donw box with the referral sources in the Create Account form, that's OK. Most important, it should have ADDED the "customers_info_source_id" column to the CUSTOMER_INFO table.
Did you test the addon by selecting one of the preset sources? Like Google? It should appear in both Admin>Customers>Customers>"Referred by" and Admin>Extras>Referrals.
When you first open Admin>Extras>Referrals the number you see for "Other" includes those customers who selected "Other" for the referral AND those customers who did NOT supply any information. When you double click the "Other" category, only those who selected "Other" are displayed.
Hope this helps.
-
Re: Can't get "referrals " mod working
Hi mauryg, thanks for your kind reply.
I rechecked the tables.
It has ADDED the "customers_info_source_id" column to the CUSTOMER_INFO table.It has installed 2 tables, SOURCES and SOURCES_OTHER also.
So still dont know whats wrong? It seems i will not be able to use this add-on feature as the data entered by the customer is not captured.
Anyone has a remedy for this?
-
Re: Can't get "referrals " mod working
Fakesharksfinsoup,
OK let's see where we stand.
You said that you could see the Referrals box on the "login" page, but I assume that you mean the "Create Account" section. I am using a split login so the Create Account section is a separate page.
I assume that:
1. You can see "Require Referral" under Admin>Configuration>Customer Details and that you have set it to "True" or "False" as you wish. I prefer False so as not to annoy my customers.
2. You can see "Display Other Referral option" on the Admin>Configuration>My Store menu and you have set it to "True".
Then you should be able to see BOTH the drop down menu for the preset referral sources AND the text box for the "Other" source information.
3. You have "Referrals" and "Referral Sources" as options under the Admin>Extras menu and that the "Referrals" option is populated with a number of suggested sources (e.g. Google, AOL, etc.)
If all of the above is true then you probably have installed the mod correctly, but I would still click through the directories to make sure all of the mod files are installed where they belong.
That's the simple part...
You said you are using ZenCart v1.38a. I just went back and checked the 4 files which I thought might give the most difficulty because of other mods added and there were no real conflicts. If you have the latest version of the How Did You Hear About Us mod they are essentially v1.38a based files. So you should be OK.
Can you give me a link to your site so I can look at it?
-
Re: Can't get "referrals " mod working
hi mauryg,
Thanks for the effort!
For points 1 -3, i am seeing it all in admin.
Just a little background,
i install the following before:
Minimum_order_amount mod
stock_by_attribute_v4_7 mod
how_did_you_hear_about_us mod
newsletter_subscriber_v210 mod
www.ecosports.com.sg/onlinestore is my website, still offline at the moment.
-
Re: Can't get "referrals " mod working
Hi Fakesharksfinsoup,
I looked at your site and everything seems to be in place on the store side.
I would recheck that ALL of the files were uploaded to the proper directories and that if you are using any override folders, e.g. in the languages folder, that the files are placed properly.
If I were having this problelm, the next thing I would do is browse the database with phpMyAdmin and check the tables directly to see if anything is added when a new account is created. You should see a new row added to the CUSTOMER table and the CUSTOMER_INFO table and if you selected one of the preset referral choices, you should see the ID number of that choice in the customers_info_source_id column. If you select "Other" and type something in the box, then that should appear in the SOURCES_OTHER table along with the customer ID> At least you'll be able to decide if the problem is on the input side or the data is just not getting displayed in the admin panel.
It really is a pretty straight forward mod, Without being able to look at the database or the admin side, I don't what else to suggest.
Hope this helps.
-
Re: Can't get "referrals " mod working
@ fakesharksfinsoup
I get the same as you for referral by - none. It only happens when people checkout via Express Checkout or Pay through credit card (Paypal API) without previously creating an account.
If they create an account first, everything works fine for me.
Maybe just a bug that needs to be worked out.
Good Luck!
-
Re: Can't get "referrals " mod working
OK, I hope someone can help me because I screwed up and did not do a backup before uploading the files :cry:
The module seems to be working fine BUT I now cannot pull up the customer and/or order lists. I get the following error:
Fatal error: Call to undefined function: zen_get_customers_address_book() in /.../customers.php on line 1125 (address edited for security)
This is the line:
$zc_address_book_count_list = zen_get_customers_address_book($customers->fields['customers_id']);
I get a similar fatal error in orders.php on line 819
This is the line:
<td class="dataTableContent" align="center"><?php echo (zen_get_orders_comments($orders->fields['orders_id']) == '' ? '' : zen_image(DIR_WS_IMAGES . 'icon_yellow_on.gif', TEXT_COMMENTS_YES, 16, 16)); ?></td>
Any suggestions as to where I go from here??
-
Re: Can't get "referrals " mod working
I'm getting the following error:
1065 Query was empty
in:
[]
I know this is happening because a selection other than 'Other' was chosen from the dropdown and nothing was put in the 'Other' field. What I don't know is WHY this is happening. Anyone got any ideas?
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
fakesharksfinsoup
Hi all,
I installed:
Zen Cart™ Version: v1.3.8
Version: 1.3.8.a
Last Updated: Dec 30 2007
Author: CnTGifts
The "how do you hear about us" does appear on the log in page. However, the information the customers posts does not appear in Admin/customers or Admin/extras/referel sources. Admin/customers shows (referered by is --none--) and
Admin/extras/referel sources shows (other............2).Once i click on it, it disappears, nothing else happens. Also, even if i state that the referrals by customers is required, customers can still carry on without entering anything.
I did the following:
1) Unpack the zip file to a temporary directory on my hard drive.
2)Changed the name of the folder "YOUR-TEMPLATE" to my own templatename. This folder is found in the includes/templates folder.
3)Upload through FTP the includes and admin folders into my web server.
4)Run install_referrals.sql in Zen cart Install SQL patch.
I can't seem to figure out why its not fully functioning even though i follow exactly the instructions. Also read all the threads in here and somehow see some similar issues faced but still not able to figure out. Really need my fellow zenners assistance.:blush:
Mine was not working, cracked my brain, killed billions of brain cells, and read through many pages in this thread, I finally got it working, so I am posting this in case anyone is in the same situation as I was.
Cart: 1.38a
Mods added:
+ how do you hear from us
+ newsletter only mod
I realized that I did everything correct while installing the referrals mod, but the records are not showing in the admin>customers>customers; nor was it showing in the extra>referral source
I noticed that the installation pack (createaccount) wasn't really pointing to the right directory since I am running a customized template (apple_zen).
In included/modules/create_account.php, it's not overriding on my custom template directory on the server.
(if you are attempting what I did, please save the original file in a temp directory, in case it doesn't work for you, you can reinstate the original file)
My newsletter only mod file is, so it's already overridden with the newsletter only file, I do not want to override the current create account file (which may means my newsletter instruction only may be lost), I opened up the original referral create_account.php file and the copy in my apple_zen directory (create_account.php) and match the 2 files.
Do take note of the 'rmh' code throughout the file, copy and paste them into the original file.
Line 78:
//rmh referral start
$source = zen_db_prepare_input($_POST['source']);
if (isset($_POST['source_other'])) $source_other = zen_db_prepare_input($_POST['source_other']);
//rmh referral end
Line 239:
//rmh referral start
if ((REFERRAL_REQUIRED == 'true') && (is_numeric($source) == false)) {
$error = true;
$messageStack->add('create_account', ENTRY_SOURCE_ERROR);
}
if ((REFERRAL_REQUIRED == 'true') && (DISPLAY_REFERRAL_OTHER == 'true') &&($source == '9999') && (!zen_not_null($source_other)) ) {
$error = true;
$messageStack->add('create_account', ENTRY_SOURCE_OTHER_ERROR);
}
//rmh referral end
Line 320:
//rmh referral start
$query_insert= "insert into " . TABLE_CUSTOMERS_INFO . " (customers_info_id, customers_info_number_of_logons, customers_info_date_account_created, customers_info_source_id) values ('" . (int)$_SESSION['customer_id'] . "', '0', now(), '". (int)$source . "')";
$db->Execute($query_insert);
$db->Execute($sql);
if ($source == '9999') {
zen_db_perform(TABLE_SOURCES_OTHER, array('customers_id' => $_SESSION['customer_id'], 'sources_other_name' => $source_other));
}
// $sql = "insert into " . TABLE_CUSTOMERS_INFO . "
// (customers_info_id, customers_info_number_of_logons,
// customers_info_date_account_created)
// values ('" . (int)$_SESSION['customer_id'] . "', '0', now())";
//
// $db->Execute($sql);
//rmh referral end
For line 320, take note not to have duplicate instruction, otherwise, when you try to create a dummy account, and hit submit, you will get an error message of duplicate.
Now, I created 2 dummy account, one to select a preset 'saplanet blog' selection; one to select 'other' and specified in the text box, I am now able to see the records in the admin>customers>customers>; and also in the admin>extras>referrals source.
Hope this helps.
-
Re: Can't get "referrals " mod working
just to mention, I am not an expert, so I don't know any smarter way, this is just what works for me, hence the sharing.
-
Re: Can't get "referrals " mod working
Hey, I was not recorded data in the bbdd and therefore in the admin. In the admin leave as all others. Someone can help me? thank you very much at all...
-
Re: Can't get "referrals " mod working
Hey, I think I've done everything right, but I get all the records as "other", does not record the option chosen by the customer always comes out "other". I have checked the databases and everything is correct. Help, please! Thank you
-
Re: Can't get "referrals " mod working
Hi there,
My head is fried from this now. :frusty:
I follow saplanets steps and uploaded. Nothing has changed so I presume it was setup the same way in the first place.
So, none of my data is appearing in the admin. Right now in admin>extras>referral sources I have 33 'other' sources. When I click into it, there is no data it simply says 'Displaying 0 to 0 (of 0 referral sources)'!! Where's my data gone?
Any advice much appreciated.
Thanks a million
-
Re: Can't get "referrals " mod working
Have a look in "referrals" rather than "referral sources".
"referral sources" seems to be for the original zencart referral code module.
-
Re: Can't get "referrals " mod working
I just installed 138a-rev2 and merged the files where needed.
All fields show on the register page, drop down can be selected. Form processes.
Admin:
In admin - customers I see the column Referred By but the selection that was made at registration is not showing up. It shows just --none-- but I did select a source at registration. Seems like it did not post to the db?
Also in Referral Sources no listing of the selected source. Referral has all the pre defined sources I set up.
Does anybody have an idea where I should start to look?
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
saplanet
us
+ newsletter only mod
I realized that I did everything correct while installing the referrals mod, but the records are not showing in the admin>customers>customers; nor was it showing in the extra>referral source
I noticed that the installation pack (createaccount) wasn't really pointing to the right directory since I am running a customized template (apple_zen).
In included/modules/create_account.php, it's not overriding on my custom template directory on the server.
Great advice....! The issue I was having with ZC 1.3.8A and this module was solved.
I had been saving the edited 'create_account.php' file in the default folder, and not my custom template.
BUT---when I installed the captcha module last week, I placed THAT create_account.php file in the right folder. So, while captcha worked, neither the DOB pulldown or this module worked. )Because there was a filename in the override template folder with the asme name, ZC was IGNORING the changes I was making to the file in the default directory!)
Both DISPLAYED correctly, but did not pass any values or strings (corresponding to the new mods) to ZC.
The DOB pulldown displayed, but ZC kept telling me the data was not in the right format once I'd submit.
As for the Referrals module, everything displayed Ok on the user's side also, but nothing happened changed in the database once the create_account.php form was submitted.
In the admin, there was an option tomake the Referrals mandatory...
I also had two extra options in Extras - Referrals and Referral Sources.
Referrals was changeable via the admin, but when I'd click on Referral Sources, all I'd get is:
'Other' in one column , and a count of how many times 'other' was selected.
So...the override issue solved both modules having issues.
I hope that my description of what an override issue, (the create_account.php changes not being processed) looks like for both this module, as well as the DOB pull down menu.
Many thanks--I overlooked the obvious.... :dontgetit
Have to start with more simple solutions..... :dontgetit:dontgetit
-
Re: Can't get "referrals " mod working
Wow, this was it!
included/modules/create_account.php
should go into:
included/modules/YOUR_TEMPLATE/create_account.php
-
Re: Can't get "referrals " mod working
Just checked back on this post for the first time in months and finally the answer to my problem. Thanks very much Donn and mydanilo :D
-
Re: Can't get "referrals " mod working
My apologies if this has been asked and answered previously in this thread...I looked but my eyes are crossing and I may have easily missed it LOL
I just went into admin to check the "Other" sources and found an error message because someone had used an apostrophe in what they wrote...is there a fix already for this? Or an easy fix if one doesn't exist yet? I deleted the apostrophe in PHPMyAdmin before copying the error message :oops: LOL TIA :)
-
Re: Can't get "referrals " mod working
Ok, so I've been reading in this thread but I still can't seem to solve the problem of why I'm not getting my customer's response. The referred by field is blank for my customers. Can anybody help me out here?
Ian
www.examplecart.com
login: visitor
password: chickenlips
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
Johns0114
Hi there,
My head is fried from this now. :frusty:
I follow saplanets steps and uploaded. Nothing has changed so I presume it was setup the same way in the first place.
So, none of my data is appearing in the admin. Right now in admin>extras>referral sources I have 33 'other' sources. When I click into it, there is no data it simply says 'Displaying 0 to 0 (of 0 referral sources)'!! Where's my data gone?
Any advice much appreciated.
Thanks a million
Hi, I have the exact same problem, did you sort this out?
I have tried everything, what does it mean by 'comparing' files?
Does anyone have the code for the files that SHOULD be uploaded?
Thanks a million!!!!!!!
-
Re: Can't get "referrals " mod working
I'm having a different problem to everyone else with this mod.
At the bottom of my create account page is...
How did you hear about us:
Fatal error: Call to undefined function zen_get_source_list() in /home/aroma/public_html/includes/templates/template_default/templates/tpl_modules_create_account.php on line 189
And now no one can create an account.
I'm using v1.3.0.1 and it hasn't been upgraded.
Server Host: web001.nz.serveweb.net (120.138.17.201) Database Host: localhost (127.0.0.1)
Server OS: Linux 2.6.18-6-xen-686 Database: MySQL 5.0.81-community
Server Date: 07/16/2009 01:36:10 Database Date: 07/16/2009 01:36:10
Server Up Time: 01:36:10 up 101 days, 23:22, 0 users, load average: 1.42, 1.54, 1.70
PHP Version: 5.2.9 (Zend: 2.2.0)
Everything has been ticking along fine until I decided this mod looked fun. I downloaded the 1.3.x.x version. 37kb.
It's taken me several hours to work out how to access the sql file to read it, however it's the same as the beginning of this post. I've put the create account php file in mytemplates as suggested.
Please help asap
Thanks
Tarn
-
Re: Can't get "referrals " mod working
I got it sorted. I cleared it all out, uploaded the original files (yes, I still have the 1.3.0 file set) and this evening whilst it was all quiet on my website as most sane people are in bed by this time, I uploaded all the files again - except the sql script as I have no idea how to delete one of them - and it worked!!!!
So I'm happy - oh, and I put all the files in the same place the download says to put them.
:-)
-
Re: Can't get "referrals " mod working
I also was having trouble with the refers not showing up. I went back through and found that I had not put modules/customers.php into my templete folder!!! fixed that and IT WORKS!!!!
-
Lucky Number 7
Well I had no installation problems with this script, smooth as silk. Although I did place more than one file in my overrides directories.
However I seem to have an extra '7' appearing in my count for 'Referral Sources'??
Where it should be '0' it's '70'
Where it should be '1' it's '71'
This is immediately after installation, with no actual results.
I've traced it as far as Line 124 of stats_referral_sources.php
<td class="dataTableContent" align="right"><?php echo $referrals->fields['no_referrals']; ?> </td>
$referrals->fields['no_referrals'] is returning "7(RESULT)"
I've tested this on two different servers, same problem, same lucky number 7.
??
-
Re: Can't get "referrals " mod working
Alright, now I'm confused.........again. Months ago when I was working on my site www.redlinestands.com I got this module to work properly and now here I find myself again with the same damn problem as before only with www.mowerpartsupply.com/catalog The fields are there on the register page and everything in my admin panel looks right but I'm still getting "none" for my referral sources. Did anyone else have this problem and know what to do? I tried taking all the files that make this module work from Redlinestands.com and transferred them to mowerpartsupply.com/catalog but it still doesn't work. I even tried installing the sql patch again but naturally that just gives me errors telling me that I've already done that. Now I'm lost.........
Ian
-
Re: Can't get "referrals " mod working
Yes I did. What other mods do you have installed? Maybe order editor? Some mods need to be merged.
customers.php might be the one...
-
Re: Can't get "referrals " mod working
Hello. Report problem. I cant tell how many customers came from sources other than 'other'? Where am I supposed to see how many were referred from Google or MSN or my custom fields? I am not using referral codes, just the drop down.
I must be missing something obvious.
Thank you
-
Re: Can't get "referrals " mod working
Found the answer post 221 in this thread.... put the create_account.php in override template folder.... that did the trick..
Thanks
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
RSprinkel
Ok I am having difficulty getting the drop down to display the different referral options in Create Account. I am not sure where all the switches are to get this enabled. I am using 1.3.7
I do have the following switches set:
Admin/Config/My Store - Display "Other" Referral option TRUE
Admin/Config/Customer Details - Require Referral TRUE
Admin/Config/Customer Details - Customers Referral Status 2
Thanks Much in Advance.
This solved my problem at least with the test account I just created. The problem I had was the referral source selected at time of creating an account was NOT showing in admin. I made sure I had the above switches to that, did a test account and referral source there!
-
Re: Can't get "referrals " mod working
Where is the download link for this "Referral' mod? I've read the 24 pages here and can't find where to download.
-
Re: Can't get "referrals " mod working
So after reading 24 pages :blush:
I am posting this in case it helps someone find this faster :wink:
and I hope it works :smile:
http://www.zen-cart.com/index.php?ma...roducts_id=186
-
Re: Can't get "referrals " mod working
Hi,
Does anyone know how to get this addon to give a javascript error if someone misses to fill this out while they are trying to create an account? At the moment if you do not fill in the 'how did you hear about us?' and click submit then the page refreshes with an error message. However, if you use javascript then the page does not need to refresh the error message just pops up.
-
Re: Can't get "referrals " mod working
I manage to do some of the work for the java script error as follows:
1. First install How did you hear about us add on (if you are unsure about where the download link is for this see 2 posts up)
2. Then find
/includes/languages/YOURTEMPLATE/english.php
Search for:
define('ENTRY_REFERENCE_FROM', 'How did you hear about us?');
…right after that line enter the following…
define('ENTRY_REFERENCE_FROM_ERROR', 'You must select a choice from How did you hear about us? pull down menu.');
3. Then find
/includes/modules/pages/create_account/jscript_form_check.php
Search for:
check_select("country", "", "<?php echo ENTRY_COUNTRY_ERROR; ?>");
…right after that line enter the following…
check_select("source", "", "<?php echo ENTRY_REFERENCE_FROM_ERROR; ?>");
That should give a java script error for the dropdown menu itself.
However, I need some help to do a javascript error if someone chooses the "other" option from the how did you hear about us drop down menu but leaves the "other" field underneath blank. Any help would be greatly appreciated.
-
Re: Can't get "referrals " mod working
Does this mod add the referral info to the confirmation email when a customer orders?
-
Re: Can't get "referrals " mod working
Looks like no need of the sources on the order email, because of the 'referral sources' page. I'm now wondering how to sort the refferals, by month, year, day, etc. Doesn't look like it's built in.. Maybe a feature request or Mod-of-Mod option.. Modification works great, was exactly what I needed. Be nice to do more detailed 'reports' or have more options on the 'referral sources' page. Thanks! :bigups:
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
dnolan
Where is the download link for this "Referral' mod? I've read the 24 pages here and can't find where to download.
Quote:
Originally Posted by
Loveme
FYI... The very 1st page of THIS thread includes the link to the "How Did You Hear About Us" module..
-
Re: Can't get "referrals " mod working
When a new customer register where can I find where they selected the "How did you hear about us" in the Admin area?
-
Re: Can't get "referrals " mod working
-
Re: Can't get "referrals " mod working
Hi, I install modul 'How Did You Hear About Us' end work o.k.
But when customer make account end nothing selects from referrals, he still can make open an account.
Hay to set up thet costumer MAST select referrals to make account? :blush:
-
Re: Can't get "referrals " mod working
If you are using other templates you need to put the create_account.php in
includes/modules/yourtemplate/
and it should work.
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
bkeaton
If you are using other templates you need to put the create_account.php in
includes/modules/yourtemplate/
and it should work.
Thenks bkeaton it's wokr :smile:
-
Re: Can't get "referrals " mod working
Installed mod and its working fine!
One quick question, can I turn of the default 'Were You Referred to Us' in the admin somewhere?
OR
Which code do I need to comment out/delete?
I don't need to ask the customer twice, where they were referred to us!!
NOTE: referencing /tpl_modules_create_account.php
-
Re: Can't get "referrals " mod working
Just installed this, seems to work fine until you test it, when a customer is added, you get this error
"Error Please select how you first heard about us."
The drop down is not there to select!!!
Guy
-
I am not able to get it working with Express Checkout
Hi All...
I have this mod working fine if anyone creates an account by the normal way. However When someone uses Express Checkout I always get referred by - none.
It is have it installed on 138a, I haven't been able to find a solution so far. Has anyone any ideas?
Many Thanks
Regards
RR
-
How to uninstall this module and clear the database?
How to uninstall this module and cllear the database? Thanks!
-
Re: Can't get "referrals " mod working
I've been trying to get this mod working for ages now, but with no real success.
I've merged my files pretty well (I think) new customers are able to select the various options from the drop down menu at sign up. However, when I go to admin>extras>referral sources all I see is "other":
Sources Referred
Other 82
Displaying 1 to 1 (of 1 referral sources) Page 1 of 1
I've created a few test accounts and selected Google, AOL, etc., etc., from the drop down but no matter what I do, it just updates "other"
When I select "other" and then type something in the box, it does not apprear anywhere.
Also, when I click on customers>customers and then edit the new account, there's no mention of the referrer anywhere.
Where am I going wrong?
-
Re: Can't get "referrals " mod working
I've just spent the last few hours reading through every single post in this thread. I can see that there's a lot of confusion about the overrides system, but that's not the problem at all.
When you put create_account.php in your includes/modules/CUSTOM folder then that file will be read and the original one in includes/modules/ will be ignored (overridden).
Now, I've just uploaded the create_account.php that shipped with this mod into my CUSTOM folder and it's erradicated the problem I outlined above (referrals not recording in the customers_info_source_id table. With the create_account.php that ships with this mod, the customers_info_source_id is updated correctly and therefore customers>customers is updated, as is extras>referral sources.
The problem therefore is with merging. Obviously I'm not merging my two files correctly!
-
Re: Can't get "referrals " mod working
I have this working (i think) so i am posting it here until it is activated in downloads. Could you guys test please?
-
1 Attachment(s)
Re: Can't get "referrals " mod working
HMM, IT DID NOT UPLOAD
I HAD TO REMOVE THE INSTRUCTIONS AND SQL FLE FOR THE SIZE TO BE SMALL ENOUGH TO UPLOAD HERE, BUT THOSE FILES REMAIN THE SAME.
INSTALL.SQL
Code:
DROP TABLE IF EXISTS sources;
CREATE TABLE sources (
sources_id int NOT NULL auto_increment,
sources_name varchar(64) NOT NULL,
PRIMARY KEY (sources_id),
KEY IDX_SOURCES_NAME (sources_name)
);
INSERT INTO sources VALUES (1, 'Google');
INSERT INTO sources VALUES (2, 'Yahoo!');
INSERT INTO sources VALUES (3, 'AOL');
INSERT INTO sources VALUES (4, 'MSN');
INSERT INTO sources VALUES (5, 'ZenCart');
DROP TABLE IF EXISTS sources_other;
CREATE TABLE sources_other (
customers_id int NOT NULL default '0',
sources_other_name varchar(64) NOT NULL,
PRIMARY KEY (customers_id)
);
ALTER TABLE customers_info ADD customers_info_source_id int NOT NULL AFTER customers_info_date_account_last_modified;
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Display "Other" Referral option', 'DISPLAY_REFERRAL_OTHER', 'true', 'Display "Other - please specify" with text box in referral source in account creation', '1', '22', 'zen_cfg_select_option(array(\'true\', \'false\'), ', now());
INSERT INTO configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ('Require Referral', 'REFERRAL_REQUIRED', 'true', 'Require the Referral Source in account creation', '5', '6', 'zen_cfg_select_option(array(\'true\', \'false\'), ', now());
README
Code:
Instructions for installing How Did You Hear About Us Version 1.3.9F
================= IMPORTANT =====================
Please BACKUP your store and database before
attempting any of these changes.
I will not be held responsible!
Core files that are modified are:
admin/customers.php
admin/orders.php
admin/includes/languages/english/customers.php
includes/modules/create_account.php
includes/templates/YOUR TEMPLATE/templates/tpl_modules_create_account.php
=================================================
1. This version is compatible with ZenCart Version 1.3.9f - The Updateto 1.3.9a was done by JT Website Design
The update from 1.3.7/8 was
done by Judy Gunderson at http://zencart-ecommerce-website-design.com
The update from 1.3.1 to 1.3.6_beta was done by CES. For support please see
the zen-cart forum http://www.zen-cart.com/forum/showthread.php?t=35623
Contact ranger_lp########################## for versions that are compatible w/1.2.x.
This contribution was converted to ZenCart from the original osCommerce
contribution (See below).
2. Unpack the zip file to a temporary directory on your hard drive. All of the
files are stored in separate directory structures and all files are based on
ZenCart Release 1.3.9f(e.g. admin and includes).
3. Copy the contents of the `how_did_you_hear_about_us_1.3.9f` directory to your
Zen Cart installation except for the `install_referrals.sql` file and this
installation file. If you are using any overrides in ZenCart that include the
files in the this contribution, use an application such as Beyond Compare or
WinDiff to compare your files and resolve any differences.
There is one file:
(\includes\templates\template_default\templates\tpl_modules_create_account.php)
which should be put in your template override folder i.e.
(\includes\templates\YOUR-TEMPLATE\templates\tpl_modules_create_account.php)
4. Run the SQL file install_referrals.sql on your database. You can use the
Install SQL Patches in the ZenCart Admin Panel under Tools -> Install SQL
Patches or you can use phpmyadmin for this purpose.
5. Enjoy your newly installed contribution!
How to Use How Did You Hear About Us Version 1.3.9f
This contrib creates a drop-down box populated by admin entered
(Admin->Extra->Referral) referral sources that prompts the customer where they
found out about the site. Admin can also make this required or not
(Admin->Configuration->Customer Details). Also includes ability to control
whether or not an "Other" appears in the dropdown and if so, displays an
additional text input box (Admin->Configuration->My Store).
Information is then stored in customers_info table for reports and data mining.
Reports are displayed in Admin->Extra->Referral Sources. If you double click on
`Other` a list of all the write in sources from customers will appear with the
dates that they were entered.
Disclaimer
----------
This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the
Free Software Foundation; either version 2 of the License, or (at your
option) any later version.
This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.
You should have received a copy of the GNU General Public License
(LICENSE) along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307,
USA.
Authors
-------
Thanks to Ryan Hobbs for the original osCommerce contribution and Keith W (homewetbar) who added functionality to the osCommerce 1.5 version of this contribution.
-
Re: Can't get "referrals " mod working
Greetings from Ireland. We are trying to get the How Did You Hear About Us ADD ON working on our site www.irishshopper.com. We installed it as per instructions and everything appears 100% in the Control Panel and we successfully added in a number of extra options in the Source Menu. When you go to the site whoever no new field appears asking the new customer how they found the site but whenever you click SUBMIT you get an error message stating you did not complete the field with an answer re how you heard about the site. So it knows about the field/question but isnt showing it on screen. I have this turned off now but can turn it back on if you want to look at it.
THANK YOU.
-
Re: Can't get "referrals " mod working
I'm using zen cart 1.3.9d with COWOA. I installed how_did_you_hear_about_us_v139a and it does work as intended. My question/problem is getting it working with COWOA which makes up about half of the checkouts in my cart.
Does anyone have how did you hear about us working with COWOA and if so what files did you work with to get it working?
I have tried copy paste of this rmh referral code
PHP Code:
<!-- //rmh referral start -->
<fieldset>
<legend><?php echo TABLE_HEADING_REFERRAL_DETAILS; ?></legend>
<!--<?php echo zen_draw_separator('pixel_trans.gif', '100%', '10'); ?> -->
<!-- <?php echo CATEGORY_SOURCE; ?> -->
<label class="inputLabel" for="source" ><?php echo ENTRY_SOURCE; ?></label>
<?php echo zen_get_source_list('source', (DISPLAY_REFERRAL_OTHER == 'true' ? true : false)) . ' ' . (zen_not_null(ENTRY_SOURCE_TEXT) ? '<span class="inputRequirement">' . ENTRY_SOURCE_TEXT . '</span>': ''); ?>
<br class="clearBoth" />
<?php
if (DISPLAY_REFERRAL_OTHER == 'true') {
?>
<label class="inputLabel" for="source_other" ><?php echo ENTRY_SOURCE_OTHER; ?></label>
<?php echo zen_draw_input_field('source_other', '', 'id="sources_other_name"') . (zen_not_null(ENTRY_SOURCE_OTHER_TEXT) ? '<span class="inputRequirement">' . ENTRY_SOURCE_OTHER_TEXT . '</span>': ''); ?>
<br class="clearBoth" />
</fieldset>
<?php
}
?>
<!-- //rmh referral end -->
from
/includes/templates/custom/templates/tpl_modules_create_account.php
into
/includes/templates/custom/templates/tpl_no_account_default.php
The input field showed up on the no account checkout form but when the info is entered the referral does not show up in admin/customers/customers
I also pasted the code into
/includes/templates/custom/templates/tpl_modules_no_account.php
the same happens as above. The info doesn't show up in admin.
What am I missing?
-
Re: Can't get "referrals " mod working
ok I been playing around with it some more and now I think I've got it. The referral input area is displaying on the COWOA form and the referral is making it into admin > customers > customers
So far looks good unless something yet to be discovered was adversely affected by my edits.
The 2 files I edited were
includes/templates/custom/templates/tpl_modules_no_account.php
with rmh code from
includes/templates/custom/templates/tpl_modules_create_account.php
and
/includes/modules/no_account.php
with rmh code from
/includes/modules/create_account.php
The /includes/modules/no_account.php was trickier because it's not at first obvious what needs to be changed.
-
Re: How to uninstall this module and clear the database?
Quote:
Originally Posted by
lina0962
How to uninstall this module and cllear the database? Thanks!
I need to uninstall also, did you get an answer??
-
Re: Can't get "referrals " mod working
I have installed this mod. I'm having the same problem with the customer write in referrals not working. If they select other they should be able to leave their source.
Any ideas? I've merged and remerged over and over, doesn't make a difference.
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
joyjoy
I have installed this mod. I'm having the same problem with the customer write in referrals not working. If they select other they should be able to leave their source.
Any ideas? I've merged and remerged over and over, doesn't make a difference.
Try my solution in post #252 above. I couldn't get them to merge either, but simply replacing a couple of ZC files with the files that ship with the mod and eureka. Works a treat for me now.
-
Re: Can't get "referrals " mod working
Nope, my create_account.php file is in my overrides system. I am running Super Orders v3.0 and I think that may be the problem. Does anyone else have Super Orders installed that is working with this mod?
HELP. Thank you.
-
Re: Can't get "referrals " mod working
It is UNLIKELY that Super Orders is a cause for your issues with this mod.. But if you are convinced that this is the issue, the easiest way to verify this is to install Super Orders OR if you have not done the optional update changes for Super Orders simply see if the issue you have with this module is present when using the default orders.php
Quote:
Originally Posted by
joyjoy
Nope, my create_account.php file is in my overrides system. I am running Super Orders v3.0 and I think that may be the problem. Does anyone else have Super Orders installed that is working with this mod?
HELP. Thank you.
-
Re: Can't get "referrals " mod working
I don't know what it is. But I've spent hours comparing and merging and have tried looking into several different things all with no success. I currently have Ty Tracker, Super Orders(with optional files installed), and Edit Orders, all of which seem to touch on similar files.
As it is right now, I am able to see the "Referred by:" heading in the customer details. When I look into "Referral Sources" I can see 147 listed under others, but when I click on others, it comes up blank (0 of 0). I see that most of the others have found the solution with the create_account.php in the overrides folders...but this isn't my issue. I have verified that it is in my overrides folder and I have even tried to change the default file just to make sure it wasn't accidentally pulling from that source. Still nothing. :frusty:
i would appreciate if someone could help. Does anyone have these mods installed (Tracker, Edit, Super) and is working with the "How did you hear about us" add on?
Or better yet, can anyone post their merged files that are working with this mod? That might help too. Thank you again.
-
Re: Can't get "referrals " mod working
I've emailed one of the people involved, hopefully they will reply and we can fix this mod. It's a great idea, just wish it worked.
-
Re: Can't get "referrals " mod working
Ok as far as I know it has nothing to do with SQL entries.
It's mainly to do with incorrectly merging files and the placement of files.
Make sure your "includes/templates/YOUR_TEMPLATE/modules" directory has the original file "create_account.php" from the actual mod. Just override what you have on your server. I know! I know!, it sounds crazy but it works!
Also make sure "create_account.php" is also in your "includes/templates/template_default/modules" directory as well.
now it should work with 1.3.9h.
-
Re: Can't get "referrals " mod working
Okay, so I'm back here again giving this another shot...
Thanks for the follow up, just a couple of questions. I have my files set up this way:
includes/modules/YOUR_TEMPLATE/create_acount.php
includes/modules/create_account.php
Do I need to rearrange my files to the placment direction that you gave:
includes/templates/YOUR_TEMPLATE/modules/create_account.php
includes/templates/template_default/modules/create_account.php
Also you stated that to make sure that the "create_account.php" is also in the template_default, this would be the create_account.php file from the mod right? Not the original file?
Thank you again.
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
joyjoy
Does anyone have these mods installed (Tracker, Edit, Super) and is working with the "How did you hear about us" add on?
Sorry to keep beating a dead horse, but errors with this module have nothing to do with Super Orders, Edit Orders or Ty Package Tracker.. From the readme:
Quote:
Core files that are modified are:
admin/customers.php
admin/orders.php
admin/includes/languages/english/customers.php
includes/modules/create_account.php
includes/templates/YOUR TEMPLATE/templates/tpl_modules_create_account.php
Of these files the ONLY file that this module has in common with the two of the three modules is the file highlighted in red.
Both Edit Orders and Ty Packager Tracker have required modifications to orders.php. Let me make sure it's clear.. The changes to orders.php WOULD IN NO WAY affect the functionality of this module unless when applying the changes to orders.php required for this module, the merging was done incorrectly.
Additionally the modifications to orders.php required by this module must also be applied to super_orders.php in order to see the referral data in Super Orders..
-
Re: Can't get "referrals " mod working
Simple answer.. You never ever replace what's in default_template with ANY modfied version of the same file. The default_template is ALWAYS and ONLY supposed to be the original Zen Cart file NEVER a modified version of the file.. Modified files must go into the proper override template folder. Here are some FAQs which might help you better understand the Zen Cart overrride system..
Understanding the Override System
Writing contributions -- often-overlooked override capabilities
Quote:
Originally Posted by
joyjoy
Okay, so I'm back here again giving this another shot...
Thanks for the follow up, just a couple of questions. I have my files set up this way:
includes/modules/YOUR_TEMPLATE/create_acount.php
includes/modules/create_account.php
Do I need to rearrange my files to the placment direction that you gave:
includes/templates/YOUR_TEMPLATE/modules/create_account.php
includes/templates/template_default/modules/create_account.php
Also you stated that to make sure that the "create_account.php" is also in the template_default, this would be the create_account.php file from the mod right? Not the original file?
Thank you again.
-
Re: Can't get "referrals " mod working
Hi Diva,
Thanks for the input. I checked the admin/orders.php file and the change for "how did you hear..." is there. I also checked the super_orders.php file and it's there as well. The field "Referred By:" does show up in Super Orders but there is no entry. The field also shows up in the customers edit file with the same result.
In admin my "Referral Sources" shows others with 145 entries, when I select it to view those entries...it's gone. I'm at my wits end, it should be simple...but I don't know what else to do. :no:
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
DivaVocals
Simple answer.. You never ever replace what's in
default_template with ANY modfied version of the same file. The
default_template is ALWAYS and ONLY supposed to be the original Zen Cart file NEVER a modified version of the file.. Modified files must go into the proper override template folder. Here are some FAQs which might help you better understand the Zen Cart overrride system..
Understanding the Override System
Writing contributions -- often-overlooked override capabilities
Thank you. I understand the overrides system, I was clarifying the instructions that were posted here earlier...because I was going to say that as far as I know, modified files should only be placed in an override folder. But I did try to stick my override create_account.php for this mod in the default folder just to see if my results would change...but it didn't.
I have replaced the create_account.php default file in the default folder. :smile:
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
joyjoy
Thank you. I understand the overrides system, I was clarifying the instructions that were posted here earlier...because I was going to say that as far as I know, modified files should only be placed in an override folder. But I did try to stick my override create_account.php for this mod in the default folder just to see if my results would change...but it didn't.
I have replaced the create_account.php default file in the default folder. :smile:
And you are absolutely right..:smile: UNLESS the file is NOT a core Zen Cart file, you should never replace a core file in the default_template folder without using an override.. (even if a module's instructions or anyone else:blush: suggests otherwise..)
-
Re: Can't get "referrals " mod working
Okay,cool. Thanks for clearing that up. It'll be one less mess that I can get myself into. :dontgetit
-
Re: Can't get "referrals " mod working
-
Re: Can't get "referrals " mod working
Hi everyone, I FINALLY got this working! Just one quick question. What would I add to my files if I wanted the "Referred By" field on the customer page.
I want the referred by filed to be visible right away instead of having to go into the details of the customer account.
Thank you!
-
Re: Can't get "referrals " mod working
Been happily using the "How Did You Hear About Us" add on without any problems or issues.
Now, I'd like to include the referral source response in the order confirmation email (mainly for the sake of the copy sent to the admin, but it won't hurt for the customer to see it too). Is this possible? How would I do it?
Can anybody help with this? Thanks so much!
-
Solved: No referral info (--none--) in admin
After hours scouring this forum and the mod files, I just wanted to share a solution I've found for:
Admin showing --none-- under "Referred by" regardless of selected source upon account creation.
I'm using Fast and Easy Checkout by Numinix so this probably applies to those of you using COWOA as well.
Found this post on the Numinix forum and replaced lines 540-559 in /modules/MY_TEMPLATE/create_account.php with the following:
Code:
// FEC MODIFICATION WITH REFERRAL CODE (HOW DID YOU HEAR ABOUT US MOD)
$_SESSION['sendto'] = $_SESSION['cart_address_id'] = (int)$address_id;
}
$_SESSION['shipping'] = '';
$sql = "insert into " . TABLE_CUSTOMERS_INFO . "
(customers_info_id, customers_info_number_of_logons,
customers_info_date_account_created, customers_info_source_id)
values ('" . (int)$_SESSION['customer_id'] . "', '0', now(), '" . (int)$source . "')";
$db->Execute($sql);
if ($source == '9999') {
zen_db_perform(TABLE_SOURCES_OTHER, array('customers_id' => $_SESSION['customer_id'], 'sources_other_name' => $source_other));
}
// $sql = "insert into " . TABLE_CUSTOMERS_INFO . "
// (customers_info_id, customers_info_number_of_logons,
// customers_info_date_account_created)
// values ('" . (int)$_SESSION['customer_id'] . "', '0', now())";
//
// $db->Execute($sql);
//rmh referral end
The referral source now shows up in the customers table as well as order details page.
Good luck.
Versions: 1.3.9h and FEC 1.9.4.
-
Re: Can't get "referrals " mod working
That number "16" under "Other" is most likely the number of orders you received before installing this mod. Because there were no referral sources at the time of those orders, they've been automatically allocated to "Other."
The only way to edit this as far as I know is to go into your database, look for the table "customers_info" and edit the values of "customers_info_source_id".
If that 16 bothers you, you could create a new referral source (under Extras -> Referrals) named something along the lines of "Pre-Referral Mod" and assigning the id of that source to those 16 customers under "customers_info_source_id".
But be very careful when working with the database! Make a backup before messing with it. No guarantees/warranties that this will work. I'm no expert; just another user who recently installed this mod and spent hours trying to get it to work. :p
I had over 300 "Others" when I installed this mod and decided to just leave it. If your customers enter their own custom source under "Other" you can see those entered sources by clicking on "Other" in Extras -> Referral Sources which will open a new page showing their entries.
-
Re: Can't get "referrals " mod working
Hello People!
I am another one having issues getting the "how did you hear about us" mod to work. The installation appeared to go smoothly. I have double and triple checked that I got all the files in the correct places. I installed the sql through Tools>Install SQL and uploaded. I am running 1.39d at hoopclothes dot com.
On making a new customer acct the referral drop down shows up and appears to function fine, but I have no idea where the data for this is going. It isn't showing up on the customer's details nor in the extras>referrals or referral sources. The "Other" count goes up so I know new customers are registering somewhere. But if you click other the sources don't show up so ?
Did anyone have a similar problem with this that they solved? I did read through this entire thread, but most of the posts seem to be from much older versions of the mod. And I didn't see any applicable solutions to what is going on with my site. Thanks for your help!
-
Re: Can't get "referrals " mod working
To update - I upgraded my cart to 1.3.9h in case that was causing the issue.
The mod still isn't working correctly, no data showing up in back end. See previous post...
If it helps the other mods I've got installed are: Image Handler2, Newsletter Subscribe 2.2 and Simple Google Analytics.
-
Re: Solved: No referral info (--none--) in admin
Quote:
Originally Posted by
fepb
After hours scouring this forum and the mod files, I just wanted to share a solution I've found for:
Admin showing --none-- under "Referred by" regardless of selected source upon account creation.
I'm using Fast and Easy Checkout by Numinix so this probably applies to those of you using COWOA as well.
Found
this post on the Numinix forum and replaced lines 540-559 in /modules/MY_TEMPLATE/create_account.php with the following:
Code:
// FEC MODIFICATION WITH REFERRAL CODE (HOW DID YOU HEAR ABOUT US MOD)
$_SESSION['sendto'] = $_SESSION['cart_address_id'] = (int)$address_id;
}
$_SESSION['shipping'] = '';
$sql = "insert into " . TABLE_CUSTOMERS_INFO . "
(customers_info_id, customers_info_number_of_logons,
customers_info_date_account_created, customers_info_source_id)
values ('" . (int)$_SESSION['customer_id'] . "', '0', now(), '" . (int)$source . "')";
$db->Execute($sql);
if ($source == '9999') {
zen_db_perform(TABLE_SOURCES_OTHER, array('customers_id' => $_SESSION['customer_id'], 'sources_other_name' => $source_other));
}
// $sql = "insert into " . TABLE_CUSTOMERS_INFO . "
// (customers_info_id, customers_info_number_of_logons,
// customers_info_date_account_created)
// values ('" . (int)$_SESSION['customer_id'] . "', '0', now())";
//
// $db->Execute($sql);
//rmh referral end
The referral source now shows up in the customers table as well as order details page.
Good luck.
Versions: 1.3.9h and FEC 1.9.4.
I am trying hard to get these two to work together but I can not follow the steps you did merging the files. What exactly did you replace with this posted code? Which file did you start out with? The version in FEC for how did you hear about us? FEC puts the create_account.php in the YOUR_TEMPLATE folder as where Referral mod puts it directly in to modules. Please help, maybe upload the merged file with instruction where to put it. Thank you.
-
Re: Can't get "referrals " mod working
What code was on your lines 540-559? I use Notepad++ and these lines are not the right place as I see it. I put your code inside the FEC supplied create_account.php replacing the following code:
PHP Code:
// FEC MODIFICATION
$_SESSION['sendto'] = $_SESSION['cart_address_id'] = (int)$address_id;
}
$_SESSION['shipping'] = '';
But I get the:
1062 Duplicate entry '1085' for key 'PRIMARY'
in:
[insert into zen_customers_info (customers_info_id, customers_info_number_of_logons, customers_info_date_account_created, customers_info_source_id) values ('1085', '0', now(), '0')]
Where did I go wrong?
-
1 Attachment(s)
Re: Can't get "referrals " mod working
So after all I got it working. For others I have the merged file attached. This is FEC 1.9.5 and How Did You Hear About Us 139hl. The file should be put in your override in includes\modules\YOUR_TEMPLATE\
-
Re: Can't get "referrals " mod working
"How Did You Hear About Us" clears the whole form if no selection is made.
A customer brought this issue to my attention:
When all the new account info is filled out correctly BUT no selection was made in the "How Did You Hear About Us?" it just clears out the whole form and no error message is displayed. The customer has to start all over again not knowing what she/he did wrong. VERY BAD for business.. I bet a lot of frustrated potential customers just leave after entering stuff a few times and not seeing any indication what was wrong.
My temporary fix is to go to the Admin- Customer Details -Require Referral and set to false. This way a selection is not enforced and the account is created no matter what. Not perfect but I prefer not to get a referral instead of loosing customers.
Where could the clearing prevention of the form and proper error message display be set?
-
Re: Can't get "referrals " mod working
Ok, got the error message to display by changing the two:
add('xxxx'
to
add_session('xxxx'
in this section:
PHP Code:
//rmh referral start
if ((REFERRAL_REQUIRED == 'true') && (is_numeric($source) == false)) {
$error = true;
$messageStack->add_session('login', ENTRY_SOURCE_ERROR);
}
if ((REFERRAL_REQUIRED == 'true') && (DISPLAY_REFERRAL_OTHER == 'true') &&($source == '9999') && (!zen_not_null($source_other)) ) {
$error = true;
$messageStack->add_session('login', ENTRY_SOURCE_OTHER_ERROR);
}
//rmh referral end
Now the error message stack displays but the form still gets cleared/reset. How can I prevent this resetting? It does not happen with any other field empty....
-
Re: Can't get "referrals " mod working
Hi,
I saw the same issue with my site aswell. I posted a partial solution using java script error which does not clear the data once entered. However, it does not work if the customer selects the 'other' field. If anyone can help to complete the solution then I would be greatful as it is beyond my expertise.
See partial solution I posted before
I manage to do some of the work for the java script error as follows:
1. First install How did you hear about us add on
2. Then find
/includes/languages/YOURTEMPLATE/english.php
Search for:
define('ENTRY_REFERENCE_FROM', 'How did you hear about us?');
…right after that line enter the following…
define('ENTRY_REFERENCE_FROM_ERROR', 'You must select a choice from How did you hear about us? pull down menu.');
3. Then find
/includes/modules/pages/create_account/jscript_form_check.php
Search for:
check_select("country", "", "<?php echo ENTRY_COUNTRY_ERROR; ?>");
…right after that line enter the following…
check_select("source", "", "<?php echo ENTRY_REFERENCE_FROM_ERROR; ?>");
That should give a java script error for the dropdown menu itself.
However, I need some help to do a javascript error if someone chooses the "other" option from the how did you hear about us drop down menu but leaves the "other" field underneath blank. Any help would be greatly appreciated.
-
Re: Can't get "referrals " mod working
I'm try to merge the file
costumers.php with costumers.php from the Mod - wholesale price
Without success. Please help .
Costumers.php - Mod - wholesale prices
costumers.php - Mod how_did_you_hear_about_us_v139h
-
Re: Can't get "referrals " mod working
Sorry but i have more q .
This can merge with Super order Mod ?
Need Merge orders.pho with super_orders.php
or just some lines ?
Thank a lot .
-
Re: Can't get "referrals " mod working
Ok I am completely stumped and hope someone can help?!?!
Mind you I develop zencart websites and can usually find anything....
I have uploaded this mod.....several times....but I CANNOT get any fields under the extra tools to define the sources for the how did you hear about us dropdown?
The 2 options that fall under configurations are fine....its the extras box that is not working for me......
What the heck am I missing here? THANK YOU!
-
Re: Can't get "referrals " mod working
I have installed this on to about 10 of our sites. Around 5 worked 100% first time others didnt and I could not find out why so eventualy re-installed everything and they are all working fine now.
-
Re: Can't get "referrals " mod working
OK I was just being dumb...forgot client has admin controls and I forgot --- the box was there just had to give myself access!!! UUGGHH
-
Re: Can't get "referrals " mod working
Ok I have one more question....not sure if anyone else has run into this?
I have installed the How Did You Hear About Us mod and i have FEC checkout installed - it is working perfectly for people that create an account....and I have the dropdown appearing on the No Account page for those that do not create an account ---- but it is not transferring the selection to the database.......again it is only not working for NO ACCOUNT users....can you offer any advice on this to get this work?
I did see one post in this thread but the FEC does not have the file that was mentioned and I cannot find any other relevant files that would be needed to pull this into the database....
-
Re: Can't get "referrals " mod working
Totally NOT trying to hijack someone's thread but, is there a support thread for this entire module before I go completely off topic?
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
jdw1979
Totally NOT trying to hijack someone's thread but, is there a support thread for this entire module before I go completely off topic?
Jd,
What issue are you having trouble with on this module?
-
Re: Can't get "referrals " mod working
I am trying to add the "how did you hear about us" data into the "Office use only" portion of the emails when a customer registers. I know that I'll have to modify "/includes/functions/functions_email.php" and that I'll have to make calls to both the "zen_sources" and the "zen_sources_other" tables...but I'm lost as to how to actually code it...please help?
:cry:
-
Re: Can't get "referrals " mod working
Does anyone have this working with the NO ACCOUNT option? I am desperate for a solution here.....I have tried everything I cna think of but it is not capturing the data for non-account holders and I cannot think of any reason it won't...I have the code on the no_account page......
:(
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
jill8026
Does anyone have this working with the NO ACCOUNT option? I am desperate for a solution here.....I have tried everything I cna think of but it is not capturing the data for non-account holders and I cannot think of any reason it won't...I have the code on the no_account page......
:(
Same here, cusomers creating an account, this mod appears fine, but if they use fast and easy checkout (no account created) this referral option does not apply. Any solutions would be great. I know someone posted a zip file but they said there were errors on it??
Thanks
-
New Question
My "admin" folder is not "admin"
Do I need to change anything because there are two folders in the download. Includes and admin. Does the admin folder need to be changed or anything inside it?
Thanks
Karl
-
Re: New Question
Quote:
Originally Posted by
keg910
My "admin" folder is not "admin"
Do I need to change anything because there are two folders in the download. Includes and admin. Does the admin folder need to be changed or anything inside it?
Thanks
Karl
You need to change your admin folder name for security purposes.
You can change anything, but when you change your admin folder name. For an example:
original folder name /admin
and change it to /store or /storemanager
you need to go to your configuration file in your which is admin/config.php you need help let us know and we will help you.
-
Re: Can't get "referrals " mod working
ok, right now my configuration.php is in a folder called zc_admin
That's what the folder was called after I installed Zen Cart.
-
Re: Can't get "referrals " mod working
Quote:
Originally Posted by
keg910
ok, right now my configuration.php is in a folder called zc_admin
That's what the folder was called after I installed Zen Cart.
ok,, you still need to change that folder name.