Closed (fixed)
Project:
Glossary
Version:
5.x-2.2
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
1 Apr 2008 at 16:31 UTC
Updated:
16 Oct 2008 at 20:54 UTC
Jump to comment: Most recent file
It seems that v2.2 doesn't recognize words containing ā, ś, ū, ñ, ... There might be some more. I have php mbstring installed. It was working ok in version 1.7 - all terms were correctly tagged.
| Comment | File | Size | Author |
|---|---|---|---|
| #10 | glossary1.png | 34.32 KB | martig |
| #10 | glossary2.png | 20.02 KB | martig |
| #10 | glossary3.png | 31.84 KB | martig |
Comments
Comment #1
nancydruI'm not sure what you mean "doesn't recognize." I have a vocabulary with a term that starts with é and another with ñ and they show up fine - although to be in correct order, one must set the alphabet on the "Alphabet" settings tab. It may also require you to adjust the collation on the term_data table, as was reported some time ago, and is (partially) documented in http://drupal.org/node/201763.
Comment #2
nancydruComment #3
martig commentedThe terms are displayed fine in the vocabulary, but they are not linked from the nodes.
Comment #4
nancydruOne more question: Do these characters begin the term, or just somewhere else in them? ("école" as opposed to plissé)
It's kind of strange, because the 1.7 version was before most of the language support was added.
Comment #5
nancydruI just set up a test node, with "In order to test foreign language support, I have the words école, plissé, and ñachi in my glossary." and all the terms are flagged as they should be.
Comment #6
martig commentedHmm, it seems the problem is not at all like it seemed at first.
Only some of the terms are linked to their description and it seems to quite random (no relation to foregin characters).
Here's an example - http://teosoofia.ee/nikola_tesla_1853_1943/vedaanta_filosoofia_moju_niko... <-- There are quite many terms but at the moment I'm not seeing any of those tagged (I use the acronym tag).
I also found these errors in the log, always in pair:
I haven't managed to reproduce these under my own user account. They occur a few times a day and only for the quests.
Comment #7
nancydruWell, let's deal with that last part first: http://drupal.org/node/239880 is fixed in the -dev version. Then there's also: http://drupal.org/node/233752#comment-793342
After midnight (GMT) tonight, download the -dev version, verify that you have acronym links styled visibly, save the settings again (even if no changes), and retry it.
Comment #8
martig commentedI installed the dev version, but it's still not tagging all the terms. Only some get tagged.
Comment #9
nancydruWell, it's progress I guess. Can you see any kind of pattern to this? Can you tell me all your settings, please.
Comment #10
martig commentedNo, there doesn't seem to be a recognizable pattern. I took screenshots of the glossary settings. Link style is acronym.
PHP version is 4.4.8, MySQL is 4.1.7. And I haven't installed any new modules since upgrading from glossary 1.7.
Comment #11
nancydruWow, that is the oldest MySql I have ever seen! BTW, are you aware that 7.x will require PHP 5.2+ (probably at least 5.2.5) and MySql 5+. Time to pressure your host to upgrade.
I'll see if there's anything that stands out.
Comment #12
nancydruWell, one thing I see that has confused some people. You have "only first match" which means only the first occurrence in a node is flagged.
Another issue is discussing the problem of non-English characters. For example, "école" does not match "école" or "école".
Comment #13
martig commentedYes, I want only the first match to be displayed.
Just an example: http://teosoofia.ee/nikola_tesla_1853_1943/vedaanta_filosoofia_moju_niko... <-- the word Ākāśa is not tagged, and so aren't many other terms.
Comment #14
nancydruIs the term (in the vocabulary) entered in exactly the same way that the word is typed in the content?
Comment #15
martig commentedYes, the terms are entered exactly. I tried copy-pasting some of the terms, but it didn't change anything.
I also tried creating a new node with the content copied from the node I brought as an example, and guess what - all the terms were tagged in the newly created node. That's really strange.
Comment #16
nancydruThat sounds like a caching issue. Make sure you've cleared the cache_filter table.
Comment #17
martig commentedHmm, before I tried just copying the text to a new node, but now I copied the html and the result is same as in the old node. I took a peek at the module's code and found that for example the
<pre>tag is blocked. Maybe this should also be made configurable.Comment #18
nancydruProbably just documented better, because there are things like <pre> and <code> where the module should not be operating.
Comment #19
mwrochna commentedmartig - were
<pre>tags the only problem?There's no reason to keep them hardcoded - someone may use them in another way (like here, it's not code-escaping, it's changing to a monospaced font) or just not use them to make the filter faster. Also we won't have to document it when it's there - just add an update and remove pre and code from $open_tags and $close_tags (lines 404-405).
(The data's serialized, so we can't just make an UPDATE query). We need '
<a' because there's the space, we can document it with[code]right where[no-glossary]is mentioned.Comment #20
nancydruThank you , Marcin.
For those who don't know him, Marcin (mwrochna) is the person who did a significant rewrite on this module (for the GHOP season) that gives it the capability to skip parts of the content.
I will look at how to better document this.
Comment #21
nancydruComment #22
nancydruChanging status so I'm reminded to fix it.
Comment #23
nancydruI just committed a fix to the form description and filter tips to mention these hard-coded tags.
I'm still thinking about moving those tags to the exposed list of blocking tags. Certainly it's easy enough, but I don't want to break the installation for those who are already using this module. So, I need comments, people.
Comment #24
mwrochna commentedI'm not sure I understand. It won't break anything if they run the update (and a red warning will remind them to). Setting
$value = "code pre $value";only adds those tags, nothing gets lost and the behaviour is exactly the same.Just add glossary_update_5103() from #19 to glossary.install, change to
$open_tags = array('[no-glossary]', '<', '<a ', '[code');, $close_tags accordingly, and change defaults in variable_get()s from 'abbr acronym' to 'code pre abbr acronym'... or did I forget something?Comment #25
nancydruYou might be surprised how many people don't run update.php when updating modules. But you are right that the impact should be close to non-existent, but I would really like more eyes on this.
Comment #26
AaronCollier commentedI think this sounds like it could be useful and people could at least have the option. Honestly, if people don't run update every time, then they should expect to have problems. It is written there to remind them.
So +1 from me.
Comment #27
nancydruComment #28
nancydruCommitted to both branches.
Comment #29
Anonymous (not verified) commentedAutomatically closed -- issue fixed for two weeks with no activity.