* SquirrelMail version number -- DO NOT CHANGE
*/
global $version;
-$version = '1.2.5 [cvs]';
+$version = '1.2.6 [cvs]';
/**
* If $haystack is a full mailbox name and $needle is the mailbox
function translateText(&$body, $wrap_at, $charset) {
global $where, $what; /* from searching */
global $color; /* color theme */
-
+
require_once('../functions/url_parser.php');
-
+
$body_ary = explode("\n", $body);
$PriorQuotes = 0;
for ($i=0; $i < count($body_ary); $i++) {
$Quotes = 0;
$pos = 0;
- $j = strlen( $line );
+ $j = strlen( $line );
while ( $pos < $j ) {
if ($line[$pos] == ' ') {
if (($size < 1) || (strlen($chars) < 1)) {
return '';
}
-
+
sq_mt_randomize(); /* Initialize the random number generator */
-
+
$String = '';
+ $j = strlen( $chars ) - 1;
while (strlen($String) < $size) {
- $String .= $chars[mt_rand(0, strlen($chars))];
+ $String .= $chars{mt_rand(0, $j)};
}
-
+
return $String;
}