Comments and answers for "HTTPCaller using POST method - unable to get a valid response" https://knowledge.亚搏在线safe.com/questions/68947/httpcaller-using-post-method-unable-to-get-a-valid.html The latest comments and answers for the question "HTTPCaller using POST method - unable to get a valid response" Comment by fgiron https://knowledge.safe.com/comments/87379/view.html

Hi@juanmahere,did you manage in the end to solve this via webscraping with the HTMLExtractor and CSS Selectors?By the way, very good idea@david_r!

I came very recently to this same problem with this very same website and I ended up using this other web service where I can easily send http GET requests to get the same data:https://ovc.catastro.meh.es/ovcservweb/OVCSWLocalizacionRC/OVCCallejero.asmx?op=Consulta_DNPRC

The only con is that every request takes about 4 seconds...I have seen faster services ;-)

Thu, 21 Feb 2019 23:26:39 GMT fgiron
Comment by juanmahere on juanmahere's comment https://knowledge.safe.com/comments/68997/view.html ummm...I'll need to hold this for a next round tomorrow...
What if I put a RC[14] = "0729806VG3802N" value?it gets me to its longest reference since it is the unique "owner" let's say...with: 0729806VG3802N0001IB[20].Where the site looks like this:

which its source is: Link

Otherwise, if I put a RC value, with various owners, like this one: "9616903VG2891N"[14]
gets me to this one:

which its source is: Link
a full list on a table with RCs of [20] chars.
So, the topic is getting complicate.

I'll this topic updated once I get any results, if I can success with FME Desktop.
Thanks,

Wed, 25 Apr 2018 15:55:26 GMT juanmahere
Comment by juanmahere on juanmahere's comment https://knowledge.safe.com/comments/68989/view.html Yeas, of course.Thanks for the reference, I'll check it up.

Let me get the output once run the process, and I'll post here back, because a Cadastral Reference may take various horizontal houses, and it is getting a bit complicate.Thanks,
Wed, 25 Apr 2018 15:30:21 GMT juanmahere
Comment by david_r on david_r's comment https://knowledge.safe.com/comments/68983/view.html You can find an OK tutorial for CSS selectors here:
https://www.w3schools.com/cssref/css_selectors.asp
To give you a more detailed reply for the HTMLExtractor, could you please post a complete URL to a listing page I can use for testing?
Wed, 25 Apr 2018 15:13:55 GMT david_r
Comment by juanmahere on juanmahere's answer https://knowledge.safe.com/comments/68982/view.html Hi David,
Thanks for taking your time, and providing a solution!

Let me show you how I've just readjusted your values:
For the Requested URL, worked fine if it was run using a particular Cadastral ID, so, once I replace with another one, it got me no results.
The Url has been changed to something like this:

"
https://www1.sedecatastro.gob.es/CYCBienInmueble/OVCListaBienes.aspx?RC1= @Value(RC1)&RC2= @Value(RC2)&RC3=&RC4=&esBice=&RCBice1=&RCBice2=&DenoBice=&pest=rc&final=&RCCompleta=@Value(RC)&from=OVCBusqueda&tipoCarto=nuevo
"
Where those RC1and 2, where a string subtraction from the used RC value.

Now, what I cared is the rest of attribute of that Building or whatever is referenced to, like AREA, TYPE,...not the addresses.But, no worries, I'll try to extract those I need, following the sample you made with Address1 and Address2.

Here is an example of the data to be extracted:


Looking up in the source, here is the html table:


Could you tell me how to use the CSS Selector you used on your example, applied here?I cannot find any documentation, and I'm finding a little hard to get the solution.

Also, I'd ask you about the Query String Parametersthat I didn't use, and seems like was the problem solver.How that works?

Many thanks David,


Wed, 25 Apr 2018 15:09:21 GMT juanmahere
Answer by david_r https://knowledge.safe.com/answers/68954/view.html

Try the following template and see if that works for you.The parcel ID comes from the attribute "RC", change it as you like in the Creator.

es-cadastre-scraper.fmwt

It will extract the first two address lines into the attributes "Address1" and "Address2", e.g.

Result, from the Data Inspector:

Wed, 25 Apr 2018 13:40:28 GMT david_r