2007-07-24:
[0:17] <Spartin92> how do i get onto irc?[3:47] <jsp> welcome back, jake. any luck on mac?[13:57] <mho> he guys[13:58] <zumbrunn> hi mho[13:58] <mho> i need help with helma ;)[13:59] <mho> i made ah login... and when the login function returns false i redirect to another action who rendes the loginscreen again[14:00] <mho> in login.skin stands <input name="name" value="response.name" />[14:00] <mho> i loose the response data after de redirection[14:01] <zumbrunn> value="<% response.name %>"[14:01] <mho> how kan i fix it? any ideas? i tryed over the session.data.variablename... but i dont think this is the best way[14:01] <mho> yeah sorry <% response.name%> i know ;)[14:02] <mho> hold on a sek, i paste the code[14:02] <zumbrunn> are you setting res.data.name somewhere?[14:02] <mho> function createUser_action()[14:02] <mho> {[14:02] <mho> if(req.data.save){[14:02] <mho> [14:02] <mho> if(req.data.password1 != req.data.password2){[14:02] <mho> [14:02] <mho> res.data.vname = req.data.vname;[14:02] <mho> res.data.nname = req.data.nname;[14:02] <mho> res.data.mail = req.data.mail;[14:02] <mho> [14:03] <mho> res.redirect(this.href("reguser"));[14:03] <mho> [14:03] <mho> return;[14:03] <mho> }[14:03] <mho> [14:03] <mho> this.evalUser(req.data);[14:03] <mho> [14:03] <mho> } else {[14:03] <mho> res.redirect(this.href("reguser"));[14:03] <mho> }[14:03] <mho> }[14:03] <mho> after the redirect on the action "reguser" where the login skins was rendered i lost the res.data.myvariable...[14:04] <mho> sorry for my bad english.[14:05] <midnightmonster> res.data doesn't survive redirect[14:05] <zumbrunn> you probably wouldn't have to do the redirect and could make a function call instead[14:05] <mho> is there no other way exept over session.data.myvariable?[14:07] <zumbrunn> res.message[14:07] <zumbrunn> http://helma.zumbrunn.net/reference/res.html#message[14:08] <mho> thx[14:08] <midnightmonster> but you shouldn't really load a bunch of data into res.message. the usual way to do this is just display the login form again from the same page without redirecting[14:09] <midnightmonster> so you have all the data still there[14:09] <mho> hm[14:10] <mho> for the login() i need a http request or not?[14:10] <midnightmonster> don't understand.[14:10] <mho> sorry ;)[14:11] <mho> the login form is on the startpage[14:11] <zumbrunn> not sure if I understand either, but I think the answer is no[14:11] <mho> the submitbutton takes you to the login_action()[14:12] <midnightmonster> Ok, so post the login form to a /login action which processes the login and if login fails, display only the login form[14:12] <mho> thats a prosibility[14:12] <mho> but not nice.[14:12] <mho> possibility[14:12] <mho> anyway... thx 4 help![14:13] <midnightmonster> that's what's usually done--I don't think there's anything wrong with it[14:13] <zumbrunn> then put the code that generates the login form into a function that you can call from the two different actions[14:13] <mho> yeah its the usually way, but i want to give the visitors some comfort[14:13] <zumbrunn> (but I agree with midnightmoster)[14:14] <midnightmonster> if your login attempt fails, it does *not* make sense to show the whole start page over again. if I tried to login, obviously what I'm trying to do is *login*. If I see anything else after the failure, it's only noise that distracts me from handling the problem[14:16] <midnightmonster> (after a *successful* login, it may make sense to go back to the start page that now shows more options because I'm logged in. you might also add a small message with res.message that says I've successfully logged in.)[14:18] <midnightmonster> btw, zumbrunn--I'm curious about res.message. do you know how it knows to survive th redirect but then go away after that? since PHP essentially runs like a CGI, PHP can't provide such things built-in, and I'm finding it terribly handy.[14:20] <zumbrunn> probably with the help of the session?[14:20] <zumbrunn> don't really know, though[19:33] <jsp> how do I define a constructor for my prototype in Helma?[19:35] <zumbrunn> what happens if you do exactly that as part of you global code?[19:36] <jsp> dunno[19:36] <jsp> let's find out![19:36] <zumbrunn> (you mean a constructor that has HobObject in it's prototype chain, I assume[19:36] <jsp> er, yeah[19:37] <jsp> I want to be able to call new Thing(arg) and have Thing arrange itself somewhat differently depending on arg[19:45] <jsp> doesn't work--just becomes a standard object and loses the HopObject-ness (also the Thing-ness)[19:46] <zumbrunn> you defined a custom prototype?[19:46] <zumbrunn> and set it's prototype property to a new HopObject() ?[19:47] <jsp> sample code to make sure I'm doing what you mean?[19:48] * zumbrunn has dinner on the table and is going to be afk for a while...[19:48] <zumbrunn> but...[19:48] <zumbrunn> one other possibility I can think of...[19:48] <zumbrunn> (if the above really dosn't work)[19:49] <zumbrunn> is to overload the constructor with a closure that contains the original Helma constructor[19:49] <zumbrunn> (not sure how to explain this right now)[19:49] <jsp> I understand in principle[19:50] * zumbrunn will be back[19:50] <jsp> enjoy your dinner. it's not critical anyway[22:58] <rjb> ok experimenting with the h2database again[22:59] <rjb> in embedded mode[23:00] <rjb> and i must say it does not *feel* blazing fast compared to mysql[23:00] <rjb> (not that i have done any meaningful comparison yet)[23:02] <jsp> how can you feel milliseconds?[23:04] <jsp> mysql is already quite fast for most cases. I wouldn't expect to notice much difference. the principle advantage as far as I'm concerned is not having to administer a separate db without worrying that I'm *losing* significant performance[23:04] <jsp> (for most cases that you can easily get to while fiddling around, anyway)[23:05] <rjb> i'm playing with pretty massive amounts of floating point data[23:06] <rjb> so i'm talking seconds, not millis[23:13] <rjb> my idea is to perform data analysis on all those numbers with stored procedures to compute the statistics i dream up[23:17] <rjb> so i could easily throw any datasets i'm provided with at the database and quickly get results[23:18] <jsp> so is it worse than mysql?[23:18] <rjb> those datasets would typically be a million or so rows of a few floats each[23:18] <jsp> that's a lot of rows[23:19] <rjb> that's why i want a database[23:19] <jsp> I've been under the impression that postgres is better for serious stored procedure stuff[23:19] <jsp> but I've never had to do anything with a million rows[23:19] <rjb> i'm told the size of those datasets seriously strains matlab[23:21] <jsp> I think I would not put it in-process in such a case--perhaps easier to set memory settings appropriately if they're separate. but I'm no expert[23:21] <jsp> bb in 10 or so[23:21] <rjb> well one webapp based on mysql i work with has at least 2 tables with over a million rows each[23:22] <rjb> make that at least 3 tables[23:22] <rjb> (of the several dozen tables total that are used)[23:23] <rjb> it's running on a pentium iii and it performs pretty well[23:24] <rjb> (i did not write the app)[23:35] * rjb is gone to sleep
In the channel now:
Logs by date: