Zen Cart Logo
Forums / All Other Contributions/Addons / Google Base Feeder Support Thread [OLD]

Google Base Feeder Support Thread [OLD]

Locked

Views: 806,208

Results 501 to 520 of 3,556
This thread is locked. New replies are disabled.
3 Oct 2007, 2:53 PM
#501
tonybenedetti avatar

tonybenedetti

Zen Follower

Join Date:
Apr 2004
Posts:
79
Plugin Contributions:
0

Google Base Feeder Support Thread [OLD]

I forgot to add the details in my above posting -- we are using:
Google Base Feeder V1.6.2
Zen Cart V1.3.7.1
PHP Version 4.4.7 (we will be moving to PHP5 next month)

BTW, I tried to use HTML entity (37) in the product entry but ZC nicely turned it into a percent sign.

5 Oct 2007, 3:07 PM
#502
tonybenedetti avatar

tonybenedetti

Zen Follower

Join Date:
Apr 2004
Posts:
79
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

TonyBenedetti:

Some of our product names include a percent sign -- e.g., "100% Kona Coffee (1 Pound Bag)". That percent sign is important to our "branding" ... no blend of beans grown other than on the Kona Coast of the Big Island of Hawaii may use the "100% Kona Coffee" appellation.
...
...
...

I sharpened my sword, girded my loins and dove into the code -- boy, do I hate (fear?) regular expressions.

In any case, the solution was pretty simple. I just added a percent sign to the list of acceptable characters in line 439 (in the zen_xml_sanitizer function of the googlefroogle.php script). Like so:

$str = eregi_replace("[^[:alnum:][:space:].,!()'-_/+=?%]", "", $str);

Hopefully, that simple change won't come back to bite me. :lamo:

Numinix, assuming that this little mod is benign --- could you sneak the change into the next update of each of your feeders?

5 Oct 2007, 5:36 PM
#503
tonybenedetti avatar

tonybenedetti

Zen Follower

Join Date:
Apr 2004
Posts:
79
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

Running the Feeder from a CRON
FWIW here's a "heads up" ... the Google Base feeder uses three input values but if you literally follow the instructions in the readme file you might get bitten. I couldn't figure out why only the first of the three parameters was being recognized when I tried using cURL to run the googlefroogle.php script.

The readme suggests something like:

0 5 * * * curl -s http://your_http_catalog/googlefroogle.php?feed=yes&upload=yes&type=products

But the URL passed to cURL should be quoted like so:

0 5 * * * curl -s [B]'[/B]http://your_http_catalog/googlefroogle.php?feed=yes&upload=yes&type=products[B]'[/B]
... or ...
0 5 * * * curl -s [B]"[/B]http://your_http_catalog/googlefroogle.php?feed=yes&upload=yes&type=products[B]"[/B]

