Please see my reply in your other thread...
http://www.zen-cart.com/forum/showpo...1&postcount=15
Regards,
Christian.
Please see my reply in your other thread...
http://www.zen-cart.com/forum/showpo...1&postcount=15
Regards,
Christian.
I removed NLS 2.0.6 on my 1.3.7 Zen Cart, to ease my upgrade to 1.3.8a and await a new tested version for 1.3.8a.
I followed the uninstall directions and removed the Subscription manager from admin menu, restored all the core files and deleted the NLS only files.
I am now getting this error when I access admin>Tools>Send email:
I was aware that the remove option in Subscription manager would drop the subscribers database. I have no customers currently so I thought that would be fine, but when I create new customers (newsletter/customers) I still see this error.1064 You have an error in your SQL syntax. Check the manual that corresponds to your MySQL server version for the right syntax to use near 'WHERE email_format != 'NONE' and confirmed = 1 and (customers_i
in:
[SELECT email_address as customers_email_address FROM WHERE email_format != 'NONE' and confirmed = 1 and (customers_id IS NULL or customers_id = 0) order by email_address ]
If you were entering information, press the BACK button in your browser and re-check the information you had entered to be sure you left no blank fields.
did I do something wrong?![]()
My original estimate of a couple of days has slipped somewhat. I love deadlines. I love the whooshing noise they make as they go by.
It looks like you have missed one of the core files when you were returning them to their original state. You need to double check the files NLS overwrites. Doing the upgrade to v1.38 will give you a clean set of files anyway so you could just do that.
Regards,
Christian.
Thanks for your reply! and thank you for working on this essential mod!
I took your suggestion and double checked the core overwrites that v2.0.6 overwrote and made sure I did successfully replace them with original 1.3.7 core files:
admin/index.php
admin/customers.php
includes/functions/function_email.php
includes/functions/audience.php
includes/modules/pages/account_edit/header_php.php
includes/modules/pages/account_newsletters/header_php.php
includes/modules/pages/unsubscribe/header_php.php
sadly the files are correct, and I still have that error.
I know nothing about MySQL databases, but I compared the current MySql database to my backed up copy and see there is indeed a table missing called subscribe.
In the uninstall directions this is stated :
Which I thought meant it just drop the customers database /info...and go back to regular ZC newsletter biz.....as I have no customers I was not concerned about putting a table back.....but I guess this table is removed (completely, not just customers) and not put back? I think ZC loses functionally:Note that the remove option also DELETES/DROPS the subscribers database, so make
sure you have a backup of that table before you remove.
Again I am guessing.
but this table is now missing from my database:
-- Table structure for table `subscribers`
--
CREATE TABLE `subscribers` (
`subscriber_id` int(11) NOT NULL auto_increment,
`customers_id` int(11) default NULL,
`email_address` varchar(96) NOT NULL default '',
`email_format` varchar(4) NOT NULL default 'TEXT',
`confirmed` varchar(8) default NULL,
`subscribed_date` date NOT NULL default '0000-00-00',
PRIMARY KEY (`subscriber_id`),
UNIQUE KEY `email_address` (`email_address`)
) TYPE=MyISAM AUTO_INCREMENT=63 ;
--
-- Dumping data for table `subscribers`
--
INSERT INTO `subscribers` (`subscriber_id`, `customers_id`, `email_address`, `email_format`, `confirmed`, `subscribed_date`) VALUES
(2, 8, '[email protected]', 'TEXT', NULL, '2007-04-15'),
(14, NULL, '[email protected]', 'TEXT', 'YXZGdj', '2007-04-15'),
(5, NULL, '[email protected]', 'TEXT', '1', '2007-04-15'),
and so on...
-- --------------------------------------------------------
--
I am going to muddle through my backed up site/Mysql and try to merge the NLS 2.06 into the upgrade of 1.3.8a if it goes in ok, disable it and wait for the upgraded NLS for 1.3.8a
What do you think?![]()
There is one more core file which has an override on it...
includes/modules/YOUR_TEMPLATE/create_account.php
...where YOUR_TEMPLATE should be replaced with the name of your template. If that file exists then take a copy of it (just in case) and then delete it.
The 'subscribers' table is not part of a standard Zen Cart installation, it is used purely for NLS so without NLS you do not need the 'subscribers' table. After checking the file mentioned above I would also do a search through all the .php files for the phrase TABLE_SUBSCRIBERS . When NLS is completely removed TABLE_SUBSCRIBERS should not appear anywhere.
Hope that helps.
Regards,
Christian.
Thanks again Christian, for your speedy help!
I did as you suggested and searched for any left over NLS files..... all NLS files are indeed completely gone from my file set. I still get the error when I access admin>tools>send email.
I searched my database for the error that I mentioned before and found it in the query_builder table as the last line under dumping data for query_builder>
Again I do not know what I am doing, but felt I had nothing to lose so I went into my phpAdmin found this line and deleted it out of database.(8, 'email,newsletters', 'Newsletter-only Subscribers', 'Returns email address of all confirmed Newsletter-Only subscribers.', 'SELECT email_address as customers_email_address FROM TABLE_SUBSCRIBERS WHERE email_format != ''NONE'' and confirmed = 1 and (customers_id IS NULL or customers_id = 0) order by email_address', '');
I do not have the error anymore and the cart seems ok, I did notice however, under admin>tools>send email : in the drop down (send to) customer menu there is a "Newsletter subscribers" option, which I don't remember if ZC had before I installed NLS 2.0.6.
Anyway, the whole cart may go up in flames now, but I wanted to trouble shoot this error, if I need to uninstall NLS again.
Did I do the correct thing?
----
Also: I am having trouble merging NLS 2.0.6 into 1.3.8a. I can clearly see the code for NLS when its commented:but I am not skilled enough to differentiate between the other old code and what could be NLS code. Is all the NLS coding commented?PHP Code:
// BEGIN newsletter_subscribe mod 3/3 .................// END newsletter_subscribe mod 3/3
NLS? ex:
admin>customers>line 882 :so...PHP Code:
echo zen_draw_hidden_field('customers_newsletter');
Would it be possible to upgrade to my ZC to 1.3.8a leaving out all the NLS 2.0.6 files, but keeping the NLS Subscription manger/'subscribers' table in the database, until the NLS 1.3.8a files are available for install?
I am looking for the easiest way to upgrade without messing up my site/database, due to my inexperience.
Again thank you for your help....
I just compared the new version of NLS 2.0.9 to my old v2.0.6 and noticed a typo that was mentioned in a previous forum , not sure if it should be carried over into the next version or not, but I thought I should mention it:
http://www.zen-cart.com/forum/showpo...&postcount=509
PHP Code:
require($template->get_template_dir('tpl_subscribe_header',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_subscribe_header.php');
hope this helps....PHP Code:
require($template->get_template_dir('tpl_subscribe_header.php',DIR_WS_TEMPLATE, $current_page_base,'templates'). '/tpl_subscribe_header.php');
I find the newletter only subscrption quite useful but it does have limitations with email control such as bounces. As such we use a product written for us for this purpose. We have a sizable database with an email going out every 3-4 weeks. As a result we get 50-150 bounces each time and when we get 3 in a row we regard these addresses as dead. Any ideas on a bulk delete of these addresses using PHP or SQL (preference is SQL)? A normal delete list is around 100 addresses.
GREAT MOD.
I was wondering how to go about adding to this mod. I want to add 3 or 4 check boxes that will allow the subscriber to choose which newsletter to subscribe to.
Such as
Check Box A = Newsletters regarding new products
Check Box B = Newsletters regarding outdated products, or discontinued products
Check Box C = Newsletters regarding the company only
Check Box D = Newsletters regarding products in development
Any ideas on going about this?
Thanks
Rooster!
Bookmarks