Zen Cart Logo
Forums / All Other Contributions/Addons / RSS Feed out of date

RSS Feed out of date

Views: 920

Results 1 to 3 of 3
6 Aug 2012, 1:54 PM
#1
darkmarauder avatar

darkmarauder

New Zenner

Join Date:
Feb 2010
Location:
Northants, England
Posts:
83
Plugin Contributions:
0

RSS Feed out of date

I have been running the RSS Feed for some time on Zen Cart v.1.5.0 and unfortunetly have just noticed it is out of date.
The date of the RSS feed is from 01/12/2011 and I don't know why.
I have v 2.1.6 3-2-2012 installed, on my cleanly installed v1.5.0 zen cart.

Any help would be appreciated.

6 Aug 2012, 4:12 PM
#2
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,513
Plugin Contributions:
176

Re: RSS Feed out of date

I'm not acquainted with that addon specifically, but I imagine it needs to be able to write updates to certain files.
And if those files aren't "writable" then maybe it's unable to do its updates properly?
Or maybe you need to run something on your admin side manually to trigger an update?

24 Nov 2013, 1:15 PM
#3
webchills avatar

webchills

Zen Follower

Join Date:
Sep 2005
Location:
Austria
Posts:
99
Plugin Contributions:
1

Re: RSS Feed out of date

includes/modules/pages/rss_feed/header_php.php

Find around line 356:

$sql_products = "SELECT DISTINCT p.products_id, pd.products_name, pd.products_description, p.products_image, GREATEST(p.products_date_added, IFNULL(p.products_last_modified, 0)) AS products_date, p.master_categories_id, p.products_price_sorter AS price, p.products_tax_class_id, p.products_quantity, p.products_model, p.products_weight, p.manufacturers_id, m.manufacturers_name, r.reviews_rating
                       FROM " . TABLE_PRODUCTS . " p

This code returns the products_date wrong,

so change to:

$sql_products = "SELECT DISTINCT p.products_id, pd.products_name, pd.products_description, p.products_image, p.products_date_added, p.products_last_modified, p.master_categories_id, p.products_price_sorter AS price, p.products_tax_class_id, p.products_quantity, p.products_model, p.products_weight, p.manufacturers_id, m.manufacturers_name, r.reviews_rating
                       FROM " . TABLE_PRODUCTS . " p

And then change around line 512 from products_date to products_date_added:

Old:

$rss->rss_feed_item($products->fields['products_name'],
                          $link,
                          array('url' => $link, 'PermaLink' => true),
                          date('r', strtotime($products->fields['products_date'])),

New:

$rss->rss_feed_item($products->fields['products_name'],
                          $link,
                          array('url' => $link, 'PermaLink' => true),
                          date('r', strtotime($products->fields['products_date_added'])),