summaryrefslogtreecommitdiffabout
authorSergey Poznyakoff <gray@gnu.org.ua>2011-06-15 09:43:43 (GMT)
committer Sergey Poznyakoff <gray@gnu.org.ua>2011-06-15 09:43:43 (GMT)
commit4d7c599a56c6864886b9261cc40769893b6d64e1 (patch) (side-by-side diff)
treea976db22ec4e13ce583220c384ee6bf98e423320
parentbb9dd8a54a96307aad7bf976f1736d20c70d43e3 (diff)
downloadellinika-4d7c599a56c6864886b9261cc40769893b6d64e1.tar.gz
ellinika-4d7c599a56c6864886b9261cc40769893b6d64e1.tar.bz2
Minor change in conj.
* src/cgi-bin/conj.scm4: Use ellinika:translate-kbd * src/ellinika/tests/xlat-kbd.scm: New file.
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--src/cgi-bin/conj.scm46
-rw-r--r--src/ellinika/tests/xlat-kbd.scm5
2 files changed, 8 insertions, 3 deletions
diff --git a/src/cgi-bin/conj.scm4 b/src/cgi-bin/conj.scm4
index b48b225..52b8d32 100644
--- a/src/cgi-bin/conj.scm4
+++ b/src/cgi-bin/conj.scm4
@@ -63,7 +63,7 @@ ifelse(IFACE,[CGI],(cgi:init))
(if value
(begin
(display " value=\"")
- (display (cgi-protect-quotes value))
+ (display (cgi-protect-quotes (ellinika:translate-input value)))
(display "\""))))
(display " />
</td>
@@ -188,8 +188,8 @@ ifelse(IFACE,[CGI],(cgi:init))
(define (do-conj)
(let ((keyval (cgi:value "key")))
- (if keyval
- (show-conjugation keyval))))
+ (if (and keyval (not (string-null? keyval)))
+ (show-conjugation (ellinika:translate-input keyval)))))
(define (conj-html)
(sql-catch-failure
diff --git a/src/ellinika/tests/xlat-kbd.scm b/src/ellinika/tests/xlat-kbd.scm
new file mode 100644
index 0000000..a181248
--- a/dev/null
+++ b/src/ellinika/tests/xlat-kbd.scm
@@ -0,0 +1,5 @@
+(use-modules (ellinika xlat))
+
+(let ((str "mila'v"))
+ (display (ellinika:translate-kbd str))
+ (newline))

Return to:

Send suggestions and report system problems to the System administrator.