diff options
| author | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2011-08-03 10:40:29 +0000 |
|---|---|---|
| committer | alec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c> | 2011-08-03 10:40:29 +0000 |
| commit | 986843fc60b3e4afa39712d257e37cb804dfd59d (patch) | |
| tree | cc9cb0dc06ce851e1230572fd9b2d1586a8c2437 /roundcubemail/program/include | |
| parent | eaefb4114abb8d0b0fc9044952d4bb410714a451 (diff) | |
- Fix EOL character in vCard exports (#1487873)
git-svn-id: https://svn.roundcube.net/trunk@5012 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/include')
| -rw-r--r-- | roundcubemail/program/include/rcube_vcard.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/roundcubemail/program/include/rcube_vcard.php b/roundcubemail/program/include/rcube_vcard.php index 90ee7da66..c7dfe537b 100644 --- a/roundcubemail/program/include/rcube_vcard.php +++ b/roundcubemail/program/include/rcube_vcard.php @@ -33,7 +33,7 @@ class rcube_vcard 'FN' => array(), 'N' => array(array('','','','','')), ); - static private $fieldmap = array( + private static $fieldmap = array( 'phone' => 'TEL', 'birthday' => 'BDAY', 'website' => 'URL', @@ -65,6 +65,7 @@ class rcube_vcard public $notes; public $email = array(); + public static $eol = "\r\n"; /** * Constructor @@ -640,11 +641,11 @@ class rcube_vcard if (self::is_empty($value)) continue; - $vcard .= self::vcard_quote($type) . $attr . ':' . self::vcard_quote($value) . "\n"; + $vcard .= self::vcard_quote($type) . $attr . ':' . self::vcard_quote($value) . self::$eol; } } - return "BEGIN:VCARD\nVERSION:3.0\n{$vcard}END:VCARD"; + return 'BEGIN:VCARD' . self::$eol . 'VERSION:3.0' . self::$eol . $vcard . 'END:VCARD'; } |
