public static function base64Encode($str, $stripEgal = true)
    {
        $str64 = base64_encode($str);
        if ($stripEgal) {
            return rtrim(strtr($str64, '+/', '-_'), '=');
        }
        
        return $str64;
    }
public static function base64Encode($str, $stripEgal = true)
    {
        $str64 = base64_encode($str);
        if ($stripEgal) {
            return rtrim(strtr($str64, '+/', '-_'), '=');
        }
        
        return $str64;
    }
public static function base64Encode ( $ str , $ stripEgal = true ) { $ str64 = base64_encode ( $ str ) ; if ( $ stripEgal ) { return rtrim ( strtr ( $ str64 , '+/' , '-_' ) , '=' ) ; } return $ str64 ; }
base64_decode sans les == de fin

@param      $str
@param bool $stripEgal

@return string
base64_decode sans les == de fin