texts: "Created From" is a required value. when adding a new customer

texts:
Everytime I attempt to add a new customer via the admin panel I am stopped in my tracks by the error

  "Created From" is a required value.

Looking at all the available options to fill, this is not one of the options.

Now looking at the Database I can see it is in the eav_attribute table:

I have not added any custom attribute to the customer for admin. So, must be a default system attribute. Now, I was wondering why this attribute ain't showing up in the admin=> add new customer ? I haven't made any changes to admin.

Is there a way I can get this to show?


texts: Magento 2.How get data of customer_entity_text table?

texts:
I create extra field in reg.form ('other_data')
after registration -> in table 'customer_entity_text is created row  with:
'entity_id' 'value'
I need this rows, how I can get this? ty fow answer


texts: Magento 2 - Call custom phtml before order grid

texts:
I want to show statistics graph in custom phtml.

My question is, how can I call my custom.phtml before order grid


texts: Magento 2.2.5 How to display item prices out of stock

texts:
Even if Magento 2.2.5 Configrable Product is out of stock, I want to display the item price.

How can I see the price?


texts: Getting error "Call to a member function setTitle()" after install extension

texts:
I have installed an extension on the website. After that I am getting error on the website:

  Fatal error: Uncaught Error: Call to a member function setTitle() on
  boolean in
  /var/www/example/app/code/core/Mage/Customer/Block/Form/Register.php:43
  Stack trace: #0
  /var/www/example/app/code/core/Mage/Core/Block/Abstract.php(297):
  Mage_Customer_Block_Form_Register->_prepareLayout() #1
  /var/www/example/app/code/core/Mage/Core/Model/Layout.php(456):
  Mage_Core_Block_Abstract->setLayout(Object(Mage_Core_Model_Layout)) #2
  /var/www/example/app/code/core/Mage/Core/Model/Layout.php(472):
  Mage_Core_Model_Layout->createBlock('customer/form_r...',
  'customer_form_r...') #3
  /var/www/example/app/code/core/Mage/Core/Model/Layout.php(239):
  Mage_Core_Model_Layout->addBlock('customer/form_r...',
  'customer_form_r...') #4
  /var/www/example/app/code/core/Mage/Core/Model/Layout.php(205):
  Mage_Core_Model_Layout->_generateBlock(Object(Mage_Core_Model_Layout_Element),
  Object(Mage_Core_Model_Layout_Element)) #5
  /var/www/example/app/code/core/Mage/Core/Model/Layout.php(206):
  Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Mo in
  /var/www/example/app/code/core/Mage/Customer/Block/Form/Register.php
  on line 43

How to fix the issue?


texts: How to make a Field only accept Numbers in Magento 2

texts:
I am new to Magento 2.

I am trying to make a field that can only accept numbers for Sort Order field  on UI Component Form

I need help


texts: Magento 2: How to move Product page Review Section from tabs to Bottom of page?

texts:
I have referred this link i.e Product page Review Section from tabs to Bottom of page and followed the same. I also got the same result.

vendor\magento\theme-frontend-luma\Magento_Theme\layout\default.xml

I added below code :

   <referenceBlock name="reviews.tab" remove="true" />
    <referenceContainer name="content">
        <container name="new_space" htmlTag="div" htmlClass="container" after="-">
            <block class="Magento\Review\Block\Product\View\ListView" name="product.info.product_additional_data" as="product_additional_data" template="product/view/list.phtml" />
        </container>
    </referenceContainer>

app\design\frontend\Test\review\etc\module.xml

    <?xml version="1.0"?>
          <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../lib/internal/Magento/Framework/Module/etc/module.xsd">
             <module name="Test_review" setup_version="1.0.0">
                 <sequence>
                     <module name="Magento_Catalog"/>
                 </sequence>
            </module>
         </config>

app\design\frontend\Test\review\Magento_Catalog\layout\catalog_product_view.xml

     <?xml version="1.0"?>
        <page layout="1column" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
         <body>
              <move element="reviews.tab" destination="content" after="-"/>
          </body>
       </page>

Home page I am getting error

   PHP Fatal error: Uncaught Error: Call to a member function getId() on null in /chroot/home/londonwa/londonwala.in/html/vendor/magento/module-review/Block/Product/View.php:131


texts: How to put script before body in Magento version 2.1?

texts:
I tried to insert in the home page a jquery horizontal slider text scroll. What I need is to insert before body two scripts.

<script type="text/javascript" src="/jquery/marquee.js"></script>

<script>
$(function (){
  $('.simple-marquee-container').SimpleMarquee();
});
</script>

What I tried so far is in example in a relative question.

In my console log I have the below errors and of course it didn't work:

JQMIGRATE: Logging is active jquery-migrate.js:21
Uncaught TypeError: $.widget is not a function

You can see the full errors log in my site http://magentoeshop.vtsoulis.gr/index.php/


texts:
When I click on Manage Categories from admin it show me this error

  Magento Commerce There has been an error processing your request
  Exception printing is disabled by default for security reasons.

  Error log record number: 429737294153


texts: I am unable to set the backgroundColor for some reason - M2.3.3

texts:
The issue does not make any sense, The helper is called and defined and I am only adjusting the image properties prior resizing from being initialised as the following:

$productImage = $_imagehelper->init($_product, $image)->backgorundColor(array(255,255,255))->resize($image_width, $image_height);
                            $productImageUrl = $productImage->getUrl();

And the error log as the following:

2020/01/08 21:35:49 [error] 25238#25238: *2028200 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught Error: Call to undefined method Magento\Catalog\Helper\Image::backgorundColor() in /home/***/m2/public/app/design/frontend/****/***/Smartwave_Filterproducts/templates/grid.phtml:84
Stack trace:
#0 /home/***/m2/public/vendor/magento/framework/View/TemplateEngine/Php.php(59): include()
#1 /home/***/m2/public/vendor/magento/framework/View/Element/Template.php(271): Magento\Framework\View\TemplateEngine\Php->render(Object(Smartwave\Filterproducts\Block\Home\FeaturedList\Interceptor), '/home/***/m2/...', Array)
#2 /home/***/m2/public/vendor/magento/framework/View/Element/Template.php(301): Magento\Framework\View\Element\Template->fetchView('/home/***/m2/...')
#3 /home/***/m2/public/vendor/magento/framework/View/Element/AbstractBlock.php(1097): Magento\Framework\View\Element\Template->_toHtml()
#4 /home/***/m2/public/vendor/magento/framework/View/Element/AbstractBlock.php(1101): Magento\Framework\View\Element\AbstractBlock->Magento\Framework" while reading response header from upstream, client: **********, server: ***.com, request: "GET / HTTP/1.1", upstream: "fastcgi://127.0.0.1:9000", host: "***.com", referrer: "https://***.com/****.html"


texts: How to change advanced search frontend URL in magento2

texts:
I want to change frontend URL

  www.example.com/catalogsearch/advanced

to

  www.example.com/testurl

in magento2.

Also, How can I use the advanced search on any CMS page.


texts: How to overwirte Catalog model in Magento 2

texts:
I try to overwrite  get_url() function located in item.php from this path \vendor\magento\module-catalog\Model\Layer\Filter\Item.php

To overwrite this function I fount 2 ways, with PREFERANCES and PLUGINS

I want to use PLUGIN method, and i found this example :

    <?xml version="1.0"?>

    <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
        <type name="Magento\Catalog\Model\Product">
            <plugin name="yourcompany-yourmodule-product-model" type="YourCompany\YourModule\Plugin\ProductPlugin" sortOrder="1" />
        </type>
    </config>

**and**

<?php

namespace YourCompany\YourModule\Plugin;

class ProductPlugin
{
    public function beforeSetName(\Magento\Catalog\Model\Product $subject, $name)
    {
        // logging to test override
        $logger = \Magento\Framework\App\ObjectManager::getInstance()->get('\Psr\Log\LoggerInterface');
        $logger->debug('Model Override Test before');

        return $name;
    }

    public function afterGetName(\Magento\Catalog\Model\Product $subject, $result)
    {
        // logging to test override
        $logger = \Magento\Framework\App\ObjectManager::getInstance()->get('\Psr\Log\LoggerInterface');
        $logger->debug('Model Override Test after');

        return $result;
    }
}
?>

But i don't know how will be for my item.php file. can anyone tell me how to modify this example to fit with my issue?


texts: ReferenceError: initializeFieldsetDataByDefault is not defined Upgrade issue Magento 2.2.2

texts:
I have upgraded website from 2.0.7 to Magento 2.2.2 but when i try to open product or category in admin than console showing me below error.

ReferenceError: initializeFieldsetDataByDefault is not defined

Also exception log is showing below error

main.CRITICAL: The element 'gallery' already has a child with alias 'content' {"exception":"[object] (Magento\\Framework\\Exception\\LocalizedException(code: 0): The element 'gallery' already has a child with alias 'content' at /var/www/vhosts/httpdocs/vendor/magento/framework/Data/Structure.php:611)"} []

You can see the screenshot below for admin layout.

https://prnt.sc/iby5fv

Let me know if any one has a solution.

Looking forward to your reply.


texts: Adding items to order as order is placed

texts:
I am trying to add a zero cost product to all shopping carts at time of placing order.  So far I have my observer setup and working as

<events>
    <sales_order_place_before>
        <observers>
            <custom_promopack_order_observer>
                <type>singleton</type>
                <class>custom_promopack/observer</class>
                <method>addPromoPack</method>
            </custom_promopack_order_observer>
        </observers>
    </sales_order_place_before>
</events>

For my observer class I start with

class Custom_PromoPack_Model_Observer
{

public function addPromoPack(Varien_Event_Observer $observer)

{

    $productId = 2;
    $qty = 1;
    $promo = Mage::getModel('catalog/product')->load($productId);

    $order = $observer->getEvent()->getOrder();
    $quote = $order->getQuote();
    $item  = $observer->getQuoteItem();

    $quoteItem = Mage::getModel('sales/quote_item')
        ->setProduct($promo)
        ->setQuote($quote)
        ->setQty($qty)
        ->save();

    $orderItem = Mage::getModel('sales/convert_quote')
        ->itemToOrderItem($quoteItem)
        ->setOrderID($order->getId())
        ->save();

}
}

The above is throwing the error

Recoverable Error: Argument 1 passed to Mage_Sales_Model_Convert_Quote::itemToOrderItem() must be an instance of Mage_Sales_Model_Quote_Item_Abstract, null given

However when I replace the $quoteItem with

$item->setProduct($promo)
        ->setQuote($quote)
        ->setQty($qty)
        ->save();

