Can I include a template into the xml for designing a specific static block? This would enable a non technical user to create a static block in the admin, without having to add a into the html part of the admin/cms editor? So in the template there would just be the html markup for the part ? Is that possible?
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
<referenceContainer name="content">
<block name="cms.block1" before="-" class="Magento\Cms\Block\Block" cacheable="true">
<arguments>
<argument name="block_id" xsi:type="string">cms_block_1</argument>
</arguments>
</block>
<block name="cms.block2" after="cms.block1" class="Magento\Cms\Block\Block" cacheable="true">
<arguments>
<argument name="block_id" xsi:type="string">cms_block_2</argument>
</arguments>
</block>
</referenceContainer>
</body>
</page>
This is my xml which handles the static blocks on the homepage. Now I added the manually into the static blocks.
So how to call a .phtml file? And how would that file look like?
Can I just have:
<div class=""></div> in that file or
do i need something like: <div class="">cms_block_1</div> ?