texts: How can we display Filters items individually in products list page

texts:
I am using Magento 2.3.3 in my project and I want to display the selected categories, product attributes individually with Remove option in Filters sections as shown below so that the user can clear one item at a time.

Category 1 X

Category 2 X

At present, it is showing as

Category 1, Category 2 X

and when the user clicks on the remove icon, both the items are cleared from the list.

Please suggest how to modify the code from the link
app/code/Codazon/AjaxLayeredNavPro/view/frontend/templates/layer/state.phtml

<?php
/**
 * Copyright © Magento, Inc. All rights reserved.
 * See COPYING.txt for license details.
 */

// @codingStandardsIgnoreFile

?>
<?php
/**
 * Category layered navigation state
 *
 * @var $block \Magento\LayeredNavigation\Block\Navigation\State
 */
?>
<?php $_filters = $block->getActiveFilters() ?>
<?php if (!empty($_filters)): ?>

    <strong class="block-subtitle filter-current-subtitle"
            role="heading"
            aria-level="2"
            data-count="<?= count($_filters) ?>"><?= /* @escapeNotVerified */ __('Filters') ?>

        <?php foreach ($_filters as $_filter): ?>
            <?php
            $label = $_filter->getLabel();
            **if (is_array($label)) {
                $label = implode(', ', $label);
            }**
            ?>

                <?= $block->escapeHtml(__($_filter->getName())) ?>
                <?= /* @escapeNotVerified */ $block->stripTags($label) ?>
                <?php
                $clearLinkUrl = $_filter->getClearLinkUrl();
                $currentFilterName = $block->escapeHtml(__($_filter->getName())) . " " . $block->stripTags($label);
                if ($clearLinkUrl):
                    ?>
                    <a class="action previous" href="<?= /* @escapeNotVerified */ $_filter->getRemoveUrl() ?>"
                       title="<?= /* @escapeNotVerified */ __('Previous') ?>">
                        <?= /* @escapeNotVerified */ __('Previous') ?>

                    <a class="action remove"
                       title="<?= $block->escapeHtml($_filter->getFilter()->getClearLinkText()) ?>"
                       href="<?= /* @escapeNotVerified */ $clearLinkUrl ?>">
                        <?= $block->escapeHtml($_filter->getFilter()->getClearLinkText()) ?>

                <?php else: ?>
                    <a class="action remove" href="<?= /* @escapeNotVerified */ $_filter->getRemoveUrl() ?>"
                       title="<?= /* @escapeNotVerified */ $block->escapeHtml(__('Remove')) . " " . $currentFilterName ?>">
                        <?= /* @escapeNotVerified */ __('Remove This Item') ?>

                <?php endif; ?>

        <?php endforeach; ?>

<?php endif; ?>

Bolded code is the logic which is used to display the items list in one line.

Please do needful by providing the solution.
Thanks in Advance.


texts:
For executing magento patches, we need to use SSH command lines

e.g. sh patch_file_name.sh

But I wonder where to put this command lines? on Hosting site? on FTP client? Please advise. Thanks for help!

I am using windows 7 and using Filezilla as connection tool


texts:
I have a store with 300k products, I set up the reindex to be "Update by Schedule",

But I don't know what is the best way for reindexing, Should I do this manually by SSH command every 24 hours by this command

  php bin/magento indexer:reindex

Or I have to set up a cron job to do reindexing.
if i set up the cron job what is he good period.

My concern is, if I set up a cron job each 1 hour, Reindexing takes about 30 minutes to finish, in this case, every one hour I will be blocked for 30 minutes.

Anyone can help me at this point, What I have to do?


texts: Magento 2 Issue with "Not Registered Handle" on all the sales sections?

texts:
If I go to "Sales" under Magento 2, I have several menu options. And every single one of those options has an error relating to that section:

Orders: Not registered handle sales_order_grid_data_source
Invoices: Not registered handle sales_order_invoice_grid_data_source
Shipments: Not registered handle sales_order_shipment_grid_data_source
Credit Memos: Not registered handle sales_order_creditmemo_grid_data_source

And so on. I was on Magento 2.0.x earlier and the issue wasn't there. I don't know when the issue appeared because this store is in development and not active. But I've since updated to 2.1.0 then 2.1.3 this week, and not sure when the problem occurred. Anything helpful would be great.


texts: How to add new sorting option for product in Magento2?

texts:
By default Magento provide Position , Name and Price sorting option for products.

But I want to add new sorting option Price high to low , Price low to high and Latest arrivals.

So how can I add my custom sorting options?

I want to know how can we add any custom sorting option so in future if I want to add any option I can do myself.I want to know code flow for sorting functionality and what steps are required to fulfill this functionality?

I have googled and find this and this but none of are useful.


texts: Is there any way to install sample data from Zip file after successful installation of magento 2.3.5-p2?

texts:
I have installed Magento 2.3.5-p2. But after that i need to install sample data i exectute command
 - php bin/magento sampledata:deploy

But i got this ..
Could not find a matching version of package magento/module-sales-sample-data. Check the package spelling, your version constraint and that the package is available in a stability which matches your minimum-stability (stable).

After that i have downloaded Zip file from mageplaza extract file and paste file in magento directory and execute command.

bin/magento setup:upgrade

I got Nothing to import.
Is there any other way to install sample data. i am using apache2, php 7.2. i have installed each thing sepratelly not any xampp, lamp etc.


texts: Magento 2 add custom static block on product detailed page next o addtocart button

texts:
I am working with the Magento2, in that, I like to add a custom  block on product detailed page, next to add to cart button. for that, i wrote the below code on

  catalog_product_view.xml

<body>
        <referenceBlock name="product.info.addtocart">
                <block class="Learn\Share\Block\Share" name="share.otherproducts" as="shareother" after="-" template="catalog/product/view/share.phtml" >
                </block>
        </referenceBlock>
        <!-- for config products -->
        <referenceBlock name="product.info.addtocart.additional">
            <block class="XXXX\YYYY\Block\Share" name="share.configproducts" as="share_config" after="-" template="catalog/product/view/share.phtml" >
            </block>
        </referenceBlock>
    </body>

I got the custom block values on simple, download product. but in bundle product detailed page I don't get any custom block values.

Then, the custom block not only for simple, download and bundle product. I want this custom block on all the Magento product types, so give me your solution for support all product type

Then why we need to add the same custom block on product.info.addtocart.additional section.

Thanks in advance for your thoughts and ideas.


texts: Catalog Rules Don't Get Applied on Product Save

texts:
I'm seeing an issue occur where the catalog price rules aren't getting applied when a new product is enabled and saved at the same time.

When I look in the CatalogRule module, I see that there is an observer on the catalog_product_save_commit_after event calling Mage_CatalogRule_Model_Observer::applyAllRulesOnProduct()

Digging in to the observer, I see it calls:

Mage::getModel('catalogrule/rule')->applyAllRulesToProduct($product);

Digging in to this method, it calls Mage_CatalogRule_Model_Resource_Rule::applyToProduct for each catalog price rule. This method either deletes the data in the db table catalog_rule_product_price for the product if the rule doesn't apply to it, or calls Mage_CatalogRule_Model_Resource_Rule::insertRuleData($rule, $websiteIds, $productIds) if the rule matches.  The parameter $productIds is an array with product ids for the keys and arrays of website ids as the values.

It's in the insertRuleData method that things seem to break down.  In the method the body is largely an if statement that executes two different paths depending on whether the catalog product flat tables are enabled.  If they aren't enabled theres a foreach statement that uses the product id array in a way it seems it was intended:

foreach ($productIds as $productId => $validationByWebsite)

If the flat tables are enabled, the $productId array is used in a select statement that appears to be incorrect:

$selectByStore->where('p.entity_id IN (?)', $productIds);

You have to wind through a bit of code, but p is set in:

Mage_Rule_Model_Resource_Abstract::getProductFlatSelect()

array('p' => $this->getTable('catalog/product')) aka the db table catalog_product_entity

So, the resulting select statement is basically SELECT ... FROM catalog_product_entity WHERE entity_id in (...website_ids...), as the website ids are the contents of the $productIds array.

This select statement will return the wrong products and the catalogrule_product table never gets properly updated.  There's an indexer that depends on catalog_rule_product to create the contents of catalog_rule_product_price

Looks to me like a core bug?  Am I missing something?

If it is a bug, what's the best practice for fixing it - over-riding the resource model or editing the core (gasp)?


texts: What are the ways for installing an extension in Magento 2?

texts: I need detailed information for installation of Magento 2 extension.


texts: Sorting and sort direction applied together

texts:
Is it possible to apply sorting option and direction at the same time, using sorting select box?

The sorting select box could have options like:

Price Asc
Price Desc
Position Asc
Position Desc
..


texts: Product Attribute - Multiple Select Not Saving

texts:
Hi I have products with a fair few custom attributes which are all working fine. I have two Multiple selects however that do not save what I enter in them!

All other text fields, dropdowns etc all save fine but it doesn't matter if I select one or ten options on the multiple selects they don't save, save and continue or just save, it doesn't make a difference!

Has anyone had this occur or does anyone have any suggestions?

Thanks!


texts:
when i execute this code after purchase with 3 products or more
$cartManagement = $objectManager->create(\Magento\Quote\Api\CartManagementInterface::class);
                    $orderId = $cartManagement->placeOrder($quote->getId());

or
$orderId = $this->cartManagement->placeOrder($quote->getId());

I get this error:  Magento\Framework\Stdlib\Cookie\FailureToSendException: Unable to send the cookie with cookieName = X-Magento-Vary
Increase the values in PhpCookieManager.php but the same error continues
const MAX_NUM_COOKIES = 500;
const MAX_COOKIE_SIZE = 40960;
const EXPIRE_NOW_TIME = 1;
const EXPIRE_AT_END_OF_SESSION_TIME = 0;
what is the solution?
Thanks


texts: Magento2: How to override widget template

texts:
There is widget.xml in CatalogWidget module. Inside the widget.xml there is

        <parameter name="template" xsi:type="select" required="true" visible="true">
            Template
            <options>
                <option name="default" value="product/widget/content/grid.phtml" selected="true">
                    Products Grid Template
                </option>
            </options>
        </parameter>

What is a proper way to change the template file for the widget?


texts: Magento2: How to search products by categories in mini search?

texts:
I want to search products with categories in search box. please find attachment of screenshots.

Anyone have an idea for that?


texts:
I have created a configurable product and I have setted different associated simple products into "Associated Products" tab.

All the simple products have quantity >1, are In Stock, Available and linked to the Main Store (actually i have only one store).

After the first configuration, in the administration products grid, the quantity of the configurable product is the sum of all the associated products and the product is correctly shown in the front-end store.
After the sale of the product, in the administration products grid, the quantity of the configurable product is automatically set to 0, while the quantity of the sold associated product is correctly decreased.

