Difference between revisions of "Template:Decliner"
From Jonathan Gardner's Latin Notebook
Line 77: | Line 77: | ||
// Break the word into syllables | // Break the word into syllables | ||
while (word) { | while (word) { | ||
− | if (s = /(?:[bcdfghijklmnpqrstxvyz]+)?[aeiouv]+[bcdfghjklmnpqrstxyz] | + | if (s = /(?:[bcdfghijklmnpqrstxvyz]+)?[aeiouv]+[bcdfghjklmnpqrstxyz]*$/.exec(word)) { |
syllables.unshift(s[0]); | syllables.unshift(s[0]); | ||
word = word.substr(0, word.length-s[0]) | word = word.substr(0, word.length-s[0]) |
Revision as of 15:57, 23 February 2012