It successfully adds the item to the order, except it adds it with the price of the original item added.  Thankfully this does not actually increase the price of the cart, but I can tell it is not completely working as intended due to this.

How can I add the item I am intending while keeping the cost of the item at zero? To sum everything up, I am just attempting to grab the order add on a free item and save it to the order.


texts:
I am trying to build an android app for magento. I wish to leverage magento XML connect for this. Currently I am unable to call any of the admin URL's(with XML connect). All of them return a 404 error.

a sample url is:
http://localhost/magento/admin/xmlconnect/user/login
returns 404(not found)

Please let know if i am doing anything wrong.


texts:
I want AWS CloudFront to be implemented on production for a Magento 2 site.

i would like to know what changes are required to change the path of images and audio/ video files, to setup on S3 bucket.

Please note that the site will remain same, its just the media files will be moved to S3 bucket on AWS.


texts: Magento 2 : How to get download link of downloadable product in product detail page

texts:
I would like to create a download link to the uploaded file on a downloadable product.

All downloadables do not have price and customers do not need to purchase them

Replace Add To Cart button with Download(clicking on download button will download file directly)


texts:
How do i programmatically check if a catalog pricerule is active or not?

I have tried loading collection like this, where 13 is ID of the catalog rule:

$catalog_rule = Mage::getModel('catalogrule/rule')->load(13);

And then use

if (!empty($catalog_rule)) {
    echo 'foo';
}

This always returns true nomatter if rule is active or not.

How do i check if catalog price rule is not empty and is active?


texts: How to use some function in configurable.js in custom phtml in magento 2

texts:
I want to use the _getSimpleProductId function of configurable.js in my custom phtml file.

What i want to achieve is get the product id according to the customer select the configurable options.

I moved the configurable.js to my custom theme too.

How to override the configurable.js or how can i reuse this method(_getSimpleProductId)


texts: Trying to rewrite getMediaDir in Mage_Core_Model_Config_Options

texts:
I have successfully managed to change the destination of CMS wysiwyg folder thanks to Marius, here but that is relative to media dir that is defauled to ./media.

Now I have made module to change the core fn getMediaDir but somehow I think it is somewhere else defined,, but I can't find where?

This is what I defined for module:

http://i.stack.imgur.com/Je7vY.png

<?xml version="1.0"?>
<config>
  <modules>
    <Mk_Hub>
      <version>0.1.0</version>
    </Mk_Hub>
  </modules>
  <global>
    <helpers>
      <hub>
        <class>Mk_Hub_Helper</class>
      </hub>
    </helpers>
    <models>
      <hub>
        <class>Mk_Hub_Model</class>
        <resourceModel>hub_mysql4</resourceModel>
      </hub>
            <core>
                <rewrite>
                    <config_options>Mk_Hub_Model_Core_Config_Options</config_options>
                </rewrite>
            </core>
    </models>
  </global>
</config>

and :

<?php
class Mk_Hub_Model_Core_Config_Options extends Mage_Core_Model_Config_Options
{

    public function getMediaDir()
    {
        return $this->getBaseDir().DS.'media' . '/' . 'subdir1');
        // return $this->_data['media_dir'];
    }

}


texts:
I just change to default theme, in my site www.fashionbelow.com, My SEO company wants me to put in the h1 tags to help with the Search engine rankings. Where can I put these in? Can I put them in using the ADMIN panel or do I have to put them into the actual code?

Thank you so much for any suggestions.


texts: Update Magento 2 using composer update (CLI)

texts:
Magento recommends a web based upgrade procedure. Upgrading through git is not recommended for production envs, as Alan Kent states below.

However, with the recommended /pub as docroot, the web update code is unavailable. What is the recommended way to upgrade through CLI?

I took the composer.json from the 2.0.1 tag and ran composer update --no-dev but it fails with:

  [ErrorException]
  Source /var/www/magento2/vendor/magento/magento2-base/dev/tests/integration/.gitignore does not exist


texts: Request does not match any routes when generate invoice of order

texts: I have created a custom payment method that place order successfully but when i tried to generate invoice for it ,it shows request does not match any routes.Any idea?


texts: Configurable swatches Not working Magento 1.9

texts: Configurable swatches Not working on product page it is not selection.


texts:
How to validate all form field

 if (!Zend_Validate::is($this->getRequest()->getPost('product[name]'), 'NotEmpty')) {
            $error = true;
            Mage::getSingleton('core/session')->addError(Mage::helper('example')->__('Please enter product name'));
        }

        if (!Zend_Validate::is($this->getRequest()->getPost('product[description]'), 'EmailAddress')) {
            $error = true;
            Mage::getSingleton('core/session')->addError(Mage::helper('example')->__('Please enter Email'));
        }

Using this code i am validate NotEmpty and EmailAddress but also i want to validate only number any other form validation so which class is use for all that


texts: magento2: add static block to header menu

texts:
My Categories are displayed in my Header Main menu. Now I want to add another link( called 'about us') after the last category in my header.
I plan to create a static cms block -> in it's content put some html:

        About Us

then add this static block to the header. How can I achieve this ?


texts: Product Images - Different Websites/Store Views

texts: I've got two websites in my Magento project which got single inventory catalog. I would like to upload different images to different Websites. I managed to use store_view_code for each image. Up to Category view page, the product images are appearing right way. However, when I click on product, the product page showing both the images. I managed to update hide_from_product_page property to hide one image. However, this property is not working for me when use CSV. When I have multiple store view codes, none of the images or hiding. May I know what am I doing wrong?


texts: Model factory create function not working

texts:
I am learning how to develop a CRUD module in magento 2. I have develop a module in which database is created through my setup file. But I am not able to use model in Block.

For this I have created my model file:

namespace CompanyName\Hello\Model;

class Test extends \Magento\Framework\Model\AbstractModel implements TestInterface, \Magento\Framework\DataObject\IdentityInterface
{
    const CACHE_TAG = 'hello_test';

    protected function _construct()
    {
        $this->_init('CompanyName\Hello\Model\ResourceModel\Test');
    }

    public function getIdentities()
    {
        return [self::CACHE_TAG . '_' . $this->getId()];
    }

    public function loadByTitle($title){
        if(!$title){
            $title = $this->getTitle();
        }
        $id = $this->getResource()->loadByTitle($title);
        return $this->load($id);
    }
}

And I have create my Block file:

<?php

namespace CompanyName\Hello\Block;

class Hello extends \Magento\Framework\View\Element\Template
{
    protected $_testFactory;
    protected $logger;
    public function __construct( \Magento\Framework\View\Element\Template\Context $context,
            \CompanyName\Hello\Model\TestFactory $testFactory, \Psr\Log\LoggerInterface $logger
    )
    {
        $this->logger = $logger;
        $this->_testFactory = $testFactory;
        parent::__construct($context);
    }

    protected function _prepareLayout()
    {
        $test = $this->_testFactory->create();
        $this->logger->info('after create');
        $test->setTitle('magento');
        $test->save();
        $this->setTestModel($test);
    }
}

But I am getting a blank page without any error. Currently I am working in Developer Mode. If I remove this code then my page is visible correctly.

Need an Urgent help.
Thanks.


texts: How to allow duplicate admin name values for color attribute in magento 2.3

texts:
As per Magento 2.3, it won't allow adding duplicate values for product attributes.

For the temporary purpose, I want to allow the duplicate value of Admin, under color attribute.

How can I restrict the condition programmatically?
in which file should I restrict the condition for duplication?


texts: How to get returned items in custom store credit email?

texts:
I have created a custom store credit email template, that will be used to sent as email for credit memo.
I am not much sure how do i add the returned items in it.
I have used {{layout handle="sales_email_order_creditmemo_items" creditmemo_id=$creditmemo_id order_id=$order_id}} but its not working in custom template
Any thoughts ?


texts: What is the best way to save a custom field in shipping address?

texts:
I have added a custom field on checkout in shipping address section using below code.

etc/frontend/di.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\Checkout\Block\Checkout\LayoutProcessor">
        <plugin name="ProcessAddressConfiguration" type="Vendor\Module\Block\Checkout\PassportProcessor"/>
    </type>
</config>

Block/Checkout/PassportProcessor.php

<?php
namespace Vendor\Module\Block\Checkout;

class PassportProcessor
{
    public function afterProcess(\Magento\Checkout\Block\Checkout\LayoutProcessor $processor, $jsLayout){

        $passport_no = 'passport_no';

        $newField = [
            'component' => 'Magento_Ui/js/form/element/abstract',
            'config' => [
                'customScope' => 'shippingAddress.custom_attributes',
                'customEntry' => null,
                'template' => 'ui/form/field',
                'elementTmpl' => 'ui/form/element/input',
                'tooltip' => [
                    'description' => 'description'
                ]
            ],
            'dataScope' => 'shippingAddress.custom_attributes.' . $passport_no,
            'label' => 'Passport Number',
            'provider' => 'checkoutProvider',
            'sortOrder' => 0,
            'validation' => [
                'required-entry' => true
            ],
            'options' => [],
            'filterBy' => null,
            'customEntry' => null,
            'visible' => true
        ];

        $jsLayout['components']['checkout']['children']['steps']['children']['shipping-step']['children']['shippingAddress']['children']['shipping-address-fieldset']['children'][$passport_no] = $newField;

        return $jsLayout;
    }
}

Questions:

In which tables I should save it so that when I pull the order, passport_no should be available in shipping address section of that order?
How I can save passport_no in those tables from here?

I went through multiple posts but I do not see a complete list of steps which should be taken to achieve it.


texts: how to add custom block at onepage checkout discount codes below?

texts:
I want to add custom block below discount codes.But no idea how to add?

because m2 using knockout.js and some new concepts like passing arguments to block in layout files.its totally confusing.


texts: Set quote item product custom weight no holding through shipping

texts:
I am trying to set a custom product weight based on a set product custom option.
I've tried multiple things like a plugin, before/after events, actual events like sales_quote_add_item etc.

I am able to set the product weight during these processes, but once I get to calculating shipping it seems to load the original product weight, not the weight from the quote_item table.

At this point I've removed everything except the sales_quote_add_item code.
Any help is appreciated, and thanks in advance.


texts: how to modify(new look) default popup alert in magento 1.9.x

texts:
how to modify and get new look default popup alert in Magento 1.9.x
Can you help me with anyone, please?
thank you!


texts: i add to custom filed in category form for upload image but facing issue that i mention below

