Help for integrating the Laravel package
Forum rules: Always add your Laravel, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
#3213 by brunojti
19 Aug 2016, 11:37

In the docs you say
Extensions that depend on the core and contain PHP template files in the client/html/templates/ directory named the same as existing ones are used first. Only if no extension contain a appropriate PHP template, the default one from the core is used.

Well, in the ./ext folder, I see that you have by default ai-client-html extension. I am trying to create a new extension but creating a file with same path won't overwrite the html structure.
I've created a file located at
Code: Select all./ext/my-ext/client/html/templates/commom/summary/detail-body-default.php

Is there any place where I am supposed to "register" which extension should be loaded?
#3221 by aimeos
19 Aug 2016, 19:54
No, you don't have to register new extensions in the ./ext/ directory.
I've created a new extension, added the same template in the ./client/html/templates/common/summery/ directory, modified that template and it worked out of the box.

Did you clear the cache (artisan aimeos:cache) or configured your Aimeos installation to use no content cache?
#3256 by aimeos
22 Aug 2016, 17:48
The full path relative to the Laravel base directory would be
Code: Select all./ext/my-ext/client/html/templates/common/summary/detail-body-default.php

The "summery" was a misspelling of mine because I didn't copy the path but wrote it from my mind.

Yes, the ai-client-html extension is always installed. Otherwise, the templates won't be used anyway.

Can you please check if the manifest.php file of your extension contains this section:
Code: Select all'custom' => array(
   // ...
   'client/html/templates' => array(
   // ...

My guess is that you've created the wrong extension version for your Aimeos version (2015.x instead of 2016.x).
#3259 by brunojti
23 Aug 2016, 01:50
How can I check the extension version? and how can I be sure that I am downloading the latest version?
btw, do you know any repository that contains a store that used aimeos? This would a huge game changer for me now!

#3261 by aimeos
23 Aug 2016, 15:56
Create a new extension ( and make sure the chosen version is "Aimeos 2016.x extension". Copy the modified template to the same location and try again.

Also make sure that you've cleared the Aimeos content cache (./artisan aimeos:cache) or configured to use no cache (

We don't know any public implementation besides the Aimeos demo you get when installing the Aimeos Laravel package like described in the docs.
#3264 by brunojti
24 Aug 2016, 14:53
I need to add some custom JS to payment step on checkout process.

I tried to:

Code: Select all<?php $this->block()->start('checkout/standard/payment'); ?>
<script type="text/javascript">
    var sender_hash = '';
    window.onload = function () {
        console.log("Setting session ID to: <?php echo $session_id; ?>");
        PagSeguroDirectPayment.setSessionId("<?php echo $session_id; ?>");
        console.log("Getting hash");
        sender_hash = PagSeguroDirectPayment.getSenderHash();
<?php $this->block()->stop(); ?>

But the `sender_hash` variable is set to undefined. When I run the same command via chrome's console I get the valid response.

I need to add this code "later" to make it work, I just don't know how to do it. Can you help me?
#3266 by aimeos
25 Aug 2016, 10:41
The first thing is to add your JS code to the payment-header-default.php file and not to the HTML body. Then you should check what getSenderHash() does so you know what must be available in the URL/environment/etc.