Monday, 01 September 2014 07:46

beggarly

New feature for images from Google !

Request new features on Xmap component
Forum rules
This

Re: New feature for images from Google !

Postby leewillis77 » Tue Apr 27, 2010 8:26 pm

I've done a bit more digging, and it looks like this is the problem.

I have a menu that contains a direct link to a number of articles.
I have a second menu which contains a link to the Content Category.

They are processed in this order.

The direct article links are processed via a direct call to printNode from components/com_xmap/xmap.php. These do not have $node->images[] populated.

The content category, and articles within it are processed by the com_content extension that is called it correctly picks up the images within the articles, and populates $node->images[].

However this second node object is never output since that article has been output already.

So, the issue is that direct article links don't parse the content for images.

I've no idea what the right fix is though :(
leewillis77
Fresh Boarder
Fresh Boarder
 
Posts: 14
Joined: Wed Apr 21, 2010 9:26 am

Re: New feature for images from Google !

Postby leewillis77 » Tue Apr 27, 2010 9:36 pm

So, since I couldn't work out that issue, I spent a little time adding image support to the Virtuemart extension :)

You can find the patched files here - it'd be great if these could be included in the next release:

http://www.leewillis.co.uk/patches/com_xmap/

Cheers
Lee
leewillis77
Fresh Boarder
Fresh Boarder
 
Posts: 14
Joined: Wed Apr 21, 2010 9:26 am

Re: New feature for images from Google !

Postby leewillis77 » Tue Apr 27, 2010 9:40 pm

PS. The default Joomla! robots.txt bans Googlebot from crawling the Virtuemart image folders, you can allow them, by adding:

Allow: /components/com_virtuemart/shop_image/product/

to the bottom of your robots.txt ...
leewillis77
Fresh Boarder
Fresh Boarder
 
Posts: 14
Joined: Wed Apr 21, 2010 9:26 am

Re: New feature for images from Google !

Postby Greg » Wed Apr 28, 2010 9:15 am

Hi,

ok, just find out why I don't see the image schema, this is just beacause when we see the sitemap with firefox (without css, so a row xml) firefox put some little design stuff that hide the real raw code.
There's only under IE, where we can see the full header of the file

So in fact I got it when I look at the source code of the page:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd" xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">
<url>
<loc>


If we just look at the normal page:
Code: Select all
<urlset xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd">

<url>


under IE:
Code: Select all
  <?xml version="1.0" encoding="UTF-8" ?>
- <urlset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd" xmlns="http://www.sitemaps.org/schemas/sitemap/0.9" xmlns:image="http://www.google.com/schemas/sitemap-image/1.1">
- <url>
  <loc>


I don't know if it can have side effect for google...but anyway I don't have errors returned in my sitemap report from GWT.
Joomla 1.5.22 / 2.5.7 | VM 2.0.12b | Xmap 1.2.14 / 2.3.0 | PHP5.3.17
Greg
Senior Boarder
Senior Boarder
 
Posts: 50
Joined: Sun Sep 16, 2007 7:42 pm

Re: New feature for images from Google !

Postby leewillis77 » Tue May 11, 2010 9:15 am

No-one got any ideas about how to add images for directly linked content items?
leewillis77
Fresh Boarder
Fresh Boarder
 
Posts: 14
Joined: Wed Apr 21, 2010 9:26 am

Re: New feature for images from Google !

Postby Greg » Wed Jun 30, 2010 8:44 am

Hi

I was wondering why the xml image schema from google always return a 404.
And so many webmasters ask too for this in the google forums.

Today here we are the explanation, the schema for the images, is not the good one (lol)

the one to use is:
Code: Select all
http://www.sitemaps.org/schemas/sitemap-image/1.1


Anyway here you are an example provide today by google himself:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
        xmlns="http://www.sitemaps.org/schemas/sitemap-image/1.1"
        xmlns="http://www.sitemaps.org/schemas/sitemap-video/1.1">
  <url>
    <loc>http://www.example.com/foo.html</loc>
    <image:image>
       <image:loc>http://example.com/image.jpg</image:loc>
    </image:image>
    <video:video>
    <video:content_loc>http://www.example.com/videoABC.flv</video:content_loc>   
      <video:title>Grilling tofu for summer</video:title>
    </video>
  </url>
</urlset>


And here you are attached, what you should have in your webmaster tools sitemaps account (note the "geo, image, video" instead of a simple "--" when schemas are wrong)
sitemap.png


Hope it can help make things little bit more clear for everybody ;)

I'm sure that Guilleva will fine tune (as usual)the next release of Xmap with this new stuff :mrgreen:
Joomla 1.5.22 / 2.5.7 | VM 2.0.12b | Xmap 1.2.14 / 2.3.0 | PHP5.3.17
Greg
Senior Boarder
Senior Boarder
 
Posts: 50
Joined: Sun Sep 16, 2007 7:42 pm

Re: New feature for images from Google !

Postby guilleva » Fri Jul 02, 2010 7:23 am

Hi Greg, thanks for sharing that!

But I still get "404 page not found" with those urls:
http://www.sitemaps.org/schemas/sitemap-image/1.1
http://www.sitemaps.org/schemas/sitemap-video/1.1

:s
User avatar
guilleva
Administrator
Administrator
 
Posts: 1527
Joined: Wed Sep 12, 2007 3:10 am
Location: San José, Costa Rica

Re: New feature for images from Google !

Postby Greg » Fri Jul 02, 2010 7:51 am

yes, sorry my mistake

whatever the schema it always return a 404

but this is apparently not a problem, because now my sitemaps are well recognized, with "image" in the type field in GWT.

so it's ok like that.
Joomla 1.5.22 / 2.5.7 | VM 2.0.12b | Xmap 1.2.14 / 2.3.0 | PHP5.3.17
Greg
Senior Boarder
Senior Boarder
 
Posts: 50
Joined: Sun Sep 16, 2007 7:42 pm

Previous

Return to New Features



Who is online

Users browsing this forum: No registered users and 1 guest