How to ? Get Html Page Data

Questions, tips and tricks and techniques for scripting in Servoy

How to ? Get Html Page Data

Postby rainer / dsp » Wed Sep 28, 2011 3:54 pm

var url = 'http://www.sitetovisit.abc'
var _result_html = plugins.http.getPageData(url);

I need to add a http header to this request (browser id) - but how to do this ?

thank you very much

Rainer Boehm


Servoy 6.x
DSP Memory Distribution GmbH
Philipp-Reis-Str..11
24941 Flensburg / Germany
www.dsp-memory.de
rainer / dsp
 
Posts: 103
Joined: Sat Nov 22, 2003 1:37 am

Re: How to ? Get Html Page Data

Postby jcompagner » Wed Sep 28, 2011 5:09 pm

Create a Client object:
plugins.http.createNewHttpClient()

and create a getrequest from that one, where you can set the header and so on.
Johan Compagner
Servoy
User avatar
jcompagner
 
Posts: 8833
Joined: Tue May 27, 2003 7:26 pm
Location: The Internet


Return to Methods

Who is online

Users browsing this forum: No registered users and 5 guests