Quoting the URL worked for me with cURL and I would assume would also work for GET and wget (although I haven't tested with those programs).

This from the cURL FAQ:

4.2 Why do I get problems when I use & or % in the URL?
In general unix shells, the & letter is treated special and when used, it
runs the specified command in the background. To safely send the & as a part
of a URL, you should quote the entire URL by using single (') or double (")
quotes around it.

An example that would invoke a remote CGI that uses &-letters could be:

 curl 'http://www.altavista.com/cgi-bin/query?text=yes&q=curl'

In Windows, the standard DOS shell treats the %-letter specially and you
need to use TWO %-letters for each single one you want to use in the URL.

Also note that if you want the literal %-letter to be part of the data you
pass in a POST using -d/--data you must encode it as '%25' (which then also
needs the %-letter doubled on Windows machines).

6 Oct 2007, 2:38 AM
#504
numinix avatar

numinix

Totally Zenned

Join Date:
Apr 2007
Location:
Vancouver, Canada
Posts:
1,566
Plugin Contributions:
58

Re: Google Base Feeder Support Thread [OLD]

You should contact your host to find out the proper cron job command. That is simply a suggestion.

8 Oct 2007, 6:26 PM
#505
birdoasis avatar

birdoasis

Inactive

Join Date:
Jun 2005
Location:
Cheney WA
Posts:
1,123
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

I have the right username and password in the setup but when I attempt to upload from the site it says that upload failed.

I have the ftp set to upload.google.com. Is that correct? It's the only thing I can think of that may be wrong.

Thanks,

JP

8 Oct 2007, 6:28 PM
#506
birdoasis avatar

birdoasis

Inactive

Join Date:
Jun 2005
Location:
Cheney WA
Posts:
1,123
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

I'm also getting the following errors.

This attribute is no longer supported. Please use a supported attribute.
shipping:1 **This attribute is no longer supported. Please use a supported attribute. - help **label:1What file do I change to get rid of those fields?

Thanks,

JP

8 Oct 2007, 8:08 PM
#507
numinix avatar

numinix

Totally Zenned

Join Date:
Apr 2007
Location:
Vancouver, Canada
Posts:
1,566
Plugin Contributions:
58

Re: Google Base Feeder Support Thread [OLD]

Both of those attributes were removed in much earlier versions. You may also need to distinguish between the FTP u/p and your Google u/p as described in the readme file.

9 Oct 2007, 2:00 AM
#508
jmartrican avatar

jmartrican

New Zenner

Join Date:
Oct 2007
Posts:
3
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

numinix,

First of all I want to thank you for creating this wonderful tool.

I am having a problem. I get 500 Internal Server error when I click on the [HERE] of step 1. I think it calls ./googlefroogle.php. I made sure the file was there and also made sure the ./admin/, ./include/, and ./feed/ files were properly uploaded. I also ran the sql statement, got back no errors.

PHP Version: 4.4.7 (Zend: 1.3.0)
HTTP Server: WebServerX
Zen Cart 1.3.7.1
Database: MySQL 4.1.22-standard

Any ideas what it could be?

thanks a lot.
joe

11 Oct 2007, 6:00 AM
#509
brimsjewelry avatar

brimsjewelry

Zen Follower

Join Date:
May 2006
Posts:
188
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

I hate to bring this up again but I'm trying to deal with the timeout error with no success. I've read (I think) everything in this thread pertaining to it and have made the fixes suggested: created php.ini and placed in root with the lines max_execution_time = 300
max_input_time = 90
memory_limit = 32M

Increased max execution time in zen cart admin configuration to 300, and tried adding these lines to a blank .htaccess file but get a server 500 error when I do that. I've got about 9,000 items in my store.

ANy thoughts?

Jason

PS: I downloaded the most recent release of this mod and installed it and i'm running ZC 1.3.7

11 Oct 2007, 11:36 AM
#510
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Base Feeder Support Thread [OLD]

I just noticed that there are still some nagging issues across all the feeders (googlebase, msn, yahoo store, etc.)

  1. The script fails to take into account configuration settings. For example when I set both language and currency to false, the url generated still includes language and currency when it shouldn't.

  2. Also, when language is included in the url it's not corrected formed. Here is an example of a url generated: http://url goes here/index.php?main_page=product_info&products_id=1&language=0&currency=USD and it should really be http://url goes here/index.php?main_page=product_info&products_id=1&language=en&currency=USD The language=0 works but it's not really the proper way to include language because it creates problems when using mod rewrite to rewrite those url because language=0 is not what's expected, it language=en or language=de, etc.

  3. Also, the whole issue of & has not been resolved. When a site already uses xhtml valid code, this mod messes it up because it's picking up the & and rewriting it. Here is an example **<MerchantCategory>DVD Videos | Kids & Family</MerchantCategory>. **Because our site already formatted the category correctly, the generated just picked the & and rewrote it which is this case is wrong.

11 Oct 2007, 6:25 PM
#511
numinix avatar

numinix

Totally Zenned

Join Date:
Apr 2007
Location:
Vancouver, Canada
Posts:
1,566
Plugin Contributions:
58

Re: Google Base Feeder Support Thread [OLD]

  1. I am unable to repeat this bug. Setting Show Language or Show Currency to false removes them from url.
http://www.numinix.com/index.php?main_page=product_info&products_id=232
  1. If Show Language is set to true then it will display language = language_id (always an integer). You can change this to "code" if you like.

  2. I haven't attempted to resolve this, but I've offered you the code to fix the issue twice now. It won't be included because most sites do not pre-process text beyond the default zen cart settings. By changing your site to sanitize the text before, you are making it difficult for all scripts to process the text again. Instead, text should be stored in the default method and each individual script that needs to make further sanitizations can do so itself (as do the feeders). You are asking for a fix to a non-default Zen Cart site and that simply will create more problems for others than it'll fix. For now, please run the str_replace line at the end of the zen_xml_sanitizer function to replace occurences of & with & or simply remove zen_xml_sanitizer from processing the titles and descriptions is you are positive your text is 100% valid XML.

11 Oct 2007, 8:17 PM
#512
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Base Feeder Support Thread [OLD]

numinix:

    1. I haven't attempted to resolve this, but I've offered you the code to fix the issue twice now. It won't be included because most sites do not pre-process text beyond the default zen cart settings. By changing your site to sanitize the text before, you are making it difficult for all scripts to process the text again. Instead, text should be stored in the default method and each individual script that needs to make further sanitizations can do so itself (as do the feeders). You are asking for a fix to a non-default Zen Cart site and that simply will create more problems for others than it'll fix. For now, please run the str_replace line at the end of the zen_xml_sanitizer function to replace occurences of & with & or simply remove zen_xml_sanitizer from processing the titles and descriptions is you are positive your text is 100% valid XML.

I am not exactly sure what you're talking about here. We have simply use valid xhtml transitional when creating categories (which Zen Cart processes correctly). This is not some sort of custom code doing this. At any rate, I will look for the code you said you provided to apply the fix.

I will uninstall and reinstall the sql statements as the configuration is not sticking.

Thanks!

12 Oct 2007, 8:50 AM
#513
ceegeeaar avatar

ceegeeaar

New Zenner

Join Date:
Mar 2007
Location:
Deep in the Black Country, UK
Posts:
34
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

brimsjewelry:

I hate to bring this up again but I'm trying to deal with the timeout error with no success. I've read (I think) everything in this thread pertaining to it and have made the fixes suggested: created php.ini and placed in root with the lines max_execution_time = 300
max_input_time = 90
memory_limit = 32M

Increased max execution time in zen cart admin configuration to 300, and tried adding these lines to a blank .htaccess file but get a server 500 error when I do that. I've got about 9,000 items in my store.

ANy thoughts?

Jason

PS: I downloaded the most recent release of this mod and installed it and i'm running ZC 1.3.7

We had to alter the code to try passive mode ftp before port. It seems after port failed passive was blocked. The same was true with LPS script. It is simple to do if you look in the code.

Hope it helps!

Claire

12 Oct 2007, 1:38 PM
#514
blessisaacola avatar

blessisaacola

Totally Zenned

Join Date:
Feb 2004
Location:
Georgia, USA
Posts:
1,875
Plugin Contributions:
1

Re: Google Base Feeder Support Thread [OLD]

I reinstalled it and the url works just fine. However the fix for the amp; does not work and it's already included in version 1.6.2.

Thanks!

12 Oct 2007, 6:11 PM
#515
numinix avatar

numinix

Totally Zenned

Join Date:
Apr 2007
Location:
Vancouver, Canada
Posts:
1,566
Plugin Contributions:
58

Re: Google Base Feeder Support Thread [OLD]

Great! So, just take the XML sanitizer function off your titles and it should leave them untouched with the original &

14 Oct 2007, 7:22 PM
#516
brimsjewelry avatar

brimsjewelry

Zen Follower

Join Date:
May 2006
Posts:
188
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

brimsjewelry:

I hate to bring this up again but I'm trying to deal with the timeout error with no success. I've read (I think) everything in this thread pertaining to it and have made the fixes suggested: created php.ini and placed in root with the lines max_execution_time = 300
max_input_time = 90
memory_limit = 32M

Increased max execution time in zen cart admin configuration to 300, and tried adding these lines to a blank .htaccess file but get a server 500 error when I do that. I've got about 9,000 items in my store.

ANy thoughts?

Jason

PS: I downloaded the most recent release of this mod and installed it and i'm running ZC 1.3.7

I take it no one has worked out this problem?

15 Oct 2007, 4:19 AM
#517
ceegeeaar avatar

ceegeeaar

New Zenner

Join Date:
Mar 2007
Location:
Deep in the Black Country, UK
Posts:
34
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

brimsjewelry:

I take it no one has worked out this problem?

I take it my suggestion 2 or 3 posts above, which you ignored, didnt work for you then...

15 Oct 2007, 4:24 AM
#518
brimsjewelry avatar

brimsjewelry

Zen Follower

Join Date:
May 2006
Posts:
188
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

ceegeeaar:

I take it my suggestion 2 or 3 posts above, which you ignored, didnt work for you then...

ceegeeaar,

I didn't "ignore" your post, I simply missed it.

It may be easy to fix in the code for someone who knows HOW to code but I haven't a clue. Could you show me what to do? I'd greatly appreciate it.

Jason

15 Oct 2007, 4:28 AM
#519
ceegeeaar avatar

ceegeeaar

New Zenner

Join Date:
Mar 2007
Location:
Deep in the Black Country, UK
Posts:
34
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

Jason, you might want to check your site. When I try to open product pages in IE it fails with Operation Aborted. Firefox is fine. That might have something to do with your problems.

15 Oct 2007, 4:37 AM
#520
brimsjewelry avatar

brimsjewelry

Zen Follower

Join Date:
May 2006
Posts:
188
Plugin Contributions:
0

Re: Google Base Feeder Support Thread [OLD]

ceegeeaar:

Jason, you might want to check your site. When I try to open product pages in IE it fails with Operation Aborted. Firefox is fine. That might have something to do with your problems.

Yikes! Thanks for telling me this. This is something new. I just had the database moved to another server and I'm betting that is behind this. As I use firefox it probably would have been some time before I noticed this not working in IE. Much obliged!

Jason