SOLVED XML Phonebook

Discussion in 'General' started by Caleb, Oct 12, 2017 at 7:29 PM.

  1. Caleb

    Caleb New Member

    We've decided to include the XML phonebook in our provisioning of our GXP2130 and 60 phones. FusionPBX doesn't come with the files to support that, so here's a basic one we made. Create a file called "phonebook.xml" in each grandstream provisioning profile folder of the profiles you use, and insert the contents below. One could modify this even more so it takes advantage of the <accountindex> tag and assign contacts to the respective extension when multiple extensions are configured on the phone.

    <?xml version="1.0" encoding="UTF-8"?>
    <AddressBook>
    {foreach $contacts as $contact}

    <Contact>
    <LastName>{$contact.contact_name_family}</LastName>
    <FirstName>{$contact.contact_name_given}</FirstName>

    <Phone>
    <phonenumber>{$contact.phone_extension}</phonenumber>
    <accountindex>1</accountindex>
    </Phone>
    </Contact>
    {/foreach}
    </AddressBook>
     

Share This Page