World: r3wp
[Web] Everything web development related
older newer | first last |
Micha 21-Mar-2005 [537x2] | <html> <head> <title>JavaScript Window Close Example 1</title> <script language="JavaScript1.2"> netscape.security.PrivilegeManager.enablePrivilege("UniversalPreferencesRead"); function openpanel() { panel = window.open("http://www.onet.pl","mywindow",""); } function closepanel() { panel.close(); } function readpanel() { alert(panel.location.host); } </script> </head> <body> <p> <a href="javascript: openpanel()">Open Popup Window</a> </p> <p> <a href="javascript: closepanel()">Close the Popup Window</a> </p> <p> <a href="javascript:readpanel()"> Read panel window</a> </p> </body> </html> |
readpanel not act . plis help | |
Anton 21-Mar-2005 [539x3] | javascript:readpanel() --> Error: uncaught exception: Permission denied to get property Location.host javascript: readpanel() --> Error: panel is not defined Source File: file:///d:/Anton/Dev/Rebol/View/list-demos/Micha's-javascript-page.html Line: 26 |
No no sorry... mmmmm.. hard. | |
Permission denied... is the real error. | |
Ammon 24-Mar-2005 [542] | Hm... I'm trying to parse a webpage and strip all HTML tags from it but my approach isn't work. Grr! |
Sunanda 24-Mar-2005 [543] | foreach item load/markup read http://www.rebol.com[if string? item [print item]] |
Ammon 24-Mar-2005 [544x2] | load/markup... That's it... |
Thanks | |
Geomol 29-Mar-2005 [546x2] | I have a problem with HTTPS over a proxy. I'm using REBOL/Command 2.5.6.3.1, that came with our SDK. This version first need the HTTPS protocol to be activated using this code: net-utils/net-install HTTPS make system/schemes/http/handler [] 443 system/schemes/https: make system/schemes/https [user-agent: reform ["REBOL" system/product system/version]] I activated trace by typing: trace/net on Our proxy is set up ok, as I can read the internet with a browser using it (both HTTP and HTTPS). Now if I in REBOL do this: >> s: read https://webservices.rki.dk I get: URL Parse: none none webservices.rki.dk none none none Net-log: ["Opening" "ssl" "for" "HTTPS"] connecting to: webservices.rki.dk Net-log: {CONNECT webservices.rki.dk:443 HTTP/1.1 Host: webservices.rki.dk:443 } Net-log: "HTTP/1.0 200 Connection established" Net-log: {GET https://webservices.rki.dk:443/ HTTP/1.0 Accept: */* Connection: close User-Agent: REBOL Command 2.5.6.3.1 Host: webservices.rki.dk:443 } Net-log: none ** User Error: Error. Target url: https://webservices.rki.dk:443/ could not be retrieved. Server response: none ** Near: s: read https://webservices.rki.dk |
I see two possibilities: 1) The proxy is not supporting tunneling, as required by reading the REBOL documentation http://www.rebol.com/docs/ssl.html 2) There's a bug in the REBOL/Command, I'm using. Any ideas would be very much appreciated! | |
Graham 29-Mar-2005 [548] | does it work without the proxy? |
Geomol 29-Mar-2005 [549] | Yes, I get this result: >> s: read https://webservices.rki.dk URL Parse: none none webservices.rki.dk none none none Net-log: ["Opening" "ssl" "for" "HTTPS"] connecting to: webservices.rki.dk Net-log: {GET / HTTP/1.0 Accept: */* Connection: close User-Agent: REBOL Command 2.5.6.3.1 Host: webservices.rki.dk:443 } Net-log: "HTTP/1.1 200 OK" Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] == { <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML> <HEAD> <title>RKI Webservices</title> <meta na... |
Graham 29-Mar-2005 [550x2] | I guess a web browser works ok? |
with the proxy... | |
Geomol 29-Mar-2005 [552x3] | Yes. |
I tested with Mozilla. | |
And I'm sure, I'm going through the proxy with the browser, as I tried a wrong TCP/IP port and got a proxy error. With the rigth port, it works ok. | |
Graham 29-Mar-2005 [555] | and can you read non ssl pages thru the proxy with rebol? |
Geomol 29-Mar-2005 [556x2] | Yes, like this: >> s: read http://www.rebol.com URL Parse: none none www.rebol.com none none none Net-log: ["Opening" "tcp" "for" "HTTP"] connecting to: www.rebol.com Net-log: {GET http://www.rebol.com/HTTP/1.0 Accept: */* Connection: close User-Agent: REBOL Command 2.5.6.3.1 Host: www.rebol.com } Net-log: "HTTP/1.0 200 OK" Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] Net-log: ["low level read of " 2048 "bytes"] == {<html> <head> <meta http-equiv="content-type" content="text/html;charset=iso-8859-1"> <title>REBOL Technologies</title> <style ... |
And if I try with a wrong TCP/IP port configuration (like I did with the browser test), I get this: >> s: read http://www.rebol.com URL Parse: none none www.rebol.com none none none Net-log: ["Opening" "tcp" "for" "HTTP"] connecting to: www.rebol.com ** Access Error: Cannot connect to 193.3.239.91 ** Where: open-proto ** Near: s: read http://www.rebol.com So I am going through the proxy with REBOL. | |
Graham 29-Mar-2005 [558x2] | so, the problem is most likely with Rebol. |
Have u tried using curl ? | |
Geomol 29-Mar-2005 [560] | No, what is curl? |
Graham 29-Mar-2005 [561x5] | it's a library and also command line utlity for doing web stuff. |
curl is a command line tool for transferring files with URL syntax, supporting FTP, FTPS, HTTP, HTTPS, GOPHER, TELNET, DICT, FILE and LDAP. Curl supports HTTPS certificates, HTTP POST, HTTP PUT, FTP uploading, HTTP form based upload, proxies, cookies, user+password authentication (Basic, Digest, NTLM, Negotiate, kerberos...), file transfer resume, proxy tunneling and a busload of other useful tricks. | |
http://curl.haxx.se/ | |
I used it before I got command. | |
wrote results out to data files, and then parsed the results out with rebol. | |
Carl 29-Mar-2005 [566] | Geomol: What proxy are you using? |
Geomol 29-Mar-2005 [567] | Carl: I have to check that at work tomorrow (I didn't set it up). We're testing on a proxy, and another one is at a customer, where it doesn't work either. The customer is the norwegian oil company Statoil, and we have their words, that it supports "tunnelling", but I'm sceptical as usual. ;-) |
Romano 29-Mar-2005 [568] | Geomol, how you set the proxy in Rebol? |
Geomol 29-Mar-2005 [569] | In the SDK, I use the set-network command. Else the set-net command can be used. |
Graham 29-Mar-2005 [570] | Can you use ethereal to see if the packets are all going thru the proxy? |
Romano 29-Mar-2005 [571] | I should like to know what is the proxy-type you set with set-net |
Geomol 29-Mar-2005 [572] | Proxy type is generic. |
Allen 29-Mar-2005 [573] | Graham, any relation to the other Curl language/platform? http://www.curl.com/ |
Graham 29-Mar-2005 [574x2] | Completely different. I think we discussed www.curl.com on the mailing list many years ago. Someone was saying that they had a proposition for View to do a job, but it ended up being done by Curl. |
There was discussion way back in 1991 http://www.rebol.org/cgi-bin/cgiwrap/rebol/ml-display-thread.r?m=rmlXQTK about Curl, and the 30Mb download required. | |
Izkata 29-Mar-2005 [576] | ....you mean 2001 |
Geomol 30-Mar-2005 [577] | Carl: On the test system, we use the proxy named squid version 2.5.9_1 (http://www.squid-cache.org) under FreeBSD 5.3. |
Graham 30-Mar-2005 [578x2] | I also tried reading a https page using command and squid, and couldn't get it to work. |
Altme works throught squid though | |
Geomol 30-Mar-2005 [580x2] | Thanks Graham. Good that someone else can recreate the problem. |
Is Altme communicating on plain TCP/IP protocol? Does Altme use encryption in any way? SSL? | |
Graham 30-Mar-2005 [582x2] | Altme uses encryption but not ssl |
I just so happened to have squid setup next to me for another purpose ...so could easily test. | |
Geomol 30-Mar-2005 [584x3] | Out customer Statoil use a hardware proxy from NetApp called NetCache, and they have the same problem. http://www.netapp.com/products/netcache/netcache_family.html Tunnelling is supported according to their specs: http://www.netapp.com/products/software/software_specs.html |
Graham: Do you know, how tunnelling works with squid? (I'm not a proxy expert in any way.) Does it have to be turned on or something in the config file? | |
I see the spelling "tunelling" with one 'n' now and then, in case you're searching the documentation. | |
older newer | first last |