texts:
string
                    category
                    Menu Image
                    true
                    fileUploader
                    ui/form/element/uploader/uploader
                    Magento_Catalog/image-preview
                    false
                   40

    <field name="image_banner">
        <argument name="data" xsi:type="array">
            <item name="config" xsi:type="array">
                <item name="dataType" xsi:type="string">string</item>
                <item name="source" xsi:type="string">category</item>
                <item name="label" xsi:type="string" translate="true">Banner Image</item>
                <item name="visible" xsi:type="boolean">true</item>
                <item name="formElement" xsi:type="string">fileUploader</item>
                <item name="elementTmpl" xsi:type="string">ui/form/element/uploader/uploader</item>
                <item name="previewTmpl" xsi:type="string">Magento_Catalog/image-preview</item>
                <item name="required" xsi:type="boolean">false</item>
               <item name="sortOrder" xsi:type="number">40</item>
                <item name="uploaderConfig" xsi:type="array">
                    <item name="url" xsi:type="url" path="sunny_catalog/category_banner/upload"/>
                </item>
            </item>
        </argument>
    </field>

Error

  file-uploader.js:74 Uncaught TypeError: value.map is not a function
      at UiClass.setInitialValue (file-uploader.js:74)
      at UiClass.initialize (abstract.js:77)
      at UiClass.initialize (wrapper.js:109)
      at new UiClass (class.js:49)
      at Object.initComponent (layout.js:137)
      at fire (jquery.js:3232)
      at Object.fireWith [as resolveWith] (jquery.js:3362)
      at Object.deferred.(/admin/catalog/category/index/key/5db0e6c2fed75d6118a879c215380e99c30f8d28c6a6d83414a674946b107297/anonymous
  function)
  (pub/static/adminhtml/Magento/backend/en_US/jquery.js:3461:37)
      at fire (jquery.js:3232)
      at Object.fireWith [as resolveWith] (jquery.js:3362)


texts:
I'm trying to install magento 2.2.6 on my local server but i'm facing permission issues.

How to set read write permissions to generated folder in windows7 with command line.

Thank you.


texts:
No matters what I do, in the checkout proccess where I've written all the shipping address, mercadoenvios shows error saying: sorry, mercadoenvios is not available at the moment..
I have checked twice, and the products have the attributes required by mercadoenvios: width, height, lenght, weight.. And each of them associated to the correspondent var in mercadoenvios..
So, any ideas what's wrong?


texts: Deleting bulk listings but there are not any changes in available space

texts: I have deleted about 17,000 listings from my Magento website, I have finished with Re-index and clear the cache but the available space is still 4GB as before deleting these listings. So, I should clear the cache from c panel too?


texts: Html tags are showing on frontend in custom module textarea admin form field?

texts:
I am using Testimonial extension which has textarea field in admin form.

When I am adding content with html tag, html tags are showing on frontend.

I have tried to change textarea to editor from block file but still it is not working.

Content field code in block file is:

$generalFieldset->addField(
            'testimonial_content',
            'editor',
            [
                'label'    => __('Testimonial Content'),
                'title'    => __('Testimonial Content'),
                'class'    => 'required-entry',
                'required' => true,
                'name'     => 'testimonial_content',
                'value'    => $this->testimonial,
                'config'    => $this->_wysiwygConfig->getConfig(),
                'wysiwyg'   => true,
            ]
        );

What is the issue? can anyone suggest?


texts: How to show out of stock in configurable product's option selection Magento 2.3.2

texts:
How to show out of stock in configurable product Magento 2.3.2

  like the below image

https://i.ibb.co/JpKdwNx/5210046c-6f62-11e6-8db7-abda30a5c09d.png


texts: Does Mage_Catalog_Block_Navigation has a bug?

texts:
Magento 1.7.0.2. I don't use flat category/products structure.

Take a look at file app/code/core/Mage/Catalog/Block/Navigation.php.

function _renderCategoryMenuItemHtml:

// get all children
if (Mage::helper('catalog/category_flat')->isEnabled()) {
     $children = (array)$category->getChildrenNodes();
     $childrenCount = count($children);
} else {
     // category is instance of Mage_Catalog_Model_Category
     $children = $category->getChildren(); // return string
     $childrenCount = $children->count();
}

function getChildren of Mage_Catalog_Model_Category object:

/**
  * Retrieve children ids comma separated
  *
  * @return string
  */
  public function getChildren()
  {
      return implode(',', $this->getResource()->getChildren($this, false));
  }

The question is - how we can call $children->count() if $children is a string? Is this a bug?


texts: Exclude Category from Catalog Price Rules

texts: I want to make a discount for only ONE category in Catalog Price Rules but I dont understand the Conditions tab.


texts: Magento 2: How to get the image from salerule?

texts:
I am showing the data of the salerule in the product view and is necessary for me to also show the image and description of the rule.

All the information I need is in Top Banner:

Is possible get it from the database?


texts: How can I rewrite a subdomain to Magento 1.9 category?

texts:
I would like to rewrite a URL with a subdomain to a Magento category. For example, I would like to write the URL:

godiva.my_magento_store.com

to

magento_store.com/godiva.html

or even better

my_magento_store.com/godiva

More than willing to play with both Magento and webserver configuration.

My thanks in advance.


texts: Cannot delete category if flat catalog index is enabled

texts:
I am using the following code to delete a category from my Magento installation programmatically:

        $hostId = $model->getId()->getHost();
        $category = \Mage::getModel('catalog/category')
            ->loadByAttribute('jtl_erp_id', $hostId);

        if ($category) {
            \Mage::register('isSecureArea', true);
            $category->delete();
            \Mage::unregister('isSecureArea');
        }

This works fine unless the flat category index is enabled. If this is the case, the following exception is being thrown:

Fatal error:  Call to undefined method Mage_Catalog_Model_Resource_Category_Flat::isForbiddenToDelete() in /path/to/magento/app/code/core/Mage/Catalog/Model/Category.php on line 755

Any ideas? I am using Magento 1.9.0.1


texts:
I have site run on hosting. but I get issue vendor/magento/framework/Stdlib/DateTime/Timezone.php(123): IntlDateFormatter->__construct('el_GR', 3, -1)
Anybody have any idea help me check that?


texts: Magento is sending the transaction as auth_only

texts:
how do i get magento and authorize direct post method to authorize and capture??
I have it in "Payment Action" selected as "authorize and capture” and the transactions still come back as “Authorized/Pending Capture” in need it to be “Captured/Pending Settlement”
…oh please help!


texts: update specific attribute value by setup upgrade

texts:
I want to change the frontend_label value of an attribute_code 'xx' only by using upgradedata.php script!
$table = $setup->getTable('eav_attribute');
            $setup->getConnection()
                ->update($table,
                ['frontend_label' => 'new version'],
                 ['attribute_code= ?' => 'xx']
                );
        }

I tried this in upgradedata.php but not working


texts: Magento 2 New Account Confirmation Email Text Broken

texts:
after creating new account trying to login but get this kind of error message

This account is not confirmed. Click here to resend confirmation email.

How can i fix this issue to get clickable link instead of html content?

Magento version is 2.3.5.

Thanks!


texts: Magento 1 and 2 SQL Select Count of picture of all SKUs?

texts:
We are in the final steps to migrate from 1 to 2. Now we found that some picture got lost.

Is there a way to select all SKUs and their picture counts like:

SKU    Count
123    2
234    6
345    2

In Magento 1 and Magento 2 Mysql backend?


texts: How to Get Top Menu in Header as dropdown in Magento 2

texts:
Want to show top links as "DROPDOWN" in custom theme. Trying from many days but still no success.

Have to show "Sign In/Up" Link in toplinks when customer is not logged in.

After Customer Logged In "Sign In/Up" replaced with Customer Name or Email Id with a "on hover" "DROPDOWN" having the following links in that

"My Account"
"My Orders"
"Custom Link"
"Sign Out"

Please help me out.

Reference for the above question


texts: I want to create three custom attribute for customer like(child name, DOB, Gender) how do i do that in magento 1.9.2.2. I tried to create it using SQL file it is created in database, but it was not coming on registration page.


texts: Magento 2 - Can't add static block to my theme

texts:
I use Magento 2.2.4 and I want to add a static block with the name "support" in the right side of the top menu, but what I try not working.

I try to add this in the phtml file

<?php echo $block->getLayout()->createBlock('Magento\Cms\Block\Block')->setBlockId('support')->toHtml();?>

I try to add this in the Magento_Theme/layout/default.xml

<referenceContainer name="page.top">
   <block class="Magento\Cms\Block\Block" name="support">
       <arguments>
            <argument name="support" xsi:type="string">support</argument>
       </arguments>
   </block>
</referenceContainer>

I do something wrong?

Thank you


texts:
Magento 2.2.2 released today with Fixes and enhancements.

http://devdocs.magento.com/guides/v2.2/release-notes/ReleaseNotes2.2.2CE.html

Let me know if anyone is facing some issues while upgrading to Magento 2.2.2?

What other issues are you facing during this upgrade?


texts: How to print specific product information provided by a CMS

texts:
I understand that magento has a print.css file that by default allows users to view/print their past orders. However, I would like users to have the option to print specific product information from a product page that works along the same lines.

Is there an easy way to do this? The product data in question is provided by a CMS, so Somehow I need to print a "section" of any product page, whose contents will contain the same fields but different values depending on the product.

Thank you!


texts:
I am trying to display random products on the homepage. but my page is getting cached and on refresh, same products are displayed. I used AJAX post request also but did not work. Can anybody say how can I avoid my page getting cached?

Read many articles, tried every possible way, but did not work.
Here is my ajax code

<script>
    require([
        'jquery'
    ], function($){
        jQuery.ajax({
        url: "/homepage/ajax/loadcategory",
        type: "POST",
        data: "",
        success: function (res) {
            if(res.indexOf("find products matching the selection") > -1){
             alert("Hello world.......");
            return;
            }
         alert("Hello world");
            var result = jQuery('.product-item-info', res).html();
            jQuery(".product-item").show();
            jQuery(".randomProd .product-item .product-item-info").html(result);
        }
        });
    });


texts:
I am trying to get core helper in magento 2. In Magento 1, I was using -

<?php $_coreHelper = $this->helper('core');
/* @var $_coreHelper Mage_Core_Helper_Data */ ?>

Is there any way to use core helper in magento 2, like this?


texts: Magento 2.4 Admin Page Two Factor Authentication

texts:
I'm trying to install Magento 2.4 Version on my Local System and getting a Two Factor Authentication option when I log in with admin page credentials.
Steps Taken by me to solve this issue -
I try to bypass this Admin page Authentication Step by following this link, But not find the required information to solve the same. - Officals Docs


