texts:
This is a bit of strange thing I've noticed.

My Category Sort Order is set to "position". For all categories.

Though, what happens is this:

If multiple products have the same "position" setting, instead of just sorting by product ID as it should, this is what happens:

First product will be the one with the lowest ID, eg: 348.
The rest all are sorted in a descending order starting with the product with the highest ID.

So After 348, the next product I have has an ID of 360, and then 359, 358, 357, and so on.

How does Magento actually decide which order to place the items in?

Why I need this:

I have "Next" / "Prev" Buttons on my product view page to allow a user to scroll through to the next product without going back to the category list.

And I'm sorting the products for the next/prev buttons using:

$order = Mage::getStoreConfig('catalog/frontend/default_sort_by');
$direction = 'asc';
$category_products = $cat->getProductCollection()->addAttributeToSort($order);

Which doesn't match that order as this code goes 348, 349, 350 etc.

Now I know I can just go and edit all the "position" values but I'm still curious as to why this happens.

Specific Questions:

How is Category Sort Order decided?
Where is this code?


texts: Add multiple products in single API call in magento2

texts:
I have to migrate data from RMS to magento. There are thousands of records that needs to be migrated. I am using REST API to save product.

http://localhost:89/index.php/rest/all/V1/products

This is the API url to add prduct.

    {
  "product": {
        "sku": "B201-SKU",
        "name": "B202",
        "price": 30.00,
        "status": 1,
        "type_id": "simple",
        "attribute_set_id":4,
        "weight": 1
    }
}

This is the sample payload. Is it possible to pass multiple product information to this request. If yes, please provide some example.

Thanks
Jawed


texts: Change "Manage_Stock" via REST API on Magento 2

texts:
Using Magento 2, I'm trying to change Manage Stock attribute via rest API however does not seem to work via both the stockItems endpoint or the product one. Updating quantity seems to work fine.
Tried like below initially:
    $url = "https://www.magestore.com/rest/all/V1/products/" . $sku;
    $post_data = array(
        'product' =>
        array(
            'sku' => $sku,
            'extension_attributes' =>
                array(
                    "stock_item" => array(
                        "qty" => $qty,
                        "is_in_stock" => $is_in_stock,
                        "manage_stock" => true
                    )
                )
            )
        );

Then tried like this for the stockItems endpoint:
    $url = "https://www.magestores.com/rest/V1/products/" . $sku . "/stockItems/1";
    $post_data = array(
        "stock_item" => array(
                "qty" => $qty,
                "is_in_stock" => $is_in_stock,
                "manage_stock" => true
            )
        );

However neither seem to change manage stock to true for me, is this possible to achieve with Rest API?


texts: this's content of page. but it not show on front-end.


texts:
When we try to login to admin it shows fatal error. So is there any solution for this problem?

Fatal error:

  Access to undeclared static property: Mage::$_isDeveloperMode in /home/mominaslib/public_html/app/Mage.php on line 881


texts: composer update --no-dev made website super slow

texts:
Im new to Magento 2.3,

first I had an issue installing anything through composer because it was saying that my php 7.3 doesnt meet requirements which is 7.1 or 7.2. My php actually 7.1, so I don't know how it was reading 7.3, anyways I went and edit composer.json and added:

"platform": {
             "php": "7.1.25"
    },

That helped and I was able to install all applications that require composer. After I went to extension manager and decided to install another application through marketplace and got a Readiness Red mark about dependencies issue, obviously because I edit my composer file. So somewhere I read that I should do

  composer update --no-dev

, I know stupid and even though after I did

  composer update

and everything was installed again, my website became super slow, can't open extension manager anymore. Please help me fix it.


texts: Magento 2 with Porto theme customization

texts:
I'm totally new to Magento... I have been working on a theme called Porto for Magento 2... I have manage to modify many things that I required but cannot seems to modify the highlighted part.

Please can anyone help me from where in magento admin I can edit that area?


texts: Magento2.2 refused to apply css because its MIME type ('text/html') not supported

texts:
Magento2.2 apache php7 server I moved the website from a Nginx server to this apache2 server. cleared cache, the magento is in default mode still so no need to re-deploy.

However now i get an error that says

Refused to apply style from 'pub/static/frontend/Smartwave/porto_child/en_US/css/styles-m.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.

Refused to apply style from ' pub/static/frontend/Smartwave/porto_child/en_US/css/styles-l.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.

I already did a chmod -R 777 * in the website directory and also a chown -R ubuntu:ubuntu on the directory for the site site. so not sure what else needs to be done to fix this?


texts:
I have an array with 3 categories names:

$arr = ['onecat','twocat','threecat'];

How can I get the IDs from this categories? For example in other array.


texts: Magento 2: How to query data in Observer?

texts: As title said, i want to query the data from custom table in Observer file. How to do it?


texts:
I need to upgrade a Magento instance from v2.3.0 to v2.3.5 later this month.

I'm wondering if I need to upgrade to v2.3.1 and run setup:upgrade first,
and then repeat for v2.3.2, v2.3.3, v2.3.4 before upgrading to v2.3.5?

Or can I upgrade directly from v2.3.0 to v2.3.5?

composer require magento/product-community-edition=2.3.5 --update-with-all-dependencies
bin/magento setup:upgrade


texts:
I've patch a Magento version 1.9.2.4 with the SUPEE-10415 patch and I can no longer add or remove items from the basket, previous branches without the patch all work fine.

It seems to be the unserialising of the data that causes the issues as stepping through the code with a debugger shows that it fails when a null type is passed to the Unserialize_Parser.

It throws an exception 'Unsupported data type N' from within lib/Unserialize/Reader/ArrValue.php on line 88

I've got around it by adding an Unserialize_Reader_Null class file to the \lib\Unserialize\Reader directory with a read method, and a TYPE_NULL constant to the Unserialize_Parser, plus I'm now additionally checking for the null value in the Unserialize_Reader_Arr::read method, but that feels like a problem waiting to happen when the next patch comes along.

Has anyone else had this issue and found a more elegant solution?

Thanks


texts: How to use the null- or notnull-operator with (complex) filter in Magento (1.9) API SOAP v2

texts:
For example:

sales_order_list api function
filter operators

Possible solutions:

value = "notnull"
value = ""
value = null
value = "true"
value = "1"
use simple filter
anything else?!?!

Who knows?


texts: What does "deferred stock update" do and how is it related to Backorders?

texts:
In M2 what does "deferred stock update" do and how is it related to Backorders?
From here it is not exactly clear what it does, especially what it has to do with Backorders (which is quite fast when compared to MSI). https://support.magento.com/hc/en-us/articles/360048996811-Magento-best-practices-for-deferred-stock-update-


texts: Magento2 WebshopApps Matrix rate extension issue with additional discount label in cart page

texts:
I have installed WebshopApps Matrix rate extension for my website in M2, i have also one custom module that shows gift card discount in cart page totals section,issue is when ajax call response comes from WebshopApps Matrix rate extension, my custom module gift card discount label disappears. when I disable WebshopApps Matrix rate extension it works fine. can anyone faced this type of issue and help me? please find 2 screenshots, one is for before shipping ajax call and one is after shipping ajax call.

Thanks,
Bhargav


texts: Magento 2.3.4 Undefined index: decimal(12,4) NOT NULL default 0

texts:
I am trying to install a Reward Point Extension from MagePlaza, after i upload the files and enable the module via SSH, My site crashes.

After the extension install I run bin/magento setup:upgrade and get this message:

Undefined index: decimal(12,4) NOT NULL default 0 in/vendor/magento/framework/Setup/SchemaListener.php on line 137

I get this error message on my site:

1 exception(s):
Exception #0 (Magento\Framework\Exception\LocalizedException): Please upgrade your database: Run "bin/magento setup:upgrade" from the Magento root directory.
The following modules are outdated:
Magestore_Rewardpoints schema: current version - none, required version - 1.2.0.5
Magestore_Rewardpoints data: current version - none, required version - 1.2.0.5

Exception #0 (Magento\Framework\Exception\LocalizedException): Please upgrade your database: Run "bin/magento setup:upgrade" from the Magento root directory.
The following modules are outdated:
Magestore_Rewardpoints schema: current version - none, required version - 1.2.0.5
Magestore_Rewardpoints data: current version - none, required version - 1.2.0.5
<pre>#1 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(&Magento\Framework\App\Request\Http#000000007f23423700000000495edb1c#) called at [vendor/magento/module-page-cache/Model/App/FrontController/BuiltinPlugin.php:69]
#2 Magento\PageCache\Model\App\FrontController\BuiltinPlugin->aroundDispatch(&Magento\Framework\App\FrontController\Interceptor#000000007f23439900000000495edb1c#, &Closure#000000007f2343f800000000495edb1c#, &Magento\Framework\App\Request\Http#000000007f23423700000000495edb1c#) called at [vendor/magento/framework/Interception/Interceptor.php:135]
#3 Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(&Magento\Framework\App\Request\Http#000000007f23423700000000495edb1c#) called at [vendor/magento/framework/Interception/Interceptor.php:153]
#4 Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch', array(&Magento\Framework\App\Request\Http#000000007f23423700000000495edb1c#), array(array('page_cache_from_...', 'storeCookieValid...', 'install', 'configHash'), array('front-controller...'), 'requestPreproces...')) called at [generated/code/Magento/Framework/App/FrontController/Interceptor.php:26]
#5 Magento\Framework\App\FrontController\Interceptor->dispatch(&Magento\Framework\App\Request\Http#000000007f23423700000000495edb1c#) called at [vendor/magento/framework/App/Http.php:116]
#6 Magento\Framework\App\Http->launch() called at [generated/code/Magento/Framework/App/Http/Interceptor.php:24]
#7 Magento\Framework\App\Http\Interceptor->launch() called at [vendor/magento/framework/App/Bootstrap.php:261]
#8 Magento\Framework\App\Bootstrap->run(&Magento\Framework\App\Http\Interceptor#000000007f23424100000000495edb1c#) called at [index.php:39]
</pre>


texts: How to get saved data in two different forms on edit action

texts:
I have custom module with two database tables
table 1 : Showroom
table 2: Showroomdetails
and two forms one for showroom and another for showroomdetails.

This model saves data in both tables but when i open for in edit mode i am not able to get saved data from table two in showroomdetails form

ShowroomController.php

