# WeSQL Upgrade Path

v0.50 -> v0.51:
In your database, add (MySQL definition, see the Addressbook application for a PostgreSQL definition): create table sessions ( pkey bigint(20) unsigned not null auto_increment, id bigint(20) unsigned not null, uid bigint(20) unsigned not null, suid bigint(20) unsigned not null default '0', epoch bigint unsigned not null, status tinyint default '1' not null, hash varchar(16) default '' not null, primary key (pkey) ); And execute: alter table sessiondata change loginid sessionid bigint(20) unsigned not null; Also, don't forget to make new copies for any copies of AppHandler.pm you have made!! In the file(s) details.cf, replace all occurencies of $key by $data{key}. I've removed this extra bit of syntactic sugar to simplify things (and to sanitize them, as it only worked in details.cf, and not in the other .cf files). Make sure to add something sensible for the following keys in the layout.cf file(s): listform1 listform2 listform3 These are used in the login forms. The default values are: loginform1 <tr> <td align=center valign=top> <br> <center> <form action="jlogin.wsql" method=post> <table width=400> <tr><td align=right><b>Login:</b></td><td><INPUT name="login"></td></tr> <tr><td align=right><b>Password:</b></td><td><INPUT name="passwd" type=password></td></tr> <tr><td colspan=2 align=center> loginform2 <input type="submit" value="Log in"></td></tr> loginform3 </table> </form> </td></tr> <tr> <td align=center> <b>If you get this page time and again, your browser does not support cookies.<br>Enable cookies and try again!</b> </td> </tr> </form>