texts:
Is Packaging weight (weight of the box or packaging) dropped in Magento 2.4?
I wanted to configure Packaging weight, to include in the shipping cost or in product cost.
Earlier Tare weight doc was available at this https://docs.magento.com/user-guide/shipping/magento-shipping-packaging.html

However, it redirects to https://docs.magento.com/user-guide/shipping/delivery.html
Here I cannot find details regarding Tare Weight.


texts: Magento 2 upgradeSchema.php Not Adding the Column on Database

texts:
I am trying to add column 'address' on existing upgradeSchema.php, but it not worked.

Here is my code:

<?php

    namespace Testing\Test\Setup;

    use Magento\Framework\DB\Ddl\Table;
    use Magento\Framework\Setup\UpgradeSchemaInterface;
    use Magento\Framework\Setup\ModuleContextInterface;
    use Magento\Framework\Setup\SchemaSetupInterface;

    class UpgradeSchema implements UpgradeSchemaInterface
    {

        public function upgrade(SchemaSetupInterface $setup, ModuleContextInterface $context)
        {
            $setup->startSetup();

            if (version_compare($context->getVersion(), '1.0.1', '<')) {
                $setup->getConnection()->addColumn(
                    $setup->getTable('testing_test_item'),
                    'description',
                    [
                        'type' => Table::TYPE_TEXT,
                        'nullable' => true,
                        'comment' => 'Item Description'
                    ]
                );
                $setup->getConnection()->addColumn(
                    $setup->getTable('testing_test_item'),
                    'address',
                    [
                        'type' => Table::TYPE_TEXT,
                        'nullable' => true,
                        'comment' => 'Item Address'
                    ]
                );
            }
            $setup->endSetup();
        }
    }
    ?>

Module.xml code:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Module/etc/module.xsd">
    <module name="Testing_Test" setup_version="1.0.2">
        <sequence>
            <module name="Magento_Catalog"/>
            <module name="Magento_Sales"/>
        </sequence>
    </module>
</config>


texts: Add Items into cart in magento2 programatically

texts:
I am new to Magento 2. I want to add items in cart programmatically. If product is found in the catalog_product_entity table then my logic is perfect & working but product is not found in the table that time i want to save the sku name, qty,price and add items in cart. Please give me suggestion.

I have written the following code:

//add items in quote
foreach($orderData['items'] as $item){

$productsku =$item['sku'];
$sql_product_entity = "Select * FROM catalog_product_entity WHERE sku ='$productsku'";
$data_product_entity = $connection->fetchAll($sql_product_entity);

if($data_product_entity){
    $product_id = $this->getProductBySku($item['sku']);
    $product = $this->_productFactory->create()->load($product_id->getEntityId());
    $product->setPrice($item['price']);
    $cart->addProduct(
                $product,
                intval($item['qty'])
            );

    }else{
        $objectManager11 = \Magento\Framework\App\ObjectManager::getInstance();
        $product11 = $objectManager11->create('Magento\Sales\Model\Order\Item');
        // $product11 = $this->productFactory->create();
        $product11->setSku($item['sku']);
        $product11->setPrice($item['price']);
        $product11->setName($item['sku']);
        $product11->setStore($store);
        $product11->setQuoteItemId(0);
        $product11->setQuoteParentItemId(NULL);
        $product11->setProductType('simple');

        $cart->addProduct(
                $product11,
                intval($item['qty'])
        );
    }
}


texts: Add custom block to admin sale order grid

texts:
i am trying to add the custom block after the sale order grid.i tried below xml code but could not succeeded.

<adminhtml_sales_order_grid>
    <reference name="sales_order.grid">
        <block type="core/template" name="testing" before="-" template="test/test.phtml"></block>
    </reference>
</adminhtml_sales_order_grid>


texts: Delete/update Configurable Product with SOAP Api v2 Magento

texts:
I am trying to delete a configurable product in my cart wiht shoppingCartProductRemove with Api SOAP v2, but the api return

  Please specify the product's option (s)

this is my Soap requets:

<?xml version="1.0" encoding="UTF-8"?>
<v:Envelope xmlns:v="http://schemas.xmlsoap.org/soap/envelope/" xmlns:c="http://schemas.xmlsoap.org/soap/encoding/" xmlns:d="http://www.w3.org/2001/XMLSchema" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
   <v:Header />
   <v:Body>
      <shoppingCartProductRemove xmlns="http://dev.WEBPAGE.mx/index.php/api/v2_soap" id="o0" c:root="1">
         <sessionId>e6ad1063fd8f8a5b1637ec7b2bedb0ed</sessionId>
         <quoteId>1016</quoteId>
         <products>
            <shoppingcartproductentity>
               <product_id>5730</product_id>
               <sku i:null="true" />
               <qty>0.0</qty>
               <qtySpecified>false</qtySpecified>
               <options i:type="d:anyType">
                  <associativeentity>
                     <key>92</key>
                     <value>410</value>
                  </associativeentity>
                  <associativeentity>
                     <key>138</key>
                     <value>406</value>
                  </associativeentity>
               </options>
               <bundle_option i:type="d:anyType">
                  <associativeentity>
                     <key>92</key>
                     <value>410</value>
                  </associativeentity>
                  <associativeentity>
                     <key>138</key>
                     <value>406</value>
                  </associativeentity>
               </bundle_option>
               <bundle_option_qty i:null="true" />
               <links i:null="true" />
            </shoppingcartproductentity>
         </products>
         <storeId>1</storeId>
      </shoppingCartProductRemove>
   </v:Body>
</v:Envelope>

The configurable product is 5730 ... this have associated a simple product (id: 5735) with the attributes:

attributeID = 92  value = color  (Attribute)

valueID =  410    value = black   (Attribute Options)

attributeId = 138  value = Size (Attribute)

valueId = 406      value = tall (Attribute Options)

What is wrong? . How do I can remove a configurable product?


texts: Group products showing "in stock" when there on of the products is out of stock

texts:
We have an issue where if one of the group products is out of stock we want it to state it is out of stock. But is states that is is in stock.

As you see on this picture above, in all of these group products 1 or more is out of stock. We know this because add to cart button is not visible but it states it's in stock. "på lager" means in stock.

As you see 2 out of 4 products is out of stock and the "add to cart-buy now" button is not there but stock status is "på lager"-In stock.
Anyone know what I can do?


texts:
Just upgraded from 1.9.3 to 1.9.4, and now this is filling up system.log

  Warning: simplexml_load_string(): Entity: line 7: parser error : XML
  declaration allowed only at the start of the document in
  /lib/Varien/Simplexml/Config.php on line 510

Any advice how to fix this ?


texts: Changes in Magento_Theme > layout are suddenly ignored (Magento 2)

texts:
I have removed the CSS in default_head_blocks.xml successfully like this:

<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <head>
        <css src="css/test.css" />
        <remove src="css/styles-m.css" />
        <remove src="css/styles-l.css" media="screen and (min-width: 768px)"/>
        <remove src="css/print.css" media="print" />
    </head>
</page>

Now I made some changes on CSS. After I turn all back as it was before it shows me Lumina CSS and it also ignores changes I made in default.xml. Before it works all, but now my changes in this Folder are ignored:

Theme > Magento_Theme > layout

I have no idea why


texts: Move related products from Left Column to Main Content above tabs (Product Description, Product Reviews, etc)

texts:
I've been reading through other posts and the one thing that eludes my problem is that the site I'm working does not use a catalog.xml file.

How would I go about moving related products on the left column over to the main content page for products?


texts: Magento same page URL on different stores

texts:
I've installed Magento Fishpig module for Wordpress integration.

I have two stores and a common blog. The only problem is that every time I accessed the blog page, the first store's layout is displayed. Any (simple) idea about how can I make it to remember the store from where the blog page is being accessed?


texts: calling {{block type="core/template" template="custom/custom.phtml"}} stop working after 1.9.3.7

texts:
I called a .phtml block inside a CMS Block with command

{{block type="core/template" template="custom/home-slider.phtml"}}

and it has been working fine on Magento version 1.9.3.2. I upgraded core Magento to latest 1.9.3.7, now the custom .phtml block doesn't work anymore. Does anyone know why?  Thanks


texts: If I add a product to my cart, is there a way to track that sku on all pages?

texts:
I have been trying this to retrieve them and it works fine on Product detail pages.

