dbTalk Databases Forums  

Opal http POST showing the resulting web page

comp.databases.paradox comp.databases.paradox


Discuss Opal http POST showing the resulting web page in the comp.databases.paradox forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jim Moseley
 
Posts: n/a

Default Opal http POST showing the resulting web page - 04-22-2009 , 02:07 PM







OK, I seem to have run into a brick wall. I need my Opal code to open up
a webpage via a POST, and then display the resulting page.

I can issue a POST in the background and capture the results, using MSXML's
xmlHTTP functions.

I can display a webpage several different ways, using Tony's MSBrowser &
via startBrowser, and via shellExecute.

I can even capture a webpage in the background via GET using Lorrin Moore's
grabIt library.

But, I can't figure out how to do both at the same time. Tony's MSBrowser
looked promising, but I need a SAFEARRAY data structure for the Navigate2
method to trigger the POSTdata, and that is out of my league.

My current webpage is pretty simple: a list of address fields to trigger
Google Maps. I can't use GET because the clients aren't limited to the number
of addresses they can enter to get a route returned, and I'd run into the
URL length limit.

BTW, there are thousands of clients that will use this code, via Runtime
9.

Any other ideas?

Thanks,
Jim Moseley

Reply With Quote
  #2  
Old   
Liz McGuire
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-22-2009 , 02:47 PM







I don't suppose you can use GET to pull up the page the form is on, then sendKeys()
to fill out the form and submit it? Ugly and brute force, but if it's all
that will work...

Liz


"Jim Moseley" <jmose (AT) mapson (DOT) triptracker.com> wrote:
Quote:
OK, I seem to have run into a brick wall. I need my Opal code to open up
a webpage via a POST, and then display the resulting page.


Reply With Quote
  #3  
Old   
Liz McGuire
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-22-2009 , 02:49 PM




"Jim Moseley" <jmose (AT) mapson (DOT) triptracker.com> wrote:
Quote:
My current webpage is pretty simple: a list of address fields to trigger
Google Maps. I can't use GET because the clients aren't limited to the
number
of addresses they can enter to get a route returned, and I'd run into the
URL length limit.
I don't get it, if the clients are going to enter these addesses, why can't
the clients submit the form, thereby triggering the post?

Liz



Reply With Quote
  #4  
Old   
Jim Moseley
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-22-2009 , 04:13 PM




Liz,

Quote:
I don't get it, if the clients are going to enter these addesses, why can't
the clients submit the form, thereby triggering the post?
The addresses come from the database. They enter a trip into my Pdox app,
then want to push 1 button to get a route for all the stops. They're not
dealing with the web page directly until the route is shown.

Thanks,
Jim Moseley


Reply With Quote
  #5  
Old   
Tony McGuire
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-22-2009 , 10:46 PM



Jim Moseley wrote:
Quote:
Liz,

I don't get it, if the clients are going to enter these addesses, why can't
the clients submit the form, thereby triggering the post?

The addresses come from the database. They enter a trip into my Pdox app,
then want to push 1 button to get a route for all the stops. They're not
dealing with the web page directly until the route is shown.

Thanks,
Jim Moseley

Doesn't the new[ish] Google map api offer the type of functionality you are
looking for?

Late into the question, and don't understand what is going on AT ALL.

--
---------------
Tony McGuire
http://www.homebookexchange.com


Reply With Quote
  #6  
Old   
Tony McGuire
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-22-2009 , 11:05 PM



Tony McGuire wrote:

By the way, I do [did] the Google Maps stuff with Paradox 9. Maybe you are
getting in deeper than I did, but I don't remember any SAFEARRAY having to be
created/designed. Certainly it didn't block me, although the maps did take
several hours to get running. Very cool 4th party tool (4th?)





---------------
Tony McGuire
http://www.homebookexchange.com

Reply With Quote
  #7  
Old   
Liz McGuire
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-22-2009 , 11:10 PM