class AdminModules_Showroom_Adminhtml_ShowroomController extends Mage_Adminhtml_Controller_action
{
    public function editAction() {
        $id = $this->getRequest()->getParam('id');
        $model = Mage::getModel('showroom/showroom')->load($id);

        if ($model->getId() || $id == 0) {
            $data = Mage::getSingleton('adminhtml/session')->getFormData(true);
            if (!empty($data)) {
                $model->setData($data);
            }

            Mage::register('showroom_data', $model);

            $this->loadLayout();
            $this->_setActiveMenu('showroom/items');

            $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item Manager'),     Mage::helper('adminhtml')->__('Item Manager'));
            $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item News'), Mage::helper('adminhtml')->__('Item News'));

            $this->getLayout()->getBlock('head')->setCanLoadExtJs(true);

            /* add wyswig editor */
            if (Mage::getSingleton('cms/wysiwyg_config')->isEnabled()) {
                $this->getLayout()->getBlock('head')->setCanLoadTinyMce(true);
            } /* end */

            $this->_addContent($this->getLayout()->createBlock('showroom/adminhtml_showroom_edit'))
                ->_addLeft($this->getLayout()->createBlock('showroom/adminhtml_showroom_edit_tabs'));

            $this->renderLayout();
        } else {
            Mage::getSingleton('adminhtml/session')->addError(Mage::helper('showroom')->__('Item does not exist'));
            $this->_redirect('*/*/');
        }
    }


texts: Magento 2 - need super simple way of assessing whether cart is empty or not in list.phtml file

texts:
Client wants to display a conditional message on the category list.phtml page depending on whether or not the cart has ANYTHING in it
I've found a lot of posts about creating a custom module to be able to assess cart items etc. but surely there must just be a simple way of identifying whether the cart contains anything or not without the need for a whole module to do so.
I don't care if we're counting items, reporting totals, assessing whether a cart exists or however it's done I just need a 'cart_empty' true or false variable
Any ideas?
UPDATED: reading a little more on this, I think the issue may be because we have caching in place on the product list page for performance reasons
This being the case do I need to access the cart using AJAX in some way?


texts: Shipping Help - varied shipping dependent on supplier

texts:
I was hoping for some advice from someone. I am in the process of moving my online store from Prestashop to Magento due to Prestashop not having the required shipping modules.

I run an online store manufacturing and distributing car parts. Within our company we manufacture a lot of products, these products vary in size, if a customer purchases a large item and 3 small ones most of the time the smaller ones can go in the large item. This means the customer would only pay for shipping on the large item. What I need is a shipping extension/setup where I can define specific rates defined on what products are purchased. I am not 100% sure how to do this yet, some people have suggested volumetric weight?

I am also taking on lots of new suppliers. Each of these suppliers have their own shipping rates dependent on product size. Some of my suppliers charge £30 UK flat rate for a bonnet plus £20 for a boot lid. What I would need is an extension/setup able to do our in house products and also to add each suppliers product up at a flat rate.

A typical basket might be

1 - CarBen Fibre Creations – 2 small, 1 large item = shipping of the large item
2 - Seibon – 1 bonnet = flat rate from supplier based on drop shipping
3 - BC Racing – suspension - flat rate from supplier based on drop shipping

Shipping would be 1 (combined total) + 2 + 3

I hope that makes sense, I am still trying to work out if I can calculate my internal items better. Maybe I could put a variable in that states it will only charge for the largest item based on volumetric weight? I am not sure.

Any advice would be great.


texts: Unable to display products in home page in Magento 1.8.1

texts:
After successful installation of Magento 1.8.1 in a system. Everything works fine, but unable to display products on the home page. As posted on Magento website, I modified the home page design using admin interface CMS >> Pages >> Home Page >> Design.
As shown in the  Magento Wiki page below lines were added in the second line of home page design -

{{block type="catalog/product_new" name="home.catalog.product.new" alias="product_homepage" template="catalog/product/new.phtml"}}

Still, the products are not displayed on home page.
What should be done to display the products on home page.
I'm using Ubuntu 13.04 server, with MySQL 5.5 database and Magento version 1.8.1 downloaded using SVN


texts:
When templates hints are turned ON , it is shown that

Magento\Checkout\Block\Cart\Sidebar\Interceptor

is responsible for

  /var/www/html/magento/vendor/magento/module-checkout/view/frontend/templates/cart/minicart.phtml

when I browsed to the loaction

