put URL... does not work. Why? Please help me! (='.'=)
Posted: Tue May 14, 2013 11:11 am
Hello!
I apologize again for my horrible english!
I'm studying LiveCode and I'm excited... i'm a beginner, an absolute beginner!
Right now I'm doing some tests on downloading web pages. I noticed a strange behavior.
Here is the code. (There is a button and 3 fields)
LiveCode can not download the page correctly! 
I built a routine more complex to understand what does not work ... here it is:
TEST progress... getting page...
http://www.cnn.com OK!!!!
http://forums.runrev.com/ OK!!!!
W LIVE CODE!!!! W THE LIVE CODE FORUM!!!! 
http://www.huffingtonpost.com OK!!!
http://www.ilfattoquotidiano.it NOOOOOOOOO!!!!!!!!!
why?
This website, however, shows "squares" and I can not see the code in the correct way!
where am I wrong?
Maybe it's a stupid thing ... but for me it is a major obstacle! Thanks to those who want to help me!
Baci!!!!
Mariasole (='.'=)
PS: I use WinXP and LiveCode Community 6.0
I apologize again for my horrible english!
I'm studying LiveCode and I'm excited... i'm a beginner, an absolute beginner!

Right now I'm doing some tests on downloading web pages. I noticed a strange behavior.
Here is the code. (There is a button and 3 fields)
Code: Select all
on mouseUp
put url "http://www.ilfattoquotidiano.it" into field "fHtml"
end mouseUp

I built a routine more complex to understand what does not work ... here it is:
Code: Select all
on mouseUp
put url "http://www.ilfattoquotidiano.it" into myData --- put your other url here for test! ;)
-- set Header (it's an example of User Agent, I have tried many other... win, mac, linux etc...!
set the HTTPHeaders to "User-Agent: Firefox 20/Linux: Mozilla/5.0 (X11; Linux x86_64; rv:20.0) Gecko/20100101 Firefox/20.0" \
& return & "Connection: Keep-Alive"
put uniencode(myData,"UTF8") into myData
-- put in my Human Viewer field (fHtml) ;)
set the unicodeText of fld "fHtml" to myData
-- view Header in field fHeader
put libUrlLastRHHeaders() into field "fHeader"
-- 5. view the UserAgent in field fUserAgent
put libURLLastHTTPHeaders() into field "fUserAgent"
end mouseUp
TEST progress... getting page...
http://www.cnn.com OK!!!!

http://forums.runrev.com/ OK!!!!


http://www.huffingtonpost.com OK!!!

http://www.ilfattoquotidiano.it NOOOOOOOOO!!!!!!!!!




This website, however, shows "squares" and I can not see the code in the correct way!
where am I wrong?
Maybe it's a stupid thing ... but for me it is a major obstacle! Thanks to those who want to help me!
Baci!!!!
Mariasole (='.'=)
PS: I use WinXP and LiveCode Community 6.0