Someone can help me to understand this problem?

I'm using Magento Magento ver. 1.9.2.1.


texts: Magento 2.2.6 reindex not finishing Catalog Search CLI Putty crashing

texts:
Apache 2.4 Linux Centos

store has 25,000 sku

I am trying to reindex Magento 2.2.6 site with elasticsearch 5.1 running

when I try to run full reindex it takes a long time when it reaches

php bin/magento indexer:reindex catalogsearch_fulltext

then after about 1 hour or so it crashes the Putty CLI

Tried to reindex manually by running  on its own but same issue is happening
php bin/magento indexer:reindex catalogsearch_fulltext

Any ideas please and what settings should I be looking at on the server too


texts: Specific block not rendering inside of a static block

texts:
Works fine in a CMS page.

But I need to render this block in a static block:

{{block type="catalog/product_list" category_id="37"  template="tm/quickbuy/catalog/product/list.phtml”}}

The block above is very similar except with different directory paths to the one below. When i insert the one below it works. The one above does not work.

{{block type="catalog/product_list" category_id="4"  template="catalog/product/list.phtml”}}

I've made sure they are whitelisted.
I've tried to change directories by putting the top block in the same directory as the bottom block.

Any idea to why my first block does not render properly?


texts: Magento2 - VAT Price not including the final price

texts:
My Product unit price € 13.50.
9% VAT apply for that product but edit cart page display the VAT amount, but it's not added to the Subtotal.
How to resolve this issue?


texts:
I am using Magento 2.3.5-p1 with claue theme.
I am getting below error in transactional email, how to fix it?
 Compilation from source: LESS file is empty: frontend/Mgs/claue/en_US/css/email-inline.less


texts:
I simply want to add js for my custom module but I'm getting this error:

  layout.js:137 Uncaught TypeError: Constr is not a constructor

The hello.js file will still work, console.log will still work, however, I still get the error above. Any idea?

requirejs-config.js

var config = {
map: {
    '*': {
        emlhello          : 'EML_CityAutocomplete/js/hello'
    }
}};

hello.js

define([
    "jquery"
], function($){
    "use strict";
    console.log('asdasd');
   return true;
})

And I'm trying to call it via layout xml

<referenceBlock name="checkout.root">
        <arguments>
            <argument name="jsLayout" xsi:type="array">
                <item name="components" xsi:type="array">
                    <item name="checkout" xsi:type="array">
                        <item name="children" xsi:type="array">
                            <item name="autocomplete" xsi:type="array">
                                <item name="sortOrder" xsi:type="string">0</item>
                                <item name="component" xsi:type="string">EML_CityAutocomplete/js/hello</item>
                            </item>
                        </item>
                    </item>
                </item>
            </argument>
        </arguments>
    </referenceBlock>


texts: Magento 1.9.3.1 Upload Buttons not working

texts:
After upgrading to magento 1.9.3.1 the uploading image buttons stop working, I already read all sites on google until page 6 and found a lot of solutions but any works for me, I also did Security-Patches/SUPEE-8788, but no success.
The box of similar questions are also looked.


texts: Exception #0 (Magento\Framework\Exception\LocalizedException): The configuration parameter "formElement" is a required for "custom_attribute" field

texts: I have created and uninstall an attribute for product , after deleting it completely when I click on ADD PRODUCT the above error is coming.


texts: Default Varnish configuration to use with Magento 2

texts: I'm setting up Varnish with Magento 2. I want to know if I can use the default configuration of Varnish (/etc/default/varnish) with Magento 2 or not?


texts:
How to set drop down field in minicart qty place

file path

view/frontend/web/template/minicart/item/default.html file

if anyone knows please explain me


texts: Magento products with different weight unit for Shipping method?

texts:
In my Magento website all items are with weight - grams (gr), litre (L), milliliter (ml), centilitre (cl).

I have created an attribute dropdown contain all weight unit for all products and select the specify weight unit for each product.

But in Shipping Calculations, i want a unified unit weight.

How to do that? any suggestion ?


texts:
I am new to Magento and following tutsplus tutorial. During module development I got this error "Call to a member function sayHello() on boolean".

Below is my test.php file in magento(for testing the module):

     require_once'app/Mage.php';
     Mage::app();
     $customer= Mage::getModel("customer/session");

     //Mage_catalog_Model_Product

     Mage::getModel("catalog/product");

     $product = Mage::getModel("demo/product");

     $product -> sayHello();

Here is the model file code (Product.php)

      class Tutsplus_Demo_Model_Product {

       public function sayHello(){

       echo "Hi";
      }
     }

When I removed the $product->sayHello(); to // echo get_class($customer); it shows the class name. config.xml file is here.

     <config>
       <global>
         <models>
            <demo>
                <class>Tutsplus_Demo_Model</class>
            </demo>
         </models>
       </global>
      </config>


texts: Cart stays empty if cookies are not deleted

texts:
For some reason people can't put things in their cart, the issue is fixed once you clear your cookies.
Problem is: we're getting reports from a lot of customers that they can't add things to their cart. Is there any way to change/update/delete the cookie for everyone?

We're running around with our hair on fire, please help.

Running Magento ver. 1.9.3.1

URL: https://6dsportsnutrition.com/shop/


texts: Adding body class for logged in user kills checkout

texts:
I have the following in my local.xml, to add a body class for logged in users (for styling purposes):

<customer_logged_in>
    <reference name="root">
        <action method="addBodyClass">
            <classname>logged-in</classname>
        </action>
    </reference>
</customer_logged_in>

Works fine, however, I've now noticed that it kills the checkout at the "Payment Information" step, with the following popup error:

Unable to set Payment Method.

Anyone know why?

UPDATE: The logs show the following error:

exception 'Varien_Exception' with message 'Invalid method Mage_Checkout_Block_Onepage_Review_Info::addBodyClass(Array
(
    [0] => logged-in
)

I don't need that body class on the checkout, so is there perhaps some way to only apply this class to certain areas? Namely the cart page.


texts: Are there any way to change attribute set using CSV in magento 2

texts:
I have added product using default attribute set now I want to change the attribute set, so I have create a csv using sku and new attribute set but it didn't work.

This is my csv file format,

sku     attribute_set_code
1110086 Cleaning
1126000 Consumables
1127841 Cleaning
1127844 Cleaning
1127845 Cleaning

I have updated and result is successfully  imported but it didn't change the product attribute sets.
can any one look this
thanks.


texts: Magento CPU 100% utilization even when less traffic

texts:
we have three store magento sites installed in server on a single instance.
the cpu is going for 100% usage for just very less traffic.

Any help will be appreciated?


texts:
Hello, I have following problem with button and link where it redirects. Here is my button code:

$block->addButton('label', array(
                          'label' => 'Get Label',
                        //'onclick'   => ((Mage::app()->getResponse()->setRedirect(Mage::helper("adminhtml")->getUrl("/label/setlabel")))),
                          'onclick'   => 'popWin();'
                        ));

I want open in new window my controller, for that I am using 'onclick'   => 'popWin();' and this opens new window, but if I am adding 'onclick'   => ((Mage::app()->getResponse()->setRedirect(Mage::helper("adminhtml")->getUrl("/label/setlabel")))), it redirects me to controller page before I can even push button, as soon as I open the page where this button is, it automatically redirects me to controller page and doesn't show the page where the button is. How can I open the page where the button is and then click button and then it redirects to controller?


texts: How to make ... translatable in layout definition

texts:
Here I have the default contact page layout file (contact_index_index.xml):

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <head>
        <title>Contact Us</title>
    </head>
    <body>
        <referenceContainer name="content">
            <block class="Magento\Contact\Block\ContactForm" name="contactForm" template="Magento_Contact::form.phtml">
                <container name="form.additional.info" label="Form Additional Info"/>
            </block>
        </referenceContainer>
    </body>
</page>

How can I translate the head title?


texts: How to get product using price range magento

texts:
I am trying to get products using  price range suppose we i want product with price range of

50-500 then how can get?


texts: Adding attribute filter sidebar in magento 1.9

texts:
Good morning,
I want to add a filter of attributes like this.Like this I should put the attribute in static block first or how i can make it possible. Your answer will be very helpful.
Thanks.


texts:
Magento 1.9.3.4 frontend runs into that error only when a customer is logged in and tries to switch the currency with the currency switcher.
My error log shows:

  End of script output before headers: index.php, referer:
  http://example.com/customer/account/login.

Can anybody help?


texts: Magento 2: admin grid form select dropdown relationship

texts:
I want to create dropdown like Country -> State relationship
where user select a country and its states visible in another dropdown in admin grid form


texts: Where to find details about magento versions

texts: Where could i find infos related to magento CE and Enterprise versions history with details including the new features added in each versions?


texts: Magento Connect: Extension unable to Install - Magento Community Edition

texts:
I am working on a magento 1.9 e-commerce project tried to install a plugin through magento connect and this is the error i get :

  SSL: no alternative certificate subject name matches target host name 'magento-community'

This occours when i insert the extension key
and this happens when i try to upload the extension package:

  CONNECT ERROR: Package file is invalid
  Invalid package name, allowed: [a-zA-Z0-9_-] chars
  Invalid version, should be like: x.x.x
  Invalid stability
  Invalid date, should be YYYY-DD-MM
  Invalid channel URL
  Empty authors section
  Empty package contents section


texts: Minimum Advertised Price doesn't work on product page Magento 2.3.1

texts: I have installed theme SM Shopping from magentech and noticed that MAP price doesnt work on a frontend. I enabled it in configuration, but still nothing. Please advise how I can maybe manually add it to category page and product page


texts: Show custom module information in 1 Module Menu not in 2 Module menu

texts:
I'm creating a custom module by show information of menu in my first module by not in second module show.

  1: How to show information menu in my second module?.

  2: I need add a New Column to Orders Grid?.

How add a new Column to Orders Grid, Admin Panel: Sales->Orders
(add in database).


texts: Magento2: how to add/remove a form field using javascript

texts:
I have created a custom form in admin in which I need to show buttons such as "Add more" and "Remove". The scenario is exact that which is discussed here:

  https://stackoverflow.com/questions/38903032/how-to-add-dynamic-field-in-magento2-admin-form?rq=1

I created and added a child block but not getting how I can add or remove a field using javascript.

Please help ?


texts:
At the moment I have an observer running on the sales_quote_save_before event to check if the customer's cart has a subtotal greater than £100 if they belong to a particular customer group.

This works well besides from it runs every time the customer adds a product to their basket. I only want to run my code if they try to go to the checkout page rather than just viewing the basket page.

Could anyone advise of the event I would need to use


texts: Auto fill form after click button magento 1.9

texts: When checkout success, I redirect to a success page with order id, this page has Confirm Payment button. And I click on the button it will show confirm payment page (contains confirm payment form). How to autofill order id into Order Id field in my form? Thanks.


texts: what is the difference between $_SERVER['MAGE_RUN_TYPE'] 'store' and 'website'

texts:
For the creation of multistore magento we use following code

$mageRunCode = isset($_SERVER['MAGE_RUN_CODE']) ? $_SERVER['MAGE_RUN_CODE'] : '';
$mageRunType = isset($_SERVER['MAGE_RUN_TYPE']) ? $_SERVER['MAGE_RUN_TYPE'] : 'store';
Mage::run($mageRunCode, $mageRunType);

What will be the difference if we use website instead of store in $_SERVER['MAGE_RUN_TYPE'] : 'store'; code


texts: Magento user permission unchecked on save custom module

texts:
I've developed a small custom module.
It worked as expected but I can't save user permission:
I can see the module in the admin panel and in the Role Resource Tab
(System->Permissions->Roles), but when I tried to check the module and save the user role, it will say that it has been saved. But when I rechecked the user role, it is still unchecked.

  adminhtml.xml:

 <menu>
    <Gestion translate="title" module="Gestion_Commande">
        <title>Navette</title>
        <sort_order>1000</sort_order>
        <children>
            <envoi>
                <title>Preparation Magasin Cursol</title>
                <sort_order>1</sort_order>
                <action>adminhtml/gestion/envoi</action>
            </envoi>
            <receptio>
                <title>Reception Begles</title>
                <sort_order>2</sort_order>
                <action>adminhtml/gestion/reception</action>
            </receptio>
            <crossdoc>
                <title>Crossdocking et Erreurs De Stock</title>
                <sort_order>3</sort_order>
                <action>adminhtml/gestion/crossdoc</action>
            </crossdoc>
        </children>
    </Gestion>
</menu>
<acl>
    <resources>
        <admin>
            <children>
                <Gestion translate="title" module="Gestion_Commande">
                    <title>Navette</title>
                    <sort_order>1000</sort_order>
                    <children>
                        <envoi>
                            <title>Preparation Magasin Cursol</title>
                            <sort_order>1</sort_order>
                        </envoi>
                        <receptio>
                            <title>Reception Begles</title>
                            <sort_order>2</sort_order>
                        </receptio>
                        <crossdoc>
                            <title>Crossdocking et Erreurs De Stock</title>
                            <sort_order>3</sort_order>
                        </crossdoc>
                    </children>
                </Gestion>
            </children>
        </admin>
    </resources>
</acl>

I've seen this post, but it doesn't seem to be the same problem

Can't Save Role Resource for Custom Module

any ideas?

EDIT

Now access are granted successfully, but when I rechecked the user role, it is still unchecked...


texts:
How to put code in home page for bxslider?

<link href="jquery.bxslider.css" rel="stylesheet" />


texts: How can I use AJAX in magento for retrieve data when change the drop-down?

texts:
I have created two drops down for height and width. data will be retrieved from the database table. below code represent that it's in my .phtml file

<select id="width">
<?php
foreach($width as $w){ ?>
    <option value="<?php print_r($w['width']);?>"><?php print_r($w['width']);?></option>
<?php
}
?>
</select>
<select id="height">
<?php
foreach($height as $h){ ?>
    <option value="<?php print_r($h['height']);?>"><?php print_r($h['height']);?></option>
<?php
}
?>
</select>

according to a selected value, there is some calculation such as area I have done those using jquery that code in .js file

There is a price according to selected width and height I need display the price by retrieving from database table I have created query for that like below

<?php
    $sql = " SELECT price_component FROM base_price WHERE width='W' AND height='H' ";
    $selected = $connection->fetchAll($sql);

    foreach($selected as $s){
        ?>
base price :
        <?php
        print_r($s['price_component']);
    }
?>

I need to get selected value so I can use it as 'W' and 'H'

How can I do that please help me with this case


texts: Magento 1.9 RWD breakpoint for iPad landscape only (SCSS)

texts: I need the breakpoint for iPad landscape only. I need to make some specific styles or iPad landscape only. How do i set this break (mediaquery) in my SCSS stylesheet?


texts: The block from my custom module isn't showing up on the product page. How can I debug?

texts:
I am making my first custom module, following a tutorial online. I get that I have to create certain XML files for the system to "discover" my module, but even when I break the XML, I don't see any difference, or I sometimes see a page which tells me there's an error report which is being hidden. How can I find these error reports, and is there a way to get feedback from the system while I am developing?

Here's my file app/etc/modules/BlueAcorn_Test.xml:

<?xml version="1.0" encoding="UTF-8"?>
<config>
    <modules>
        <BlueAcorn_ExampleModule>
            <active>true</active>
            <codepool>local</codepool>
        </BlueAcorn_ExampleModule>
    </modules>
</config>

And here's my configuration file at app/code/local/Blueacorn/Example/etc/config.xml:

<?xml version="1.0" encoding="UTF-8"?>
<config>
    <global>
        <blocks>
            <test>
                <class>BlueAcorn_ExampleModule_Block</class>
            </test>
        </blocks>
        <layout>
            <updates>
                <test>
                    <file>example.xml</file>
                </test>
            </updates>
        </layout>
    </global>
</config>


texts: Paypal Pro Instant Payment Notifications

texts:
I have set up paypal pro following all the info re API etc but I am getting the following message from paypal everyday

Is this an error in my magento back end or something I have done wrong in my paypal account?

What should my URL in the paypal back end be?

Please check your server that handles PayPal Instant Payment Notifications
(IPN). Instant Payment Notifications sent to the following URL(s) are
failing:


texts: Add module Enable/disable functionality in Magento 2

texts:
I want to add Enable/disable functionality in my custom module by which the module can be enabled or disable directly form admin-panel for just selecting.

I want to add something like this in my custom module


texts:
I am new in Magento. I am scratching my head for 2 days for a issue.
I have built a custom page using which I can pass some static data to Paypal for make a payment. It is working. But now I am wanting that from magento when user add some products to cart and click proceed button then it will redirect my custom page and pass to paypal for payment.
I want to know how can I pass the data of products which are added to cart and pass it to my custom page?and also want to to how to retrieve the data to show on the products details on my custom page and pass the data to paypal for payment?


texts: Best way to add On Sale link in top navigation

texts:
I'm wondering if there is a correct way (or best) way to implement this. I would like there to be a link in the top menu navigation that, when clicked, will bring users to our "on-sale" page.

We currently mark things "on-sale" using magento's special price fields.

The way I currently have it setup is like this:

I created a category called "Sale" which put a link into the top nav.

in the URL key I put in "sale"

I then went to the Catalog>URL Rewrite Management and changed the "requested path" to "/sale"

This is currently working, although I don't know if it's the best way to have done this. Please let me know your thoughts and thanks in advance!

This is the site: http://bit.ly/1iv22yg


texts: Magento multicountry set-up (1 domain, or more domains, or /countryname subdir)

texts:
when setting up a new store view I was wondering what the best of the best method is to set-up multistores - in multicountries.

For store A we have

storeA.com => English
winkel1.com => Dutch
geschafte1.com => German

For store B this trick does not work, we only have 1 domain

StoreB.com => English, Dutch and German

Now what is the best SEO friendly way to set-up these Dutch and German stores?

Do I create a store view with subdirectory /nl and /de
Or maybe with subdomain nl.StoreB.com and de.StoreB.com
Or would I use the same main store URL (and install some GEO ip); but how then does the sitemaps work?

I can imagine that method 3 looks easier to start. You already start the domain with autority, but the language/goal country gest confused. With method 1 you loose all existing SEO and start again, but focussed on a country.

Many thanks, Sean


texts: How to add a delete button/icon for each product in the compare page?

texts:
How can I add a delete function for each product on product compare page?

For example, if I added three products and click compare, then decided to remove any one of the products by clicking on a delete icon to remove it from the comparison, how can I add a delete function for each of the compared products on the product compare page. (The page that pops up)


texts: Production collection remove visibility filter

texts:
I'd like to load products by IDs, but ignore the product visibility. So when loading a product collection I'd like to even have products in the collection that have visibility "Search".

On a related note: I am using a custom Catalog Block extending Mage_Catalog_Block_Product_List so I can get the product list by calling

Mage::app()->getLayout()->createBlock('catalog/product_list_xyz')->setTemplate('catalog/product/list.phtml')

Inside my custom catalog type block I'm using Mage::getModel('catalog/layer')->prepareProductCollection($collection); Is there any way to "reset" the visibility filter?


texts:
I have the following form element which gets a list of products and adds them to a select form element

<field name="featuredproduct">
        <argument name="data" xsi:type="array">
            <item name="options" xsi:type="object"><VENDOR>\<MODULE>\Model\Settings\ProductOptions</item>
            <item name="config" xsi:type="array">
                <item name="dataType" xsi:type="string">text</item>
                <item name="label" translate="true" xsi:type="string">Homepage Featured Product</item>
                <item name="formElement" xsi:type="string">select</item>
                <item name="source" xsi:type="string">Settings</item>
                <item name="sortOrder" xsi:type="number">10</item>
                <item name="dataScope" xsi:type="string">homepage_featured_product</item>
                <item name="caption" xsi:type="string" translate="true">-- Please Select --</item>
                <item name="default" xsi:type="string">**RETURN VALUE FROM DB**</item>
                <item name="validation" xsi:type="array">
                    <item name="required-entry" xsi:type="boolean">false</item>
                </item>
            </item>
        </argument>
    </field>

This works, but I need to set the default value from the current value stored in a custom table in the database.

Not sure how I can pass the value in. The custom table has the resource modal etc.

Any help would be great.


texts: How I can replace page on on 'My product review' page on account side?

texts:
How can I edit this page as I want to change position of pager and  per page handler And want to place this before review div .
Image is :


texts: How to show custom options in layer navigation

texts:
Some of my products have custom options for size/color/etc. I'd like to allow users to filter by these like they can filter by regular attributes.

The site I'm working on is here: http://www.electravapor.com/accessories.html

I essentially want a list of all possible colors under the "SHOP BY" block, allowing users to filter the same as they can with price.


texts: Magento2 coding style for files and folder names

texts:
I find that Magento2 core modules don't follow the same style, so I cannot take a reference from there (they're all different).

How should a folder be named:

PreviouslyBought or Previouslybought? (module name under your package name)

A php file should be:

PreviouslyBought.php or Previouslybought.php?

A phtml file should be:

PreviouslyBought.phtml or Previouslybought.phtml or previouslybought.phtml?

A javascript file should be:

PreviouslyBought.js or Previouslybought.js or previouslybought.js or previouslyBought.js?

A css file should be:

previously-bought.css or previously_bought.css?


texts: Magento 2: Cart Price Rules without coupon not working

texts:
I am trying to create a cart price rules where, when 4 or more products within an attribute set and a certain category are added, the customer should receive a 15% discount.
The rule I have created works perfectly IF we assign a coupon code.
With a coupon code - Within the shopping basket page the parameters are met - 4 or more products in basket within x attrib. set & category, when the discount code is applied, the 15% Discount is correctly assigned.
However - we want this rule to work without the use of a coupon code.
Unfortunately, it doesn't and i'm not sure why.
Any advice appreciated. Thanks.


texts: Security PATCH SUPEE-10975 Installation Issues in Config.xml

texts:
[test_servert@AMER14VMW03 htdocs]$ bash ./PATCH_SUPEE-10975_CE_v1.9.1.1_v1-2018-11-27-09-18-02.sh

Checking if patch can be applied/reverted successfully...

ERROR: Patch can't be applied/reverted successfully.

patching file app/code/core/Mage/Adminhtml/Block/Customer/Group/Edit.php
patching file app/code/core/Mage/Adminhtml/Block/Newsletter/Template/Edit.php
patching file app/code/core/Mage/Adminhtml/controllers/Cms/BlockController.php
patching file app/code/core/Mage/Adminhtml/controllers/Customer/GroupController.php
patching file app/code/core/Mage/Adminhtml/controllers/SitemapController.php
patching file app/code/core/Mage/Adminhtml/controllers/System/BackupController.php
patching file app/code/core/Mage/Captcha/Model/Observer.php
patching file app/code/core/Mage/Captcha/Model/Zend.php
patching file app/code/core/Mage/Captcha/etc/config.xml
patching file app/code/core/Mage/Catalog/Model/Api2/Product/Image/Rest/Admin/V1.php
patching file app/code/core/Mage/Catalog/Model/Product/Attribute/Media/Api.php
patching file app/code/core/Mage/Cms/Model/Wysiwyg/Images/Storage.php
patching file app/code/core/Mage/Core/etc/config.xml
Hunk #1 FAILED at 28.
Hunk #2 succeeded at 428 (offset 3 lines).
Hunk #3 succeeded at 452 (offset 3 lines).
1 out of 3 hunks FAILED -- saving rejects to file app/code/core/Mage/Core/etc/config.xml.rej
patching file app/code/core/Mage/Core/sql/core_setup/upgrade-1.6.0.6.1.2-1.6.0.6.1.3.php
patching file app/code/core/Mage/Dataflow/Model/Convert/Container/Abstract.php
patching file app/code/core/Mage/ImportExport/Model/Import/Entity/Customer.php
patching file app/code/core/Mage/ImportExport/Model/Import/Entity/Customer/Address.php
patching file app/code/core/Mage/Payment/etc/config.xml
patching file app/code/core/Mage/Payment/etc/system.xml
patching file app/code/core/Mage/Payment/sql/payment_setup/upgrade-1.6.0.0.1.1-1.6.0.0.1.2.php
patching file app/code/core/Mage/Sendfriend/Block/Send.php
patching file app/code/core/Mage/Wishlist/controllers/IndexController.php
patching file app/code/core/Zend/Controller/Request/Http.php
patching file app/design/adminhtml/default/default/template/cms/browser/content/files.phtml
patching file app/design/frontend/base/default/layout/captcha.xml
patching file app/design/frontend/base/default/template/wishlist/sharing.phtml
patching file app/design/frontend/rwd/default/layout/page.xml
patching file app/design/frontend/rwd/default/template/sendfriend/send.phtml
patching file app/etc/modules/Mage_All.xml
patching file app/etc/modules/Mage_Captcha.xml
patching file app/locale/en_US/Mage_Wishlist.csv
patching file js/lib/jquery/jquery-1.12.0.js
patching file js/lib/jquery/jquery-1.12.0.min.js
patching file js/lib/jquery/jquery-1.12.0.min.map
patching file js/lib/jquery/jquery-1.12.1.js
patching file js/lib/jquery/jquery-1.12.1.min.js
patching file js/lib/jquery/jquery-1.12.1.min.map


texts:
I can't choose any category in the admin panel for editing. You will always see the creation of a new category.

Magento 1.9.4.0 clean setup,

mariaDB 10.3,

php 7.1.25,

CentOS.


texts: Vendor files not found, after trying to install extension

texts:
I tried to install an extension in my website. Now frontend and backend are giving "Error 500" and in ssh, command php bin/magento setup:upgrade gives me errors:

PHP Warning:  require(/home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/composer/../../src/Migration/cli_commands.php): failed to open stream: No such file or directory in /home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/composer/autoload_real.php on line 70
PHP Warning:  require(/home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/composer/../../src/Migration/cli_commands.php): failed to open stream: No such file or directory in /home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/composer/autoload_real.php on line 70
PHP Fatal error:  require(): Failed opening required '/home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/composer/../../src/Migration/cli_commands.php' (include_path='/home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/magento/zendframework1/library:.:/usr/share/php') in /home/148511.cloudwaysapps.com/tnkvxgzzzd/public_html/vendor/composer/autoload_real.php on line 70

How can I fix this and get my website back to normal?


texts: Get URL of Current Store View Store Magento 2

texts:
I have created multiple stores in one. Now when I change the store view it definitely changes and I have set the Base URLs for this store view accurately.
But when I try to get the current store view URL or Name I got the default store view name and URL.
I am trying to get using $storeManager->getStore()->getBaseUrl()
Any idea how I can get this ?


texts: how to change usd to indian rupee in magento 1.9.2?

texts: I forget to change the default currency value at the time of magento installation, may i know how to change USD to indian rupee in magento 1.9.2


texts: Switch off WS-I Compliance, Magento 2 Opensource

texts:
Does anyone know how I could switch off WS-I compliance for a Magento 2 website, or even if it is possible?

Trying to connect to a shipping API (Royal Mail Click and Drop) and they say WS-I compliance needs to be off.

They also say it is possible to switch off WS-I compliance in Magento 2 but they have not been able to tell me how and I can't figure it out!

Any ideas much appreciated.


texts: Trying to override a non-core admin controller

texts:
So I have this module named Thatcompany_Module, and it has some admin controllers.
I'm trying to override one of these controllers with my custom module, named Mycompany_MyModule

This is what the original routers section looks like in Thatcompany_Module :

<config>
    <admin>
        <routers>
            <modulefrontname>
                <use>admin</use>
                <args>
                    <module>Thatcompany_Module</module>
                    <frontName>modulefrontname</frontName>
                </args>
            </modulefrontname>
            <adminhtml>
                <args>
                    <modules>
                        <ThatCompany_Module before="Mage_Adminhtml">ThatCompany_Module_Adminhtml</ThatCompany_Module>
                    </modules>
                </args>
            </adminhtml>
        </routers>
    </admin>
</config>

What I've done yet, following advices found here and there on the Internet :

My config :

<config>
    <admin>
        <routers>
            <adminhtml>
                <args>
                    <modules>
                        <Mycompany_MyModule before="Thatcompany_Module">Mycompany_MyModule_Adminhtml</Mycompany_MyModule>
                    </modules>
                </args>
            </adminhtml>
        </routers>
    </admin>
</config>

And my controller :

<?php
include_once('Thatcompany/Module/controllers/Adminhtml/TheControllerName.php');

class Mycompany_MyModule_Adminhtml_TheControllerName extends Thatcompany_Module_Adminhtml_TheControllerName
{
    // [...]
}

Unfortunately, this is not working (I placed a big dirty die() in both index() actions, and the "Thatcompany" one displays instead of mine)

Any help, hint, link will be highly appreciated !


texts: how to reuse same images for multi products

texts:
I have a lot of the same simple products but with slight changes, so I use the same image for them all. and as many would know, in magento when you upload a product image you can't use it again for another, you have to re upload it again.  So it will produce a large number of duplicate images in the disk...

For example, I have 2 categories named C1 and C2. All products under C1 have same product images 1.jpg and 2.jpg.  And all products under C2 have same product images 3.jpg and 4.jpg. By the way, all the products are simple product.

Fed up of uploading the same product images over and over! Can some one help me? Thanks


texts: Base table or view not found: 1146 Table 'amazon_sales_order' doesn't exist

texts:
I'm using Magento 2.2.5 Cloud commerce version and at success page I'm getting following error

  2019-07-01T13:35:09+00:00 INFO (6): SQLSTATE[42S02]: Base table or
  view not found: 1146 Table 'm2.amazon_sales_order' doesn't exist,
  query was: SELECT main_table.*,
  extension_attribute_amazon_order_reference_id.amazon_order_reference_id
  AS
  extension_attribute_amazon_order_reference_id_amazon_order_reference_id,
  extension_attribute_amazon_order_reference_id.order_id AS
  extension_attribute_amazon_order_reference_id_order_id FROM
  sales_order AS main_table  LEFT JOIN amazon_sales_order AS
  extension_attribute_amazon_order_reference_id ON
  main_table.entity_id =
  extension_attribute_amazon_order_reference_id.order_id WHERE
  ((increment_id = '14000018349'))

I've checked database and amazon_sales_order isn't exist.

I can't update the Amazon module version nor Magento 2.

Does any have SQL Script to create this table? or any other solution?


texts:
I have an issue with a custom cron scheduling on Magento EE 2.1.4. I would like to run my crons every hour. I based my crontab.xml on the "index" cron group in my custom module. Below, my crontab.xml file:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Cron:etc/crontab.xsd">
    <group id="index">
        <job name="custom_geocoding" instance="Vendor\Module\Cron\Geo" method="execute">
            <schedule>* */1 * * *</schedule>
        </job>
         <job name="custom_sage_import" instance="Vendor\Module\Cron\SageImport" method="execute">
            <schedule>* */1 * * *</schedule>
        </job>
    </group>
</config>

My crons are executed every minute, what is the problem?


texts: magento 2 | Categories not showing in Admin Product Edit Page

texts:
I have started working with magento earlier this year, I am running magento CE 2.2.2

I have noticed that when I go back to edit a product from the catalog I have noticed that the categories are not listed.

I have checked the frontend and item visible in the category, the problem is in the backend, you can see the attachment image below.

Does anyone encounter the problem or know a solution that can be applied?

here you can see the categories I chose during product setup:

image url

but it is showing like this when I go to edit, which makes it impossible to edit categories:

image url


texts: How to get customerData in js uiComponent asynchronously?

texts:
This is the usual way to get customerData on frontend.

define([
    'uiComponent',
    'Magento_Customer/js/customer-data'
], function (Component, customerData) {
    'use strict';

    return Component.extend({
        initialize: function () {
            this._super();

            this.firstname = customerData.get('customer')().firstname;
        }
    });
});

Problem: oth the first load of the page, when mage-cache-storage in local storage is cleared, customerData.get('customer')().firstname returns undefined. And at this moment, request to server is sent, but js doesn't wait for the response, and the variable is undefined.

I guess it has to be done asynchronously. But how to do it correctly?

I have found these stack questions, but the solutions are the same as mine. Am I missing something?

How to call customerData js in phtml on a specific page after page load
Magento2 RequireJS CustomerData is empty at page load, but populated once page finishes loading?
GitHub: Magento_Customer/js/customer-data empty on the first page after login

Edit 1:

subscribe works, but it is executed after knockout.

var customer = customerData.get('customer');
customer.subscribe(function (customer) {
    console.log(customer.firstname);
}, this);


texts: Unable to access the PUT API service of Magento 2 through Python

texts:
I'm trying to update a particular product in Magento through PUT using python. I'm using OAuth1Service for authentication to Magento 2. GET products is actually giving me all the products in Magento where as PUT payload is not taking payload.

My payload is a JSON string

'''{
   "product": {
   "price": 1,
   "extension_attributes": {
   "stock_item": {"qty": 2}
   }
  }
}'''

My put request looks like this, the headers has the authentication token and the content type inside it.

payload = json.loads(product)
r = session.put(
'products/12345',
headers=headers,
data=json.dumps(payload),
)

Rather than taking the payload, it is giving me this error:


texts: Magento 1.9 onepage checkout stuck on billing information for downloadable/virtual products

texts:
I have Magento CE 1.9.2.2, and when I try to check out with ONLY downloadable and/or virtual products, my onepage checkout won't move past the billing information step. Clicking the continue button causes the text loading next step to appear for a moment, then the button comes back and no progress has been made.

In the google chrome console, a javascript error appears:
Uncaught TypeError: Cannot read property getElementsByTagName of null

and every time I click "continue", i get this in the console:
XHR finished loading: POST my-magento-site.org/checkout/process/verifyBilling/.

I get that second message in the console over and over when I click continue and the first message once when the page loads. The javascript error is coming from here, in my-magento-site.org/checkout/onepage/(index):

document.getElementById("shipping-buttons-container").getElementsByTagName("button")[0].onclick = qas_first_pass_shipping;

Though i don't know where this code is located in my site's source.

I have tried numerous solutions to similar questions I have found on this site (and others) but none have worked. Any help would be greatly appreciated.


texts:
I'm trying to override:

/vendor/magento/module-checkout/view/frontend/web/template/shipping.html

I made a copy in:

app/design/frontend/Vendor/Theme/Magento_Checkout/template/shipping.html

As explained in http://devdocs.magento.com/guides/v2.0/frontend-dev-guide/themes/theme-inherit.html

  The order is defined in the /view/frontend/templates/cart/minicart.phtml module template. The Blank theme does not override this template. OrangeCo decided they want the product list to be displayed before the Go to Checkout button. To do this, they need to add an overriding template for the corresponding module in the Orange theme folder: app/design/frontend/OrangeCo/orange/Magento_Checkout/templates/cart/minicart.phtml

I've flushed the cache and static files and it's not overriding. Any suggestions would be appreciated.


texts: Whatever happened to the Magento Community Engineering Slack?

texts:
At the M2 github page: https://github.com/magento/magento2/wiki/Slack-Channels

..there are a few links to https://opensource.magento.com that don't work:

Is that Slack community not active anymore, or is it now closed to outsiders?


texts: Getting Notice Notice: Use of undefined constant sales_flat_order_status_history - assumed 'sales_flat_order_status_history'

texts:
I have created below collection query in my custom external magento page--

<?php

$mageFilename = 'app/Mage.php';
require_once $mageFilename;
Mage::setIsDeveloperMode(true);
ini_set("display_errors", 1);
ini_set('max_execution_time', 3000);
umask(0);
Mage::init('default');
Mage::app();

$start_date='2016-03-01';
$end_date='2016-04-01';

$orderCollection=Mage::getModel('sales/order')->getCollection();
try{
    $orderCollection->getSelect()->join(array('order_history'=> sales_flat_order_status_history), "main_table.entity_id=order_history.parent_id WHERE (order_history.entity_name = 'invoice' OR order_history.entity_name = 'shipment') AND order_history.status = 'complete' AND order_history.created_at >= '".$start_date."' and order_history.created_at < '".$end_date."' ", array('order_history.parent_id'));
}
catch(Exception $e)
{
        echo $e->getMessage();
}

this query gives me following error--

Notice: Use of undefined constant sales_flat_order_status_history - assumed 'sales_flat_order_status_history'

I don't know, what wrong there ? Can anybody found out the problem there?
thanks in advance.


texts: Selected Simple Product as default on product grid

texts:
I have lots of group and simple products but I mostly search simple products to edit qty and price. I need to select 'Type - Simple Products' to be able to see only simple products on search result

How can I make the 'Type - Simple Products' is already selected as default on manage products grid?


texts: magento 2 : Add custom field in checkout payment page and save data to table

texts:
I am trying to add a custom field in the checkout page payment section.

I created field's with override LayoutProcessor using the plugin. Before place order button.

What is the next step of action to get that data and save to sales_order and quote table?


texts: How to create custom payment module in magento 2?

texts:
I want to get payment request in Test\Testpayment\Gateway\Request

Request.php

 namespace Test\Testpayment\Gateway\Request;
 use Magento\Payment\Gateway\ConfigInterface;
 use Magento\Payment\Gateway\Data\PaymentDataObjectInterface;
 use Magento\Payment\Gateway\Request\BuilderInterface;

  class PaymentDataBuilder implements BuilderInterface
  {
/**
 * @inheritdoc
 */
public function build(array $buildSubject)
{
    $paymentDO = $this->subjectReader->readPayment($buildSubject);
    $payment = $paymentDO->getPayment();
    $order = $paymentDO->getOrder();

    $result = [
        self::AMOUNT => $this->formatPrice($this->subjectReader->readAmount($buildSubject)),
        self::PAYMENT_METHOD_NONCE => $payment->getAdditionalInformation(
            DataAssignObserver::PAYMENT_METHOD_NONCE
        ),
        self::ORDER_ID => $order->getOrderIncrementId()
    ];

    $writer = new \Zend\Log\Writer\Stream(BP . '/var/log/nitesh.log');
    $logger = new \Zend\Log\Logger();
    $logger->addWriter($writer);
    $logger->info('data'.print_r($result, true));

    return $result;
 }
}

DataAssignObserver.php

 namespace Test\Testpayment\Observer;
 use Magento\Framework\Event\Observer;
 use Magento\Payment\Observer\AbstractDataAssignObserver;

 class DataAssignObserver extends AbstractDataAssignObserver
 {
  const PAYMENT_METHOD_NONCE = 'testpayment';

/**
 * @var array
 */
protected $additionalInformationList = [
    self::PAYMENT_METHOD_NONCE,
];

/**
 * @param Observer $observer
 * @return void
 */
public function execute(Observer $observer)
{
    $data = $this->readDataArgument($observer);

    $method = $this->readMethodArgument($observer);

    $paymentInfo = $method->getInfoInstance();

    $writer = new \Zend\Log\Writer\Stream(BP . '/var/log/nitesh.log');
    $logger = new \Zend\Log\Logger();
    $logger->addWriter($writer);
    $logger->info('data'.print_r($data, true));
    $logger->info('method'.print_r($data->getData(PaymentInterface::KEY_ADDITIONAL_DATA), true));
    die();

    $additionalData = $data->getData(PaymentInterface::KEY_ADDITIONAL_DATA);
    if (!is_array($additionalData)) {
        return;
    }

    $paymentInfo = $this->readPaymentModelArgument($observer);

    foreach ($this->additionalInformationList as $additionalInformationKey) {
        if (isset($additionalData[$additionalInformationKey])) {
            $paymentInfo->setAdditionalInformation(
                $additionalInformationKey,
                $additionalData[$additionalInformationKey]
            );
        }
    }
}

getting error on $data->getData(PaymentInterface::KEY_ADDITIONAL_DATA)

Observer/DataAssignObserver.php' on line 34","trace":"Trace is not available."

events.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Event/etc/events.xsd">
<event name="payment_method_assign_data_testpayment">
    <observer name="testpayment_gateway_data_assign" instance="Test\Testpayment\Observer\DataAssignObserver" />
</event>
</config>

I want to use PhonePe API

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://apps-uat.phonepe.com/v3/transaction/initiate");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, TRUE);
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
    'X-VERIFY: ' . $xVerify,
    'X-CLIENT-ID: ' . $payload['merchantId'],
    'Content-Type: application/json',
    'X-CALLBACK-URL: https://localhost/tnm/status.php'
));
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($request));
$data = curl_exec($ch);
curl_close($ch);


texts: How to show Qty left in Magento 2 Listing page?

texts:
I need to show Qty left message with qty of product in product detail page with below condition.
If the available stock is less than 'Notify for Quantity Below' parameter of each product.

And can we show same message in product detail page More Information tab?

I have set Only X left Threshold as 15 in Store -> Configuration->Catalog->Inventory

I need to show That Qty left message message only if it is less than this value.

How this can be checked and show.

Please anyone suggest me in this?


texts: Shopping Cart Price Rule: Spend $X Get SKU1 or SKU2 Free NOT Counting SKU1,2 in Total Spend

texts:
I've got a situation where if a user spends $40, they are eligible for either one free SKU1 or one free SKU2. The issue I am having when setting up the catalog price rule is that SKU1 or 2 in the cart is counting toward that $40.

I tried this but I think the SKU is not logic nullifies the action:

If ALL  of these conditions are TRUE :
    Subtotal  equals or greater than  40
    If total quantity  equals or greater than 1  for a subselection of items in cart matching ANY  of these conditions:
        SKU  is not  SKU1
        SKU  is not  SKU2

Any help would be nice!


texts: Security Patch SUPEE-8788 - Possible Problems?

texts:
The latest Magento 1 security patch SUPEE-8788 contains 17 APPSEC updates, so it is very important to apply it as soon as possible. On the other hand, there are many potential backward compatibility breaks, and given the history of patches over the last year I would not apply it carelessly.

Good thing is that this time there are no frontend templates involved, so it looks like we don't need to patch all our themes. This is only true for Magento 1.8 or higher.

Nonetheless: Did you encounter any compatibility problems or bugs after applying the patch?


texts: How to integrate Wordpress Post in Magento

texts:
I have two websites :

Wordpress
Magento

I know the plugin of fishpig but I want to know how I can still have my WP blog and showing the posts into my Magento ( CMS for example ).
Thanks for your answer


texts:
facing this issue:

  Fatal error: Namespace declaration statement has to be the very first
  statement or after any declare call in the script in
  /home/dukaania/public_html/testing2/app/code/Tutorial/SimpleNews/Controller/Adminhtml/News.php
  on line 3

Here's my code:

<?php

 namespace Tutorial\SimpleNews\Controller\Adminhtml;

 use \Magento\Framework\App\Action\Action;
 use Magento\Backend\App\Action\Context;
 use Magento\Framework\Registry;
 use Magento\Framework\View\Result\PageFactory;
 use Tutorial\SimpleNews\Model\NewsFactory;

 class News extends Action
{
 /**
 * Core registry
 *
 * @var \Magento\Framework\Registry
 */
      protected $_coreRegistry;

      protected $_resultPageFactory;

     /**
     * News model factory
       *
     * @var \Tutorial\SimpleNews\Model\NewsFactory
       */
     protected $_newsFactory;

 public function __construct(
Context $context,
Registry $coreRegistry,
PageFactory $resultPageFactory,
NewsFactory $newsFactory
  ) {
  parent::__construct($context);
      $this->_coreRegistry = $coreRegistry;
    $this->_resultPageFactory = $resultPageFactory;
   $this->_newsFactory = $newsFactory;
   }

 protected function _isAllowed()
     {
return $this->_authorization->isAllowed('Tutorial_SimpleNews::manage_news');
      }

public function execute()
 {
   /** @var \Magento\Backend\Model\View\Result\Page $resultPage */
     $resultPage = $this->_resultPageFactory->create();

  return $resultPage;
}

}


texts: I need to get ONIX data to my Magento ebook store. I could convert it into a format that Magento understands (i.e. CSV) and then use the default import. But at times the a single feed can have a few new books, a few updates. This can’t be achieved by the default Magento import. Do you guys have any suggestions about how I would go about this?


texts: Magento 2.3 - Can't change any settings in backend

texts:
EDIT: I noticed that I can't change any setting anymore! It just resets after save to the old value. No error message is shown.

Old Title: Theme does not change, even though database value changes
If I change the theme in Content -> Design -> Configuration

Then it always changes back to the old theme even though I can see that the value is changed in the database. (Table "core_config_data" -> path: "design/theme/theme_id")

If I reload the frontend, then it still loads the old theme though.

How can I fix this bug? I already cleared the cache with

php bin/magento cache:flush


texts: How to find file to customize content in product long description in magento 1.9.3

texts:
I am working on a project in which I will be adding product description in a tabular format to the product specification. But I could not find the file responsible.

I am using default Magento Theme. I am able to find the product page at app\design\frontend\rwd\default\template\catalog\product\view.phtml but it doesn't contain any code for making changes in the Long description of the product.


texts: Where is the const CONFIG_KEY_PRODUCT_TYPES defined Magento2

texts:
Where is this defined? in Which config xml file?

const CONFIG_KEY_PRODUCT_TYPES = 'global/importexport/import_product_types';


texts: Prepare custom collection for admin grid

texts:
I have created custom collection for my data and now I want to display the data in the admin grid using collection.Can you please help me out ?
Here is my code.

      $connection = Mage::getSingleton('core/resource')->getConnection('core_read');
      $sql = "Select * from TABLE_NAME";
      $rows = $connection->fetchAll($sql);
      $data = new Varien_Object();
      $data->setData($rows);

      $collection_of_things = new Varien_Data_Collection();
      $collection_of_things->addItem($data);
      $this->setCollection($collection_of_things);
      return parent::_prepareCollection();

I am getting the blank admin grid for it.

Here is my _prepareColumns function

protected function _prepareColumns() {

      $this->addColumn('Field 1', array(
          'header'    => 'ID',
          'align'     =>'center',
          'width'     => '10px',
          'index'     => 'field_1'
      ));
      $this->addColumn('field_2', array(
          'header'    => 'Field 2',
          'align'     =>'left',
          'width'     => '50px',
          'index'     => 'field_2'
      ));
      $this->addColumn('field_3', array(
          'header'    => 'Field 3',
          'align'     =>'left',
          'width'     => '50px',
          'index'     => 'field_3'
      ));
      $this->addColumn('field_4', array(
          'header'    => 'Field 4',
          'align'     =>'left',
          'width'     => '50px',
          'index'     => 'field_4',
          'filter_index' => 'field_4',
          'type' => 'datetime'
      ));
      $this->addColumn('field_5', array(
          'header'    => 'Field 5',
          'align'     =>'center',
          'width'     => '50px',
          'index'     => null,
          'renderer'      => 'Namespace_MyModule_Block_Adminhtml_Template_Grid_Renderer_Image',
          'sortable'    => false,
          'filter' => false,
          'is_system'   => true
      ));
      $this->addExportType('*/*/exportCsv', 'CSV');
      return parent::_prepareColumns();
    }


texts: How to get parent product collection from child product collection

texts:
I have a simple product collection and I want to get a collection of parent products from the child product collection.

$child_collection = Mage::getResourceModel('catalog/product_collection')
    ->addAttributeToFilter('custom_attribute',array('eq'=>'value'));

How can I get the parent product collection from this child products collection?


texts:
How to check if product is a bundle in the checkout_cart_add_product_complete event?

I want to redirect the page after adding to the cart when the product is bundled.


texts: magento2: Creating custom Rest API POST method

texts:
I know how to create APIs with GET method, wondering how to create custom REST API with POST Method ??..

I have spend enough time into core module but didn't get anything from there(May be I am not understanding) so is there anybody who have some Idea about this..

How can we pass & get the confidential data from POST method in REST API ??


texts:
I SSH the patch - Authorize.net Direct Post Signature Key patch - PATCH_SUPEE-11085_CE_1.14.4.0_v1-2019-02-28-05-21-55.sh and it was successful then following the directions here

I entered my security key and saved it successfully. I then went to make a purchase and when I select "Place Order" at the end all that happens is that the page flashes. I don't get any errors. I don't know whats wrong. I contacted Authorize.net and they said to contact Magento.

Authorize.net Direct Post transaction key update (MD5 to SHA-512)

I am already using Authorize.net Do I have to do anything? I am not using Authorize.net Direct Post in Magento’s backend. The patch is misleading making me think I have to switch over but I read if you are using Authorize.net you don't have to switch to Authorize.net Direct Post in Magento's backend. Can someone give some clarity to this?


texts:
If i didn't put an image in a child product that is linked to a
configurable that it would only show the image in the parent product,
it is  showing the placeholder. How do I stop this from happening?


texts: Magento2 How to set pretty url for advance search

texts:
i need to change the url patter in advance search in magento2 like : catalogsearch/advanced/result/name/simple/ in default is gives the as query string but i need to change this.

how can i do this ?

can any one suggest the better solution for this ?

thanks in advance for your suggestion.


texts: How to Copy Code/Core system.xml file into Code/local in magento

texts:
i wanted some customization in admin panel so i have made changes in

   1) "app/code/core/../system.xml file its working fine.

