Skip to content

magento man

How to add select state dropdown field in custom phtml form and save in database(frontend) in magento2.2.5?

I have added a select state dropdown field in my custom phtml file. But not able to save that value in database in Magento2.2.5? /var/www/html/magento2/app/code/Amy/Contactform/Block <?php namespace AmyContactformBlock; use MagentoFrameworkViewElementTemplate; class ContactForm extends MagentoContactBlockContactForm { public function __construct( TemplateContext $context,… Read More »How to add select state dropdown field in custom phtml form and save in database(frontend) in magento2.2.5?

How to get current Cart_id/quote_id in plugin file Magento 2?

namespace AsmSetselleridPlugin; use MagentoQuoteModelCartTotalsItemConverter; use MagentoQuoteApiDataTotalsItemExtensionFactory; class Item { /** * @var TotalsItemExtensionFactory */ protected $totalsItemExtensionFactory; /** * ItemConverterPlugin constructor. * * @param TotalsItemExtensionFactory $totalsItemExtensionFactory */ public function __construct( MagentoCheckoutModelCart $cart, TotalsItemExtensionFactory $totalsItemExtensionFactory ) { $this->totalsItemExtensionFactory = $totalsItemExtensionFactory; $this->cart =… Read More »How to get current Cart_id/quote_id in plugin file Magento 2?

When click Image and show clicking Image in popup in magento 2

How to create, When click Image and show clicking Image in popup. This is my code :- echo “<td>”?><img src=”<?php echo $this->getMediaUrl() .’brand’. $data->getImage(); ?>” width=”100px” height=”100px” class=”click-header”></td> JS Code :- <script type=”text/javascript”> require([ ‘jquery’, ‘Magento_Ui/js/modal/modal’ ], function($, modal) {… Read More »When click Image and show clicking Image in popup in magento 2

Elastic Search issue in Magento 2.4.1

I am facing below error in exception.log file. How can i resolve this error? {“error”:{“root_cause”:[{“type”:”illegal_argument_exception”,”reason”:”no mapping found for field [amxnotif_hide_alert_value]”}],”type”:”search_phase_execution_exception”,”reason”:”all shards failed”,”phase”:”query”,”grouped”:true,”failed_shards”:[{“shard”:0,”index”:”magento2_product_1_v226″,”node”:”YsQHRziLSUeMo8kQPmEqbw”,”reason”:{“type”:”illegal_argument_exception”,”reason”:”no mapping found for field [hide_value]”}}],”caused_by”:{“type”:”illegal_argument_exception”,”reason”:”no mapping found for field [amxnotif_hide_alert_value]”,”caused_by”:{“type”:”illegal_argument_exception”,”reason”:”no mapping found for field [hide_value]”}}},”status”:400} {“exception”:”[object] (Elasticsearch\Common\Exceptions\BadRequest400Exception(code: 400):… Read More »Elastic Search issue in Magento 2.4.1

Could not find a matching version of package

I have uploaded my magento 2 module to GitHub, and published my private module to https://packagist.com/. Now module published successfully as below. And my composer as below { “name”: “vlcsolutions/module-connector”, “description”: “Business Central Express Connect”, “require”: { “php”: “~7.0.0|~7.1.0|~7.2.0|~7.3.0|~7.4.0″ },”minimum-stability”:… Read More »Could not find a matching version of package