Support #47
closedremove all spaces phone number LDAP
100%
Description
I have à VCAR "+33 6 87 49 53 88"
whit default config
country = "FR"
int = 33 # Your international dial code. 1 = US, 49 = Germany, ...
area = 80 # Your local area code (without a leading 0)
areaPrefix = "0" # Dial prefix for national calls (has to be written as "string")
maxarealength = 7
I have "06 87 49 52 88"
But I want "0687495288"
which variable should I add in the config file?
Regards
Files
Updated by Jörg Ebeling over 3 years ago
- Tracker changed from Bug to Support
Hi Sébastien.
Thanks a lot asking for support.
Unfortunately it isn't supported at the moment. But please read on...
The phone numbers get formatted currently by a powerful Google phone number library.
So, the resulting "06 87 49 52 88" phone number, from your "+33 6 87 49 53 88" VCard input, is the "pretty" version of what Google's library means how a French number get commonly displayed.
I just googled a little bit about the French telephone number plan, and it look okay for me.
You can disable this "pretty" number formatting within L2CPBG with config option:
[location]
prettifyNums = false
but then you'll receive it in the same format as it was in your VCard number "+33 6 87 49 53 88".
Could you please explain what's the reason why you want it without the spaces?
May be I find an easy implementable option within the library for your support request.
Updated by Sébastien COURATIN over 3 years ago
Thank you for your answer !
I have a limited asterisk operator that does not support space in phonenumbers.
For now I have modified my carddav code to remove spaces before they are sycronized on L2CPBG.
It works but I would prefer it to be handled by L2CPBG.
Regards,
Updated by Jörg Ebeling over 3 years ago
- Status changed from New to In Progress
- % Done changed from 0 to 10
- Estimated time set to 2:00 h
Will implement a
[location]
prettifyRemoveSpaces = true|false
config option
Updated by Jörg Ebeling over 3 years ago
- File l2cpbg_0.9.3beta6_amd64.deb l2cpbg_0.9.3beta6_amd64.deb added
- Status changed from In Progress to Feedback
- % Done changed from 10 to 100
Hi Sébastien!
Within the attached 0.9.3beta6 there's a new config option
[location]
prettifyRemoveSpaces = false|true
It is false (off) by default, so you need to add
[location]
prettifyRemoveSpaces = true
to your config.
As I'm not aware of your special use case, there's another #48 config option location.prettifyNoAreaInSameArea
which is true (on) by default. This will skip dialing the local area code if you're in the same local area. You probably need to disable it if you don't like it.
Lastly, when reading https://en.wikipedia.org/wiki/Telephone_numbers_in_France, I've the opinion that your location.area
should be 8 instead of 80!!
Your resulting location settings should look like this:
[location]
country = "FR"
int = 33 # Your international dial code. 1 = US, 49 = Germany, ...
area = 8 # Your local area code (without a leading 0)
areaPrefix = "0" # Dial prefix for national calls (has to be written as "string")
prettifyRemoveSpaces = true
maxarealength = 7
Looking forward to your response/result.
Updated by Jörg Ebeling over 3 years ago
Hi Sébastien!
or did you forgot to adapt the area code in your location settings?
Because, when checking your mails signature, then your're in area = 1