But you did it on a web site - where the web OCX was processing the
request. He's trying to do it in the MS Browser OCX. At least, I think
that's the case...

Liz


Tony McGuire wrote:
Quote:
Tony McGuire wrote:

By the way, I do [did] the Google Maps stuff with Paradox 9. Maybe you
are getting in deeper than I did, but I don't remember any SAFEARRAY
having to be created/designed. Certainly it didn't block me, although
the maps did take several hours to get running. Very cool 4th party
tool (4th?)





---------------
Tony McGuire
http://www.homebookexchange.com

Reply With Quote
  #8  
Old   
Jim Moseley
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-23-2009 , 12:08 AM




Liz,

Quote:
But you did it on a web site - where the web OCX was processing the
request. He's trying to do it in the MS Browser OCX. At least, I think

that's the case...
Spot on, Liz. I've got my webpages working with Google Maps, if I use IE
& go to the URL and type in my info.

I'm trying to automate this so that I can call it from a Pdox form. The
trick is that I need to POST the webpage to get it to use all my data. I'm
not using the CWS OCX in this part of my app - it is actually my main data
entry form.

And, I'm not tied to the MS Browser OCX if someone has a different idea.

Since I can grab a non-displayed webpage via POST using MSXML's xmlHttp,
one possibility is to save the returned html & display it locally. But,
I'm trying to avoid that (if I can figure out how to do it, to begin with).

Thanks,
Jim Moseley


Reply With Quote
  #9  
Old   
modri dirkac
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-23-2009 , 08:27 AM



What about curl.exe?

Nowdays I use it only to GET some web pages (exchange rates) and
download ZIP files from web.

But in the past I wrote a paradox program for automatic
answering questions in a music quiz.

* GET web page with question, parse it
* if question is not yet in my database, then store it and select first from
3 answers.
* POST back answer
* GET result and new answer
if result is OK, then remember answer to this question fo future.
if result is not OK, remeber this wrong result and not select it in future
* POST back next answer
* GET result
* POST back email and name.

From 100.000 answers more than 20.000 werw mine, but I was disqualified.
:-(


curl.exe can write and read session state from TXT file.
So on first GET you save session ID in header.txt, when doing
POST you tell curl.exe to use session from header.txt

Jure



"Jim Moseley" <jmose (AT) mapson (DOT) triptracker.com> je napisal v sporočilo
news:49ef5cf2 (AT) pnews (DOT) thedbcommunity.com ...
Quote:
OK, I seem to have run into a brick wall. I need my Opal code to open up
a webpage via a POST, and then display the resulting page.

I can issue a POST in the background and capture the results, using
MSXML's
xmlHTTP functions.

I can display a webpage several different ways, using Tony's MSBrowser &
via startBrowser, and via shellExecute.

I can even capture a webpage in the background via GET using Lorrin
Moore's
grabIt library.

But, I can't figure out how to do both at the same time. Tony's MSBrowser
looked promising, but I need a SAFEARRAY data structure for the Navigate2
method to trigger the POSTdata, and that is out of my league.

My current webpage is pretty simple: a list of address fields to trigger
Google Maps. I can't use GET because the clients aren't limited to the
number
of addresses they can enter to get a route returned, and I'd run into the
URL length limit.

BTW, there are thousands of clients that will use this code, via Runtime
9.

Any other ideas?

Thanks,
Jim Moseley



Reply With Quote
  #10  
Old   
Tony McGuire
 
Posts: n/a

Default Re: Opal http POST showing the resulting web page - 04-23-2009 , 09:45 AM



Liz McGuire wrote:
Quote:
But you did it on a web site - where the web OCX was processing the
request. He's trying to do it in the MS Browser OCX. At least, I think
that's the case...

Liz
I do both; websrv and simple web browser for generic client usage.


--
---------------
Tony McGuire
http://www.homebookexchange.com


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.