User avatar
diabloNL
Posts: 55
Joined: Mon Feb 26, 2007 2:08 am

Postby diabloNL » Tue Mar 06, 2007 5:13 am

I made a config file for the review section of Gamespot.com:



Code: Select all

[ChannelParameters]
URL=http://www.gamespot.com/reviews.html?type=reviews&platform=1024&tag=subnav;reviews
Title=Gamespot PSP Reviews
Description=
BaseUrl=http://www.gamespot.com/psp/
MaxItems=15
Shorthand=
SectionPattern=Latest PSP Reviews(.*)Browse All Reviews
ItemPattern-1=(?P<D><img src.*?alt="
ItemPattern-2=(?P<T>.*?)".*?)<br><a href="(?P<L>.*?)"
ItemPattern-3=


I attached a picture:

CLICK

The problem is that the baseURL only works for the Titel (green arrows). But for the other links(red arrows) it links to my local c:\ disk.

What am I doing wrong?

Thanks! :wink:

User avatar
support
Site Admin
Posts: 2925
Joined: Fri Feb 07, 2003 8:48 am
Location: Melbourne, Australia
Contact:

Postby support » Tue Mar 06, 2007 9:43 am

diabloNL wrote:The problem is that the baseURL only works for the Titel (green arrows). But for the other links(red arrows) it links to my local c:\ disk.

What am I doing wrong?


I didn't get anything extracted when I ran your config but looking at the source code for the web page, I think I know what's going on.

They're using <u>relative</u> URL's for their links e.g. <tt>[a href="/psp/action/machmodifiedaircombatheroes/review.html"]7.2[/a]</tt> Because WebScrape just extracts text without understanding what it's extracting, these URL's are what gets put into the feed. Awasu converts relative links to absolute but in this case, it doesn't know the original base URL. Plugins generate their feed to a temp file on your local hard disk and since that's all Awasu knows, that's what it uses as the base URL for relative link translation. Hence, links look like they're located on your C: drive :-)

I'll try to get a debug switch in to 2.3.rc2 that will let you manually set the base URL to be used for relative link translation that should work around this problem.

User avatar
diabloNL
Posts: 55
Joined: Mon Feb 26, 2007 2:08 am

Postby diabloNL » Tue Mar 06, 2007 9:51 am

Thanks for the reply. I know it has relative URL's but I thought that the setting for "Base URL" took care of that. And it does for the link that I describe with (?P<L>.*?) but it doesn't do it for the links in the "description" (?P<D>.*?) part.

BTW, strange the file doesn't work for you... :?

User avatar
support
Site Admin
Posts: 2925
Joined: Fri Feb 07, 2003 8:48 am
Location: Melbourne, Australia
Contact:

Postby support » Tue Mar 06, 2007 9:55 am

diabloNL wrote:I know it has relative URL's but I thought that the setting for "Base URL" took care of that.

This plugin was written by someone else and I don't have the source so I can't say but I'd be surprised if the plugin does relative link translation.

diabloNL wrote:And it does for the link that I describe with (?P<L>.*?) but it doesn't do it for the links in the "description" (?P<D>.*?) part.

I guess the plugin does special handling for feed item links (easy) but not for links embedded in the feed item descriptions (hard).

I'm just looking at the Awasu code now and it seems pretty easy to insert a debug switch to force the base URL for relative link translation. If you can get yourself set up with 2.3.rc1 (which edition are you using?), send us an email and I'll send you a pre-release of 2.3.rc2 with the change in it.

User avatar
support
Site Admin
Posts: 2925
Joined: Fri Feb 07, 2003 8:48 am
Location: Melbourne, Australia
Contact:

Postby support » Tue Mar 06, 2007 9:59 am

diabloNL wrote:BTW, strange the file doesn't work for you... :?

You might be logged in or have some other cookie set that causes the page served to be slightly different to what I'm getting :-)

User avatar
diabloNL
Posts: 55
Joined: Mon Feb 26, 2007 2:08 am

Postby diabloNL » Tue Mar 06, 2007 10:06 am

support wrote:
diabloNL wrote:BTW, strange the file doesn't work for you... :?

You might be logged in or have some other cookie set that causes the page served to be slightly different to what I'm getting :-)


Hmm... I'm not logged in so maybe a cookie. :?


I send you an email for version 2.3.rc2. Thanks! :wink:

User avatar
support
Site Admin
Posts: 2925
Joined: Fri Feb 07, 2003 8:48 am
Location: Melbourne, Australia
Contact:

Postby support » Tue Mar 06, 2007 11:55 am

diabloNL wrote:I send you an email for version 2.3.rc2.

I've just sent you a pre-release of 2.3.rc2 ::-):

User avatar
diabloNL
Posts: 55
Joined: Mon Feb 26, 2007 2:08 am

Postby diabloNL » Tue Mar 06, 2007 12:07 pm

Thanks, will try it tonight! 8)


Return to “Awasu - Extensions”

Who is online

Users browsing this forum: No registered users and 2 guests