× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I'm looking at Scott Klement's Open Source HTTP stuff now.

Be seeing you...B

Joel B. Harvell
Food Lion, LLC
(704) 633-8250 x2709
jbharvell@xxxxxxxxxxxx


-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Walden H. Leverich
Sent: Friday, July 11, 2008 1:34 PM
To: Midrange Systems Technical Discussion
Subject: RE: Using a webpage with an RPG program

The program would have to log onto the website and then upload the
file to the website.

Assuming the remote site doesn't offer a more program-friendly interface
(FTP, webservice, etc.) then you'll have to pretend to be a browser and
send the appropriate request to the remote site. The difficulty of this
can vary from trivial to impossible depending on the remote site.

Also, you'll be doing things that the average user would do w/out
thinking about, but which can really trip up a computer. For example.
Say the site has a simple button names "Login", and by "named" I mean
that the html says "name=Login". The text shown to the user also happens
to be "Login" (text=Login), as does the value of the button
(value=Login). Now, you could send the HTTP post stream that contains
Login=Login, and you'd be all set. Unless, of course, the remote side
now changes the name of the button to "cmdLogin", but doesn't change the
text. The (human) user would never even know about the change and click
the "login" button and all would be good in the world. Your application,
however, would still send Login=Login and the remote server would say
"Login? I don't have anything on my form called login, choke, die". Of
course, you could isolate yourself from the problem of them changing the
name of the button by looking for a button with the text "Login". Then
if they changed the name of the button you'd be all set, your program
would handle the change. Of course, if they changed the text to be "Go"
then you wouldn't find the button...

In short, yes, it can be done, but it's a fragile setup. And the more
pages you have to transition, to more fragile it gets.

Oh, and then there's the licensing/rights issue, if that's applicable.
Some sites don't allow computerized access (not that they could tell)...
um... (not that I'd recommend breaking a license agreement. ;-)

-Walden

--
Walden H Leverich III
Tech Software
(516) 627-3800 x3051
WaldenL@xxxxxxxxxxxxxxx
http://www.TechSoftInc.com

Quiquid latine dictum sit altum viditur.
(Whatever is said in Latin seems profound.)


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.