  /vendor/magento/module-checkout/Block/Cart

There is Sidebar.php

Not Sidebar/Interceptor.php, which is expected from the block name conventions followed by magento.

Where can I find the file?

Also In which layout file the minicart.phtml file is defined?


texts: Increase varchar limit fot small_image attribute

texts:
I am using Magento 2.3.4.I have imported the product sheet in back end.
It throws the error "Attribute small_image exceeded max length in row(s): 1".I have to import image from external url  the image url length is so long.I have to increase the length only for small_image.


texts:
I've noticed Magento2 has Javascript Coding Standards, in which they reference an eslint config file.
Suppose I have an M2 project I'm developing with a large group of folks and I'd like the team to adhere to these standards. How can I leverage this? For example, do I need to make a custom grunt task, or is there one already present somewhere?
Ideally I'd like something like grunt eslint that would look over all the javascript files in the custom theme and extensions.


texts: I'm using magento 1.9 and i want to display 4 items in a list block but layout breaks?

texts:
I'm using magento 1.9 and i want to display 4 items in a list block
ex: {{block type="catalog/product_list" category_id="411" column_count="4" &nbsp;mode="grid" template="catalog/product/list.phtml"}}, then magento display 4 items correct! but in a row below it should show next 4 items side by side and that not happen magento show 1 item and break to next line showing again 4 items.


texts: How to get Config value in PDF magetno 2

texts:
how do you get config value in model class i am doing a override for PDF INVOICE by <preference for="Magento\Sales\Model\Order\Pdf\Invoice" but i am not able to get the config value

const COMPANY_ADDRESS = 'module_name/general/address';

public function __construct(
    \Magento\Framework\View\Element\Template\Context $context,
    \Magento\Framework\UrlInterface $urlInterface,
    ScopeConfigInterface $scopeConfig,
    array $data = []
) {
    parent::__construct($context, $data);
    $this->_urlInterface = $urlInterface;
    $this->scopeConfig = $scopeConfig;

}
public function getConfigValue($field, $storeId = null)
{
    return $this->scopeConfig->getValue(
        $field, ScopeInterface::SCOPE_STORE, $storeId
    );
}

public function getAddress($storeId = null)
{
    return $this->getConfigValue(self::COMPANY_ADDRESS, $storeId);
}

In invoice class
instead calling this $this->insertAddress($page, $invoice->getStore());
i wantto call my config getAddress


texts: Filter CMS page collection by title or content

texts:
I'm working on a module to make certain CMS pages searchable on the front end. Right now I'm having a little trouble filtering the pages. I get the collection, filter it by an "is_searchable" field that I've added, which is working fine. When I try to filter it by title or content using a like statement, it either returns no results, or every result, regardless of if that matches the title/content at all or not. Here's what I'm using so far:

$results = Mage::getModel('cms/page')->getCollection()
               ->addFieldToFilter('title', array('like'=> '%' . $search . '%'))
               ->addFieldToFilter('content', array('like'=>'%' . $search . '%'))
               ->addFieldToFilter('is_searchable', 1);

I also tried using addAttributeToFilter() but get an error that that function doesn't exist in that model. Not sure what I'm doing wrong here, but any help or direction would be appreciated. Thanks!


texts: Magento 2 - How use join between sales_order and sales_order_item table

texts:
How to use Join in Magento2. i want to get customer_firstname from sales_order table and price , qty_ordered columns from sales_order_item table where sales_order.entity_id=sales_order_item.order_id
Kindly guide me it will be appreciated.


texts: How to replace Category Name with Category custom attribute in breadcrumbs Magento 2?

texts: I want to replace the category name with the category custom attribute in the breadcrumbs on the list and product details page.


texts: Magento 2 Set Tax rules and Rates for UK country

texts:
I want to set tax rule and rates for UK country as per the below scenario.

Rest of the world   0%        (217 countries)
Uk                  20%
Europe              20%       (27 Countries)

do we require to create rules and rates for all countries or there is any other approach that will do?
Please share me your experince what will be best approach to do it.
Thanks,


texts: Upload custom jacket lining magento plugin

texts:
I need to let customers upload image and customise the lining of the jackets and cotes with it. I couldn't find a plugin for it.
Does it even exist? Any alternatives, or I should start creating it by myself?

thanks


texts:
Magento version: 2.2.3

We have faced a strange issue in the sequence of order number for our site. For example this weekend Magento was at number 100034468 and the next order number that came in was 100034470. We don't know what happened to the order number 100034469.

Since this is the peak time for us, we are scarring that we may be missed the orders.

I have read some posts about the order number inconsistent on Magento StackExchange. Though, I have not satisfied with the answers. I want to have the clear reason for this issue. So, I'm posting this question.

Could you please help me to know why this has happened?

Looking for your quickest reply. Thanks.


texts:
What does the  tag exactly mean in config.xml?

Would it be possible to put it in the  instead of the  section? What is the differece?

<admin>
    <routers>
        <mymodule>
            <use>admin</use>
            <args>
                <module>Mynamespace_Mymodule</module>
                <frontName>admin_mymodule</frontName>
            </args>
        </mymodule>
    </routers>
</admin>

THanks!


texts: Dynamically generated block identical for all clients - Why?

texts:
I use PHP to create the content of a block dynamically on a CMS page (created via the admin portal). But I found out during testing that the first generated block remains active for all clients until I flush the cache of the server.
My code:

<?php if($_COOKIE["businesskind"] == "private"){

$productsBlock = $this->getLayout()->createBlock(ProductsList::class);
$productsBlock->setProductsCount(100);
$productsBlock->setTemplate("product/widget/content/grid.phtml");
$productsBlock->setConditionsEncoded("^[`1`:^[`type`:`Magento||CatalogWidget||Model||Rule||Condition||Combine`,`aggregator`:`all`,`value`:`1`,`new_child`:``^],`1--1`:^[`type`:`Magento||CatalogWidget||Model||Rule||Condition||Product`,`attribute`:`category_ids`,`operator`:`==`,`value`:`3`^]^]");
echo $productsBlock->toHtml();
}
else{
$productsBlock = $this->getLayout()->createBlock(ProductsList::class);
$productsBlock->setProductsCount(100);
$productsBlock->setTemplate("product/widget/content/grid.phtml");
$productsBlock->setConditionsEncoded("^[`1`:^[`type`:`Magento||CatalogWidget||Model||Rule||Condition||Combine`,`aggregator`:`all`,`value`:`1`,`new_child`:``^],`1--1`:^[`type`:`Magento||CatalogWidget||Model||Rule||Condition||Product`,`attribute`:`category_ids`,`operator`:`==`,`value`:`4`^]^]");
echo $productsBlock->toHtml();
}
?>

I create a cookie and query the value of the cookie via PHP. Depending on the input the user should see a different output in the next step. The output in the next step should be a filtered product list.
How can the selected one be valid only for the one user?


texts:
i am using magento 1.9 and i am try to set session out side magento file.
my problem is session  set but when i`m try to get session in view.phtml page it show result null.

this is my code:

set_time_limit(0);
ini_set('memory_limit', '-1');
define('MAGENTO_ROOT', getcwd());
$mageFilename = MAGENTO_ROOT . '/app/Mage.php';
require_once $mageFilename;
Mage::init();
$ponumber = "123456";
Mage::getSingleton('core/session')->setPonumber($ponumber);
$getponumber = Mage::getSingleton('core/session')->getPonumber();
echo "ponumber->".$getponumber; // its print 123456

view.pthml

$ponumber= '';
$ponumber= Mage::getSingleton('core/session')->getPonumber();
echo "----->".$ponumber."<-----";

what am i doing wrong.

Any help or suggestion will be appreciated.


texts: Remove Categories from Product Page Title

texts:
When navigating to a product in Magento 2, through multiple categories - i.e. site.com/tops/bras - if there is no manually set SEO title, it adds Tops - Bras to the product page title, what would be the most efficient way to remove this (without manually editing every product SEO title).

Example:


texts: How can I get a product's image URL using service contracts?

texts:
I know that in Magento 2.0, there is a recommended way to access products info from another module using service contracts.

So, my first question: how can I get a product's image URL using service contracts and an API function?

Second question: I want to override product's possible "getImageUrl" function so that I can generate a custom URL (points to an external source) and return it back as Image URL. So, any other external or internal module that wants to access a product's image's URL will get my generated URL instead of Magento's default product Image URL. Should it be implemented using service contracts ? Because its the recommended way in Magento 2.0.


texts: Reload Total section in checkout/cart page - Matgento 2

texts:
I want to reload total section when checkbox checked/unchecked.

Here is the code I am trying to implement.

etc/frontend/sections.xml

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Customer:etc/sections.xsd">
    <action name="extrafee/update/updatesession">
        <section name="cart"/>
    </action>
</config>

Trying to call the line in my phtml file.

<script>
    require(['jquery'], function ($) {
        $("#installation").change(function() {
            require('Magento_Customer/js/customer-data').reload(['checkout-data'], false)
        });
    });
</script>

If I reload page manually, it is okay. the total is updating.


texts: Is there a reason hyphen/dash is not allowed in store codes?

texts: Both M1 and M2 don't allow hyphens or dashes in its store codes. There is backend validation against it. However, it is not clear why. Any idea?


texts:
I have an issue on magento 2 site. The button "Save Config" not work, I click on in but nothing.

My configuration: magento2.3.3 on VPS with Plesk and php 7.3.

How can solve it?

Thanks


texts: Magento 2 block controller action not calling second time

texts:
I have a block in my module and when the block is loaded first time it will calling the controller and I am getting the url parameters,but when the block open with same url parameters then the controller is not calling.
http://127.0.0.1/magentotest/myintegration/mymodule/link/code/12345/ClickId/1200

this link will open a block and the controller is calling so that I am getting the url parameters,like code and clickId
but next time when I hit the same url with same parameters then the controller is not calling and I am not getting the url parameters.
After clear the magento cache then it will calling.So what is the reason for not calling the controller second time with same parameter values?


texts: What is the PHP file for /contacts/index/post/?

texts:
Lots of spam is being sent to this form. I need to add Google Recaptcha to it.

What is the PHP file that's responsible for receiving the contact POST at /contacts/index/post/ ?

After some search I couldn't find anything relevant except form.phtml which seems to be only responsible for displaying the form but not receiving the POST data.


texts: how to upload an image for each store view

texts:
Won't let me place images for each product the following message is there...image type and information need to be specified for each store view.
Why does this mean? How do i get my images loaded into each product?


texts:
In /customer/account there are several links

account dashboard
account information
addressbook
etc

I do not have any need (as far as i can tell) for:

recurring profiles
my applications
my downloadable products (or I must be needing this when using gift card module, I don't know yet)

Where can I turn these off? It should be update proof ;-)


texts: Why magento installation hangs on configuration phase?

texts:
I am done with all what i can do to figure out why magento installation hangs on configuration phase. I did everything what is given here: http://www.ironion.com/installing-magento-on-xampp/

But even then I am stuck on configuration wile installing magento. Please help. Thank you


texts: Is it possible to add create nested bundle product?

texts: I have came across a very peculiar requirement where there are two bundle product with A and B. A has  Options X,Y,Z. Normally this will be bundle options but we need to add the Bundle Product B to the Options instead of X and rest Y and Z will remain as it is. While selecting the  option/product B it will show B's option and its values.


texts: M2.2 - Raising maximum failures_count in oauth_token_request_log

texts:
We recently experienced an issue that seems to have been lingering around for a while now with no real concrete solution but moreso bandaid fixes; https://github.com/magento/magento2/issues/4432
In short, using the API call for customer token generation, the failure count is tracked and if a customers account reaches 6 failures, they get locked out.
Most of the suggestions are to just manually or setup a cronjob to clear the oauth_token_request_log table so customers don't end up accumulating too many failure_count's and end up getting a locked account.
Seems like a valid solution but I am just curious of any other alternatives, such as possibly raising the maximum failure count or even removing the tracking of the token request failures. Any ideas?


texts: Cache and module status not the same in Admin and shell - Magento 2.3.2

texts:
I am new on the Magento 2 platform and working on migrating our shop from Magento 1. I am working on a testmigration and have successfully migrated data and products from M1 to M2 (version 2.3.2).

But i am facing a really confusing problem. When installing extensions, Magento backend does not recognize the extensions as enabled. If i check app/etc/config.php the extension has status 1, enabled and if i run bin/magento module:status the extension has status enabled, but not in Magento admin. The extension is not visible in Stores->Configuration either. I have tried several extensions and the problem is the same. If i try to enable the extension in Magento admin i get this dependency error " Can not find module name. " and in the Module manager list the "module name" field is empty.

To make it even more confusing cache status is not the same in shell as in admin. If i disable cache in shell, cache is still enabled in admin, but if i disable cache in admin it is also disabled in shell.

It seems that Magento admin is not reading changes done in shell. Can anyone help?

Server is running Ubuntu / Nginx / PHP 7.2

All native Magento functions seems to work fine.

EDIT:
I have run the following commands in shell:

bin/magento setup:upgrade

bin/magento setup:di:compile

bin/magento indexer:reindex

bin/magento setup:static-content:deploy en_US nb_NO -f

bin/magento cache:flush

I have also deleted the content of /generated/code

My main concern is that Magneto admin/GUI and shell/CLI has different status on cache and module status.


texts: Catalog Price Rules not working / accessing Cron.php results in 503

texts:
I'm working on a store with about 80,000 skus, on a quad-core dedicated server with 12GB ram and applying a Catalog Price Rule is just not working for some reason.  No discounts show, even after i've done the following:

Create Rule
Status: Enabled
Customer Groups selected
From/To Dates created
No Conditions set (sitewide)
Actions - apply percentage of original price, 20 percent
Click "Save & Apply

After a good 5 minutes, i'll get the green notification saying the rule has been applied.  I'll then proceed to flush Cache and also Re-Index. Proceeding to view the site on the front-end, It's as if nothing ever happened. Not a template issue because it's worked previously.

I was assuming it may have to do with Cron not being executed yet, so i manually have accessed Cron.php in my web browser- which hangs and eventually gives the entire site a 503 error which lasts for a couple minutes and goes away.

I've tried everything from upping Memory Limits in PHP / MySQL settings and Max_Execution_Time, and I'm at my wits end as I just can't get this to work.

Any clues?


texts: Need to change customer account side tabs layout Vertical Layout to horizontal on top.Magento 2.3

texts:
I need to change the My Account section side tabs layout (Vertical to Horizontal) and wanted to add on top before the My Videos Label.

Please Help me to change this layout.


texts: Magento 2 - Extend layout of another module

texts: I have developed a module vendor_module1 and I want to extend the layout of magento_customer module. Is there a way to do it in module? or only in theme? Is it a good practice to do so?


texts: Assign Bottle sizes based upon store in multi-store

texts:
I have 150 configurable products.  Each product has bottle sizes ranging from 10ml to 5kg.  I have set up two stores: Wholesale and Retail.  I am trying to show all bottle sizes in wholesale store with wholesale pricing. And then show only 3 sizes of bottles with retail pricing in the retail store.

I have tried assigning them on a per store basis, but it still shows all sizes in both stores.

Do I need to make a duplicate set of all the configurable products on a store by store basis?


texts: Finding visitor IP for specific search query

texts: I am trying to figure out if there is a way to find the visitor IP address of a visitor with a specific search query. We have some odd search terms on the site and I know visitors info is stored in log_visitor_info but I am wondering if there is a way I can find out which visitor executed a specific query. Catalogsearch_query shows me the store view, but is there anyway to combine the data to figure it out?


texts:
Ok, I've given up. I had a friend come to me to ask for assistance with her website - she has a few things that she'd like me to change on the front end like the calendar plugin. For some reason it defaults to a date in 2015, and the events she creates in the back end aren't going to the calendar on the site.

I've never used Magento before, and I've scoured the web trying to figure out how to actually edit the front end. Is that not possible with Magento? Is it just a platform that the front end code interacts with? If so, that means I need to go through her hosting company to get ssh into the server.. I already have the login info for the admin panel so I'd love to be able to fix the calendar from that.

Please excuse my ignorance, I've never even heard of this platform.

The page in question is here: http://www.shopintheweeds.com/events/


texts: Magento 2 : Configuration array must have a key for 'dbname' that names the database instance

texts:
I have created below model for get navigation filter by category id but getting below error.
Working fine with fresh magento setup but not working with migration setup.
Exception #0 (InvalidArgumentException): Configuration array must have a key for 'dbname' that names the database instance
Exception #1 (Zend_Db_Adapter_Exception): Configuration array must have a key for 'dbname' that names the database instance

Code-
namespace Nv\Finder\Model;

class FiltersManagement
{
  protected $_filterableAttributeList;
  protected $_layerResolver;
  protected $_filterList;
  protected $_storeManagerInterface;
  protected $_response;
  protected $_redirFactory;

  public function __construct(
    \Magento\CatalogGraphQl\Model\Resolver\Layer\FilterableAttributesListFactory $filterableAttributeList,
    \Magento\Catalog\Model\Layer\FilterListFactory $filterList,
    \Magento\Store\Model\StoreManagerInterface $storeManagerInterface,
    \Magento\Catalog\Model\Layer\Resolver $layerResolver
  )
  {
    $this->_filterList                      = $filterList;
    $this->_filterableAttributeList         = $filterableAttributeList;
    $this->_layerResolver                   = $layerResolver;
    $this->_storeManagerInterface           = $storeManagerInterface;
  }

  /**
    * GET  review by its ID
    *
    * @api
    * @return array
    * @throws \Magento\Framework\Exception\NoSuchEntityException
    *
    */
  public function getLayeredFilters()
  {
    $categoryId   = 147;
    $layer        = $this->_layerResolver->get();

    $layerType = "search";
    if ($categoryId){
      $layer->setCurrentCategory($categoryId);
      $layerType = "category";
    }

    $filterArray['store_id']  = $this->_storeManagerInterface->getStore()->getId();
    $filterableAttributesList = $this->_filterableAttributeList->create($layerType);

    $filterList = $this->_filterList->create(['filterableAttributes' => $filterableAttributesList]);
    $filters    = $filterList->getFilters($layer);
    $i = 0;
    foreach($filters as $filter)
    {
        // Don't show options with no items
      if (! $filter->getItemsCount()) {continue;}

      $availablefilter = (string)$filter->getName();
      $items           = $filter->getItems();
      $filterValues    = array();

      $j = 0;
      foreach($items as $item)
      {
        $filterValues[$j]['display'] = strip_tags($item->getLabel());
        $filterValues[$j]['value']   = $item->getValue();
        $filterValues[$j]['count']   = $item->getCount(); //Gives no. of products in each filter options
        $filterValues[$j]['url']     = $item->getUrl();   //Gives filter url.
        $j++;
      }

      if(!empty($filterValues) && count($filterValues)>1)
      {
        $filterArray['availablefilter'][$availablefilter] =  $filterValues;
      }
      $i++;

    }

    if (!isset($filterArray["availablefilter"])) {
      $filterArray['availablefilter'] = "No filters to show.";
    }

    header("Content-Type: application/json; charset=utf-8");
    $this->response = json_encode($filterArray);
    print_r($this->response,false);
    die();
  }

}


texts:
I followed these two guides: one, two
but I can't add my link at the end of the others, and maybe it's because there's an extension that put their own.

I don't know how Magento construct the layout if it has an order or something.

In customer.xml after the Magento default links, I tried to add mine but after the extension ones (with after="extensionLinkName"). And it doesn't work. Any idea?


texts: How to export and display products which are going to expire in Magento admin panel reports tab?

texts:
How can I export and display products which are going to expire in the Magento admin panel reports tab?

Below is a screen shot with my requirement.


texts: When is event sales_quote_item_set_product triggered?

texts: I'd like to know when event sales_quote_item_set_product is triggered, please?


texts:
I have a module built in magento 2.1.16 which store details of contacts in database and fetches them on list page and details view page.
The contacts are of 3 types

Branches (https://roadmaster.com.co/en_sa/contacts)
Dealers (https://roadmaster.com.co/en_sa/dealers)
Authorized Centers (https://roadmaster.com.co/en_sa/servicecenters)

When i clik on more information on any I get url like this one https://roadmaster.com.co/en_sa/dealers/view/index/id/24/
While i want something like
https://roadmaster.com.co/en_sa/dealers/al-khaleej

or for this url
https://roadmaster.com.co/en_sa/contacts/view/index/id/1/
I want something like
https://roadmaster.com.co/en_sa/contacts/rm-jeddah

The contacts are stored in single table and are distinguished by contact_type attribute.


texts: magento 2.4 : customer session get destroyed after payment

texts:
I am using magento 2.4.1, i have used plugin for payment gateway like - ccavenues , payu but issues it that after payment it gets redirected to "checkout/cart/"
While debugging it seems session is getting destoryed please help me with issue as i am bit new and could not trace issue.


texts: Help writing an observer the "Magento Way"

texts:
Fairly new to objected oriented programming and very new to Magento programming, but trying to learn the "right way".

I'm writing a before save observer to update product attributes based on other product attributes. I've got that working (in the most basic sense). Now I'm trying to figure the right way to make it do what I want. I have...

class Company_Namespace_Model_Observer
{
    public function UpdateStuff(Varien_Event_Observer $observer)
    {
        $product = $observer->getEvent()->getProduct();
    $product->setData('MyAttribuite', 'NewData');
    }
}

That works great. But, now I want 'NewData' to be a bunch of code. My first thought was to add more public functions to the class, but that didn't work. If that was my only question, I'm sure I could find the answer already answered somewhere. But then thinking of all the examples I've seen, is inside this class the right place to put these functions, or should I have another file under a Helper directory?

Second part of the question, should the UpdateStuff() function get return values from other functions like...

$MyNewData = SomeFunction($product);
$product->setData('MyAttribuite', $MyNewData);

or should I just call SomeFunction($product) and have it set the new data?

or does it not really matter, and I'm just reading too much into what I've read about writing your code the "Magento way"


texts: I can't change quantity for multiple products at once, using admin products listing page

texts: I want to change quantity for 20 or so products at once, from the admin products listing page. The products are of type Configurable. I select the products, and choose "Update attributes" in the Action dropdown, and then click Submit. On the next page I should be able to change some of the settings (one of which is quantity - in the Inventory section) for this group of products. When I change the quantity here, the quantity stays unchanged for some reason, on the admin products listing, even though Magento says everything has been saved correctly. What am I missing here?


texts:
I have just made a fresh installation of Magento 2.2.1 to eventually be able to migrate from my present 1.7.

But I already encountered some difficulties.
The message "One or more indexes are invalid. Make sure your Magento cron job is running." is showing in admin.

I tried to google how to get the cron job running but can't find how to do it in cPanel, and I don't understand how to get it running.
I do not have SSH access and can't do anything through CLI. Does anybody know how I can get this cron thing set up and working from cPanel?


texts: Create Magento 2 Upgrade Script to add/update new field into custom module table

texts:
Anybody have any idea/suggestion about creating Magento 2(CE Stable version) Upgrade Script(in custom-module) for adding/updating new field into custom table ?

I know about "InstallSchema" but is there something like "UpgradeSchema" for upgrading the module tables ?

Please explain in detail with examples.


texts:
For a few weeks, my admin and user password are stolen.

I followed all the rules against brute force, but after a few days, after I restore the website with the old backup, I found a new admin user and password.

What is strange is that today I found the previous admin user and a impossible to decrypt password:
'39a5b5d9bb44e4d16227f7c71aa60af6:USi9sn2VLm3SssMLS8BS7QrJ2kQFRjvs'

I have 1.9.2.4 version, including captcha on the backend login.

Please help me with some advice,


texts: Magento 2.3 - setup:upgrade Schema creation/updates error in DefinitionAggregator.php

texts:
I am trying to setup:upgrade but its giving me this error
Undefined index: version in /var/www/html/vendor/magento/framework/Setup/Declaration/Schema/Db/DefinitionAggregator.php on line 91

I am not able to trace it. How do I fix this?


texts: Magento2 : Using RequireJS module conditional of whether it exists

texts:
It is possible to use RequireJS to inject some modules into a custom script, for example:

define([
    'jquery',
    'tinymce',
    'Magento_Ui/js/modal/modal'
], function($, modal, tinymce) {
    "use strict";
    ...
});

However, it looks like in Magento 2.3 the module tinymce is no longer supported, but it is possible to use tinymce4. However, that is not backwards-compatible.

The question is, is it possible to check whether a module exists before defining it? It have tried with require.defined and require.specified but they appear to check against what's defined with define(), not what exists.

Ideally I'd want something like this:

var tinymce_module = requirejs.moduleExists('tinymce4') ? 'tinymce4' : 'tinymce';
define([
    'jquery',
    tinymce_module,
    'Magento_Ui/js/modal/modal'
], function($, modal, tinymce) {
    "use strict";
    ...
});

P.S. Any help regarding loading TinyMCE across Magento 2 versions specifically would be appreciated in the comments as well.


texts:
Since an update of a plugin my CMS pages dont load anymore. See screenshot:

I dont know what is going wrong or why it doesn't load anymore. The plugin is off and it doesn't effect it anymore, but still it doesn't load. Please need help where to start looking or what is going wrong where.

This is what I get out of the error log:

2016-04-29T10:20:30+00:00 ERR (3): Warning: include(Mage/Mageworx/Seobase/Helper/Data.php): failed to open stream: No such file or directory  in /data/web/public/lib/Varien/Autoload.php on line 93

2016-04-29T10:20:30+00:00 ERR (3): Warning: include(Mage/Mageworx/Seobase/Helper/Data.php): failed to open stream: No such file or directory  in /data/web/public/lib/Varien/Autoload.php on line 93

2016-04-29T10:20:30+00:00 ERR (3): Warning: include(): Failed opening 'Mage/Mageworx/Seobase/Helper/Data.php' for inclusion (include_path='/data/web/public/app/code/local:/data/web/public/app/code/community:/data/web/public/app/code/core:/data/web/public/lib:.:/usr/share/php:/usr/share/pear')  in /data/web/public/lib/Varien/Autoload.php on line 93


texts: could not open file bin/magento in magento 2 ssh

texts:
after uploading my marketplace-module in

  app/code

i've run the command as

php bin/magento module:status

but it gave me the following error as shown in image :

i checked the file permission of magento in

  bin/magento
  it is set to 0755
  after that i tried to change the permission to 0777
  but no chnage im still getting this error

could not open the file bin/magento

can anoyone tell me what is going wrong from my side?
thanks in advance.


texts: undefined field store_id on catalog search reindex, magento 2 with solr search

texts: I have configured the solr-4.10.4 with magento 2.0.2 and tested the connecton.Connection is successful but when i tried to reindex i am getting the "undefined field store_id" exception, please provide your suggestion on this problem.


texts: Magento: How to add .html extension on custom module Front Name?

texts:
I have created a custom extension, My module XML files is as follow:

  <frontend>
    <routers>
      <articlepagination>
        <use>standard</use>
          <args>
            <module>Test_Articlepagination</module>
            <frontName>test-landing</frontName>
          </args>
      </articlepagination>
    </routers>
        <layout>
          <updates>
            <articlepagination>
              <file>articlepagination.xml</file>
            </articlepagination>
          </updates>
        </layout>
  </frontend>

When I run URL with frontname "test-landing" it works (www.xyz.com/test-landing) but i want my url to work with .html extension (www.xyz.com/test-landing.html)

How can it be done (without any htacess redirect) ?

To make it work,I tried to change the Frontname as   <frontName>test-landing.html</frontName> and the www.xyz.com/test-landing.html worked, Is it correct way to do so ? I don't think its correct way.

Thanks.


texts: Magento 1.7 to 1.9 Payment Method Problem

texts:
I have some trouble by an update from 1.7 to 1.9.
One Payment Extension Smasoft_Oneclickorder shows the ajax response message

The requested Payment Method is not available.

After click on the onepage checkout button in the card.
The Extension is build for 1.7 and have no updates yet, but it works till this point.

in the Class: Smasoft_Oneclickorder_IndexController i found a method:
_saveMagentoOrder

With this content:
protected function _saveMagentoOrder()
{
    /** @var $onepage Mage_Checkout_Model_Type_Onepage */
    $onepage = $this->getOnepage();

    try {
        $onepage->savePayment(array(
            'method' => 'smasoft_oneclickorder',
        ));
        $onepage->getQuote()->collectTotals()->save();
        Mage::register('oneclickorder_ignore_quote_validation', true, true);
        $onepage->saveOrder();
        Mage::unregister('oneclickorder_ignore_quote_validation');
        return true;
    } catch (Exception $e) {
        $this->_errors[] = $message = $e->getMessage();
    }
    return false;
}

... it seems normal ... but later in the
class: Mage_Sales_Model_Quote::public function getPaymentsCollection()
the $this->_payments

is null ... so he tries to load the payment method.
Do you have an idea what i have to change, that the method will be found in 1.9?
Thanks!


texts: transferred Magento website to live server , why does it show 404 error?

texts:
I have transferred Magento website to live server successfully but, after 5 days i am not able to use any link . not even admin.

my website loads perfectly fine :

www. example.com

But when i click on links or my admin link I see this weird thing in my url :

http://www.example.com/%7B%7Bwww.example.com%7D%7D/?SID=bcsgcudcnkj54nhknxsncnks23cabout-magento-demo-store/

the url contains the domain name twice , with flower brackets, which re-directs to 404 error.

Kindly help.


texts: Error 500 after choosing additional payment method (onepage checkout) - magento 1.9.2

texts:
I have added additional payment method almost the same as banktransfer, and everything works fine until this payment is checked at checkout. This payment shows up in adminpanel and front end.

Html code in checkout form looks the same for both payment methods.

            <input id="p_method_custom" value="custom" type="radio" name="payment[method]" title="Custom Payment" onclick="payment.switchMethod('custom')" class="radio validation-passed" autocomplete="off">
            Custom Payment

               some text

            <input id="p_method_banktransfer" value="banktransfer" type="radio" name="payment[method]" title="Banktransfer title" onclick="payment.switchMethod('banktransfer')" class="radio validation-passed" autocomplete="off">
            Banktransfer title

some text

Unfortunately after clicking next step, i got 500 error if i choose this custom method. I have found nothing in Apache log. Chrome log looks like this:

headerJSON    :    null
readyState    :    4
request    :    klass
responseJSON    :    null
responseText    :    ""
responseXML    :    null
status    :    500
statusText    :    "Internal Server Error"
transport    :    XMLHttpRequest
__proto__    :    Object
_getHeaderJSON    :    ()
_getResponseJSON    :    ()
constructor    :    klass()
getAllHeaders    :    ()
getAllResponseHeaders    :    ()
getHeader    :    (name)
getResponseHeader    :    (name)
getStatus    :    ()
getStatusText    :    ()
initialize    :    (request)
status    :     0
statusText    :    ""
__proto__    :    Object

Function payment.save() works, but next one makes error.

reloadStep: function(prevStep) {
        var updater = new Ajax.Updater(prevStep + '-progress-opcheckout', this.progressUrl, {
            method:'get',
           onFailure:this.ajaxFailure.bind(this),
            onComplete: function(response){
                this.checkout.resetPreviousSteps();
console.log(response);
            },
            parameters:prevStep ? { prevStep:prevStep } : null
        });
    },

Any idea what could I messed up?

///Bypassed
I've made a custom module for another payment method instead of duplicating method in core files. Now works fine, no problems in JS.
Any way, i'll try to check why the problem occured.


texts: Input type image validation in add field in admin grid custom module

texts:
How to make the add field for image in custom module admin grid as required entry?

The following is the way i have given , but it is not taking as required - entry field while saving.

$fieldset->addField(
            'background_image',
            'image',
            array(
                'label' => $this->__("Background Image"),
                'class' => 'required-entry',
                'required' => 'true',
                'name' => 'background_image',
                'note' => $this->__("Background Image")
            )
        );

        $fieldset->addField(
            'background_image_hover',
            'image',
            array(
                'label' => $this->__("Background Hover Image"),
                'class' => 'required-entry',
                'required' => 'true',
                'name' => 'background_image_hover',
                'note' => $this->__("Background Hover Image")
            )
        );


texts: How to call multiple Knockout templates within one component

texts:
I'm currently experimenting with Knockout JS templates within Magento 2 and all is going well but I do have one thought.

It seems that you can only call  once per component as there is no option to create a second template and I can't see any components where Magento are using multiple templates.

Example code:

My Template - app/design/frontend/Ben/blankClone/Magento_Cms/templates/knockout.phtml

My JS - It's a rough experiment ;) - app/design/frontend/Ben/blankClone/Magento_Cms/web/js/knockout-example.js

define(['ko', 'jquery', 'uiComponent'], function(ko, $, Component) {
    'use strict';

    function getRandomInt(min, max) {
        return Math.floor(Math.random() * (max - min + 1)) + min;
    }

    var messageCollection = ['Hello', 'Hi', 'Yo!', 'Sup?'];

    return Component.extend({
        defaults: {
            exampleMessage: 'This is the default title for my KO example',
            template: 'Magento_Cms/test'
        },

        initialize: function() {
            this._super();
        },

        /**
         * @return {exports.initObservable}
         * This is the same as var example = ko.observable('Example text');
         */
        initObservable: function () {
            this._super()
                .observe({
                    message: this.exampleMessage,
                    messageChanged: false,
                    updateTitle: false
                });

            return this;
        },

        updateTitle: function() {
            var numberOfMessages = messageCollection.length;
            var chosenMessageIndex = getRandomInt(0, (numberOfMessages - 1));
            var chosenMessage = messageCollection[chosenMessageIndex];

            this.message(chosenMessage);
            this.messageChanged(true);
        },

        resetTitle: function() {
            this.message(this.exampleMessage);
            this.messageChanged(false);
        },

        addYourOwnTitle: function() {

        }
    });
});

My HTML templates

app/design/frontend/Ben/blankClone/Magento_Cms/web/template/test.html

Lorem ipsum dolor sit amet, consectetur adipisicing elit. Asperiores assumenda beatae blanditiis culpa cupiditate doloremque, expedita ipsum iure magni minima modi molestiae nulla optio porro ratione reiciendis repellat soluta voluptatum!

app/design/frontend/Ben/blankClone/Magento_Cms/web/template/test-two.html

Hi!

So my question is: Is it possible to call a second template? and if so, how?

My thinking is you are limited to only one template per component to force you to write smaller components.

The only lead I have on this is the following markup, but I can't see how to get this working within Magento.


texts:
I'm using magento 1.9 with a custom theme, I didn't build it, I inherited it and its a bit of a mess, but at least functional. My question is

There is no space between 'my cart and 'checkout'

What can I do to fix this please?


texts: Magento 2 ExportButton component Product grid not working

texts:
I have added ExportButton on admin product grid and when i click on export it shows error
Exception #0 (Magento\Framework\Exception\LocalizedException): A joined field with this alias is already declared.

I have added the button in

  app/code/Mycompany/Gridexport/view/adminhtml/ui_component/product_listing.xml

<listingToolbar name="listing_top">
   <exportButton name="export_button">
            <argument name="data" xsi:type="array">
                <item name="config" xsi:type="array">
                    <item name="selectProvider" xsi:type="string">product_listing.product_listing.product_columns.ids</item>
                </item>
            </argument>
    </exportButton>
</listingToolbar>

But When i click on export button I get following error

  1 exception(s): Exception #0
  (Magento\Framework\Exception\LocalizedException): A joined field with
  this alias is already declared.

  Exception #0 (Magento\Framework\Exception\LocalizedException): A
  joined field with this alias is already declared.
  generated/code/Magento/Catalog/Ui/DataProvider/Product/ProductCollection/Interceptor.php(973):
  Magento\Eav\Model\Entity\Collection\AbstractCollection->joinField('qty',
  'cataloginventor...', 'qty', 'product_id=enti...',
  '{{table}}.stock...', 'left')
  vendor/magento/module-catalog-inventory/Ui/DataProvider/Product/AddQuantityFieldToCollection.php(27):
  Magento\Catalog\Ui\DataProvider\Product\ProductCollection\Interceptor->joinField('qty',
  'cataloginventor...', 'qty', 'product_id=enti...',
  '{{table}}.stock...', 'left')
  vendor/magento/module-catalog/Ui/DataProvider/Product/ProductDataProvider.php(91):
  Magento\CatalogInventory\Ui\DataProvider\Product\AddQuantityFieldToCollection->addField(Object(Magento\Catalog\Ui\DataProvider\Product\ProductCollection\Interceptor),
  'qty', NULL)
  generated/code/Magento/Catalog/Ui/DataProvider/Product/ProductDataProvider/Interceptor.php(37):
  Magento\Catalog\Ui\DataProvider\Product\ProductDataProvider->addField('qty',
  NULL)


texts:
How can we get Magento 2 base URL in web template (.html file) ?

Note: I am talking about web template (.html file). Not about general templates file (.phtml file).


texts: remove discount code form from checkout page magento2?

texts:
In my custom theme i do not use discount form. In cart, I removed via xml and it works. But in checkout I can't remove it via xml.

How i can remove discount form in onepage checkout?


texts: Magento 2.3.X static block not save any script code while saving block

texts:
Could anyone help me to debug the issue?

Why Magento 2.3.X is not saving any script code in static block?

I have put some javascript code in the block and press the save button but the code is not saved.

Is there any solution to store script code in the block?


texts: How To add custom Menu admin side in customer tab in magento 2

texts: How to add my module name inside the customer menu tab inside the admin panel? Whether there are any possibilities to add a menu inside the customer menu?


texts: Magento 2.2.8 and 3D Secure v2 (SCA / PSD2)

texts:
Come 14th September 3D Secure v2 comes into effect. (Some places call it Strong Customer Authentication or Payment Services Directive 2)

Does anyone know if your the native Paypal integration (PayPal Express Checkout) is fully compatible and if any updates will need to be applied to ensure we can still take payments with 3D Secure V2?

Paypal have "It pays to be prepared for PSD2" but it does not mention how to check if your version of Magento is covered

Along with this Paypal state the following:

  PayPal Pro hosted
  With our hosted solution, when a customer pays, a payment page either opens in a separate frame or the customer is redirected. If you use our hosted solution, then we manage your payment process at checkout. We will automatically upgrade the payment process, so you don’t need to worry. But, if you want to know more, visit our PSD2 page.

This was taken from here however this relates to "PayPal Pro hosted" and not PayPal Express


texts:
Getting following error in magento 2 email.

CSS inlining error: Warning: DOMXPath::query(): Invalid expression in /home/patios/public_html/vendor/pelago/emogrifier/Classes/Emogrifier.php on line 294

I have already tried to update pelado vendor. But still getting error.

"pelago/emogrifier": "1.0.0 as 0.1.1"

My magento version is 2.2.1

Update

Before upgrading pelago to to 1.0.0, error was like following...

Warning: DOMXPath::query(): Invalid expression in /home/public_html/vendor/pelago/emogrifier/Classes/Emogrifier.php on line 269

Warning: Invalid argument supplied for foreach() in /home/public_html/vendor/pelago/emogrifier/Classes/Emogrifier.php on line 272


texts: Different locations for search bar depending on width

texts:
I have a problem regarding the block moving with XML. I moved the search-bar with
<move element="top.search" destination="catalog.topnav" after="-"/> which is working as needed (it´s moved into the navbar), but now for responsiveness purposes I need to  move it back to its default position as for now on small devices it - logically - is moved to the sidenav (luma based).
This is obviously sth I don´t want to happen. So as far as I know there is no way of adding a condition to the default.xml so I tried some simple JS
window.onload = function() {
    if(window.width < 768) {
        document.querySelector('.header.content').appendChild(document.querySelector('.block-search'));
    }
}

but - surprise - this does not work (nothing is happening. no errors). I checked the selectors so they should be fine.
Maybe someone would be so kind to help me please. Thanks :)
EDIT: I removed the XML part and added the JS else part
window.onload = function() {
    if(window.width < 768) {
        document.querySelector('.header.content').appendChild(document.querySelector('.block-search'));
    }
    else{
        document.querySelector('.navigation').insertBefore(document.querySelector('.block-search'),document.querySelector('.navigation').firstChild);
    }
}

but with small devices it is still not in the default header position, but moved inside the side nav panel...


texts: Magento 2 How to display custom product attributes on product page

texts:
I have some attributes that I want to go above the "Add to Cart" button. How can I achieve this?

I followed this tutorial but that didn't work for me -> http://www.dckap.com/blog/display-custom-attribute-value-product-viewlist-page-magento-2/

I am using Magento version 2.1.8


texts:
In the Login page, I want to show a message in below Login Button instead of page top.

How to change Login page error message position in below Login Button in Magento 2.

How to achieve this?


texts: Add to cart button not working in product page

texts:
here the error (from dev tools) when clicking on the Add to Cart button :

"Uncaught TypeError: Cannot read property 'submit' of undefined
at HTMLButtonElement.onclick"

Changes I made (but several days before the problem appeared where activing an SSL and upgrading to Magento 1.9.3.6)

Here the code from the file addtocart.phtml:

<?php $_product = $this->getProduct(); ?>
<?php $buttonTitle = $this->__('Add to Cart'); ?>
<?php if($_product->isSaleable()): ?>

<?php if(!$_product->isGrouped()): ?>

<?php echo $this->__('Qty:') ?>
<input type="text" name="qty" id="qty" maxlength="12" value="<?php echo
$this->getProductDefaultQty() * 1 ?>" title="<?php echo $this->__('Qty') ?>"
class="input-text qty" />

<?php endif; ?>
<button type="button" title="<?php echo $buttonTitle ?>" id="product-
addtocart-button" class="button btn-cart"
onclick="productAddToCartForm.submit(this)"><?php echo
$buttonTitle ?></button>
<?php echo $this->getChildHtml('', true, true) ?>

<?php endif; ?>


texts: Add multiple products in cart programatically magento 2

texts:
I am trying to add multiple products in cart programmatically.  This below code is working properly but I need to set quantity dynamically. If quantity is not set that product to be skipped without adding in cart.

   <?php
$count = 0;
$cartItems = array();
$objectManager = MagentoFrameworkAppObjectManager::getInstance();
$_childProducts = $_product->getTypeInstance()->getUsedProducts($_product);

foreach($_childProducts as $simpleProduct)
    {

    // echo '
' , var_dump($simpleProduct->getData()) , '
';

    $sku = $simpleProduct->getSku();
    $count++;
    $stringSku = '"' . $sku . '"';
    if ($simpleProduct['jasani_color'] == $tmp['value_index'])
        {
        $sql = "select * from inventory_stock_4 where sku =" . $stringSku;
        $result = $connection->fetchAll($sql);
?>

                <?php
        echo $option_label = $result[0]['quantity'] ?>
                <input  type="number" min="0" max="1000" pattern="[0-9]*" id="qty" name="qty"  />
                " ?>
    </script>

    <?php
        if (isset($_POST['submit'])): ?>

    <?php
            $cart = $objectManager->create('Magento\Checkout\Model\Cart');
            $product = $objectManager->create('\Magento\Catalog\Model\Product')->load($simpleProduct->getId());
            $params = array();
            $params['qty'] = $qty;
            $params['product'] = $simpleProduct->getId();
            $cart->addProduct($product, $params);
            $cart->save();
            $cart->addProduct($product, $params);
            $cart->save();
            if (count($_childProducts) == $count)
                {
                header("Location:magento_controller/");
                exit;
                }

?>

            <?php
        endif; ?>

        <?php
        }

?>

        <form method="post">
        <input class="cart-btn-custom float-right" type="submit" name="submit"/>
        </form>

        <?php
endif; ?>

<?php
}

?>

I can't assign a form tag before the quantity input tag because It is inside a loop. So that I cannot assign this quantity to cart quantity.
I need this quantity to be the quantity given by the user in the multiple text box. The below image clarifies my question.

I need to enter this submit box with the assigned quantities like image above.


texts: How to Login with phone number without extension?

texts:
I am working on magento-1.9.

Here, the customer can login to my website by Email address only. But I need to login with phone number/email address. How I can do it?

Please any one can answer me.


texts:
i want to Check Magento volume discount condition manually for show notification message to customer shop $xx more  to get Y% discount.
see this post
I want to show next best volume discount to customer for total amount

i have all conditions is array

    $myarray = array(
  "type" =>  "salesrule/rule_condition_combine",
  "attribute" => NULL,
  "operator" => NULL,
  "value" =>  "1",
  "is_value_processed" => NULL,
  "aggregator" =>  "all",
  "conditions" => array(
         "type" =>  "salesrule/rule_condition_combine",
         "attribute" => NULL,
          "operator" => NULL,
          "value" => "1",
          "is_value_processed" => NULL,
          "aggregator" =>  "all",
          "conditions" => array(
                                     array(
                                      "type" => "salesrule/rule_condition_address",
                                      "attribute" =>  "base_subtotal",
                                      "operator" =>  ">=",
                                      "value" =>  "50",
                                      "is_value_processed" =>false,
                                        ),
                                    array(
                                      "type" =>  "salesrule/rule_condition_address",
                                      "attribute" => "base_subtotal",
                                      "operator" => "<=",
                                      "value" => "100",
                                      "is_value_processed" => false,
                                    ),
                array(
                  "type" => "salesrule/rule_condition_product_found",
                  "attribute" => NULL,
                  "operator" => NULL,
                  "value" =>  "1",
                  "is_value_processed" => NULL,
                  "aggregator" =>  "all",
                  "conditions" => array(
                                        array (
                                          "type" =>  "salesrule/rule_condition_product",
                                          "attribute" =>  "category_ids",
                                          "operator" =>  "==",
                                          "value" =>  "357, 358, 407",
                                          "is_value_processed" =>false,
                                        )
                                     )
                )
         )

  )
);

i want to check condition like this from array

if ($total_ amount >= 50 && $total_ amount <= 100)
{
.......
}
elseif ($total_ amount >= 101 && $total_ amount <= 200)
{
......
}


texts: Subcategories of disabled Categories are still accessible

texts:
I have the following scenario:

+ Primary Category       <---- DISABLED
|
+-- Secondary Category   <---- ENABLED
|
+---- Tertiary Category  <---- ENABLED

So the primary category is not web-accessible, and does not show in the navigation. However the secondary and tertiary is accessible if you have the link bookmarked or find it via a web search.

Is this normal behavior? What is the proper way to disable all children of a parent category?


texts: Cloudflare with Magento 2 admin page issues

texts:
I have configured a Magento 2.0.5 website with Cloudflare. The issue is some admin pages are not loading correctly. For example, catalog management page cannot load products list, user management page cannot load user list. Other admin pages work OK. It seems related to XHR queries used in those pages. But I checked those XHR queries, all returned correct responses.

I can only get those pages working by enabling Cloudflare development mode. I also configured Cloudflare Page Rules to by pass cache for admin pages, but it doesn't work.

Anyone has encountered the same issue before?


texts: Magento 2 add new custom option text field

texts: I would like to add new custom option text field like 'New Text Field Title' in the magento 2.x 'Customizable Options' section could you please suggest me and guide me how to add please refer my screenshot.


texts: Magento 2 how to check customer is logged in js file using phtml file

texts:
I have found the below code. but it's not working and showing define error in frontend if i use this code in phtml file.
Like this error shown :
require.js:166 Uncaught Error: Mismatched anonymous define() module: function($,customerData){
<script type="text/javascript">
    define(['Magento_Customer/js/model/customer'], function (customer) {
        if (customer.isLoggedIn()) {
            // Do your Logic.
        }
    });
</script>

Also i have tried the below code in phtml file to get customer data in js but it always return null or ko observer object.
<script type="text/javascript">
    require([ 'jquery', 'Magento_Customer/js/customer-data'],function($,customerData){
        var customer = customerData.get('customer')();
        console.log(customerData.fullname);
        if (customer.fullname && customer.firstname)
        {
            alert(customer.fullname);
        }else{
            alert(customer.fullname);
        }
    });
</script>


texts: PayPal glitch or Hack? Payments went to a random address

texts:
I'm either looking at a hacking attempt or a temporary PayPal glitch here. We're with PayPal Australia using PayPal Express. We're on Magento CE 1.7.0.2.

Luckily I had the PayPal Express module on debug all the way through. What I've managed to find after a good 4 hours is that the Magento admin wasn't compromised or the 'wrong email' wasn't hardcoded in the file system (according to the timestamp and server logs - who knows if it's a hacker that tidies these things up). A database compromise is looking unlikely too. We're running RDS on EC2.

This issue affected 3 payments. In the logs, first I can see:

[url] => https://api-3t.paypal.com/nvp
[SetExpressCheckout] => Array
    (
        [PAYMENTACTION] => Sale
        [AMT] => 999.00
        [CURRENCYCODE] => AUD
        [RETURNURL] => https://foobar/paypal/express/return/
        [CANCELURL] => https://foobar/paypal/express/cancel/
        [INVNUM] => 9999999
        [SOLUTIONTYPE] => Mark
        [GIROPAYCANCELURL] => https://foobar/paypal/express/cancel/
        [GIROPAYSUCCESSURL] => https://foobar/checkout/onepage/success/
        [BANKTXNPENDINGURL] => https://foobar/checkout/onepage/success/
        [LOCALECODE] => en_AU
        [SUBJECT] => wrong@email.com
        [ITEMAMT] => 999.00

Obviously the wrong part is the [SUBJECT] where the 'possible hacker' put his/her email in somehow, I don't know how. But strangely enough, if this was the work of a hacker, then he/she kindly put everything back for us and erased all traces, reset the timestamps, and removed entries from the server logs.

After 3 payments going to the wrong email address, this shows up in the log:

[exception] => Requested wrong@email.com and configured right@email.com merchant emails do not match.

Then the order after that, the payments resume going to the right address.

Now, that's a lot of background information but my question is - when is the exact time that the PayPal module logs the array [SetExpressCheckout]? Is it possible that Magento has already gotten a response back from PayPal at this stage - or is that email definitely originating from our server?

We're using the Magento one page checkout.

EDIT: I do notice that the single log entry contains the PayPal response as well - so at the time of Magento logging this information, it's already heard back from PayPal. Very puzzling stuff but nevertheless interesting.


texts: Magento 2.2.1 Show Msrp and Actual price on Category list page?

texts: I want to show MSRP and actual price on product listing page without pop up.


texts: Magento 2: Upload JPEG/PNG Image via API

texts:
I'm trying to rework a custom script that upload products to the e-commerce but firstly we implement the base64 encoding via Magento and we took almost 16/17 sec of API call (a lot).
We need to get something that works around 5/6 sec and we think to first convert the image from base64 to jpeg/png but we can't find a way to send image automatically to Magento.
So, the question is: Is there a way to send plain jpeg/png images to use with products via API?


texts: How to show time chooser in datepicker on magento configuration

texts:
I am trying to display time chooser in magento date picker but it didn't how up.

can anyone please guide on this how to set timer in magento system confif.

I have followed This Link but it show only date picker.


texts:
I have modified the review form as popup modal in my custom module. And now How to submit a Review form in ajax and need to pass the submitted values to controller, Please provide me a solution.
My js will look like below before ajax submission

js file

 define(['jquery', 'Magento_Ui/js/modal/modal'], function (jQuery, modal) {
    return function (config) {

        var customFunction = {
            ajaxSubmit: function () {
                var nickname = jQuery("#nickname_field").val();

                var review = jQuery("#review_field").val();

                var rating = jQuery(".field required review-field-ratings").val();

                alert(nickname);
                alert(review);
                alert(rating);
                var reviewurl = config.url;
                alert(reviewurl);
                jQuery.ajax({
                    url: reviewurl,
                    type: 'POST',
                    //Order id and reason passed to the controller
                    data: {'nickname': nickname, 'review': review, 'rating': rating, },
                    success: function (response) {
                        alert("successful");
                    },
                    error: function (response) {
                        alert("failed");
                    }
                });
            },

            options: {
                type: 'popup',
                responsive: true,
                innerScroll: true,
                title: jQuery.mage.__('Product Review'),
                buttons: [{
                        text: jQuery.mage.__('submit'),
                        class: '',
                        click: function () {
                            //Ajax function call
                            customFunction.ajaxSubmit();
                            var close = this;
                            setTimeout(function () {
                                close.closeModal();

                            }, 3000);
                        }
                    }]
            }
        };
        jQuery(".product-reviews-summary").on('click', function () {
            modal(customFunction.options, jQuery('#popup-modal'));
            jQuery("#popup-modal").modal("openModal");

        });
        jQuery(".add-review").on('click', function () {
            modal(customFunction.options, jQuery('#popup-modal'));
            jQuery("#popup-modal").modal("openModal");

        });
        jQuery(".star-popup").on('click', function () {
            modal(customFunction.options, jQuery('#popup-modal'));
            jQuery("#popup-modal").modal("openModal");

        });
    };
});


texts: Catalog price rules just working a short time

texts:
I´ve set up several catalog price rules. After applying them everything works fine.

Some days later (it´s a testshop and I dont look after the prices every day) the discounted prices showing up in frontend but if I click on the article the price rules arent active anymore -> first thing u see is a working price rule -> checkout or articlepage -> undiscounted price.

So i applied all the rules again and it worked (checkout too).
That was about three days ago - now I´ve got the same problem and I got it working same way as before.

This shop will go live on january 1th so I´m a bit scared of checking it every day... I dont know why this happens neither when.

Maybe someone got this issue too? (catalog price rules seems to disapply in articlepage and checkout after some time)


texts: I need a specific equation on some parts of my website, the question is: is it better to create a module, or put all the code in phtml files?


texts:
I dug up the "stack" and found one good example of how to add new attribute to the field but it won't work.

    $founderFieldset->addType('text', 'Amber_SupaSlid_Block_Adminhtml_Text');
    $founderFieldset->addField('founder_name', 'text', array(
        'label'     => Mage::helper('vendors')->__('Founder Name'),
        'required'  => true,
        'class'     => 'required-entry',
        'name'      => 'founder_name',
        'placeholder' => $this->__('Blah blah...')
    ));

in this case I got blank page (just navbar and title).
In case I use:

    $founderFieldset->addType('text',
    $fieldset->addType('text', Mage::getConfig()->getBlockClassName('supaslid/adminhtml_text'));
    );

Error 500 ....
I forgot to mention that there is no errors in logs as well :) the only error I can see it console log where it deffinitely saying there is a code problem (500) so I assume the "renderer" does not work regardless it's position/location which is correct, class name as well.


texts: How to remove header footer and left bar on ui component in magento 2

texts: I want to just show the customer table on page and need to remove header footer and left bar as well.How i can achieve it.


texts: Magento 2 need to get custom module image url from admin

texts:
I need to get asset image url in block file

Here is my code:

I have image on this page: logo.svg

\Abc\Mkt\view\adminhtml\web\images

Abc\Mkt\Block\image.php

namespace Abc\Mkt\Block;

use Magento\Backend\Block\Template\Context;
use Magento\Config\Block\System\Config\Form\Field;
use Magento\Framework\Data\Form\Element\AbstractElement;

class Image extends Field
{
    /**
     * @var string
     */

    /**
     * @param Context $context
     * @param array $data
     */
    protected $_assetRepo;
    public function __construct(
        Context $context,
        \Magento\Framework\View\Asset\Repository $assetRepo,
        array $data = []
    ) {
        $this->_assetRepo = $assetRepo;
        parent::__construct($context, $data);
    }

    /**
     * Remove scope label
     *
     * @param  AbstractElement $element
     * @return string
     */
    public function render(AbstractElement $element)
    {
        $image = $this->_assetRepo->getUrl("Abc_Mkt::images/logo.svg");
        $html='

';
        return $html;
    }
}


texts: Special prices are not displaying in magento

texts:
special prices are not displaying here. but we mentioned values for both prices and special prices. no "from-date" and to-date" set for special price. we can found special prices values  in admin panel. but it's displaying in frontend.

please help me to find solution.

thanks in advance.


texts: Error after trying to update custom columns

texts:
Im trying to update a column, but no succces, im getting a error of:

Fatal error: Uncaught ArgumentCountError: Too few arguments to function Zend_Db_Adapter_Abstract::update(), 1 passed in ..Model\Observer.php on line 76 and at least 2 expected in ..\lib\Zend\Db\Adapter\Abstract.php:590 Stack trace: #0 ..\Model\Observer.php(76): Zend_Db_Adapter_Abstract->update('UPDATE sales_fl...')

Here is my code, dont understand what is wrong with it:

  $resource = Mage::getSingleton('core/resource');
        $writeConnection = $resource->getConnection('core_write');
        $themeTable = $resource->getTableName('sales_flat_order');

       $order = $observer->getEvent()->getCreditmemo()->getOrder();

        $sql1 = "UPDATE " . $themeTable . " SET finance_invoice_url = 'teste' WHERE entity_id = ".$order->getId();//update
        $writeConnection->update($sql1);

Following the link example online:

$writeConnection->update(
            $themeTable,
            array("finance_invoice_url" => "teste", "finance_invoice_id" => 2),
            "entity_id =".$order->getId()
        );


texts: Stop Zoom on small images on Magento 1.9.0.1 RWD theme

texts:
I cant seem to stop the new rwd zoom from trying to zoom even on small images works fine for images that are bigger than the product image dispaly area box but with a small image the zoom still activates and displays the identical sized image as the zoom which looks a mess.

In the old Magento versions i think the zoom never activated if the image was smaller than the image holder, but i cant find how to stop it in 1.9.0.1 rwd.

Any ideas would be great, many thanks


texts: Magento 2: Facing Error -> Uncaught TypeError: data.some is not a function

texts:
I am using magento version 2.2.2. From yesterday I suddenly started getting error when I try to add a new product. Spinner continue to move on this page but having this error on console.

Uncaught TypeError: data.some is not a function
at findFirst (select.js:71)
at UiClass.clear (select.js:295)
at UiClass.setInitialValue (select.js:309)
at UiClass.setInitialValue (/static/version1527225664/adminhtml/Magento/backend/en_US/mage/utils/wrapper.js:109)
at UiClass.initialize (abstract.js:73)
at UiClass.initialize (/static/version1527225664/adminhtml/Magento/backend/en_US/mage/utils/wrapper.js:109)
at UiClass._super (/static/version1527225664/adminhtml/Magento/backend/en_US/mage/utils/wrapper.js:106)
at UiClass.initialize (select.js:123)
at UiClass.initialize (/static/version1527225664/adminhtml/Magento/backend/en_US/mage/utils/wrapper.js:109)
at new UiClass (/static/version1527225664/adminhtml/Magento/backend/en_US/Magento_Ui/js/lib/core/class.js:49)

  See image attached

Kindly Help me to resolve this issue. Much Appreciated your help, thanks in Advance :)


texts: Magento 2 google recaptcha for wishlist popup

texts: I have enabled google recaptcha it show all the forms but when i click the wishlist as guest user it shows the popup in that popup google recaptcha not loaded, how to show google recaptcha ?


texts:
I am getting the errors below
[2021-01-18 10:55:22] main.DEBUG: URI '/customer/account/loginPost/referer/aHR0cHM6Ly93d3cuY2xpY2tzYXZlYW5kcHJpbnQuY29tL2NhdGFsb2cvcHJvZHVjdC92aWV3L2lkLzEwMzYyMy8jcmV2aWV3LWZvcm0,/'' cannot be accessed with GET method (Magento\Customer\Controller\Account\LoginPost) [] []
[2021-01-18 10:55:22] main.DEBUG: Request validation failed for action "Magento\Customer\Controller\Account\LoginPost\Interceptor" {"exception":"[object] (Magento\\Framework\\App\\Request\\InvalidRequestException(code: 0): Invalid request received at /home/clicksav/public_html/vendor/magento/framework/App/Request/HttpMethodValidator.php:69)"} []

[2021-01-18 10:55:29] main.DEBUG: URI '/checkout/cart/add/uenc/aHR0cHM6Ly93d3cuY2xpY2tzYXZlYW5kcHJpbnQuY29tL2Jyb3RoZXItbGMtMjIxY2N5YW4taW5rLWNhcnRyaWRnZS1sYzIyMWM,/product/99216/'' cannot be accessed with GET method (Magento\Checkout\Controller\Cart\Add) [] []
[2021-01-18 10:55:29] main.DEBUG: Request validation failed for action "Magento\Checkout\Controller\Cart\Add\Interceptor" {"exception":"[object] (Magento\\Framework\\App\\Request\\InvalidRequestException(code: 0): Invalid request received at /home/clicksav/public_html/vendor/magento/framework/App/Request/HttpMethodValidator.php:69)"} []

These constantly appear in the debug.log file and i am not sure how to find the error.
I am using magento 2.4.1, PHP 7.3, MySQL 8, Elastisearch 7.10
I also had these errors on version 2.3.6 but i wasnt on that version for long and hoped it would be fixed when upgrading but it wasnt.
Any help debugging would be helpful.


texts: Magento's Secure/Unsecure Image Link - Link Securely for Secure Pages only

texts:
I have installed an SSL certificate on my site but have found that when using this image source address:

<img src="{{media url='wysiwyg/infortis/ultimo/menu/featured2.jpg'}}"

I receive an error saying that not all page content is secure.

When I change to:

<img src="https://mywebsite.com/media/wysiwyg/infortis/ultimo/menu/featured2.jpg"

Then everything works fine.

The problem is that I do not wish to deliver this image via HTTPS for nonsecure pages as I believe this may cause pages to load slower.

How can I link to the image in a way that will use Magento's secure/unsecure system correctly?


texts: new products on home page magento CE1.9 with rwd theme

texts:
having used the following code in the home page cms screen

{{block type="catalog/product_new" name="home.catalog.product.new" alias="product_homepage" template="catalog/product/new.phtml"}}

this displays the new products on the home page no problem, when the screen is full width, with one exception, it doesnt centralise them on the screen

Also the rwd theme is totaly responsive which is awesome, except for this new products block. you can see when you shrink the screen size down (or look on tablets or mobiles) the layout is totaly broken

anyone got any ideas how i can fix this, i just want 4 products displayed and to be responsive like the rest of the site

any help much appreaciated.
thanks


texts: Magento 2 - Creating Configurable product show 404

texts:
I have just upgraded to Magento 2.4 and when I try and create a Configurable product it takes a while to save but redirected to a 404 page in the admin panel. The product still saves and still comes up in the frontend which is positive.
However, how do I resolve the issue as it is an inconvenience when creating mass amounts of products in a short space of time.
Thanks in advance.


texts: How to get all state code in magento 2.1.7?

texts:
I am passing the parameters as

'recipientstate' => $customer['region'] and

'cardholderstate' => $customerbilling['region']

Right now I am getting the region value's as ARIZONA , but I want it as AZ in Magento 2.1.7

How to get the solution for this.. I googled a lot but not able to find perfect answer

Any help would be appreciated.


texts: Magento 2 add text input to massaction from dropdown

texts:
In magento 1, if I wanted to add a text input to send a custom value with my massaction to my controller, I would do something like:
$this->getMassactionBlock()->addItem('add_ship_method', array(
    'label'=> Mage::helper('sales')->__('Add Shipping Method'),
    'url'  => $this->getUrl('*/custom_admin_route/changeship'),
    'additional' => array(
        'ship_method' => array(
            'name' => 'ship_method',
            'type' => 'text',
            'class' => 'required-entry',
            'label' => 'Shipping Method'
        )
    )
);

But for Magento 2, I'm at a loss for how to add a custom text input, similar to the functionality described above.
It seems like a pretty simple feature to add, so I'm assuming I'm just not googling the right thing.


texts: Get every category with its sub categories without module

texts:
I need to get category list with sub categories. I've found multiple solutions that I may need to create a module and get category list inside module's template file. But I need to do this without creating a module. How can I do it?

I tried creating a class and I used those included magento classes in the answers I mentioned with use inside my phtml file, before declaring my class. but it didn't work.

Is it possible to get every category with its sub categories (and if sub category has its own sub category, I need to get it too ) without creating a module? if so, how can I do it? (I need to do this inside single phtml file)


texts:
> Check Cron Scripts Cron script readiness check failed. Hide detail
>
> Error from Updater Application Cron Script:
>
> Found non-writable path(s): /var/www/html/pub/media/.htaccess
> /var/www/html/pub/media/customer/.htaccess
> /var/www/html/pub/media/downloadable/.htaccess
> /var/www/html/pub/media/import
> /var/www/html/pub/media/theme_customization/.htaccess
>
> For additional assistance, see cron scripts help.

I tried on chmod -R 777 on var/www/html &

find var vendor pub/static pub/media app/etc var/cache var/generation -type d -exec chmod u+w {} \;

find var vendor pub/static pub/media app/etc var/cache var/generation -type f -exec chmod u+w {} \;

chmod u+x bin/magento

It is not working still,need suggestion to fix this


texts: Magento 2.2.2 Upgrade failed due to Dotmailer severe issues API endpoint

texts:
I hope someone else has seen this issue. We do have an email program to send follow-on emails to clients after a set time in our previous 2.1.9 install.

We upgraded using composer to 2.2.1 and all "looked good" (not thoroughly tested).

So we decided since 2.2.2 is better than 2.2.1 - to try that upgrade. On web set up wizard it just stops on update pending. On trying the upgrade with composer it seems to go smoothly but when admin or web site is opened there is a big error and the exception log shows

main.CRITICAL: Dotmailer connector API endpoint cannot be empty. {"exception":"[object] (Magento\Framework\Exception\LocalizedException(code: 0): Dotmailer connector API endpoint cannot be empty.

I don't know how dot mailer could think that I had ever used it. But regardless, is there a way to upgrade and INSIST that dotmailer not be added? Or is there a fix for this issue? Workaround?


texts: I am confused in creating attribute and in creating attribute set. Kindly help me

texts:
If there is two category for example say category A and category B and they are attributes with name size and color and i wanted to add color in cat-A as well as cat-B but " In filters of cat-A it should show " Delight Colors " and in cat-B it should show " Beautiful Colors " " but the colors remains the same only the name in the header changes.

So will i have to add different attribute for both categories A and B. Like Beautiful colors attribute for category A and Delight colors attribute for category B OR Question: Should i only add colors as the main category.?
Answer: If yes,than how to assign the name delight and beautiful to colors.

KINDLY CHECK THE IMAGE
![3 Different categories with different name but all the colors are same
]1

3 Different categories with different name but all the colors are same


texts:
When I'm seraching product title "Mixer, Ribbon, 25 CF, 304 S/st, 15 HP, New, HD, (2)" on the website, then getting following error:-

2 exception(s):
    Exception #0 (Zend_Db_Statement_Exception): SQLSTATE[42000]: Syntax error or access violation: 1064 syntax error, unexpected $end, expecting FTS_TERM or FTS_NUMB or '*', query was: INSERT INTO `search_tmp_5b97c02fa7b3d4_51710438` SELECT `main_select`.`entity_id`, SUM(score) AS `relevance` FROM (SELECT DISTINCT  `eav_index`.`entity_id`, (((0)) * 1 + LEAST((MATCH (data_index) AGAINST ('Mixer* Ribbon* 25 CF 304* S st 15 HP New* HD 2 ribbon* mixer\"ribbon* blender\"*' IN BOOLEAN MODE)), 1000000) * POW(2, search_weight)) AS `score` FROM `catalog_product_index_eav` AS `eav_index`
     INNER JOIN `catalogsearch_fulltext_scope1` AS `search_index` ON eav_index.entity_id = search_index.entity_id
     INNER JOIN `catalog_eav_attribute` AS `cea` ON search_index.attribute_id = cea.attribute_id
     INNER JOIN `cataloginventory_stock_status` AS `stock_index` ON stock_index.product_id = eav_index.entity_id AND `stock_index`.`website_id` = 0 AND `stock_index`.`stock_status` = 1 AND `stock_index`.`stock_id` = 1 WHERE (eav_index.store_id = '1') AND (`eav_index`.`attribute_id` = 85 AND `eav_index`.`value` in ('3', '4') AND `eav_index`.`store_id` = '1') AND (MATCH (data_index) AGAINST ('Mixer* Ribbon* 25 CF 304* S st 15 HP New* HD 2 ribbon* mixer\"ribbon* blender\"*' IN BOOLEAN MODE))) AS `main_select` GROUP BY `entity_id` ORDER BY `relevance` DESC, `entity_id` DESC
     LIMIT 10000
    Exception #1 (PDOException): SQLSTATE[42000]: Syntax error or access violation: 1064 syntax error, unexpected $end, expecting FTS_TERM or FTS_NUMB or '*'

Exception #0 (Zend_Db_Statement_Exception): SQLSTATE[42000]: Syntax error or access violation: 1064 syntax error, unexpected $end, expecting FTS_TERM or FTS_NUMB or '*', query was: INSERT INTO `search_tmp_5b97c02fa7b3d4_51710438` SELECT `main_select`.`entity_id`, SUM(score) AS `relevance` FROM (SELECT DISTINCT  `eav_index`.`entity_id`, (((0)) * 1 + LEAST((MATCH (data_index) AGAINST ('Mixer* Ribbon* 25 CF 304* S st 15 HP New* HD 2 ribbon* mixer\"ribbon* blender\"*' IN BOOLEAN MODE)), 1000000) * POW(2, search_weight)) AS `score` FROM `catalog_product_index_eav` AS `eav_index`
 INNER JOIN `catalogsearch_fulltext_scope1` AS `search_index` ON eav_index.entity_id = search_index.entity_id
 INNER JOIN `catalog_eav_attribute` AS `cea` ON search_index.attribute_id = cea.attribute_id
 INNER JOIN `cataloginventory_stock_status` AS `stock_index` ON stock_index.product_id = eav_index.entity_id AND `stock_index`.`website_id` = 0 AND `stock_index`.`stock_status` = 1 AND `stock_index`.`stock_id` = 1 WHERE (eav_index.store_id = '1') AND (`eav_index`.`attribute_id` = 85 AND `eav_index`.`value` in ('3', '4') AND `eav_index`.`store_id` = '1') AND (MATCH (data_index) AGAINST ('Mixer* Ribbon* 25 CF 304* S st 15 HP New* HD 2 ribbon* mixer\"ribbon* blender\"*' IN BOOLEAN MODE))) AS `main_select` GROUP BY `entity_id` ORDER BY `relevance` DESC, `entity_id` DESC
 LIMIT 10000

Please help me to resolve this issue.


texts: Add Continue Shopping button in checkout page Magento 2.3.1

texts:
Can anyone help me on how to add the "Continue Shopping" button?

please see attached screenshot.
https://imghostr.com/ySnHx3Cb


texts: NGINX 404 error despite Magento Installation complete on CentOS 7 terminal

texts:
I am trying to load the /admin part of my development build of the website. I am unsure what could be the cause of this.

Using this command: (Some of these details are intentionally not in line with our actual configuration)

bin/magento setup:install \
--base-url=http://localhost/ \
--db-host=localhost \
--db-name=magento \
--db-user=root \
--db-password='password' \
--backend-frontname=admin \
--admin-firstname=admin \
--admin-lastname=admin \
--admin-email=admin@admin.com.au \
--admin-user='admin' \
--admin-password='password' \
--language=en_US \
--currency=AUD \
--timezone=Australia/Sydney \
--use-rewrites=1

I want to be able to use the Magento admin panel as described on my CentOS 7 terminal window.

[SUCCESS]: Magento installation complete.
[SUCCESS]: Magento Admin URI: /admin
Nothing to import.

I came to this result after following Magento DevDocs on the nginx section of this documentation. However, I seem to be getting to this page when I went onto my browser window:

  The page you are looking for is not found.

As a form of troubleshooting, I have gone through /etc/nginx/conf.d/default.conf but I am unsure what the proper values are supposed to be in server_name. I have currently appointed the value currently to 127.0.0.1:8080 while listening to port 80 (potential answer...?)

Here is my current setup so far:

centos 7
nginx/1.12.2
php/7.2.16
mariadb/10.3.13 (mysql 15.1)
magento 2.3 community edition
composer/1.8.4
apache/2.4.6

I'm primarily trying to use nginx as a reverse proxy for apache so that it can support higher traffic volumes and still be able to utilize the .htaccess  file (and retain functionality opportunities of the apache system).

This is a development environment, so I am willing to try experimental changes onto this server.

The /var/log/nginx/error.log is currently empty.

I know for sure that I am not implementing this properly so any ideas, comments or suggestions will much be appreciated.