From 8acfe0e85a149f357b867c3f487e2270e234f1dd Mon Sep 17 00:00:00 2001 From: fyr77 Date: Mon, 7 Dec 2020 10:59:27 +0100 Subject: [PATCH] make hohoho implementation closer to original vision --- index.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.html b/index.html index aefc793..267f1e2 100644 --- a/index.html +++ b/index.html @@ -94,7 +94,7 @@ hocode = hocode.replace(/\-/g, "Hoho"); hocode = hocode.replace(/\>/g, "HoHo"); hocode = hocode.replace(/\./g, "hoho"); - hocode = hocode.replace(/(\w{4})/g, '$1! ').replace(/(^\s+|\s+$)/,''); //Space after each set of 4 characters + hocode = hocode.replace(/(H[oOh]*)/g, '$1! ').replace(/(^\s+|\s+$)/,''); //Group into Hohoho groups startinh with capital letter } else { var hocode = bfcode.replace(/\+/g, "HoHoHo"); @@ -105,7 +105,7 @@ hocode = hocode.replace(/\]/g, "hohoHo"); hocode = hocode.replace(/\./g, "hoHoho"); hocode = hocode.replace(/\,/g, "HohoHo"); - hocode = hocode.replace(/(\w{6})/g, '$1! ').replace(/(^\s+|\s+$)/,''); //Space after each set of 6 characters + hocode = hocode.replace(/(H[oOh]*)/g, '$1! ').replace(/(^\s+|\s+$)/,''); //Group into Hohoho groups startinh with capital letter } hofield.value = hocode; }