Free AD0-E720 Exam Braindumps (page: 6)

Page 5 of 13

An Adobe Commerce developer wants to remove the default Wishlist and Compare Products blocks on a category page with layered navigation Where would this modification be placed, assuming the developer only wants to make this change?

  1. app/design/frontend/Vendor/Theme/Magento_LayeredNavigation/layout/override/catalog_categor y_view_type_layered.xml
  2. app/design/frontend/Vendor/Theme/Magento_Layered.Navigation/layout/catalog_category_view_t ype_layered.xml
  3. app/design/frontend/Vendor/Theme/Magento_Catalog/layout/catalog_category_view.xml

Answer(s): B

Explanation:

To remove the default Wishlist and Compare Products blocks on a category page with layered navigation, the developer should place the modification in the app/design/frontend/Vendor/Theme/Magento_LayeredNavigation/layout/catalog_category_view_t ype_layered.xml file. This file is specific to the category pages with layered navigation and will override the default layout file from the Magento_LayeredNavigation module. The modification should use the <referenceBlock> tag with the name attribute specifying the name of the block and the remove attribute set to true. For example:

<referenceBlock name="catalog.compare.sidebar" remove="true"/> <referenceBlock name="wishlist_sidebar" remove="true"/>

The app/design/frontend/Vendor/Theme/Magento_LayeredNavigation/layout/override/catalog_categor y_view_type_layered.xml file is not valid and will not work, as it is not a valid override path. The app/design/frontend/Vendor/Theme/Magento_Catalog/layout/catalog_category_view.xml file is not specific to the category pages with layered navigation and will affect all category pages.


Reference:

[Layout override], [Remove an element]



An Adobe Commerce developer has created a system configuration field:



Using Layout XML, how can the visibility of a block be controlled by a system configuration?

  1. <block name="block.name" template="Vendor_Module::template.phtml=" ifconfig="vendor/general/enable" />
  2. <block name="block.name" template=''Vendor_Module:
    :template.phtml"ifconfig="module/general/enable" />
  3. <block name="block.name" template="Vendor_Module::template.phtml" ifconfig="general/module/enable" />

Answer(s): A

Explanation:

To control the visibility of a block using a system configuration, the developer should use the ifconfig attribute in the <block> tag. The ifconfig attribute should specify the path to the system configuration field that determines whether the block is visible or not. For example:

<block name="block.name" template="Vendor_Module::template.phtml" ifconfig="vendor/general/enable" />

This will render the block only if the vendor/general/enable system configuration field is set to true. The module/general/enable and general/module/enable paths are not valid and will not work, as they do not match the system configuration field defined in the image.


Reference:

[Layout instructions], [System configuration]



An Adobe Commerce developer has been asked to add text to an email template that supports translations.
Which two options would they use during their implementation? (Choose two.)

  1. {{translations "Lorem Ipsum is simply dummy text of the printing"}}
  2. {{translations "%items items" items="numltems"}}
  3. {{trans "Lorem Ipsum is simply dummy text of the printing"}}
  4. {{trans "%items items" items="numltems"}}

Answer(s): B,D

Explanation:

To add text to an email template that supports translations, the developer should use the {{trans}} directive with the text enclosed in double quotes. For example:

{{trans "Lorem Ipsum is simply dummy text of the printing"}}

This will render the text as it is, or translate it if a translation file is available for the current locale. If the text contains a variable, the developer should use a placeholder with a percent sign and pass the variable name as an argument. For example:

{{trans "%items items" items="numItems"}}

This will render the text with the value of numItems replacing the %items placeholder, or translate it if a translation file is available for the current locale. The {{translations}} directive is not valid and will not work.


Reference:

[Translate email templates], [Email template syntax]



An Adobe Commerce developer wants to completely overwrite _module. less of Orange_Checkout module, in their theme.
Where would the developer place the file?

  1. Custom/theme/Orange_Checkout/frontend/web/css/_module.less
  2. Custom/theme/web/css/source/Orange_Checkout/_module.less
  3. Custom/theme/Orange_Checkout/web/css/source/_module.less

Answer(s): C

Explanation:

To completely overwrite _module.less of Orange_Checkout module in a custom theme, the developer should place the file in the Custom/theme/Orange_Checkout/web/css/source directory. This will override the default _module.less file from the Orange_Checkout module and apply the custom styles to the theme. The Custom/theme/Orange_Checkout/frontend/web/css/_module.less and Custom/theme/web/css/source/Orange_Checkout/_module.less paths are not valid and will not work, as they do not follow the theme structure or the module naming convention.


Reference:

[Theme structure], [Module naming convention]






Post your Comments and Discuss Adobe AD0-E720 exam with other Community members:

AD0-E720 Exam Discussions & Posts