(* COCANWIKI - a wiki written in Objective CAML.
* Written by Richard W.M. Jones <rich@merjis.com>.
* Copyright (C) 2004 Merjis Ltd.
- * $Id: wikilib.ml,v 1.6 2004/09/17 15:09:48 rich Exp $
+ * $Id: wikilib.ml,v 1.7 2004/09/25 16:05:03 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
let generate_url_of_title (dbh : Dbi.connection) hostid title =
(* Create a suitable URL from this title. *)
- let url = String.map (function '\000' .. ' ' | '<' | '>' | '&' | '"' -> '_'
- | c -> Char.lowercase c) title in
+ let url =
+ String.map (function '\000' .. ' ' | '<' | '>' | '&' | '"' | '+' -> '_'
+ | c -> Char.lowercase c) title in
(* Check URL is not too trivial. *)
if not (Pcre.pmatch ~rex:nontrivial_re url) then