$data = array();
// PDP
if ($module === 'catalog' && $controller === 'product' && $action === 'view') {

            $customer = Mage::getSingleton('customer/session');
            $product  = Mage::registry('current_product');
            $category = Mage::registry('current_category');

            // Product(s) IDs
            $data['u2'] = $product->getSku();

I've noticed it pulls various styles from configurable and there is lots of them which means there will be lots of style numbers (only shows one).

My question is... is there a way to pull all the style numbers and display them for all various colors in a configurable or just pull the simple sku?

I hope that makes sense. I'll eagerly await for feedback. Thank you.

Magento ver. 1.13.1.0


texts: Get Shipping Address information aftersave Order

texts:
I'm kind of stuck. I'm building an API but for some reason I can't do getShippingAddress aftersave of the Order.
Everything else works fine :

etc/di.xml

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\Sales\Api\OrderRepositoryInterface">
        <plugin name="customer_aftersave" type="...\...\Plugin\OrderPlugin" sortOrder="10"/>
    </type>
</config>

OrderPlugin.php

use Magento\Sales\Api\OrderRepositoryInterface;
use Magento\Sales\Api\Data\OrderInterface;
...
public function aftersave(OrderRepositoryInterface $subject, OrderInterface $order){

            $order = $subject->get($order->getEntityId());
    .....
    }

How should I get shipping address information in the aftersave function?

$order here does not provide the getShippingAddress() function.

A big thanks in advance!


texts:
I'm trying to change the text Cart Subtotal to be Basket Subtotal but upon checking this text is within the checkout_index_index.xml and is under the referencontainer content. I want to modify the value of this and upon checking this is the node that is responsible for this

<referenceContainer name="content">
<block class="Magento\Checkout\Block\Onepage" name="checkout.root" template="Magento_Checkout::onepage.phtml" cacheable="false">
    <arguments>
        <argument name="jsLayout" xsi:type="array">
            <item name="components" xsi:type="array">
                <item name="checkout" xsi:type="array">
                    <item name="children" xsi:type="array">
                        <item name="sidebar" xsi:type="array">
                            <item name="children" xsi:type="array">
                                <item name="summary" xsi:type="array">
                                    <item name="children" xsi:type="array">
                                        <item name="totals" xsi:type="array">
                                            <item name="children" xsi:type="array">
                                                <item name="subtotal" xsi:type="array">
                                                    <item name="config" xsi:type="array">
                                                        <item name="title" xsi:type="string" translate="true">Basket Subtotal</item>
                                                    </item>
                                                </item>
                                            </item>
                                        </item>
                                    </item>
                                </item>
                            </item>
                        </item>
                    </item>
                </item>
            </item>
        </argument>
    </arguments>
</block>

When I tried to put this to my checkout_index_index.xml it broke the view and was not loading. Any idea on how to achieve this?


texts: how to show product id included in url on product listing page?

texts:
I am using magnto2.1.3. i want to show my product id in url on product listing page.below is what i need.

how to achieve this?kindly help me please?


texts: Magento2 : Service Contracts response headers

texts:
If I implement a custom API using a Magento2 service contract, how can I set the response headers of the API calls from inside the service implementation?

EDIT: I am looking for a solution for the scenario that my service implementation is a standard model class and not a controller, for example:

<route url="/V1/vendor/modulename/my_custom_endpoint" method="POST">
    <service class="Vendor\ModuleName\Api\ServiceInterface" method="my_custom_endpoint"/>
    <resources>
        <resource ref="anonymous"/>
    </resources>
</route>

and

<preference for="Vendor\ModuleName\Api\ServiceInterface" type="Vendor\ModuleName\Model\Service" />


texts:
i'm trying to adapt a module from Prestashop to Magento 2 did someone know how i can traslate this pls i need to use it in Magento 2:

$this->context->link->getAdminLink(-------)


texts: How to get comparable attributes on the up-sell page

texts:
I succeeded to got all the comparable attributes by the following code:

$_attributes = Mage::getResourceModel('catalog/product_attribute_collection');
$_attributes->addFieldToFilter('additional_table.is_comparable', array('1'));

But I can't call these attributes from the up-sell products when I'm trying:

<?php echo $this->helper('catalog/output')->productAttribute($_link, $this->getProductAttributeValue($_link, $_attribute), $_attribute->getAttributeCode()) ?>


texts: Change validation dynamically on Checkout Shipping

texts:
I have a certain condition that if I have only a certain product selected then only the Email Address should be required and all other field like firstname, lastname etc will be optional and this field should be hidden. Now I managed to hide this field when that product condition was satisfied but I don't know what to change the validation of the shipping address field. It always requires the other field like the firstname, lastname, address and etc... how can we make it optional when we arrive or loads the shipping page?
So basically I added the shouldDisplayAddress in the shipping.js
shouldDisplayAddress: function()
    {
       if (quote_items.length == 1) {
           return false;
       }

       return true;
    },

How do I make the validation for the shipping address changed? specially when I click the next button to view the Billing Address step. So I just want to dynamically change the validation.
Update:
So I found something similiar like this but I don't know how to make the other field optional except the email address


texts: Magento2 : Redirect Using Plugin (With Website Restrictions ON)

texts:
Postlogin.php
<?php
namespace Mycompany\Customerhomepage\Plugin;
use Magento\Framework\Controller\ResultFactory;

class Postlogin
{
    public function __construct(
        \Magento\Framework\UrlInterface $url,
        \Magento\Framework\App\Response\Http $response,
        ResultFactory $resultFactory
    ) {
        $this->_url = $url;
        $this->_response = $response;
        $this->resultFactory = $resultFactory;
    }

    public function afterExecute(\Magento\Customer\Controller\Account\LoginPost $subject , $result)
    {
        $customerBeforeAuthUrl = $this->_url->getUrl('customerhomepage/index/landing');
        $this->_response->setRedirect($customerBeforeAuthUrl)->sendResponse();
    }
}

di.xml
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
   <type name="Magento\Customer\Controller\Account\LoginPost">
       <plugin name="Mycompany_Plugin_Postlogin" type="Mycompany\Customerhomepage\Plugin\Postlogin"></plugin>
   </type>
</config>

I want to redirect to a custom page after login ,  how to do that by plugin ?
UPDATE
The Code Works fine it redirects to Custom page , as soon as the website restrictions are on it stop working


texts: Magento 2 - Changing "enter coupon here" to "Enter coupon or voucher here"

texts: I'd like to change placeholder on the coupon field from "enter coupon here" to "enter coupon or voucher here". I've enabled template hints but couldn't find out what template it's pulling from.


texts: Magento 2 : In IWD one page checkout module how to remove ajax call from city field

texts: I am using IWD one page checkout module in Magento 2. I want to remove ajax call to load shipping and payment block on city change. Is it possible to remove Ajax call on city field ?


texts: There has been an error processing your request, can't click on products

texts:
I'm getting this error when I click on any product in my magento store -

  There has been an error processing your request

  Invalid method
  Mage_Catalog_Block_Product_View_Type_Simple::displayProductStockStatus(Array
  ( ) )

  Error log record number: 747934858945

I tried these steps below, but they didn't work -

In the CPanel, go to File Manager and then go to the "errors" folder.
Rename local.xml.sample to local.xml.
Go to lib/Zend/Cache/Backend and click "Edit" on File.php
Scroll down a bit until you see this code:

protected $_options = array(
      'cache_dir' => 'null',
      'file_locking' => true,
      'read_control' => true,
      'read_control_type' => 'crc32',
      'hashed_directory_level' => 0,
      'hashed_directory_perm' => 0700,
      'file_name_prefix' => 'zend_cache',
      'cache_file_perm' => 0600,
      'metadatas_array_max_size' => 100

Change null to tmp/ and the code will look like this -

protected $_options = array(
        'cache_dir' => 'tmp/',
        'file_locking' => true,
        'read_control' => true,
        'read_control_type' => 'crc32',
        'hashed_directory_level' => 0,
        'hashed_directory_perm' => 0700,
        'file_name_prefix' => 'zend_cache',
        'cache_file_perm' => 0600,
        'metadatas_array_max_size' => 100

Go to your root directory folder and make a tmp folder.
After that refresh your page.

I did these steps but they didn't work.

Is there anything else I can do to fix the issue where clicking on any product brings me to an error page? Please give me all the steps on where to go and exactly how to locate specific files and edit certain parts of these files.


texts: Magento 2 how to get data from database?

texts: I added an attribute to customer segment, admin can use that attribute to upload image and the database magento_customersegment_segment stored the image path in a newly added column logo. But how to get back the image path from database and show the image to users?


texts: How to replace searchable column “store_id” to "website_id" into Sales/Orders admin grid?

texts:
I want to filter the orders by website (rather than store ID)

I have tried to remove:

    $this->addColumn('store_id', array(
            'header'    => Mage::helper('sales')->__('Purchased From (Store)'),
            'index'     => 'store_id',
            'type'      => 'store',
            'store_view'=> true,
            'display_deleted' => true,
            'filter_index' => 'main_table.store_id',
            ));

And to replace it by:

    $this->addColumn('website_id', array(
            'header'    => Mage::helper('sales')->__('Website'),
            'align'     => 'center',
            'width'     => '80px',
            'type'      => 'options',
            'options'   => Mage::getSingleton('adminhtml/system_store')->getWebsiteOptionHash(true),
            'index'     => 'website_id',
        ));

(Which I copied from app/code/core/Mage/Adminhtml/Block/Customer/Grid.php)

The website combo box shows the right websites, but the row value is blank.

Am I doing something wrong?


texts: Magento 2 SSL Centos Varnish + How to update Magento 2 Shop without harming Main Page

texts:
Got two Questions actually sorry for that.

  I got varnish, when I turn the https:// SSL on, it goes super slow because varnish is not build for SSL, you can fix this by SSL
  termination, but no where you can find how to do this for centos 7,
  apache or nginx, simple explained

Somebody can help?
Because customers of course like SSL, but so slow, I put SSL off for now

  Thereby what is the way to develop magento 2 shop in an different directory, so the main magento 2 shop in my case:
  www.takoda.shop stay
  always online

What I mean here is when I develop the shop often it is out of the air in maintenance or something like that, or when I compile, it's also out of the air, of course killing for customers, maybe never coming back

So I want a backup directory or something like that where I can develop and edit the magento 2 shop without harming the front shop, when everything works perfectly, than I update this shop to the main shop.

You got what I mean, or must i explain it more clearer?

I respect all the people who really care about helping and are much smarter and better than me in this parts!

Thank you very much


texts: Cannot get user and cart session info from controller

texts:
I have this piece of code in a controller:

public function getiframeAction() {
    if (Mage::getSingleton('customer/session')->isLoggedIn())
        echo "Yes";
    else
        echo "no";
}

And it always returns "no", regardless the front-end user is logged in or not. How can I figure out what is going on?

Thank you


texts:
I was trying to install a free theme (fashionista) using system>web setup wizard>component manager. It completed readiness check and backup steps during installation.

During the next step (new purchase status page) it started installation and showed the text

update application is running

But it took very long and showed the message 'script stopped or not responding'. It gave the option to continue or stop the script. Whatever I choose, the page (and browser) was not responding after that.So I closed the browser.

Then I rolled back the media and code using the following command

magento setup:rollback -c filename -m filename

But now when I go to system>web setup wizard, it opens a blank page(page title 'magento updater', URL- magento/update/index.php ).

How can I resolve it ? Please help.


texts: I want to add zoom effect on click of product images

texts:
I have attached the screenshot of before and after zoom

after on click the should be like


texts: Fatal error after updating template, skin, layout and default in 1.8 CE

texts:
I'm in serious need of help ASAP. I have numerous stores set up inside a Magento install, and they're all (including the Magento admin) resulting in the following error:

Fatal error: Call to a member function addHandle() on a non-object in /home/USERNAME/public_html/store/includes/src/__default.php on line 13860

Here are lines 13857-13861 in that file:

 {
        // if handles were specified in arguments load them first
        if (false!==$handles && ''!==$handles) {
            $this->getLayout()->getUpdate()->addHandle($handles ? $handles : 'default');
        }

Here's what broke it all. I had just uploaded theme files In the Magento admin, I went to System > Configuration, then to the General > Design tab, and opened the Themes section . I set the configuration scope to a website level, and then put the name of the theme in the Template, Skin, Layout and Default fields. When I clicked 'Save Cofig', it resulted in the error. I'm running Magento 1.8 CE.

Any help is greatly appreciated.


texts: Magento2 Add line separator in mass action list in sales order grid

texts: I need to add line separator before my two newly created custom mass action "Custom Action 1" and "Custom Action 2" and


texts: How to add Magento 2 social sharing links in product view page? Actually I have registered in add this tool and followed the steps to integrate social sharing via addthis snippet I have a snippet that want to place in the view page from customer theme


texts: Fooman Speedster, CSS minifying correctly however JS returns a 403?

texts:
I installed Fooman Speedster today (I've used it before without problems) and set it up as per the guidelines. I didn't experience any of the common issues however when loading the page I noticed all the JS was unavailable. I viewed the source to see a correctly generated minified link for the JS files, however on clicking it and attempting to view the result I get a 403.

As regards the CSS, this minifies and displays perfectly, and doesn't return a 403 when trying to view. I've been through the troubleshooting, checked permissions and there are no obvious faults, I just find it odd why the CSS works and the JS doesn't? Self tests passed without a problem and all relevant .htaccess files are in place.

Any suggestions?


texts:
i create my custom UI Grid, then i have next problem, my grid is infinity load.

Can someone recomend me, how can i debug my problem?


texts:
Where is the correct place to validate field in model?

For example, I have a database, with a table Product, but the database designer didn't force NOT NULL in some required fields (for instance, column SKU). So now I have to check whether these fields are NULL or not by code

I thought it will be added in setData() method. But I think setData() should only care about the "set data" job. Is there any better place for this validation job?


texts:
I want to change my customer registration page to a under construction page. I use magento 1.9.
for example, when customer goes to customer/account/create see just a text not any form


texts: Adding item to cart using REST API magento 2 shows price as zero

texts:
I can successfully add item to the cart using this rest API from my APP.

  POST /V1/carts/mine/items

However the item is added with a price of ZERO.

The new quote was created from the APP using this API.

  POST /V1/carts/mine

But when I try to add an item from magento web the price is showing correct value.

I am using magento 2 .


texts:
Can someone suggest if there is any function to update the quote item tables price columns

  (custom_price,original_custom_price,row_total,qty,price,base_price,row_total,base_row_total,price_incl_tax,base_price_incl_tax,row_total_incl_tax,base_row_total_incl_tax
  etc)

changes internally rather than calculating and updating each column manually?

When a product price change happens, the quote details are not changing. I was trying to add code for the same while checking out, where mini cart details were not getting updated.


texts: Magento 2: how to debug pub/static files generation in developer mode?

texts:
I am developing a custom payment module in Magento2. I used http://inchoo.net/magento-2/implementing-payment-gateway-magento-2/ as example to build it.

I need to debug static code generation. Where are generated pub/static/ files ? What class/method works to do it?

I'm going crazy to make this work on a develop server. I dont understand why method-renderer files are not loadng into http://myserver.com/pub/static/frontend/Magento/luma/es_AR/MyVendor_MyCustomPayment/js/view/payment/custom-payment.js when it exists in magento project (pub/static).

I tried:

php bin/magento module:enable MyVendor_MyCustomPayment --clear-static-content
php bin/magento setup:upgrade
rm -rf var/di
php bin/magento setup:di:compile
php bin/magento --ansi setup:static-content:deploy es_AR
php bin/magento setup:static-content:deploy
Verify file permissions: (ls -la var/)
chown -R magento_user:www-data var/ pub/static/
find . -type d -exec chmod 770 {} \; && find . -type f -exec chmod 660 {} \; && chmod u+x bin/magento


texts:
I have added background image with

.minicart-wrapper .action.showcart::before

when we remove content: '\e611';   it also remove newly added background image.
anyone help me.


texts: Is it possible to add a check box to the terms and conditions when registering in this page (/customer/account/create/) ?


texts:
We have a grid with data that we wants to filter by multiple criteria. For Id, text and date values it works fine. But we need a filter for a boolean value as well. The filter fields appears with the code below but nothing happens when select an option in the dropdown field. Any ideas?

Filter:

<filterSelect name="is_exported">
                <argument name="data" xsi:type="array">
                    <item name="config" xsi:type="array">
                        <item name="caption" xsi:type="string" translate="true">Select...</item>
                        <item name="label" xsi:type="string" translate="true">Status</item>
                        <item name="dataScope" xsi:type="string">is_exported</item>
                        <item name="options" xsi:type="array">
                            <item name="not_exported" xsi:type="array">
                                <item name="value" xsi:type="string">0</item>
                                <item name="label" xsi:type="string" translate="true">Not Exported</item>
                            </item>
                            <item name="exported" xsi:type="array">
                                <item name="value" xsi:type="string">1</item>
                                <item name="label" xsi:type="string" translate="true">Exported</item>
                            </item>
                        </item>
                    </item>
                </argument>
            </filterSelect>

Column definition:

 <column name="is_exported">
            <argument name="data" xsi:type="array">

                <item name="js_config" xsi:type="array">
                    <item name="component" xsi:type="string">Magento_Ui/js/grid/columns/column</item>
                </item>
                <item name="config" xsi:type="array">
                    <item name="dataType" xsi:type="string">select</item>
                    <item name="align" xsi:type="string">left</item>
                    <item name="label" xsi:type="string" translate="true">Exported?</item>
                     <!--<item name="filter" xsi:type="string">select</item>-->
                </item>
            </argument>
        </column>


texts: How to change the text of details tab on product page?

texts:
Can any one tell me how to change the text of detail tab in  product page.

check the site url :http://apetrailportfolio.com/mod/demo9.html


texts: Discount label issue if simple and downloadable product in cart

texts:
I have a 10% Shopping Cart Rule on my store. Let's say this can be applied to all products.

The only action is to apply a 10 per cent discount to the product price. No conditions. The label is "10% off"

Let's say I have:
Simple Product A - £10.00
Simple Product B - £20.00
Downloadable Product C - £5.00

If I have just Product A and B in my cart (simple), the discount row in my cart totals reads:

Subtotal: £30.00
Discount (10% off): -£3.00

If I have just Product C in my cart (downloadable), the discount row in my cart totals reads:

Subtotal: £5.00
Discount (10% off): -£0.50

Both of the above are fine and exactly what I want.

BUT if I have Product A and C (simple AND downloadable), the discount row in my cart totals reads:

Subtotal: £15.00
Discount: -£1.50

Where has the "10% off" label gone?! I have disabled all other promotional rules so there's no conflict, just for some reason the discount label seems to not show if a simple AND a downloadable product are in the cart.

Has anyone experienced the same problem and found a fix? Thanks!

I'm using Magento CE 1.7.0.2


texts: How to do i display custom attribute on order details page in magento?

texts:
i want to change the 'Ship to Name' attribute to a custom attribute like 'employee id' from the customer account information page.
I want this change to be reflected in Order details page under 'sales tab' in magento.

Thanks in advance!


texts:
I would like to transform the default textarea editor in my custom admin module with this module : https://github.com/Magenerds/PageDesigner

It is a module to create responsive content with CMS et block, it is perfectly working. Demo: https://www.youtube.com/watch?v=E0wZzVPFhM0

Now, I need to use this functionnality in my custom module, I tried to modify the di.xml file to modify the behavior of my module, not result.

Default di.xml:

<?xml version="1.0"?>
<!--
/**
 * NOTICE OF LICENSE
 *
 * This source file is subject to the Open Software License (OSL 3.0)
 * that is available through the world-wide-web at this URL:
 * http://opensource.org/licenses/osl-3.0.php
 */
 -->
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <preference for="\Magento\Widget\Block\Adminhtml\Widget\Form"
                type="\Magenerds\PageDesigner\Block\Adminhtml\Widget\Form"/>
    <preference for="Magento\Framework\App\Arguments\ValidationState"
                type="Magenerds\PageDesigner\Model\ValidationState"/>
    <preference for="Magenerds\PageDesigner\Utils\HtmlRendererInterface"
                type="Magenerds\PageDesigner\Utils\HtmlRenderer"/>

    <!-- Plugins -->
    <type name="\Magento\Cms\Model\Page">
        <plugin name="Magenerds_PageDesigner::cmsPageRenderJson"
                type="Magenerds\PageDesigner\Plugin\Cms\Model\Page\PagePlugin" sortOrder="100"/>
    </type>
    <type name="Magento\Cms\Model\Page\DataProvider">
        <plugin name="Magenerds_PageDesigner::injectPageHtmlIntoJson"
                type="Magenerds\PageDesigner\Plugin\Cms\Model\Page\DataProviderPlugin" sortOrder="100"/>
    </type>
    <type name="\Magento\Cms\Model\Block">
        <plugin name="Magenerds_PageDesigner::cmsBlockRenderJson"
                type="Magenerds\PageDesigner\Plugin\Cms\Model\Block\BlockPlugin" sortOrder="100"/>
    </type>

    <type name="Magento\Cms\Model\Block\DataProvider">
        <plugin name="Magenerds_PageDesigner::injectPageHtmlIntoJson"
                type="Magenerds\PageDesigner\Plugin\Cms\Model\Block\DataProviderPlugin" sortOrder="100"/>
    </type>

    <type name="Magento\Widget\Model\Widget">
        <plugin name="Magenerds_PageDesigner::widgetEncode"
                type="Magenerds\PageDesigner\Plugin\Model\WidgetPlugin"/>
    </type>
    <type name="Magento\Widget\Block\Adminhtml\Widget\Options">
        <plugin name="Magenerds_PageDesigner::widgetDecodeBackend"
                type="Magenerds\PageDesigner\Plugin\Block\WidgetOptionsPlugin"/>
    </type>
</config>

What is the best way to override my textarea with this module?


texts:
suddenly all products disappeared from the magento catalog.
I have a backup of the database on a daily basis.
How can I import only catalog/category data from the dump or just import everything without order / invoice data?

Thanks for you help


texts: Override Block & Template File in Magento 1

texts:
What is the best way to override the below files theme/module & how one can override it ?
app/code/core/Mage/Adminhtml/Block/Sales/Order/Create/Items/Grid.php

app/design/adminhtml/default/default/template/sales/order/create/items/grid.phtml


texts:
When trying to install Magento 2, the installation is currently stuck at 49% "Installing user configuration". I have tried changing the "vendor" directory to 777 as recommended by a couple of others here, though this hasn't worked. Is there anything else I can try?

For reference, I am using PHP7.0.7 on Ubuntu. Any other information needed to assist in answering, please comment.


texts: Is it possible to pass some custom values as parameter while adding products to the cart

texts:
Please see the code that we use to add product to the cart.

$product = Mage::getModel('catalog/product')->load($productId);
$cart = Mage::getModel('checkout/cart');
$cart->init();
$result = $cart->addProduct($product, array('qty' => quantity);
$cart->save();

While adding the product to the cart i need to add some additional information along with the products details so that it can be accessed from the shipping module. For example is it possible to do something like this?

$result = $cart->addProduct($product, array('qty' => quantity,'s_class'=>'next');

I have added a variable s_class and its value in the parameter array. Is it possible to do this so that i can get the value for the s_class in the shipping module?
I tried above code, there is no error while adding the product to the cart.

But not sure how to access the same from the shipping module.

Are there any alternative ways to achieve this ie adding some values with the products while adding it to the cart the and get the same in shipping module?


texts:
I'm trying to display a "Free Gift" text box over any products that have options. This works well but now I'm just trying to refine it so it doesn't appear on products that have size options which is also a custom options.

Is it possible to get the options label and display my text box depending on if it says "Free Gift"?

Here is the code I've used to display my text box on any product that has options.

<?php if ( $_product->getData('has_options') && ($_product->getTypeID() == 'simple')): ?>

<?php echo "Free Gift" ?>
; <?php endif; ?>

And this is the code I've tried but doesn't work.

<?php if ( $_product->getData('has_options') && ($_product->getTypeID() == 'simple') && ($_product->getOptionsLabel('Free Gift') == "Free Gift") ): ?>
<?php echo "Free Gift" ?>
; <?php endif; ?>


texts: There was no Home CMS page configured or found magento 2.1.7

texts:
I've the error.

There was no Home CMS page configured or found.

On the magento website homepage, I've tried to clean the cache, reindex, run the command setup:upgrade but still got the error.


texts:
There are some post to discuss depends on multi-value for system.xml, (https://magento.stackexchange.com/questions/9935/system-xml-field-dependency)

Below example come from Magento Core Code(app/code/core/Mage/Payment/etc/system.xml

<depends>
    <order_status separator=",">processing,processed_ogone</order_status>
</depends>

I have tested this feature for system.xml, it works, but it is not work for widget.xml can anyone tell me how to do "depends on multi-value" for widget.xml?


texts:
I can't open simple products.. keep getting error as below,
tried disabling Temando_shipping..

no joy.. any ideas to resolve?

1 exception(s):
Exception #0 (ReflectionException): Class Temando\Shipping\Model\Source\PackagingType does not exist

Exception #0 (ReflectionException): Class Temando\Shipping\Model\Source\PackagingType does not exist
<pre>#1 Magento\Framework\Code\Reader\ClassReader->getConstructor() called at [vendor/magento/framework/ObjectManager/Definition/Runtime.php:49]
2 Magento\Framework\ObjectManager\Definition\Runtime->getParameters() called at [vendor/magento/framework/ObjectManager/Factory/Dynamic/Developer.php:48]
3 Magento\Framework\ObjectManager\Factory\Dynamic\Developer->create() called at [vendor/magento/framework/ObjectManager/ObjectManager.php:56]
4 Magento\Framework\ObjectManager\ObjectManager->create() called at [vendor/magento/framework/Validator/UniversalFactory.php:36]
5 Magento\Framework\Validator\UniversalFactory->create() called at [vendor/magento/module-eav/Model/Entity/Attribute/AbstractAttribute.php:641]
6 Magento\Eav\Model\Entity\Attribute\AbstractAttribute->getSource() called at [generated/code/Magento/Catalog/Model/ResourceModel/Eav/Attribute/Interceptor.php:1181]


texts: Magento 2: Multiple Maximum Order Total value in Cash on Delivery

texts:
The requirement is to set up cash on delivery "Maximum Order Total" values specific for each country.

For example in my case for Saudi Arabia, Maximum Order Total of 1500 and for Other Gulf countries, Maximum Order Total of 1000. How can I do this?

Saudi Arabia - 1500
Other Gulf countries - 1000

In admin dashboard, there is only one common "Maximum Order Total" field which applies for all countries.


texts:
Is there anyway to configure Magento's Price rules so that if Free shipping is given for purchases which in total are equal to or greater than X AND if a coupon reduces X to a lesser value customer pays for shipping?

Thanks


texts: redirect customer to associated website on successful registration

texts:
I'd been working on a module where customer choose at the time of registration for which website he need to register. So far I'd done it working. A quick reference to that. On successful registration the customer is being redirected to customer/account/ in the current website regardless of which website he chosen. But I need him to be redirected to that particular website for which he had registered.

So far I'd tried overriding the Customer/AccountController's _welcomeCustomer():

protected function _welcomeCustomer($customer, $isJustConformed = false) {
    $webid = $customer->getWebsiteId();
    $successurl = parent::_welcomeCustomer($customer, $isJustConfirmed);
    if (Mage::app()->getStore()->getWebsiteId() == $webid) {
        return $successurl;
    } else {
        return Mage::app()->getWebsite($webid)->getDefaultStore()->getBaseUrl() . 'customer/account/index';
    }
}

But instead of redirecting the customer to associated website it being redirected to home page of the current website. Any help? How could it be done? or this happening so?


texts: Stuck with image import using magento 1.9.2.1

texts:
I m importing magento product with native magento import profile. All the product imported successfully but image is not imported. I have also put the images on media/import folder and in csv write image name like /image1.jpg but it still giving null image after successfully imported csv.

what will be the issue please help


texts: Magento 2 - top menu show from 2nd sub category

texts:
a client has now a shop with the following structure of categories:

 Base
   Shop
   --Menu 1
     ---Sub menu 1
     ---Sub menu 2
   --Menu 2
   --etc

Normal magento would only show "shop" in the menu.
But i would like to start skip this subcategory and shop directly Menu 1, menu 2 etc in the menu.

I could remove the shop step, but thats not good for google, and would relate in many redirects in the .htaccess because the client has many categories (100+)


texts: Simple product with multiple images for showing sides

texts:
Hope you will be fine. I am a newbie in Magento. I am really stuck here.

There are about 50 Simple Products in my store. Everything is fine. I just want to show multiple images (different sides: front, side, back) of my simple products. But right now, I can show only 1 picture. Is there any way to show multiple images for simple product in magento?

Please do not recommend "Configurable Products". I do not want to create all of my products again.

Please help!

In case of any question, please ask. I will be happy to hear :)

Anxiously waiting for any response.


texts: Magento2 : How to add confirmation alert to custom field in

texts:
I have created custom admin grid,I wish to add confirmation alert popup while clicking my custom field (like before deleting,before update status).Please provide me a solution

I need to show the confirm alert like below


texts:
I have followed this tutorial from inchoo.net to get a test module to override a frontend module and it worked. I am now trying to override an adminhtml module, but without much less success.

<config>
....

<global>
    <blocks>
        <adminhtml>
            <rewrite>
                <newsletter_queue_grid_renderer_action>Ps_Newsletter_Block_Adminhtml_Newsletter_Queue_Grid_Renderer_Action</newsletter_queue_grid_renderer_action>
            </rewrite>
        </adminhtml>

        <newsletter>
            <class>Ps_Newsletter_Block</class>
        </newsletter>
    </blocks>
</global>

<admin>
    <routers>
        <adminhtml>
            <args>
                <module>
                    <Ps_Newletter before="Mage_Adminhtml">Ps_Newsletter_Adminhtml</Ps_Newletter>
                </module>
            </args>
        </adminhtml>
    </routers>
</admin>
....
</config>

-

class Ps_Newsletter_Block_Adminhtml_Newsletter_Queue_Grid_Renderer_Action
extends Mage_Adminhtml_Block_Newsletter_Queue_Grid_Renderer_Action
{
public function render(Varien_Object $row)
{
    $actions[] = array(
        'url'       =>  $this->getUrl('*/newsletter_queue/send',array('id'=>$row->getId())),
        'caption'   =>  Mage::helper('newsletter')->__('Send'),
        'popup'     =>  true
    );

    $this->getColumn()->setActions($actions);
    return parent::render($row);
}
}

I have tried to follow a similar technique to the test module, while adding the additional nodes in for it being on the admin side, then tried this tutorial, I guess i've missed something, but what am I doing wrong?

===EDIT===

I have var_dump($actions) and it is displaying expected information, however "send" is not being applied in the action section, below "preview". When I add the above code into the core file it works. So what is happing here that is different? (I thought that extending a file would output the extension value as well as block are called automatically....or so i believe)


texts: No subscribers for newsletter on multiple stores

texts:
We have 3 stores on one domain.

When I try to add a new subcriber, with a non customer mail, the subscriber is NOT added to the newsletter list.

I can go to the customer section and a a existing customer to the newsletter list. But not from the frontend. Is it because we have more that one store?

Any idea?


texts: Discount all products in stock in Magento 1.9.0.1

texts:
I need to set a discount for all products that we have 1 or more pieces in stock. It seems there is no such condition in Magento shopping cart rules or catalog rules. Catalog price rule would be preferable so that customer could see the discount right at the product page.

I found and bought an extension that promises this feature as a bonus, but it's not working:

http://top-magento-extensions.com/magento-extensions/magento-discount-conditions-extension-week-scheduler-edition.html


texts: Magento2: How to load a product using URL key?

texts:
I need to load a product using its URL key. I find methods to load using only ID and SKU like,

use Magento\Catalog\Model\ProductRepository;

$product = $this->_productRepository->getById($productId);
$product = $this->_productRepository->get($productSku);

How can I achieve this using URL key?


texts: Mini-Cart displaying Configurable Product Image instead of simple Product Image Magento 2

texts:
While adding product variations from configurable product, in mini cart it displays only configurable product image,

how to show simple product image instead of current parent image.


texts: Some products have catalog/product/view/id/2221/name-of-the-product from product URL magento 2?

texts:
In the Site, product URL is like this: http://www.test.com/product-url-key

But when I searching the product then some product URLs are showing like this:

http://www.test.com/catalog/product/view/id/2221/product-url-key

This is not for all products.

i want to url like this type http://www.test.com/product-url-key.html


texts: Magento 2 Customer Account Navigation Add Css Class to link not working

texts:
XML:

<referenceBlock name="customer_account_navigation">
 <block class="Magento\Customer\Block\Account\SortLinkInterface" name="customer-account-navigation-account-link">
    <arguments>
       <argument name="label" xsi:type="string" translate="true">Account Dashboard</argument>
       <argument name="path" xsi:type="string">customer/account</argument>
       <argument name="sortOrder" xsi:type="number">250</argument>
       <argument name="css_class" xsi:type="string">my-custom-css-class-here-not-working</argument>
    </arguments>
 </block>
 <!-- @Prashant Valanda suggestion -->
 <referenceBlock name="customer-account-navigation-account-link">
  <arguments>
   <argument name="label" xsi:type="string" translate="true">Account Dashboard works</argument>
   <argument name="path" xsi:type="string">customer/account</argument>
   <argument name="sortOrder" xsi:type="number">250</argument>
   <argument name="css_class" xsi:type="string">but-my-custom-css-class-here-still-does-not-work</argument>
  </arguments>
 </referenceBlock>
</referenceBlock>

Taken from /../vendor/magento/module-customer/view/frontend/layout/customer_account.xml

Any ideas how one can add css class?


texts:
I added a Widget for all new Products to show on the Front Page, but the "Positioning" is kinda strange..

As you see in the image below..

Shouldn't it work out of the box? (It's a pre-made widget from Magento 2.)


texts: Customer user | The account sign-in was incorrect or your account is disabled temporarily. Please wait and try again later. M2

texts:
I get this error mostly on my local magento setup when I try to get customer token using default API. And usually it is with more than one customer accounts.

"message": "The account sign-in was incorrect or your account is disabled temporarily. Please wait and try again later.",

I checked customer Personal information from backend and there it is showing as:

  Account Lock: Unlocked

I tried to solve by upgrading db also flushed cache but no luck.


texts: How to change field name in Review tab(Product page tab) as Nickname to Firstname

texts:
In product Page tab - Review tab I want to change name of one field: Nickname
to Firstname.
I have attached image here describing the same.
Please advise me on that.


texts:
I have the problem that i always get the error 404 not found, if I want to get the url of my controller. This is my filestructure:

And this is the URL I am trying to get loaded: http://localhost/shoppingcart/index/index
(edit) also tried:
http://localhost/post/index/index

If this URL does not work, which URL should work for my controller?

My base URL is localhost

Whis is my controller:

<?php
namespace MassiveArt\ShoppingCart\Controller\Index;
use Magento\Framework\App\Action\Action;
use Magento\Framework\App\Action\Context;
use Magento\Framework\Data\Form\FormKey;
use Magento\Framework\Controller\Result\JsonFactory;
use Magento\Checkout\Model\Cart;
use Magento\Catalog\Model\Product;
class Post extends Action
{
    protected $formKey;
    protected $cart;
    protected $product;
    public function __construct(
       Context $context,
         JsonFactory $resultJsonFactory,
       FormKey $formKey,
       Cart $cart,
       Product $product) {
            $this->formKey = $formKey;
               $this->resultJsonFactory = $resultJsonFactory;
            $this->cart = $cart;
            $this->product = $product;
            parent::__construct($context);
    }
    public function execute()
    {
         $result = $this->resultJsonFactory->create();
       $productId = $this->getRequest()->getParam('productId');
       try {
               $params = array(
                    'form_key' => $this->formKey->getFormKey(),
                    'product' => $productId,
                    'qty'   => 1
            );
              $product = $this->product->load($productId);
              $this->cart->addProduct($product, $params);
              $this->cart->save();
                $result->setData(['message' => __("Product is added in cart")]);
            return $result;
       } catch(\Exception $e) {
               $result->setData(['error' => __($e->getMessage())]);
               return $result;
         }
 }
}

This is my routes.xml:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:App/etc/routes.xsd">
   <!--define id for frontend route is “standard”-->
   <router id="standard">
       <!--Route name-->
       <route id="post" frontName="post">
           <!--Module name-->
           <module name="MassiveArt_ShoppingCart" />
       </route>
   </router>
</config>


texts: Adding Discount percentage on Magento 2 Special Price

texts:
Using Magento 2.1 I have overridden the final_price.phtml  and uploaded to my theme however when adding the following calculation to echo the amount in % the cuistomer will save, the price disappears. Any thoughts on what is throwing the spanner in my cogs?

<?php $specialPrice = $_helper->productAttribute($_product, $_product->getSpecialPrice(), 'special_price');
$standardPrice = $_helper->productAttribute($_product, $_product->getPrice(), 'price');
$Save = ((($standardPrice - $specialPrice) / $standardPrice)*100);?>
<?php echo round($Save,2) . '%'; ?>

I have also edited like so...

<?php $specialPrice = $block->getPriceType('final_price');
$standardPrice = $block->getPriceType('regular_price');
$Save = ((($standardPrice - $specialPrice) / $standardPrice)*100);?>
<?php echo round($Save,2) . '%'; ?>


texts: Magento 1.9.1 Bug? Discount + Tax + Paypal Pro = incorrect total

texts:
I have a problem with a magento store 1.9.x

I configured tax for the products and i created a coupon code -30%.

When i proceed to Checkout with Paypal Pro, the imports for the products are incorrect.

Example:

Product: 100$ incl. tax
discount40 %: -30$
shipping: 5$
tax: 12.62$
TOTAL tax escl. 62,38
TOTAL: 75$

the Review in Paypal PRo:

Total item: 51,97$
TAX: 12,62$
Shipping: 5$
TOTAL: 69,59

The problem appears only when
- The tax is actived & configured
- Customer use a Coupon Code
- The payment method is PayPal Pro.

If the customer use a different payment method or don't use a coupon code the problem does not occur.

I tested the problem on a clean installations (1.9.0.1 and 1.9.1) and with the same configurations, the problem appears.

It's a reported bug? how do I fix?

Thanks


texts: Magento 1: Add Option to Shipping Address Selection

texts:
In Magento 1 checkout page I want to add the third option In-Store Pickup with, Ship to this Address, Ship to different Address.

If the customer chooses this In-Store Pickup then any offline shipping method will be selected and tax will be calculated using custom logic according to the address of the store.


texts: Updating products on backend doesn't reflect on frontend

texts:
I have this magento store I just installed and configured according to guides Varnish cache.
Website now is blazing fast, but if I update a product (for example, add a description), even if I cache clean/flush, invalidate indexes and reindex, product page still shows stale data (ie none of the changes I just made).
How can I make sure that, anytime I update a product, I either invalidate/redo the cache for that product?


texts: where can i remove the resultnumber for search?

texts:
when adding a search term,sometimes ther eis a dropdown with results sowing also a number before it (the number of expected results?)

Is that a setting somewhere or would i need to do something in code?

thanks


texts: Magento 2.2 Grid in custom module missing styles and format

texts:
We've successfully created a custom module, but it appears that none of the js or css/less is being applied to a grid component that is being used.

Any suggestions would be appreciated-


texts: Magento 2 get customer info after customer save event

texts:
I created a custom module that call a remote API service.

I have to call this API on some events, like: customer create, customer edit, order create etc...

For customer edit all works fine with:

app/code/Vendor/Module/etc/events.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Event/etc/events.xsd">
    <event name="customer_account_edited">
        <observer name="my_customer_account_edited" instance="Vendor\Module\Observer\EditCustomer" />
    </event>
</config>

app/code/Vendor/Module/Observer/EditCustomer.php

<?php
namespace Vendor\Module\Observer;

use Magento\Framework\Event\Observer;
use Magento\Framework\Event\ObserverInterface;

class EditCustomer implements ObserverInterface{
    public function execute(Observer $observer){
        $writer = new \Zend\Log\Writer\Stream(BP . '/var/log/mylog.log');
        $logger = new \Zend\Log\Logger();
        $logger->addWriter($writer);

        $editedCustomerEmail = $observer->getEvent()->getEmail();

        // Ref: app/code/Magento/Customer/Controller/Account/EditPost.php
        // $this->_eventManager->dispatch(
        //     'customer_account_edited',
        //     ['email' => $customerCandidateDataObject->getEmail()]
        // );

        $logger->info($editedCustomerEmail);

        // load customer by email and do my things...
    }
}

Now I need to do the same thing when a new customer is registered.

events.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Event/etc/events.xsd">
    <event name="customer_account_edited">
        <observer name="my_customer_account_edited" instance="Vendor\Module\Observer\EditCustomer" />
    </event>
    <event name="customer_register_success">
        <observer name="my_customer_register_success" instance="Vendor\Module\Observer\NewCustomer" />
    </event>
</config>

app/code/Vendor/Module/Observer/NewCustomer.php

<?php
namespace Vendor\Module\Observer;

use Magento\Framework\Event\Observer;
use Magento\Framework\Event\ObserverInterface;

class EditCustomer implements ObserverInterface{
    public function execute(Observer $observer){
        $writer = new \Zend\Log\Writer\Stream(BP . '/var/log/mylog.log');
        $logger = new \Zend\Log\Logger();
        $logger->addWriter($writer);

        $editedCustomerEmail = $observer->getEvent()->getEmail();

        $logger->info($editedCustomerEmail);

        // load customer by email and do my things...
    }
}

In this case the variable $editedCustomerEmail is empty...

Already tried with:

// Ref: app/code/Magento/Customer/Controller/Account/CreatePost.php
// $this->_eventManager->dispatch(
//     'customer_register_success',
//     ['account_controller' => $this, 'customer' => $customer]
// );
$customer = $observer->getEvent()->getCustomer();
// or
$customer = $observer->getEvent()->getData('customer');

But Customer Object is always Null...

If this can be useful:
I'm using the 3rd party extension Amasty_Checkout, and I found this code in 2 files:

$this->eventManager->dispatch(
    'customer_register_success',
    [
        'customer' => $account,
        'amasty_checkout_register' => true
    ]
);

Where I wrong? This is a conflict? How can I solve?


texts: Magento 2: Image Upload Not Calling Validator

texts:
I'm using Magento 2 CE Version 2.1.0. I would like to validate that uploaded image should not exceed 5MB.

app\code\Custom\Module\Controller\Posts\Post.php

public function execute() {
    $uploader = $this->_fileUploaderFactory->create(['fileId' => 'picture1']);
    $uploader->setAllowedExtensions(['jpg', 'jpeg', 'gif', 'png']);
    $uploader->addValidateCallback('picture1', $uploader, 'validateUploadFile');
}

public function validateUploadFile($filePath) {
    echo "here";
    exit;
}

It's not calling validateUploadFile function within that file.


texts: Querying a table using data from another table

texts:
I have a custom table with the following columns:

entity_id Primary int(10) UNSIGNED AUTO_INCREMENT
order_id int(14) UNSIGNED
order_increment_id int(20) UNSIGNED
link varchar(255) utf8_general_ci

There can be multiple rows for the same order.

I am retrieving all orders in a certain state, and need to then retrieve all the rows in my custom table, filtering on order IDs that the collection of orders contains.

I get the orders like this:

    $collection = Mage::getModel('sales/order')->getCollection();
    $collection->addFieldToFilter('status', 'picking_in_progress');

How do I go about using the orders in $collection to retrieve the records in my custom table that match the orders in $collection?

I want to display the results on a grid, and will use data from both tables ie the customer name and surname and date of order creation from $collection, and the link column from my custom table.