So I want to add some text under "Additional address entries":

enter image description here

I tried overriding \magento\module-customer\view\frontend\templates\address\book.phtml in my custom theme \Magento_Customer\templates\address\book.phtml like this:

<div class="block block-addresses-list">
<div class="block-title"><strong><?php echo $block->escapeHtml(__('Additional Address Entries')) ?></strong></div>
<div class="block-content">
    <?php if ($_pAddsses = $block->getAdditionalAddresses()): ?>
        <ol class="items addresses">
            <?php foreach ($_pAddsses as $_address): ?>
                <li class="item">
                        <?php echo $block->getAddressHtml($_address) ?><br />
                    <div class="item actions">
                        <a class="action edit" href="<?php echo $block->escapeUrl($block->getUrl('customer/address/edit', ['id' => $_address->getId()])) ?>"><span><?php echo $block->escapeHtml(__('Edit Address')) ?></span></a>
                        <a class="action delete" href="#" role="delete-address" data-address="<?php echo $this->helper(\Magento\Framework\EscapeHelper::class)->escapeHtmlAttr($_address->getId()) ?>"><span><?php echo $block->escapeHtml(__('Delete Address')) ?></span></a>
            <?php endforeach; ?>
    <?php else: ?>
        <p class="empty"><?php echo $block->escapeHtml(__('You have no other address entries in your address book.')) ?></p>
    <?php endif ?>
<!-- My added code -->
    <p class="empty"><?php echo $block->escapeHtml(__('You must get in contact with your representative in order to do any modification to your personal details.')) ?></p>

It doesn't appear to have any changes, but not only what I have changed but also if I try to put some die('text') in order to make sure I'm working in the right place.

Of course I run the commands:

php bin/magento cache:flush
php bin/magento setup:upgrade
  • Make sure file path is fine or not. According to the mentioned path everything looks ok. Can you write the full path of book.phtml in your theme? Jul 11, 2018 at 7:23
  • As far as I understand the custom_theme folders are like "smart enough" to find the path missing. I have lots of other modifications that are like that and work perfectly. I really don't know what I have missing.
    – Raül
    Jul 11, 2018 at 8:03
  • Did you try to modify the same in vendor? Just for testing purpose. Jul 11, 2018 at 8:04

1 Answer 1


I found out what happened, it appears we had a extension called CustomerCrm that overrides the theme:


In the end I had to modify the CustomerCrm Extension, the same file and just put the same change in the design.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.