But I don't want to change code inside core folder. Because of my version change.

So i like to move that  file into my local folder but its not working

 2) "app/code/local/../system.xml" files is not working

Can anyone please guide me how to override system.xml file?

Thanks


texts: Magento 2 - using CSS calc in LESS doesn't appear to work

texts:
I'm tring to add a gradient shadow to the edges of my pages using css which works using inspector features etc.

However when I add the following code "left: -webkit-calc(50% - 769px);"
to the _extend LESS file in my custom theme, after compilation it changes it to "left: -webkit-calc(-719%);"

No idea where to start with this could it be a bug in the compilation?

Thanks


texts: Mage_ImportExport: Why is the import of custom option type "file" disabled?

texts:
In Mage_ImportExport_Model_Import_Entity_Product::_saveCustomOptions the custom option type "file" is commented out in product import. If you uncomment it and change 'image_size_x'   => 0, to 'image_size_x'   => null, and 'image_size_y'   => 0, to 'image_size_y'   => null, below (following http://www.magentocommerce.com/boards/viewthread/275362/), you can reenable it. I just tested it successfully and was able to import custom options of type "file".

Does anyone know why this isn't enabled by default?


texts: Strategery - InfiniteScroll Not Working in in magento 1.8.1 and where to paste strategery-infinitescroll.xml file

texts:
Am download the Strategery - InfiniteScroll and installed in my store.

(I'm just copy and paste the files to my store).
1st i got a error like

  Fatal error: Class 'Mage_ConfigurableSwatches_Helper_Mediafallback' not found in /home/mwinwm/public_html/includes/src/Etheme_Coolbabyconfig_Helper_ConfigurableSwatches_Mediafallback.php on line 8

Then am asking the query in stackoverflow that link here Magento 1.8 "Load More Product" Button Not working

After that i got the answer to clear the error. I just command the lines in app/design/frontend/base/default/layout/strategery-infinitescroll.xml

<!--<reference name="product_list.name.after">
            <block type="core/template" name="product_list.infinitescroll" template="strategery/infinitescroll/swatches.phtml"/>
    </reference>-->

But still now product not loaded in list page. i refer this link https://github.com/Strategery-Inc/Magento-InfiniteScroll/wiki/Installation-under-a-different-package---theme but am not understand.

Am using coolbaby theme. Where i want to paste strategery-infinitescroll.xml
app/design/frontend/base/default/layout/ or app/design/frontend/coolbaby/default/layout


texts:
I was asked how to save all the magento media assets in Amazon S3. I thought about using a PHP Stream Wrapper like this one: https://github.com/punkave/aS3StreamWrapper and just set the media folder to s3:\mybucket\mediaFolder

Does anyone has experience with this?

Or better use something like this: https://github.com/sstoiana/magento-s3
But this extension doesn't look good. Any other recommendations?


texts: Magento 2 Training Overriding a core class

texts:
I'm trying to implement a basic m2 class override following the M2 Fundamentals Course and it is not working.  Here is what I have in my Training/Test/etc/di.xml

<?xml version="1.0"?>
<!--
/**
 * Copyright © 2015 Magento. All rights reserved.
 * See COPYING.txt for license details.
 */
-->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">

<preference for="Magento\Catalog\Model\Product" type="Training\Test\Model\Testproduct" />

</config>

And inside the Training\Test\Model\Testproduct.php

<?php
namespace Training\Test\Model;

class Testproduct extends \Magento\Catalog\Model\Product
{

 public function getPrice() {
    return 3;
 }
}

I understand it's better to do plugins / events, but my question is why is the above not working?

The module is installed and I also ran the following:

php bin/magento cache:flush
rm -Rf var/cache/*
rm -Rf var/di/
rm -Rf var/generation/*
rm -Rf var/page_cache/*
php bin/magento setup:di:compile

It also shows when runnning:
    php bin/magento module:status

List of enabled modules:
...
Training_Test


texts: Get downloadable product link details added in cart

texts:
I have ques.

I want to get downloadable products link added in cart..

Mean I want total links added in cart

I have used below code..

I am developing functionality to auto discount if downloadable products links are more than 2 in cart.

I created event

    <?xml version="1.0"?>
<config>
  <modules>
    <Manoj_AutoDiscount>
      <version>0.1.0</version>
    </Manoj_AutoDiscount>
  </modules>
  <global>
    <models>
      <checkout>
        <rewrite>
          <observer>Manoj_AutoDiscount_Model_Observer</observer>
        </rewrite>
      </checkout>
    </models>
    <events>
      <checkout_cart_add_product_complete>
        <observers>
          <checkoutApplyCouponToProduct>
            <type>singleton</type>
            <class>Manoj_AutoDiscount_Model_Observer</class>
            <method>applyAutoDiscount</method>
          </checkoutApplyCouponToProduct>
        </observers>
      </checkout_cart_add_product_complete>
      <sales_order_place_after>
        <observers>
          <checkoutRemoveCouponAuto>
            <type>singleton</type>
            <class>Manoj_AutoDiscount_Model_Observer</class>
            <method>removeAutoDiscount</method>
          </checkoutRemoveCouponAuto>
        </observers>
      </sales_order_place_after>
    </events>
  </global>
</config>

and below method in observer

class Manoj_AutoDiscount_Model_Observer
{
    public function applyAutoDiscount($observer)
    {

$items =Mage::getSingleton('checkout/session')->getQuote()->getAllItems();
        foreach($items as $item) {
            $_links = $item->getProduct()->getTypeInstance(true)->getLinks($item->getProduct());
echo count($_links)

            foreach ($_links as $link) {
                   // echo "
Link ids".$linkId = $link->getLinkId();echo "
";

            }
        }
}
}

Here I am getting all link of downloadable products.
I need only links added in cart only..
e.g  products has 3 links
and we added only 2 links in cart then i want record of 2 links only not of  3.

Can you please provide solution for same..
Appreciate your help..

Thanks in adavnce

Manoj Ninave


texts:
In my home page we have Buy 2 @ 222 , Buy 4 @ 444 , Buy 6 @ 666 . all these links will point to one page. On that page we can have
1.
2.
3.
4

Options based on Buy 6@666 , Lets assume when user selected Buy 4 @666 then 4 rows will be populated with "Select Your Products". When user clicks on Select your products then it will redirect again user to Buy6@666 category page where user can pick 3 to 4 products to the cart and the user can complete the checkout process.
When i researched more on this functionality no module suits up with this. Do any one have a module or functionality or idea on how it can be achieved.


texts: Magento2 CSS was blocked due to MIME type mismatch (X-Content-Type-Options: nosniff)

texts:
I am using Magento 2 in Windows 10 using xampp.

I have installed magento2 and it was running perfectly. After that, I migrate data from magento1 with migration tool.

Now I am having an error with the resource from “
(CSS path)” was blocked due to MIME type mismatch (X-Content-Type-Options: nosniff).

Already tried to deploy static content many times with cache and index refresh. URL rewrite is already ON.

Can anyone please help me out?

Thanks


texts: How find low stock products to add to a 'special offers' category

texts:
Is there a way to find all low stock products and add them, or a manually selected subset of them, to a category, so that I can market low stock products?
When creating or editing a category, I can search for products to add by 'name', 'sku', or 'price', but I can't search by stock.
On the product grid page, I can search by stock, but when I have found the products, I can't then bulk add them to a particular category.
In M1 I've seen an extension to add a stock column to the "category products" grid and I'm working on an extension to do this in M2, but I was hoping that there was already some way to achieve this out of the box.


texts: How to make arrow visible for all the time on Slider banner

texts:
I want to use fontawesome icon for arrow on my Slider banner for Next & Previous. What code I have to use for Magento 2.1.1? Can anyone please help
thanks me.


texts: reset form fields in billing form - onepage checkout

texts:
I already implemented this with success.
My only problem now is to reset also the input fields. For example the user logs in checks out his order. He gets to the billing page, where his data is already predefined within the fields (name, first name, email and so on). I don't need an extra shipping address step, so the billing info = shipping info. When the user now decides to ship to another address he should be able to clear all fields by clicking a clear button

I tried several approaches. Most of them worked as fiddle but when I'm trying to use them with magento, they won't work.

In the billing.phtml I added a button on the bottom via

<button type="button" onclick="clearFields()" title="Clear" id="form_clear">Clear</button>

The javascript function I added to the bottom of the file:

function clearFields() {
   // several approaches tested, nothing worked
};

fiddle example 1
fiddle example 2

Is there anybody who has already done this and got this working? I guess this is not very complicated, but I don't see anything anymore.

###### update

I couldn't get either solution to work. jquery is loaded. What I have now is the following in billing.phtml in the script part at the bottom.

var billing = new Billing('co-billing-form', '<?php echo $this->getUrl('checkout/onepage/getAddress') ?>address/', '<?php echo $this->getUrl('checkout/onepage/saveBilling') ?>');
 var billingForm = new VarienForm('co-billing-form');
.
.
.
// my code
$('suggestform_clear').observe('click', function(){
  billingForm.validator.reset();
  // alert($('co-billing-form'));
  // console.log('test');
}.bind(billingForm));

This code works. It's resetting the validation when I click the button. But still no chance to reset the input fields. If don't use default template. Maybe the problem is that I use an extension with my own inputfields, but it shouldn't make a difference because they are built the same way as the default inputfields.

Example: <input type="text" id="billing:aitoc_checkout_968 " class=" required-entry form-control input-text" name="billing[aitoc_checkout_968]" value="test test">


texts: Magento CE 1.9.1 not using cron for sending emails

texts:
I recently upgraded from Magento CE 1.9.0.1 to 1.9.1.

I read that emails are supposed to be sent via a queue/cron but after some testing this turned out to not be true.

When I place an order the email is sent immediately, just like before upgrading to 1.9.1.

I put some Mage::log() statements in Mage_Core_Model_Email_Queue::send() to verify. The method is being executed via cron every minute, but no messages are ever present in the queue to be processed.

My question is this: Do I need to enable some setting somewhere or did I miss anything?


texts: Can't select cms page/blog or product/category widget

texts:
I realy hope you can help me with this...

I have installed a brand new Magento at GoDaddy. Everything but Widgets works fine...

The button that should appear in Plugin Detail are simply missing.

No matters which browser i'm using. The only way I can made this button shows up was importing a magento's instalation (1.8.1.1) from another server.

I've tryed with CE 1.9.2.2 and CE 1.9.1.0, both without success

Nothing in console.

What do you guys think? Have you ever seen this problem before?

system.log

2015-11-21T00:04:05+00:00 DEBUG (7): HEADERS ALREADY SENT: <pre>[0] /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Response/Http.php:52
[1] /home/myhappyface/public_html/loja/lib/Zend/Controller/Response/Abstract.php:768
[2] /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Response/Http.php:84
[3] /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Varien/Front.php:184
[4] /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/App.php:365
[5] /home/myhappyface/public_html/loja/app/Mage.php:684
[6] /home/myhappyface/public_html/loja/index.php:83
</pre>

exception.log

2015-11-22T16:00:50+00:00 ERR (3):
exception 'Mage_Core_Exception' with message 'Tipo de bloco inválido: Mage_Dynamicslideshow_Block_List' in /home/myhappyface/public_html/loja/app/Mage.php:595
Stack trace:
#0 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/Layout.php(495): Mage::throwException('Tipo de bloco i...')
#1 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/Layout.php(437): Mage_Core_Model_Layout->_getBlockInstance('dynamicslidesho...', Array)
#2 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/Layout.php(472): Mage_Core_Model_Layout->createBlock('dynamicslidesho...', 'dynamicslidesho...')
#3 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/Layout.php(239): Mage_Core_Model_Layout->addBlock('dynamicslidesho...', 'dynamicslidesho...')
#4 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/Layout.php(205): Mage_Core_Model_Layout->_generateBlock(Object(Mage_Core_Model_Layout_Element), Object(Mage_Core_Model_Layout_Element))
#5 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#6 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Varien/Action.php(344): Mage_Core_Model_Layout->generateBlocks()
#7 /home/myhappyface/public_html/loja/app/code/core/Mage/Cms/Helper/Page.php(113): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#8 /home/myhappyface/public_html/loja/app/code/core/Mage/Cms/Helper/Page.php(52): Mage_Cms_Helper_Page->_renderPage(Object(Mage_Cms_IndexController), 'home')
#9 /home/myhappyface/public_html/loja/app/code/core/Mage/Cms/controllers/IndexController.php(45): Mage_Cms_Helper_Page->renderPage(Object(Mage_Cms_IndexController), 'home')
#10 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Varien/Action.php(418): Mage_Cms_IndexController->indexAction()
#11 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('index')
#12 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Controller/Varien/Front.php(172): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#13 /home/myhappyface/public_html/loja/app/code/core/Mage/Core/Model/App.php(365): Mage_Core_Controller_Varien_Front->dispatch()
#14 /home/myhappyface/public_html/loja/app/Mage.php(684): Mage_Core_Model_App->run(Array)
#15 /home/myhappyface/public_html/loja/index.php(83): Mage::run('', 'store')
#16 {main}


texts: How to Get Product Image data in Order API Magento 2?

texts:
Get /V1/orders/{id}

This API Returns information for the order for a specified customer.
How to get Order Item Images


texts:
I would like to know how we can control the cache lifetime on a collection.

Here's how I initialize caching on my collection:

public function _construct()
{
    ...

    // Configure collection cache
    $this->initCache(
        Mage::app()->getCacheInstance(),
        'MY_COLLECTION',
        array(Namespace_Module_Model_Something::CACHE_TAG)
    );
    parent::_construct();
}

Where the cache instance comes from Mage_Core_Model_Cache. I can see how its frontend model is created out of Zend_Cache_Core -- whose class provides a cache lifetime setter. But this does not appear to solve my problem.

I'm using APC caching on the backend, and that's what I want to modify when the cache entry is written. And I'd like to be able to control this per collection (as in the constructor shown above).

Is this possible?


texts: Magento 2 - Error the specified key does not exist on Amazon aws cdn

texts:
We have created an account in amazon Aws.

We have replace the secure base url for static and media files with the domain name that is shown in the AWS distribution.

The site is not showing correctly and also the images is not showing.

My website is developed in magento 2.2.2


texts:
I have an extension on which I would like to change a few sentences and I do not want to do that in core files, since those will be overwritten on next update.

I already tried to put files into: app/design/frontend/<vendor>/<theme>/<extension_vendor>_<extension_name>/i18n/en_US.csv and it's not working, but if I change the original .csv file, it does work.

Is it possible to only change the specific extension's i18n file (and where to put it) or must I follow this answer: https://magento.stackexchange.com/a/160688/52640 ?

Magento CE v2.2.3
Extension: Amasty Out of Stock Notification v1.9.2 CE


texts: Magento 1.7 minimum qty allowed and configurable products

texts:
I'm sort of at a loss on this one. I changed the 'Minimum Qty Allowed' setting in the admin and now I don't see the add 2 cart button for any products. I think it's just configurable products that this affected.

EDIT: I deleted the minimum qty allowed rule and it's still showing no 'add to cart' button.
Also, manage stock is set to 'No'

I can't seem to figure out why this is or what to do about it. Any ideas?


texts: Magento how to change action url of contact page

texts:
I add contact form in CMS page using this code -

   <form class="form contact"
  action="<?= $block->escapeUrl($block->getFormAction()) ?>"
  id="contact-form"
  method="post"
  data-hasrequired="<?= $block->escapeHtmlAttr(__('* Required Fields')) ?>"
  data-mage-init='{"validation":{}}'>
<fieldset class="fieldset">
    <legend class="legend"><?= $block->escapeHtml(__('Write Us')) ?></legend>

<?= $block->escapeHtml(__('Jot us a note and we’ll get back to you as quickly as possible.')) ?>

        <?= $block->escapeHtml(__('Name')) ?>

            <input name="name" id="name" title="<?= $block->escapeHtmlAttr(__('Name')) ?>" value="<?= $block->escapeHtmlAttr($this->helper('Magento\Contact\Helper\Data')->getPostValue('name') ?: $this->helper('Magento\Contact\Helper\Data')->getUserName()) ?>" class="input-text" type="text" data-validate="{required:true}"/>

        <?= $block->escapeHtml(__('Email')) ?>

            <input name="email" id="email" title="<?= $block->escapeHtmlAttr(__('Email')) ?>" value="<?= $block->escapeHtmlAttr($this->helper('Magento\Contact\Helper\Data')->getPostValue('email') ?: $this->helper('Magento\Contact\Helper\Data')->getUserEmail()) ?>" class="input-text" type="email" data-validate="{required:true, 'validate-email':true}"/>

        <?= $block->escapeHtml(__('Phone Number')) ?>

            <input name="telephone" id="telephone" title="<?= $block->escapeHtmlAttr(__('Phone Number')) ?>" value="<?= $block->escapeHtmlAttr($this->helper('Magento\Contact\Helper\Data')->getPostValue('telephone')) ?>" class="input-text" type="text" />

        <?= $block->escapeHtml(__('What’s on your mind?')) ?>

            <textarea name="comment" id="comment" title="<?= $block->escapeHtmlAttr(__('What’s on your mind?')) ?>" class="input-text" cols="5" rows="3" data-validate="{required:true}"><?= $block->escapeHtml($this->helper('Magento\Contact\Helper\Data')->getPostValue('comment')) ?></textarea>

    <?= $block->getChildHtml('form.additional.info') ?>
</fieldset>

        <input type="hidden" name="hideit" id="hideit" value="" />
        <button type="submit" title="<?= $block->escapeHtmlAttr(__('Submit')) ?>" class="action submit primary">
            <?= $block->escapeHtml(__('Submit')) ?>
        </button>

How to change action url of contact page.It transfer localhost/sanjeev/contacts/index/
I show contact form in footer section without action redirection other page.


texts: How to get the value of custom product attribute in order item

texts:
I am able to get the values of custom product attribute in the cart and checkout page.
Using the code below

<group name="quote_item">
    <attribute name="ts_dimensions_height"/>
    <attribute name="ts_dimensions_length"/>
    <attribute name="ts_dimensions_width"/>
</group>

In this file VendorName/ModuleName/etc/catalog_attributes.xml

I wanted to get the custom product attribute value from the ordered item after the order placed event.


texts: magento 2 estimate shipping and tax disappeard

texts:
After some updates and an installation of myparcel module for some reason my "estimate shipping and tax" disappeard in cart.

How can i enable it again?


texts: Magento 2. Retrieve information from env.php in the js files programmatically

texts: I'd like to read and use the information stored in my env.php to my js files. Is there an entity that I can use to fix this?


texts: how to avoid to create customer account when payment failed with guest checkout

texts: Currently if customer transaction failed due to some credit card error then customer account is being created. How to auto delete if order failed?


texts: Magento 2 link youtube videos to products

texts:
I know in Magento 2.3, we can able to link youtube videos with products. At the end of the youtube video, I can see the suggested video thumbnails in it.

Is there any way to remove the suggested videos thumbnail at the end of the youtube video?


texts: Magento 1 - Hide products from customers

texts:
We have a problem with the visibility. We need to add some new configurable products, but the customers should not be able to see them, until we finished testing them.

How are we supposed to do this the right way?

My idea is to create a new category which is not showing in the menu, and set the URL to something cryptic like hidden_new_products_2020 so that nobody will find it, and in the product set the visibility to "Catalog" so that it does not show in the search.

But is this the official way or is there a better approach?

It would be best, if we could create the products on our non public staging (clone) shop and then just export the products and import them to our live shop. But this does not seem to be possible.


texts: Magento SEO implement rel="prev" and rel="next" meta tags

texts:
I'm attempting to improve SEO for my product catalog by implementing the <link rel='next' href='..'> and <link rel='prev' href='..'> head meta tags for catalog pages with several pages of items.

After searching around quite a bit, I found the following solution [Source] but no way to accomplish the same task in Magento 2.

How can I accomplish the same thing in Magento 2?

$actionName = $this->getAction()->getFullActionName();
if ($actionName == 'catalog_category_view') // Category Page
{
    $category = Mage::registry('current_category');
    $prodCol = $category->getProductCollection()->addAttributeToFilter('status', 1)->addAttributeToFilter('visibility', array('in' => array(Mage_Catalog_Model_Product_Visibility::VISIBILITY_IN_CATALOG, Mage_Catalog_Model_Product_Visibility::VISIBILITY_BOTH)));
    $tool = $this->getLayout()->createBlock('page/html_pager')->setLimit($this->getLayout()->createBlock('catalog/product_list_toolbar')->getLimit())->setCollection($prodCol);
    $linkPrev = false;
    $linkNext = false;
    if ($tool->getCollection()->getSelectCountSql()) {
        if ($tool->getLastPageNum() > 1) {
            if (!$tool->isFirstPage()) {
                $linkPrev = true;
                if ($tool->getCurrentPage() == 2) {
                    $url = explode('?', $tool->getPreviousPageUrl());
                    $prevUrl = @$url[0];
                }
                else {
                    $prevUrl = $tool->getPreviousPageUrl();
                }
            }
            if (!$tool->isLastPage()) {
                $linkNext = true;
                $nextUrl = $tool->getNextPageUrl();
            }
        }
    }
    if ($linkPrev) echo '<link rel="prev" href="' . $prevUrl . '" />';
    if ($linkNext) echo '<link rel="next" href="' . $nextUrl . '" />';
}


texts: Installed version 1.9.1 - "Sitemap" menu option missing

texts:
I've just updated Magento to version 1.9.1 and I cannot find the sitemap menu. I was on version 1.9.0.1 previously and it was located at:

Top menu - Catalog - Google Sitemap

but that option just simply isn't there any more. Is this an error with my installation/upgrade or has it been removed or moved?

Could someone who is also using 1.9.1 check if they have the menu option please?

Thanks in advance!


texts:
I need to update some elements/variables of my wsdl output. For example I want to change "shipping_amount" so it gives me the amount incl. tax and not (as it is now) without tax:

<complexType name="salesOrderEntity">
   <all>
      ...
      <element name="shipping_amount" type="xsd:string" minOccurs="0" />
      ...
   </all>
</complexType>

Same goes for the element "price". I want to edit it so it gives me the amount incl. tax.

<complexType name="salesOrderItemEntity">
   <all>
      ...
      <element name="price" type="xsd:string" minOccurs="0" />
      ...
   </all>
</complexType>

In what file is this element "built" or retrieved so i can edit the output of it? The elements I am talking about are found in:

  app/code/core/Mage/Sales/etc/wsdl.xml


texts: Display all atrribute sets as a dropdown list in a static block.Then selecting one, display all the products from corresponding attribute set


texts: How to call one module inside other module in magento admin panel?

texts: how to put "news" module inside "Entry" Module. ?


texts: Is it possible to refund discount coupon?

texts:
Is it possible to "refund" discount coupon in case if order is cancelled via admin?

I'll describe in more detail.

Discount code created and set at

  "Marketing" => "cart price rules"

and

  "uses per coupon" == 1

for customer. Customer placed order and used that discount code.
Then admin make this order cancelled. But discount code isn't available nevertheless customer actually didn't use that coupon.


texts: observer.php won't work after magento local to live migration

texts:
i have this Observer.php file in app/code/local/Moh3n/Attvaluecopier/model to copy a product attribute value into another product  attribute on product save:

<?php

class Moh3n_Attvaluecopier_Model_Observer
{

public function  copyAttribute($observer){

    if(!$this->_processFlag):

        $this->_processFlag=true;
        $_product = $observer->getProduct();
        $_productid = $_product->getId();
        $productModel = Mage::getModel('catalog/product');
        $loadCurrentProduct = $productModel->load($_productid);
        $loadCurrentProduct->setGeneralWeight(intval($loadCurrentProduct->getWeight()));
        $weight = intval($loadCurrentProduct->getWeight());
        $gw = (string)$weight. " KG";
        $loadCurrentProduct->setGeneralWeight($gw);
        $loadCurrentProduct->save();
        endif;}
    }

i created Moh3n_Attvaluecopier.xml file in app/etc/modules with this content:

<?xml version="1.0"?>
<config>
    <modules>
        <Moh3n_Attvaluecopier>
            <active>true</active>
            <codePool>local</codePool>
        </Moh3n_Attvaluecopier>
    </modules>
</config>

and config.xml file in app/code/local/Moh3n/Attvaluecopier/etc with this content:

<?xml version="1.0"?>
<config>
    <modules>
        <Moh3n_Attvaluecopier>
            <version>0.0.1</version>
        </Moh3n_Attvaluecopier>
    </modules>
    <global>
        <models>
            <moh3nattvaluecopier>
                <class>Attvaluecopier_Model</class>
            </moh3nattvaluecopier>
        </models>
        <events>
            <catalog_product_save_after>
                <observers>
                    <moh3n_attvaluecopier_model_observer>
                        <type>singleton</type>
                        <class>Moh3n_Attvaluecopier_Model_Observer</class>
                        <method>copyAttribute</method>
                    </moh3n_attvaluecopier_model_observer>
                </observers>
            </catalog_product_save_after>
        </events>
    </global>
</config>

full extension link: How to copy a product's attributes value to another attribute?

it was working fine on localserver but after i migrated magento from local to online server it wont work. no error, no log. it wont copy the value.


texts:
i want to ask my site is not updating with out cleaning cache. after any changes i have to clear the cache before it was not like that

i already try to disable cache the it's work but after disable cache my site is taking to much time to open

for example

if i change title from
32" led {model}
32 inch led {model}

it will not take effect until i didn't clear the cache


texts: Plugin to request combined shipping rate before processing payment

texts: I'm looking for a plugin where the buyer can add all of the items into their cart and request a manual combined shipping rate before processing their payment. I need to be able to manually adjust the shipping rate, yet have the order marked as "pending" so that way the buyer's items aren't sold to someone else in the process.