You are here:  » Not overwriting already imported pages


Not overwriting already imported pages

Submitted by bodybuildingcom... on Tue, 2017-08-29 20:34 in

Hi David,

When I add and import new feeds, it seems to import all of my feeds, even the ones I have previously imported already into WordPress. It overwrites the previous pages from the same merchant again.

I am wondering if there is a setting which I can use to disable overwriting WordPress pages which I have already imported? I am slowly adding datafeeds one by one, but it also re-imports the pages for datafeeds I have already imported.

I am wondering if you have a solution where we could toggle a setting to occasionally disable the overwriting mechanism of already imported pages?

I am looking to add some manual things i.e. a different review system plugin, a plugin coupon etc. to the imported individual Wordpress pages, and I am afraid that it will overwrite my changes when I import new feeds.

I am using 3.0 BETA as per the previous post.

Thanks.

Norbert

Submitted by support on Wed, 2017-08-30 07:07

Hello Norbert,

If you would prefer plugin genereated posts to be left untouched once created that's no problem. Firstly, make sure that the Auto Delete setting is set to FALSE (wp-admin > Settings > PriceTapestry.org > Configuration > Imported) since this works by checking the modified date/time of plugin generated posts following import. Then, edit pto_common.php and look for the following code at line 294:

  wp_insert_post( $post, FALSE );

...and REPLACE with:

  if (!isset($post["ID"]))
  {
    wp_insert_post( $post, FALSE );
  }

Hope this helps!

Cheers,
David.
--
PriceTapestry.com

Submitted by bodybuildingcom... on Wed, 2017-08-30 19:14

Thank you David for your help.

Much appreciate it as always.

Norbert

Submitted by babrees on Mon, 2017-09-04 10:12

That's brilliant!

I'd like to be able to import, then add my own additional content. With that on though, will it still update the stockist information?

Submitted by support on Mon, 2017-09-04 10:29

Sure - the plugin generated posts contain the shortcodes rather than the actual content, so even though the pages appear as actual WordPress posts, the plugin generated content is still "live" so yes, stockists and best prices etc. will all update.

Cheers,
David.
--
PriceTapestry.com

Submitted by babrees on Mon, 2017-09-04 10:40

Fantastic!

Thank you David!