From 5144814ad03c29955974902f8e28d73455bb904c Mon Sep 17 00:00:00 2001 From: Jens Maus Date: Tue, 14 Jul 2020 09:28:55 +0200 Subject: [PATCH] version bump to 1.12 to catch latest changes from upstream. --- README.md | 66 ++++++++++++++++++++++++++------------------------ carddav2fb.php | 4 +-- 2 files changed, 36 insertions(+), 34 deletions(-) diff --git a/README.md b/README.md index b7521121..3ae80a2a 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,10 @@ Features: **CAUTION: This script will overwrite your current contacts in the FritzBox without any warning!** +## Information + +This version of carddav2fb is a forked version from carlos22 (https://github.com/carlos22/carddav2fb) and adding support for convenient image upload, different FRITZ!Box base paths (for example for FRITZ!Box 7490 (UI) OS: 6.50) and full name design support. + ## Requirements * PHP-version 5.3.6 or higher @@ -21,10 +25,10 @@ Features: ## Installation -Checkout the carddav2fb sources including its related subprojects using the following command: + Checkout the carddav2fb sources including its related subprojects using the following command: ``` -git clone https://github.com/carlos22/carddav2fb.git +git clone https://github.com/jens-maus/carddav2fb.git ``` Now you should have everything setup and checked out to a 'carddav2fb' directory. @@ -56,36 +60,34 @@ Now you should have everything setup and checked out to a 'carddav2fb' directory ## config.php Example (owncloud) -```php -$config['fritzbox_ip'] = 'fritz.box'; -$config['fritzbox_user'] = ''; -$config['fritzbox_pw'] = ''; -$config['phonebook_number'] = '0'; -$config['phonebook_name'] = 'Telefonbuch'; -$config['fritzbox_path'] = 'file:///var/media/ftp/'; - -// full name format options default 0 -// parts in '' will only added if existing and switched to true in config -// 0 = 'Prefix' Lastname, Firstname, 'Additional Names', 'Suffix', 'orgname' -// 1 = 'Prefix' Firstname Lastname 'AdditionalNames' 'Suffix' '(orgname)' -// 2 = 'Prefix' Firstname 'AdditionalNames' Lastname 'Suffix' '(orgname)' -$config['fullname_format'] = 0; - -// fullname parts -$config['prefix'] = false; // include prefix in fullname if existing -$config['suffix'] = false; // include suffix in fullname if existing -$config['addnames'] = false; // include additionalnames in fullname if existing -$config['orgname'] = false; // include organisation (company) in fullname if existing + $config['fritzbox_ip'] = 'fritz.box'; + $config['fritzbox_user'] = ''; + $config['fritzbox_pw'] = ''; + $config['phonebook_number'] = '0'; + $config['phonebook_name'] = 'Telefonbuch'; + $config['fritzbox_path'] = 'file:///var/media/ftp/'; + + // full name format options default 0 + // parts in '' will only added if existing and switched to true in config + // 0 = 'Prefix' Lastname, Firstname, 'Additional Names', 'Suffix', 'orgname' + // 1 = 'Prefix' Firstname Lastname 'AdditionalNames' 'Suffix' '(orgname)' + // 2 = 'Prefix' Firstname 'AdditionalNames' Lastname 'Suffix' '(orgname)' + $config['fullname_format'] = 0; + + // fullname parts + $config['prefix'] = false; // include prefix in fullname if existing + $config['suffix'] = false; // include suffix in fullname if existing + $config['addnames'] = false; // include additionalnames in fullname if existing + $config['orgname'] = false; // include organisation (company) in fullname if existing -$config['quickdial_keyword'] = 'Quickdial:'; // once activated you may add 'Quickdial:+49030123456:**709' to the contact note field and the number will be set as quickdialnumber in your FRITZ!Box. It is possible to add more quickdials for one contact each in a new line - -// first -$config['carddav'][0] = array( - 'url' => 'https:///remote.php/carddav/addressbooks//contacts', - 'user' => '', - 'pw' => '' -); -``` + $config['quickdial_keyword'] = 'Quickdial:'; // once activated you may add 'Quickdial:+49030123456:**709' to the contact note field and the number will be set as quickdialnumber in your FRITZ!Box. It is possible to add more quickdials for one contact each in a new line + + // first + $config['carddav'][0] = array( + 'url' => 'https:///remote.php/carddav/addressbooks//contacts', + 'user' => '', + 'pw' => '' + ); ## Note This script is using third-party libraries for downloading VCards from CardDAV servers based on the following packages @@ -97,4 +99,4 @@ This script is using third-party libraries for downloading VCards from CardDAV s This script is released under Public Domain. ## Authors -Copyright (c) 2012-2016 Karl Glatz, Martin Rost, Jens Maus, Johannes Freiburger +Copyright (c) 2012-2020 Karl Glatz, Martin Rost, Jens Maus, Johannes Freiburger diff --git a/carddav2fb.php b/carddav2fb.php index 6ac06332..c4335eeb 100755 --- a/carddav2fb.php +++ b/carddav2fb.php @@ -23,7 +23,7 @@ setlocale(LC_ALL, 'de_DE.UTF8'); // Version identifier for CardDAV2FB -$carddav2fb_version = '1.11 (2016-05-12)'; +$carddav2fb_version = '1.12 (2020-07-14)'; // check for the minimum php version $php_min_version = '5.3.6'; @@ -70,7 +70,7 @@ // --------------------------------------------- // MAIN print "carddav2fb.php " . $carddav2fb_version . " - CardDAV to FRITZ!Box phonebook conversion tool" . PHP_EOL; -print "Copyright (c) 2012-2016 Karl Glatz, Martin Rost, Jens Maus, Johannes Freiburger" . PHP_EOL . PHP_EOL; +print "Copyright (c) 2012-2020 Karl Glatz, Martin Rost, Jens Maus, Johannes Freiburger" . PHP_EOL . PHP_EOL; $client = new CardDAV2FB($config);