X-Git-Url: http://git.annexia.org/?a=blobdiff_plain;f=scripts%2Fedit_host_settings_form.ml;h=ce92f531f3b8d776f21a800c3c3c864bca5dd068;hb=b9bed1282a309aaf3227ec93ccdeacce8cbb89b2;hp=ed27bb0835eb0bdedc9d93683d8a9ed2a5bb5a21;hpb=50f72e5597bef62747f462d26cae836c7c9ee6b9;p=cocanwiki.git diff --git a/scripts/edit_host_settings_form.ml b/scripts/edit_host_settings_form.ml index ed27bb0..ce92f53 100644 --- a/scripts/edit_host_settings_form.ml +++ b/scripts/edit_host_settings_form.ml @@ -1,7 +1,7 @@ (* COCANWIKI - a wiki written in Objective CAML. * Written by Richard W.M. Jones . * Copyright (C) 2004 Merjis Ltd. - * $Id: edit_host_settings_form.ml,v 1.2 2004/09/24 16:30:07 rich Exp $ + * $Id: edit_host_settings_form.ml,v 1.3 2004/09/27 16:21:09 rich Exp $ * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -44,24 +44,24 @@ let run r (q : cgi) (dbh : Dbi.connection) hostid _ _ = let sth = dbh#prepare_cached "select canonical_hostname, edit_anon, create_account_anon, theme_css, - feedback_email, mailing_list + feedback_email, mailing_list, search_box from hosts where id = ?" in sth#execute [`Int hostid]; let canonical_hostname, edit_anon, create_account_anon, theme_css, - feedback_email, mailing_list = + feedback_email, mailing_list, search_box = match sth#fetch1 () with [ `String canonical_hostname; `Bool edit_anon; `Bool create_account_anon; (`String _ | `Null) as theme_css; (`String _ | `Null) as feedback_email; - `Bool mailing_list ] -> + `Bool mailing_list; `Bool search_box ] -> let theme_css = match theme_css with `String s -> s | `Null -> "" in let feedback_email = match feedback_email with `String s -> s | `Null -> "" in canonical_hostname, edit_anon, create_account_anon, theme_css, - feedback_email, mailing_list + feedback_email, mailing_list, search_box | _ -> assert false in template#set "canonical_hostname" canonical_hostname; @@ -69,6 +69,7 @@ let run r (q : cgi) (dbh : Dbi.connection) hostid _ _ = template#conditional "create_account_anon" create_account_anon; template#set "feedback_email" feedback_email; template#conditional "mailing_list" mailing_list; + template#conditional "search_box" search_box; (* Themes table. *) let table =