CaseUnSensitive in viewtopic

Forum_Lexicon_Desc

CaseUnSensitive in viewtopic

Beitragvon wicher » 5. Apr 2006 14:49

Hello AmigaLink,

Here i am again...

As you know i could not get case unsensitive working.
Now i did as follows:
I changed in viewtopic.php:
Code: Alles auswählen
      $quicklink_keyword[] = '#\b(' . $row['keyword'] . ')\s#';
      $quicklink_lex_url[] = '<a href="lexicon.'.$phpEx.'?letter=' . $row['keyword'] . '" class="crosslink" alt="'.$lang['to_Lexicon'].'" title="'.$lang['to_Lexicon'].'">' . $row['keyword'] . '</a> ';
      $quicklink_keyword[] = '#\s(' . $row['keyword'] . ')\b#';
      $quicklink_lex_url[] = ' <a href="lexicon.'.$phpEx.'?letter=' . $row['keyword'] . '" class="crosslink" alt="'.$lang['to_Lexicon'].'" title="'.$lang['to_Lexicon'].'">' . $row['keyword'] . '</a>';

INTO:
Code: Alles auswählen
      $quicklink_keyword[] = '#\b(' . $row['keyword'] . ')\s#i';
      $quicklink_lex_url[] = '<a href="lexicon.'.$phpEx.'?letter=' . $row['keyword'] . '" class="crosslink" alt="'.$lang['to_Lexicon'].'" title="'.$lang['to_Lexicon'].'">' . $row['keyword'] . '</a> ';
      $quicklink_keyword[] = '#\s(' . $row['keyword'] . ')\b#i';
      $quicklink_lex_url[] = ' <a href="lexicon.'.$phpEx.'?letter=' . $row['keyword'] . '" class="crosslink" alt="'.$lang['to_Lexicon'].'" title="'.$lang['to_Lexicon'].'">' . $row['keyword'] . '</a>';


Now all words, regardless if the have uppercase or lowercase letters in them will be linked.
But now following problem (for me that is):
All words in viewtopic are now replaced with the word that is in the lexicon.
So when someone puts a word somewhere in there post that begins with a uppercase letter and in the lexicon it is put in in lowercase, it will be replaced by the lexiconword $row['keyword'].
Is there a way to not replace the word but still be linked?
Benutzeravatar
wicher
User
 
Beiträge: 32
Registriert: 9. Feb 2006 01:11
Wohnort: Netherlands

Beitragvon AmigaLink » 5. Apr 2006 15:55

Hmmm Bild

If one can change that at all, then only with backreferences. And that is much spends. :?
Die deutsche Sprache ist Freeware, du kannst sie benutzen, ohne dafür zu bezahlen. Sie ist aber nicht Open Source, also darfst du sie nicht verändern, wie es dir gerade passt.
Benutzeravatar
AmigaLink
Administrator
 
Beiträge: 3987
Registriert: 11. Aug 2004 01:06
Wohnort: NRW

Beitragvon wicher » 6. Apr 2006 01:43

Then i will leave it as it is now, thanks for answering.
Benutzeravatar
wicher
User
 
Beiträge: 32
Registriert: 9. Feb 2006 01:11
Wohnort: Netherlands


Zurück zu Lexicon v2



Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 10 Gäste

cron