It seems to work on OSX and the latest shoes build:

<html>
<head>
<title>Welcome to Jalot</title>
<link href="/jalot/jalot.css" type=text/css rel=stylesheet>
<link rel="shortcut icon" href="/image/jalotfav.gif">
<style type="text/css">
    a { font-family: Arial; font-size: 12px; color: #069; font-weight: bold;
}
</style>
<script src="/jalot/util.js"></script>
<script>
    var username, userkey, userhandle, userrealname, userpin;
    function canSubmit(in_form) {
        if (document.getElementById("handle").value.length == 0) {
            document.getElementById("handle").focus();
            return false;
        }
        if (!document.getElementById("password").value.length) {
            document.getElementById("password").focus();
            return false;
        }
        if (!raccreq("/raccxml.cgi?db=vark", {
                "loginname": document.getElementById("handle").value,
                "loginpassword": document.getElementById("password").value,
                "logindbname": "jalot" }, null, false)) {
            var err_obj =
curr_raccreq.responseXML.getElementsByTagName("error");
            if (err_obj)
                alert("Could not log in: " + getXmlValue(err_obj[0],
"message"));
            else
                alert("No response from server");
            return false;
        }
        var req_obj = curr_raccreq;
        if (!req_obj.responseXML.getElementsByTagName("userkey").length) {
            alert("Could not log in: " +
                getXmlValue(req_obj.responseXML, "message"));
            return false;
        }
      document.cookie = "raccauth=\"" +
         encodeURIComponent(getXmlValue(req_obj.responseXML, "userkey")) +
            "\"; path=/";
        username = getXmlValue(req_obj.responseXML, "username");
        userhandle = getXmlValue(req_obj.responseXML, "handle");
        realname = getXmlValue(req_obj.responseXML, "realname");
        userpin = getXmlValue(req_obj.responseXML,
"pinstring").substring(0,4);
        if (document.getElementById("opennewwin").checked) {
            var new_win = window.open("/jalot/","jalotwin",
                "resizable,height=570,width=700");
        } else {
            document.location = "/jalot/?acct=" +
encodeURIComponent(username)
                 + '/' + encodeURIComponent(userhandle) + '/' +
                encodeURIComponent(realname) + '/' +
encodeURIComponent(userpin);
        }
        return false;
    }
    function mkacct(link_obj) {
        var new_win = window.open("/jalot/mkacct.html","jalotwin",
                "resizable,height=450,width=550");
        new_win.focus();
        link_obj.blur();
        return false;
    }
    function lostpass(link_obj) {
        alert("Function not implemented; please email " + "lbrintle" +
            "@" + "leepfrog.com to reset");
        link_obj.blur();
    }
</script>
<style type="text/css">
    #maindiv {
        background-image: url(/images/pda.gif);
        background-repeat: no-repeat;
        background-position: center 75px;
        oldbackground-position: 0px 75px;
        height: 390px;
        width:100%;
    }
</style>
</head>
<body>
<form onSubmit="return canSubmit(this);" method="POST">
<div id="maindiv">
<table border=0 align="center">
<tr><td colspan=3><img src="/images/jalot.png" class="png"></td></tr>
<tr>
    <td style="width:310px; height:160px;">&nbsp;</td>
    <td><table valign=center>
        <tr><td align=left valign=center>
            <input type=text name=handle id=handle tabindex=1
                value="" size=20
                onfocus="this.select();"></td>
            <td rowspan=2 valign=center><input type="image"
                src="/images/arrow.gif" tabindex=4></td></tr>
        <tr><td align=left valign=center>
            <input type=password tabindex=2 id=password
                name=password size=20 onfocus="this.select();"></td></tr>
        <tr><td colspan=2 valign=top align=right>
            <input type=checkbox name=opennewwin id=opennewwin tabindex=3>
            Open in new window</td></tr>
    </table></td></tr>
<tr><td colspan=2 align=right style="padding-right: 60px;">
<a href="/jsrequired/" onClick="return mkacct(this);">Create an Account</a>
|
<a href="/jsrequired/" onClick="return lostpass(this);">Forgot Your
Password?</a> |
<a href="/about/">About Jalot</a>
</td></tr>
</table>
<script>
    document.getElementById("handle").focus();
    document.getElementById("handle").select();
</script>
</div>
</form>
</body>

K.

On Tue, Mar 31, 2009 at 6:10 PM, Edward Heil <[email protected]> wrote:

> Is there any particular trick to using download() with SSL that I'm
> missing?
>
> I tried this:
>
> Shoes.app do
>  stack do
>    button "go" do
>      @thing.text = "fetching..."
>      download( 'https://www.jalot.com/') do |dl|
>        self.clipboard = @thing.text = dl.response.body
>      end
>    end
>    @thing = para ""
>  end
> end
>
> and got this:
>
> <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
> <html><head>
> <title>400 Bad Request</title>
> </head><body>
> <h1>Bad Request</h1>
> <p>Your browser sent a request that this server could not understand.<br />
> Reason: You're speaking plain HTTP to an SSL-enabled server port.<br />
> Instead use the HTTPS scheme to access this URL, please.<br />
> <blockquote>Hint: <a href="https://jalot.com/";><b>https://jalot.com/
> </b></a></blockquote></p>
> <hr>
> <address>Apache/2.0.54 (Fedora) Server at jalot.com Port 443</address>
> </body></html>
>
>
>

Reply via email to