Recent

Author Topic: How should one enter a http request in android  (Read 3595 times)

stab

  • Full Member
  • ***
  • Posts: 234
How should one enter a http request in android
« on: November 13, 2012, 03:53:53 pm »
Hi,

After I was adviced how to add new events to an android app I've been trying to
load  a web-page :

http://www.nasa.gov/mission_pages/mars/main/index.html

with OpenURL and  LoadHTMLPageViaJNI

in OpenURL the request is modified to
http:%2F%2Fwww.nasa.gov%2Fmission_pages%2Fmars%2Fmain%2Findex.html

and when using LoadHTMLPageViaJNI I don't get anything

How shall I do to get the request right, guess it's something about encoding or
escaping characters?

Thanks in advance
stab ::)

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: How should one enter a http request in android
« Reply #1 on: November 13, 2012, 05:01:45 pm »
I'd first test openurl on another platform (Linux, Windows, OSX), read any documentation on it and if necessary file a bug.
Your URL seems to work when run on Laz trunk x86 on Windowx ...

« Last Edit: November 13, 2012, 05:04:34 pm by BigChimp »
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

stab

  • Full Member
  • ***
  • Posts: 234
Re: How should one enter a http request in android
« Reply #2 on: November 13, 2012, 06:33:45 pm »
Thanks BigChimp,

Checked out trunk, followed README.txt guide to make clean bigide but there must be somethng that I don't understand. Because when I start Lazarus via Lazarus.exe in trunk it seems to start Lazarus 1.1 that is installed from Lazarus-1.1-39275-fpc-2.6.1-20121113-win64.exe.
I used lazarus1.1\fpc\2.6.1\bin\x86_64-win64\make.exe.

I don't find any ftp-directory in the trunk-directory after make.

Am I doing wrong and what am I supposed to do?

/stab %)

BigChimp

  • Hero Member
  • *****
  • Posts: 5740
  • Add to the wiki - it's free ;)
    • FPCUp, PaperTiger scanning and other open source projects
Re: How should one enter a http request in android
« Reply #3 on: November 14, 2012, 09:29:45 am »
No idea about ftp directories etc... I usually use fpcup to get new Lazarus.

Regardless, if you're sure you called the correct Lazarus exe (with the correct primary config path, assuming you want to separate multiple Lazarus versions), a simple rebuild from the IDE tools menu works for me as well after updating Lazarus sources.

My Lazarus trunk says 1.1 and the SVN revision is around 39277... so those numbers seem ok? Have you been using a snapshot before this? If so, you are on trunk as it existed on that day.

Finally: why did you change to trunk? Are there android fixes in there?
Want quicker answers to your questions? Read http://wiki.lazarus.freepascal.org/Lazarus_Faq#What_is_the_correct_way_to_ask_questions_in_the_forum.3F

Open source including papertiger OCR/PDF scanning:
https://bitbucket.org/reiniero

Lazarus trunk+FPC trunk x86, Windows x64 unless otherwise specified

 

TinyPortal © 2005-2018