Skip to content

magento man

Inserting button in mini cart which is loaded by a javascript code

I need to add button in mini cart just below the “Proceed to checkout” button. And the button is loaded using this javascript code: let sourceUrl = “{some_url/index.js}”; let scriptEle = document.createElement(“script”); scriptEle.setAttribute(“src”, sourceUrl); scriptEle.setAttribute(“type”, “module”); document.head.append(scriptEle); const buttonHolder =… Read More »Inserting button in mini cart which is loaded by a javascript code

Get selected values from Grid which is created by insertListing /button component inside a modal component to display on parent

I have add this button to display a grid inside a custom UI form, but cannot able to get in Controller Data of which is selected from the grid <button name=”insert_listing_example_modal_button” component=”Magento_Ui/js/form/components/button”> <argument name=”data” xsi:type=”array”> <item name=”config” xsi:type=”array”> <item name=”buttonClasses”… Read More »Get selected values from Grid which is created by insertListing /button component inside a modal component to display on parent

Magento 2 How to get td value using script and assign that value to php variable in same phml file?

I have php variable called itemId in same phtml file and i got td value using js. now i need to assign that var id value to $itemId variable. <?php $itemId = null; ?> <table class=”item-table”> <tr data-row=”product-item” id=”<?= $block->escapeHtmlAttr($item->getId())… Read More »Magento 2 How to get td value using script and assign that value to php variable in same phml file?

Parse error: syntax error, unexpected ‘RewriterInterface’ (T_STRING), expecting function (T_FUNCTION) or const (T_CONST) in …Delegator.php on line27

Magento ver. 2.4.5-p1 PHP 8.1 Smartwave Porto theme I am trying to install the Mageplaza Multiple Shipping Flat Rates extension via composer by running the following command: composer require mageplaza/module-multi-flat-rates But it gives me this Error: Parse error: syntax error,… Read More »Parse error: syntax error, unexpected ‘RewriterInterface’ (T_STRING), expecting function (T_FUNCTION) or const (T_CONST) in …Delegator.php on line27