Using variable as substr_replace characters

From: Laiverd.COM (share_your_knowledge_at_someserver.com)
Date: 07/29/04


Date: Thu, 29 Jul 2004 16:33:45 +0200

Why would:

$stringPadding = ' ...';

not be used in

return substr_replace($string, $stringPadding, $maxLength - 3 ,
strlen($string));

which is part of a function to chop strings that are too long? If I use:

return substr_replace($string, " ...", $maxLength - 3 , strlen($string));

it works perfectly well. PHP 4.2.3.

Thanks for any input.

John

-- 
----------------------------------------------------------------------------
-----------
RESOURCES
http://groups.google.com/advanced_group_search?hl=en&as_ugroup=*flash
----------------------------------------------------------------------------
-----------
TUTORIALS at
www.laiverd.com
Flash & PHP Emailform
Using textfiles in Flash
----------------------------------------------------------------------------
-----------


Relevant Pages