Changeset 1681 in ExiteCMS for trunk/includes/core_functions.php


Ignore:
Timestamp:
08/22/08 20:30:31 (4 years ago)
Author:
hverton
Message:

fixed not counting quote and code blocks when not in lower case

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/includes/core_functions.php

    r1660 r1681  
    695695    // quote     & code blocks 
    696696    $text = preg_replace('#\[quote=([\r\n]*)(.*?)\]#si', '<b>\2 '.$locale['199'].':</b><br />[quote]', $text); 
    697     $qcount = substr_count($text, "[quote]"); $ccount = substr_count($text, "[code]"); 
     697    $qcount = substr_count(strtolower($text), "[quote]"); $ccount = substr_count(strtolower($text), "[code]"); 
    698698    for ($i=0;$i < $qcount;$i++) $text = preg_replace('#\[quote\](.*?)\[/quote\]#si', '<div class=\'quote\'>\1</div>', $text); 
    699699    for ($i=0;$i < $ccount;$i++) $text = preg_replace('#\[code\](.*?)\[/code\]#si', '<b>code:</b><div class=\'codeblock\'>\1</div>', $text); 
Note: See TracChangeset for help on using the changeset viewer.