get url

Getting into LiveCode for iOS? Ask your questions here.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
edmerckx99
Posts: 8
Joined: Sat Nov 20, 2010 2:32 am

get url

Post by edmerckx99 » Thu Feb 10, 2011 12:26 pm

i have been struggeling with this for a bit.
this works great

Code: Select all

get url "myurl/folder/folder/text.txt"
but if i try and create a url from a variable it does not work

Code: Select all

local tURL
put "myurl/folder/folder/" & fld "Variable" & ".txt" into tURL 
get url tURL 
i am making sure that there are not spaces in the url and that the url does exist.

help

Klaus
Posts: 13829
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: get url

Post by Klaus » Thu Feb 10, 2011 1:52 pm

Hi Ed,

hm, just tried it here and it worked fine:

Code: Select all

on mouseUp
  put "http://www.major-k.de/" & fld "Variable" & ".html" into tURL
  get url tURL
  put it into fld "test"
end mouseUp
I put "index" into fld "variable".
MacMini, OS X 10.6.6

Did you check "the result" right ater your line:
...
get url tUrl
anser the result
## Will be empty on success and may give hint if not.
...


Best

Klaus

edmerckx99
Posts: 8
Joined: Sat Nov 20, 2010 2:32 am

Re: get url

Post by edmerckx99 » Thu Feb 10, 2011 2:44 pm

it does seem to work on the desktop but when i send to the iphone simulator it does not work
i get a 404 error message. but when i

Code: Select all

answer tURL
the url is correct and if i would copy and paste that into a browser it would work.

Klaus
Posts: 13829
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: get url

Post by Klaus » Thu Feb 10, 2011 3:39 pm

Hi Ed,

ah, I see, but I have no idea so far...


Best

Klaus

edmerckx99
Posts: 8
Joined: Sat Nov 20, 2010 2:32 am

Re: get url

Post by edmerckx99 » Thu Feb 10, 2011 6:31 pm

thank you for the help Klaus! it has been very frustrating to debug this problem, i will keep plugging away on this.

Klaus
Posts: 13829
Joined: Sat Apr 08, 2006 8:41 am
Location: Germany
Contact:

Re: get url

Post by Klaus » Thu Feb 10, 2011 9:36 pm

Hi Ed,

sometimes the Simulator is behaving a bit strange, but then it mostly works on a real device.
Did you check this on an iPhone?


Best

Klaus

Post Reply

Return to “iOS Deployment”