Menu

Smiles and other staff

Hilfe/Help
Anonymous
2002-04-17
2002-04-17
  • Anonymous

    Anonymous - 2002-04-17

    Hello

    I've noticed that filter_inc.php replaces any expression only once. This fails to work when there are several smilies or :me/:you expressions.

     
    • Anonymous

      Anonymous - 2002-04-17

      Just for the case anyone interested...
      in filter_inc.php:

      replace the smiles cycle with this one...

          do {
            $pattern=current($smiley);
            $replacement=current($smileyfile);

            $chat=preg_replace("/".preg_quote($pattern,"/")."/",$smileyopen.$replacement.$smileyclose,$chat);

            next($smileyfile);
          } while (next($smiley));

       
    • Anonymous

      Anonymous - 2002-04-17

      Again if anyone interested...

      The line right before "return $chat;" will allow to enter new lines into message...

        $chat = preg_replace("/\s+\*n/","<br/>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ",$chat);

      The usage, I think, is obvious...

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.