texts: Why can i use getData('custom_column') but not getCustomColumn()?

texts:
This one has bugged me just enough to post this.. So imagine we are getting a row from the database on a custom table like so:

$row = $this->getCollection()->addFilter('quote_id', 1)->setPageSize(1)->getFirstItem();

This is all okay - and I can pull through the entire array using:

$row->getData();

Which produces:

Array ( [entry_id] => 15 [quote_id] => 1 [custom_column] => it works [created_time] => 2014-02-05 21:10:53 )

I can even get a single column by passing the column as a parameter:

$row->getData('custom_column');

But here comes the weird part for me - when I try to do this using the other technique - it cannot pull it through:

$row->getCustomColumn(); // DOESN'T WORK

Now this is strange seeing as I can pull through other columns:

$row->getEntryId(); // works - where is the logic?

Can anyone shed light on why this is? Or if the answer is out there please reference it by all means. Thanks


texts: Magento 2 How to redirect customer to custom page after registration

texts:
Actually i am going to "Send email to admin" after customer registration using events observer AND Redirect to customer to "custom page with customer logout".

Send email to admin is working fine but redirecting to my account page instead of custom page with logout.

I am following that answer - Magento 2 - Redirect user to specific page after register


texts: After each month i saw some junk files on server where magento 1.9.2.3 is installed , How can I safe my magento store from malware attacks.


texts: how to update product preview image on product page like the functionality on list page , magento2

texts:
I created a configurable product, use attribute colour and size.
There is a setting on attribute colour: "Update Product Preview Image -> yes."

so that, on list page, when i click the colour, the product image updated.

list page link

But when I go to product page. I need click both colour and size, then the image can be changed. If i just select colour, the image doesn't change.

I don't want that, I want the functionality like list page.

Anyone can help me?

How can i do this functionality?


texts:
I have added one filter in Method _getProductCollection()  of the class Mage_Catalog_Block_Product_List  as follows.

protected function _getProductCollection()
{
     ...
    $this->_productCollection = $layer->getProductCollection();
    $this->_productCollection->getSelect()->joinInner(
        array('cpe' => 'catalog_product_entity'),
        'e.entity_id = cpe.entity_id'
    )
    ->where("cpe.type_id = 'simple'");
    ...
}

The above code is working fine as of Magento Version 1.7. But whenever I write the following code, it gives

  Column not found: 1054 Unknown column 'e.type_id' in 'where clause'

error.

The code (which is not working).

protected function _getProductCollection()
{
     ...
    $this->_productCollection = $layer->getProductCollection();
    $this->_productCollection
        ->addAttributeToSelect('type_id')
        ->addAttributeToFilter('type_id','simple');
    ...
}

Now the Questions.

Will there be any performance impact if I use the first working
code?
is there any other way to get around to have a proper product
filter?

UPDATE:

Whenever I apply the following code and use rwd theme, I am not getting any error. But whenever I user default theme, I get the below error,

Code

protected function _getProductCollection()
{
     ...
    $this->_productCollection = $layer->getProductCollection();
    $this->_productCollection
         ->addAttributeToSelect('type_id')
         ->addAttributeToFilter('type_id','simple');
    ...
}

Error

  SQLSTATE[42S22]: Column not found: 1054 Unknown column 'e.type_id' in
  'where clause', query was: SELECT FLOOR((ROUND((e.min_price) * 1, 2))
  / 10) + 1 AS range, COUNT(*) AS count FROM
  catalog_product_index_price AS e  INNER JOIN
  catalog_category_product_index AS cat_index ON
  cat_index.product_id=e.entity_id AND cat_index.store_id=1 AND
  cat_index.visibility IN(2, 4) AND cat_index.category_id = '3' WHERE
  (e.type_id IN('simple')) AND ( e.website_id = '1' ) AND (
  e.customer_group_id = 0) AND (e.min_price IS NOT NULL) GROUP BY
  FLOOR((ROUND((e.min_price) * 1, 2)) / 10) + 1 ORDER BY
  FLOOR((ROUND((e.min_price) * 1, 2)) / 10) + 1 ASC


texts:
OK, this is a little confusing to explain.

What I need is to show an attribute only within a certain time/date frame.

I have a custom attribute which shows text and after a certain date, I want it to disappear.

I am sure it is possible as there is something similar already built into magento which is the special price attribute which works with the special price to date and from date.

I hope this is enough information.

Thanks :)


texts: Magento 2 - Frontend Controller conditional based 404 page

texts:
I have custom frontend controller, I added the URL Rewrite for this controller

I want to figure out the way, How I send requesting URL to 404 page based on some condition within the controller.

I don't want the noroute redirect solution because it change the URL. For example if you disable the product, URL remain same but it goes to 404 page and also I don't want to remove the URL Rewrite for this controller as well.

Any help, experience and knowledge sharing would be appreciated.


texts: How can I get bar on the top of homepage?

texts:
How can i get a bar on top of the homepage? like this one. "Free delivery" text on the black horizontal bar?

http://monosnap.com/image/1qKfrzgi0uXyggGhQKdKxKMsxRveb5


texts: unable to insert widget in product detail page

texts:
I am developing the Magento theme I am trying to add the widget in the product detail page through layout so that I can make it installable but I am unable to add the widget. here is the following code I am using the embed widget. please help me, friends

<?xml version="1.0"?>
<layout version="1.0">
    <default>
        <reference name="product_additional_data">
            <block type="sharer/sharer" name="sharing_widget" />
        </reference>
    </default>
</layout>

and in view.phtml this code is used to fetch reference

echo $this->getChildHtml('product_additional_data');


texts: i want Latest Product of Home Page also show on Product Detail page

texts:
Can you please guide me, how can i show Latest products of Home Page on Product Page detail. What steps we need to do this? Recently i have copy code from new.phtml and past into view.phtml. But nothing showing on Product Page. I think i'm missing something..
Thanks


texts: How to remove / rebuild product cache image with the help of product id?

texts:
I want to remove the particular product image from cache folder at the time of product edit from admin.

I need to change the product image when product getting edit and its working fine.

Now at that time I also want to remove old product image from Cache with the help of product id.


texts:
I'm using Magento CE 1.7. I want to add the customer telephone number to the Abandoned Cart grid (Reports->Shopping Carts->Abandoned Carts). I have overridden the block Mage_Adminhtml_Block_Report_Shopcart_Abandoned_Grid. My _prepareCollection() function is as below. But it loads the wrong telephone number. Can anyone suggest what tables should i join here or the issue with this code ? Any help will be appreciated.

protected function _prepareCollection()
    {
        $collection = Mage::getResourceModel('reports/quote_collection');

        $filter = $this->getParam($this->getVarNameFilter(), array());
        if ($filter) {
            $filter = base64_decode($filter);
            parse_str(urldecode($filter), $data);
        }

        if (!empty($data)) {
            $collection->prepareForAbandonedReport($this->_storeIds, $data);
        } else {
            $collection->prepareForAbandonedReport($this->_storeIds);
        }

        //-----------------------------------------------------------------------
        // Get customer telephone.
        $collection->getSelect()
        ->joinLeft(
        array('table_billing'=>'customer_entity_int'),
        ('table_billing.entity_id=main_table.customer_id AND table_billing.attribute_id=13'), // 'default_billing' attribute id = 13
        array('table_billing_value'=>'value')
        )

        ->joinLeft(
        array('table_billing_telephone'=>'customer_address_entity_varchar'),
        ('table_billing_telephone.entity_id=main_table.customer_id AND table_billing_telephone.attribute_id=31'), // 'telephone' attribute id = 31
        array('telephone'=>'value')
        );

        //-----------------------------------------------------------------------

        $this->setCollection($collection);
        return Mage_Adminhtml_Block_Report_Grid_Shopcart::_prepareCollection();
    }


texts: Run Magento 2 cron with a different database user

texts:
Is it possible to run Magento 2 cron tasks under a different database user? This user will be able to connect to the same database as the website itself, and have exactly the same privileges; perhaps the only difference is that it may use a different password.

The main reason why I want to do this is to analyse the SQL queries that Magento are calling, and want to separate these between generic website usage, and background usage that are called via cron, and filtering these via the connected user will be the easiest approach.

If for whatever reason this is a bad approach, then please say so with your reasons.

Thank you!


texts:
I can able to get token from http://example.com/magento2/rest/V1/integration/admin/token with Username & Password.

Using this token, I can request product details on http://example.com/magento2/rest/V1/products/:sku and get stock level are working.

When I try to get a order details, I am getting error like:

"message": "Consumer is not authorized to access %resources",
"parameters":
    "resources": "Magento_Sales::sales"

When I try to get a customer details, I am getting error like:

"message": "Consumer is not authorized to access %resources",
"parameters":
    "resources": "Magento_Customer::customer"

I can access only functions which is vendor/magento/module-moduleName/etc/webapi.xml with resource ref="anonymous".

Rest of them I am having same error "Consumer is not authorized to access %resources".

How can able to access all magento core function through rest api?


texts: Magento 2.4 and PWA How We can deploy with two different URL as admin panel and front-end

texts: I try to many ways to setup Magneto 2 Backend side and frontend side with different domains. But not a success. I using LEMP stack and PWA as React frontend.. If someone setup with two different domains in production pleace help me...


texts: Remove existing admin menu Items in Magento 2

texts:
Looking for advice on where to place the menu.xml file in my child theme to remove menu items in Admin. Trying to clean it up after modules install extra items. Hopefully my syntax is correct.

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Backend:etc/menu.xsd">
    <menu>
      <remove id="Mageplaza_Core::partners" />
      <remove id="Magento_Marketplace::partners" />
    </menu>
</config>

Currently located at /public_html/app/design/frontend/My/childtheme/etc/adminhtml/menu.xml


texts: How to clean up magento2 database programatically?

texts: How can I delete all test data from Magento 2 database programatically by running an API?


texts: Add dynamic discount value in custom discount section html file Magento 2

texts:
I have created the module for the custom discount from https://www.mageplaza.com/how-add-custom-discount-magento-2.html. But there is a static value '$10'in customdiscount.html file.I want to add the dynamic value in that file or similar to value $baseDiscount from 'Custom.php'. Please help me if anyone knows that how can I add the dynamic amount as a discount?
Thanks in advance!!!


texts: How to get value for dropdown in custom form?

texts:
customform.phtml

    <?php /* @escapeNotVerified */
            echo __('Country') ?>

        <input name="country" id="country" title="<?php /* @escapeNotVerified */
        echo __('Country') ?>"
               value="<?php echo $block->escapeHtml($this->helper('Magento\Contact\Helper\Data')
                   ->getPostValue('country')) ?>"
               class="input-text" type="text" data-validate="{required:true}"/>

Country dropdown:
<?php $countryBlock = $block->getLayout()->createBlock('Magento\Directory\Block\Data');?>

<?= $countryBlock->getCountryHtmlSelect($defValue = null, $name = 'country_id', $id = 'country', $title = 'Country');?>

as per: https://magento.stackexchange.com/a/262790
How to put the dropdown in the form and get the selected country as $post variable / value?
Thanks


texts: how to save custom field in custom database table while editing product from back-end?

texts:
I have created a custom module to display custom tab on product form in back-end. I used this solution.

Now on tab i am adding custom fields to save in custom database table.
say <input type="text" name="my_new_field" value="123">

Also created a custom controller for admin product save like below.

In etc/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">
    <preference for="Magento\Catalog\Controller\Adminhtml\Product\Save" type="Namespace\Module\Controller\Adminhtml\Rewrite\Product\Save" />
</config>

And in Controller/Adminhtml/Rewrite/Product/Save.php

<?php

    namespace Namespace\Module\Controller\Adminhtml\Rewrite\Product;

    class Save extends \Magento\Catalog\Controller\Adminhtml\Product\save
    {

        public function execute()
        {
            echo "hello"; print_r($_POST); die;

            return parent::execute();
        }
    }

Now in execute function i am expecting POST value of my_new_field. But i am not getting it. After getting that i will use custom queries to save data in custom table.

What am i doing wrong or should i use some other method?

Update: 26 Aug.

I have used Ajax form to save data from product tab as i had time restrictions. I have accepted @william-oakley's answer. Now as @mageworx added in his answer that this is not a standard way to do this.

I want to use UI form standard usage in further development.
So my question is how to add custom tab to product edit using UI form standard and save custom fields in custom table or in another way.


texts: Get current product details in price phtml file in magento 2

texts:
I want to get current product details in /Magento_Catalog/templates/product/price/amount/default.phtml file.

I want to display custom price as per my requirements. so i need to get product collection here.
Below is the code what i have tried so far. This works in other phtml file but not working in default.phtml file where price is displayed.

$objectManager =  \Magento\Framework\App\ObjectManager::getInstance();

$registry = $objectManager->get('\Magento\Framework\Registry');
$currentProduct = $registry->registry('current_product');
echo $currentProduct->getName() . '<br />';

The product collection is coming as NULL.


texts: Magento 2 Customer update API using CURL

texts:
I am able to get create, view and delete using curl to a Magento 2.1 site. However, update seems to be not working. In this example I have already grabbed my token: curl -X POST "http://www.russellalbin.com/index.php/rest/V1/integration/admin/token" -H "Content-Type:application/json" -d '{"username":"someusername", "password":"somepassword"}'

That returns my Bearer that is used below ( masked of course for this posting )

curl -X "PUT" "http://www.russellalbin.com/rest/V1/customers/2" \ -H "Authorization: Bearer MASKEDCODEqoopucla3gt3bh" \ -H "Content-Type: application/json" \ -H "Accept: application/json" \ -d '{"customer": {"id": 2,"dob": "string","firstname": "updatedFn","lastname": "UpdatedLN","middlename": "updatedMN",},}'

I have a customer with the ID of 2. This request returns the following message pretty much no matter what I use for my json

{"message":"Decoding error."}

Is this still an issue with the version 2.1? I think I read that in 2.0.x it was causing issues but I never validated the complaints until now.

SOLVED
Bad JSON was to blame, here is an example of a working json

'{"customer": {"id": 2,"dob": "1972-08-20 00:00:00","firstname": "updatedFn","lastname": "UpdatedLN","middlename": "updatedMN", "email": "test@test.com", "website_id":1}}'


texts: Insert custom variable into email templates in magento 2

texts:
I'm trying to insert custom variable(company, Phone Number) into my customer email template. But it's not working for me.

 {{template config_path="design/email/header_template"}}

{{trans "%name," name=$customer.name}}

{{trans "Welcome to %store_name." store_name=$store.getFrontendName()}}

        {{trans
            'To sign in to our site, use these credentials during checkout or on the My Account page:'

            customer_url=$this.getUrl($store,'customer/account/',[_nosid:1])
        |raw}}

            {{trans "Email:"}}
            {{var customer.email}}

            {{trans "Password:"}}
            {{trans "Password you set when creating account"}}

        {{trans
            'Forgot your account password? Click here to reset it.'

            reset_url="$this.getUrl($store,'customer/account/createPassword/',[_query:[id:$customer.id,token:$customer.rp_token],_nosid:1])"
        |raw}}

    {{var company}}

{{trans "When you sign in to your account, you will be able to:"}}

{{trans "Proceed through checkout faster"}}

{{trans "Check the status of orders"}}

{{trans "Store alternative addresses"}}

{{trans "For shipping to multiple family members and friends"}}

{{trans "View past orders"}}

{{template config_path="design/email/footer_template"}}

Any help on this?


texts: Knockout If-else condition inside html file in Magento 2

texts:
I am customizing the shopping cart page, Here I worked knockout js and html code file. I successfully wrote If statement by below code.

<!-- ko if: isFreeShipping() -->
   //My Code goes here
<!-- /ko -->

For else statement not working, for these, I wrote below code.

    <!-- ko if: isFreeShipping() -->
       //My Code goes here
    <!-- ko ifnot: isFreeShipping() -->
       //My Code goes here
    <!-- /ko -->

  Error: Uncaught Error: You cannot apply bindings multiple times to the
  same element.

Can you please suggest me how to write If Else statement in html file?


texts: What would generate the message "Quote item is not found."

texts:
I have a module that emails me all frontend messages that are displayed to visitors.

Under what circumstance would the following message be displayed:

Quote item is not found.

I've tried to reproduce their steps but cant figure it out.


texts: Shipping method Sorry, no quotes are available for this order at this time

texts:
The plant guru website
wont show me shipping method


texts: Magento 2 product price different on catalog page and on product page

texts: I made a script for updating the price for a product using simple SQL queries, and I - expectedly - missed something, and now I have different price on catalog page and on the actual product page for a product. Price is the same on product page as on the admin product page, but on frontend catalog page, in the listing, for this product, price is different then on the product page and in admin. What tables need to be changed to synchronize these?


texts: Magento 2 - Got Error in Adminhtml Controller

texts:
I am trying to create custom module in magento2.
I got below error while click on the menu in admin.
it seems my admin controller not configured properly.

Can anyone help me in this issue.

  Fatal error: Class [NameSpace][ModuleName]\Controller\Adminhtml[ModuleName]\Index contains 1 abstract method and must therefore be declared abstract or implement the remaining methods (Magento\Framework\App\ActionInterface::execute)

My controller file is containing below codes.

namespace [NameSpace]\[ModuleName]\Controller\Adminhtml\[ModuleName];
use Magento\Framework\Controller\ResultFactory;
class Index extends \[NameSpace]\[ModuleName]\Controller\Adminhtml\[ModuleName]
{
    public function executeInternal()
    {   die('3243');
        $resultPage = $this->_initAction();
        $resultPage->getConfig()->getTitle()->prepend(__('Priya'));
        return $resultPage;
    }
}

where i have change in code.

Updated Question:
[NameSpace]/[ModuleName]/etc/adminhtml/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">
<router id="admin">
    <route id="hello" frontName="hello">
        <module name="[NameSpace]_[ModuleName]" before="Magento_Backend" />
    </route>
</router>
</config>

[NameSpace]/[ModuleName]/etc/adminhtml/menu.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Backend:etc/menu.xsd">
<menu>
    <add id="[NameSpace]_[ModuleName]::main_menu" title="Priya" module="[NameSpace]_[ModuleName]" sortOrder="80" action="hello/hello" resource="[NameSpace]_[ModuleName]::hello"/>
</menu>
</config>

[NameSpace]/[ModuleName]/Controller/Adminhtml/[ModuleName].php

<?php
namespace [NameSpace]\[ModuleName]\Controller\Adminhtml;
abstract class Hello extends \Magento\Backend\App\AbstractAction
{
protected $_coreRegistry;
public function __construct(
    \Magento\Backend\App\Action\Context $context,
    \Magento\Framework\Registry $coreRegistry,
     \Magento\Framework\App\Response\Http\FileFactory $fileFactory,
    \Magento\Framework\Translate\InlineInterface $translateInline,
    \Magento\Framework\View\Result\PageFactory $resultPageFactory,
    \Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory,
    \Magento\Framework\View\Result\LayoutFactory $resultLayoutFactory,
    \Magento\Framework\Controller\Result\RawFactory $resultRawFactory
) {parent::__construct($context);
    $this->_coreRegistry = $coreRegistry;
    $this->_coreRegistry = $coreRegistry;
    $this->_fileFactory = $fileFactory;
    $this->_translateInline = $translateInline;
    $this->resultPageFactory = $resultPageFactory;
    $this->resultJsonFactory = $resultJsonFactory;
    $this->resultLayoutFactory = $resultLayoutFactory;
    $this->resultRawFactory = $resultRawFactory;
}
protected function _initAction()
{
    $resultPage = $this->resultPageFactory->create();

    return $resultPage;
}
protected function _isAllowed()
{
    return $this->_authorization->isAllowed('[NameSpace]_[ModuleName]::hello');
}

}

[NameSpace]/[ModuleName]/Controller/Adminhtml/[ModuleName]/Index.php

<?php
namespace [NameSpace]\[ModuleName]\Controller\Adminhtml\[ModuleName];
use Magento\Framework\Controller\ResultFactory;
class Index extends [NameSpace]\[ModuleName]\Adminhtml\[ModuleName] {

protected $_publicActions = ['index'];
protected $resultPageFactory;

public function __construct(
Context $context,
PageFactory $resultPageFactory
) {
parent::__construct($context);
$this->resultPageFactory = $resultPageFactory;
 }

public function execute()
{
   echo "Hello World";
}

}


texts: Magento 2 - How to disable access Rest API Default

texts:
How to disable access permission Rest API default?
Such as I can view all product attribute information by: http://localhost/magento/rest/V1/products/attributes/status

{
    "is_wysiwyg_enabled": false,
    "is_html_allowed_on_front": false,
    "used_for_sort_by": false,
    "is_filterable": false,
    "is_filterable_in_search": false,
    "is_used_in_grid": false,
    "is_visible_in_grid": false,
    "is_filterable_in_grid": false,
    "position": 0,
    "apply_to": [],
    "is_searchable": "1",
    "is_visible_in_advanced_search": "0",
    "is_comparable": "0",
    "is_used_for_promo_rules": "0",
    "is_visible_on_front": "0",
    "used_in_product_listing": "1",
    "is_visible": true,
    "scope": "website",
    "attribute_id": 94,
    "attribute_code": "status",
    "frontend_input": "select",
    "entity_type_id": "4",
    "is_required": false,
    "options": [
        {
            "label": "Enabled",
            "value": "1"
        },
        {
            "label": "Disabled",
            "value": "2"
        }
    ],
    "is_user_defined": false,
    "default_frontend_label": "Status",
    "frontend_labels": null,
    "backend_type": "int",
    "source_model": "Magento\\Catalog\\Model\\Product\\Attribute\\Source\\Status",
    "default_value": "1",
    "is_unique": "0",
    "validation_rules": []
}


texts: Magento 2 : How to add category selector on admin form?

texts: I want to add a category selector on a new tab in my admin form. Please help me to do the same or provide me a suitable tutorial.


texts: Magento 2.3 - what's in the Default attribute set? (migration wiped it)

texts:
I have used the Data Migration Tool and now am cleaning my migrated attribute sets, wanting to remove attributes that dont make sense. My attribute sets have many groups called Migrated_ and a few attribute groups which are original, but most of them contain very little. I suspect that if an attribute was in my migration, it is in my migrated groups and not in the original default group it should be.

I obviously don't want to remove attributes that are used by functionality and I would also move the

But somehow as a result of running the tool, the Default attribute set has only 5 attributes in it. That's clearly not right!

I have been looking around the documentation for even a set of screenshots that would show me the contents of the default attribute set but can only find the top bit. It's frustrating.

Sure, I can install another M2 somewhere or try to reverse-figure from old SQL and code but maybe there's a reference somewhere that shows the attributes?


texts: Multiple datasource define in di.xml magento2

texts:
<?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\Framework\View\Element\UiComponent\DataProvider\CollectionFactory">
        <arguments>
            <argument name="collections" xsi:type="array">
                <item name="customerreport_customer_form_data_source" xsi:type="string">Tatva\Subscription\Model\ResourceModel\Subscription\Grid\CollectionReport</item>
                <item name="customerreport_customer_report_data_source" xsi:type="string">Tatva\Subscription\Model\ResourceModel\Subscription\Grid\CollectionSubReport</item>
            </argument>
        </arguments>
    </type>
    <type name="Tatva\Subscription\Model\ResourceModel\Subscription\Grid\CollectionReport">
        <arguments>
            <argument name="mainTable" xsi:type="string">subscription_history</argument>
            <argument name="eventPrefix" xsi:type="string">Tatva_Subscription_grid_collection</argument>
            <argument name="eventObject" xsi:type="string">Tatva_grid_collection</argument>
            <argument name="resourceModel" xsi:type="string">Tatva\Subscription\Model\ResourceModel\Subscription</argument>
        </arguments>
    </type>
    <type name="Tatva\Subscription\Model\ResourceModel\Subscription\Grid\CollectionSubReport">
        <arguments>
            <argument name="mainTable" xsi:type="string">subscription_history</argument>
            <argument name="eventPrefix" xsi:type="string">Tatva_Subscription_report_grid_collection</argument>
            <argument name="eventObject" xsi:type="string">Tatva_report_grid_collection</argument>
            <argument name="resourceModel" xsi:type="string">Tatva\Subscription\Model\ResourceModel\Subscription</argument>
        </arguments>
    </type>
</config>

Is it possible?


texts: Getting:'Mage_Core_Exception' with message 'Invalid block type:

texts:
I just started getting this error in my exceptions log file.  I'm running 1.7.0.2 and nothing has been touched on the site in a long time and this is popping up repeatedly.

exception 'Mage_Core_Exception' with message 'Invalid block type: ' in /chroot/home/thoughtt/thoughttechnology.com/html/app/Mage.php:598
Stack trace:
#0 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Model/Layout.php(495): Mage::throwException('Invalid block t...')
#1 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Model/Layout.php(437): Mage_Core_Model_Layout->_getBlockInstance('', Array)
#2 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Model/Layout.php(472): Mage_Core_Model_Layout->createBlock('', 'product.info.bu...')
#3 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Model/Layout.php(239): Mage_Core_Model_Layout->addBlock('', 'product.info.bu...')
#4 /chroot/home/thoughtt/thoughttechnology.com/html/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 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Model/Layout.php(210): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#6 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Controller/Varien/Action.php(344): Mage_Core_Model_Layout->generateBlocks()
#7 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Catalog/Helper/Product/View.php(73): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#8 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Catalog/Helper/Product/View.php(144): Mage_Catalog_Helper_Product_View->initProductLayout(Object(Mage_Catalog_Model_Product), Object(Mage_Catalog_ProductController))
#9 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Catalog/controllers/ProductController.php(132): Mage_Catalog_Helper_Product_View->prepareAndRender(206, Object(Mage_Catalog_ProductController), Object(Varien_Object))
#10 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Controller/Varien/Action.php(419): Mage_Catalog_ProductController->viewAction()
#11 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(254): Mage_Core_Controller_Varien_Action->dispatch('view')
#12 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#13 /chroot/home/thoughtt/thoughttechnology.com/html/app/code/core/Mage/Core/Model/App.php(354): Mage_Core_Controller_Varien_Front->dispatch()
#14 /chroot/home/thoughtt/thoughttechnology.com/html/app/Mage.php(687): Mage_Core_Model_App->run(Array)
#15 /chroot/home/thoughtt/thoughttechnology.com/html/index.php(108): Mage::run('', 'store')
#16 {main}

Not sure where to start looking...

Thanks


texts: Default value of 'yes/no' dropdown custom product attribute

texts:
I install the attribute with the following script:

$installer = $this;
$installer->startSetup();

$installer->removeAttribute('catalog_product', 'customizableonly');
$installer->addAttribute('catalog_product', 'customizableonly', array(
        'group'                     => 'General',
        'input'                     => 'select',
        'type'                      => 'int',
        'label'                     => 'Customizable Only',
        'source'                    => 'eav/entity_attribute_source_boolean',
        'global'                    => Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_GLOBAL,
        'visible'                   => 1,
        'required'                  => 0,
        'visible_on_front'          => 0,
        'is_html_allowed_on_front'  => 0,
        'is_configurable'           => 0,
        'searchable'                => 0,
        'filterable'                => 0,
        'comparable'                => 0,
        'unique'                    => false,
        'user_defined'              => false,
        'default'           => 0,
        'is_user_defined'           => false,
        'used_in_product_listing'   => true
));

$this->endSetup();

Also tried with $installer = new Mage_Catalog_Model_Resource_Eav_Mysql4_Setup('core_setup');

And then I am using the value of the attribute in some other code. But I always get null. I found out that, the attribute does not get set a default value. When I open a product - the dropdown shows No, but when I get its value in code it's null. If I just click the dropdown, simply set No and save the product - everything works.

How to overcome this?


texts: How to Remove Url Parameters and make english store as default

texts:
i have a website with 4 different stores, English (default), french, Italian, German.

but the issue is when i had default settings in magento my urls contains that parameter "?___store=en"

but i searched online and came across this answer: http://www.mcnab.co/blog/e-commerce/magento/magento-urls-remove-the-appended-store-parameter/

which is working fine for me but half. i have now store urls without any parameter.

but the issue i am facing is when i select English store it changes to url: http://www.smartteck.co.uk/en/ and when i remove

  /en/

from in front of url it directs me to french store.
i have tried by clearing caches and solution in other posts but nothing solved my issue.
can some one please tell me how keep my English store on base url http://www.smartteck.co.uk/  and rest of them should stay on url extension like /fr /de  /it etc and when some one visit our site http://www.smartteck.co.uk/ it must go to english store and (without any /en/) until he/she adds extension in url or change the language from drop down.
currently the hope page is opening in french
Thanks


texts: How to get front action from admin in magento 2

texts:
In my custom module i call one custom phtml.

In there is one button on that click i want to redirect front action

How can i call front action from admin?


texts: How to save custom product tab drop box fields values to database in Magento 2

texts:
By using data-form-part="product_form" in input tag, text values are getting. But how gets the drop down values.

When i used data-form-part="product_form" same in option, it gives an array with key index [undefined] and always give its last value of dropdown


texts: SoapFault: looks like we got no XML document - Magento and laravel

texts:
I am with a problem in my application Laravel, when i use the SoapClient, for example my_object_soap->login(); returned this error:

  Fatal error: Uncaught SoapFault exception: [Client] looks like we got
  no XML

I already tried several solutions that I researched in google and here, but I did not solve my problem.

my code follows:

    ini_set("soap.wsdl_cache_enabled",0);
    ini_set("soap.wsdl_cache",0);
    ini_set("error_reporting",-1);
    ini_set("display_errors","On");

    $wsdl_url = "https://example.com/index.php/api/v2_soap/index/?wsdl";
    $apiAuth = new \stdClass();
    $apiAuth->username = trim("myusermagento");
    $apiAuth->apiKey = trim("mykeymagento");

    try{
        $proxy = new SoapClient($wsdl_url,array('cache_wsdl' => WSDL_CACHE_NONE, 'trace' => true));
        $session = $proxy->login($apiAuth);
        $data = $session;
        $status = true;
        $responseStatus = 200;
    } catch(SoapFault $e) {
        $error = $e->getMessage();
        $data = $proxy->__getLastResponse();
        $status = false;
        $responseStatus = 500;
    }

    return Response::json([
        'success' => $status,
        'data' => $data,
        'erros'=> $error,
    ],$responseStatus);

I have no idea which a problem, when i tested in SoapUI, with this user and key, it's alright, but in my app not.

My magento version app is 1.6.2, and my php is 7.2, I already tried to downgrade to php 5.6 because it could be incompatibility with the magento version and my php but it still did not work.

Can someone help me?


texts: What does catalog:images:resize do in magento 2?

texts:
I am having a problem with how my images are displaying on my Magento 2 store.

And also I would like to know:

What does catalog:images:resize in Magento 2.x version ?


texts: What happens to the applied sales rules when items are cancelled?

texts:
I'm not sure magento supports the partial cancellation(cancel only subset of items from order)

Below is my guess how magento works with this issue, but need confirmation.

It seems one can achieve the partial cancellation by creating partial invoice (dropping the items that needs to be cancelled)

When creating a invoice, magento re-inspect rules that holds (without the dropped items) and recalculate the total.

magento doesn't have a function where it removes sales rules already applied it only re-inspect the rules whenever it goes from order -> invoice.

(otherwise how can one ensure that cancellation doesn't affect the sales rules in some unwanted way?) <= this is my question


texts: system.xml admin menu - disable autocomplete in username password

texts:
I have setup a module and my system.xml to enable admin menus. The issue is that the username and password fields are auto-populating which can potentially cause problems later down the track via a human error. Is it possible to put parameters in system.xml (and thereby render the input tag with autocomplete="off" to disable the autocomplete?

EDIT

This is not a question about browser behaviour. It is asking if it is possible to insert parameters into the <input> HTML when it is rendered via system.xml and/or AdminHTML.


texts: Magento 2 Catalog Product Flat Data not reindexing

texts:
the indexing of magento product Flat data is staying on "index required".The mode is on "Scheme" and the cron is running. I tried several things like:

  truncate catalog_product_flat_1, catalog_product_flat_2,
  catalog_product_flat_3, catalog_product_flat_4

php bin/magento indexer:reindex
php bin/magento indexer:reset
php bin/magento indexer:reindex
php bin/magento indexer:reset catalog_product_flat

Error :-

  message in shell: State for the same indexer already exists.

update indexer_state set status = 'invalid' where status != 'valid';

Then reindex again

Can anybody help?
Thanks


texts:
Starting this morning, we began receiving a 401 error when sending a request. Nothing we know has changed on our end

{
  "message": "Consumer is not authorized to access %resources",
  "parameters": {
    "resources": "Magento_Sales::sales"
  }
}

This was previously working with no issues. Here is the sample request:

curl -X GET -k -H 'Authorization: OAuth oauth_signature_method="HMAC-SHA1", oauth_nonce="tNmhe", oauth_timestamp="1560297878", oauth_consumer_key="key_here", oauth_token="token_here", oauth_version="1.0", oauth_signature="sig_here"' -i 'https://domain/rest/V1/orders/7586/'


texts: How to get tracking info using tracking Number

texts:
I want get tracking info, which is used in popup.phtml.
In trackingcontroller.php tracking info load by hash.

 $shippingInfoModel = Mage::getModel('shipping/info')->loadByHash($this->getRequest()->getParam('hash'));

How to load tracking info using tracking number?


texts: Why is Magento Category view limit defaulting to 5000?

texts:
I have added a custom category list mode. Everything seems to be working fine (limit settings are the same as any other category list mode) but for some reason when I change from Grid or List mode to Slider (my new mode) the default category per page is set to 5,000.

When I comment the line in the following code (app\code\local\Mage\Catalog\Block\Product\List\Toolbar.php) the limit is set to the new mode's default of 12 and functions exactly as expect. If I print_r($this->_availableLimit[$mode] it returns array(5000=>5000).

protected function _getAvailableLimit($mode)
{
    if (isset($this->_availableLimit[$mode])) {
        //return $this->_availableLimit[$mode];
    }
    $perPageConfigKey = 'catalog/frontend/' . $mode . '_per_page_values';
    $perPageValues = (string)Mage::getStoreConfig($perPageConfigKey);
    $perPageValues = explode(',', $perPageValues);
    $perPageValues = array_combine($perPageValues, $perPageValues);
    if (Mage::getStoreConfigFlag('catalog/frontend/list_allow_all')) {
        return ($perPageValues + array('all'=>$this->__('All')));
    } else {
        return $perPageValues;
    }
}


texts: Install Magento 2.3 local gives a error 500

texts: I try to install Magento 2.3 local in windows but i get error 500. What can i do to solve this problem or/and where is the problem settled? Thanks for advising. I am a absolute beginner.


texts: Product attribute genarate value depending on other attribute value

texts:
Can somebody help me.....is there a way to get value from more then one product attribute's

Example: Let say I have product with attribute color, size and model (red, 8.5, sneaker). Know I need a attribute that generate these value from 3 attribute's and make as the value red8.5sneaker

Instead of creating attribute with a text field or dropdown, I need these value from this other attribute's


texts: Maximum 1000 products per Customer Group Catalog Rule

texts:
I am currently workong on a 1.9 Community E Magento site that, unfortunately, has nearly 50,000 products. Aside from the Magento issues with that many products, I am utilizing the Amasty Customer Group Catalog plugin to asign a credit system to all products using a Customer Group Rule, but the Customer Group Rule caps out at 1000 products per rule, or it throws a token error.

Are there any other options for this ruling other than creating 50 duplicates of the same rule and assigning roughly 1000 products to each?


texts: Button in CMS page that links to registering page

texts:
I am using Magento 1.7. I am designing a CMS page through the WYSIWYG editor in the Admin->CMS->Pages section, with the tool 'Edit HTML source'. I need to add a button in the CMS page that links to the registration page.

I added the following to the HTML code of my page:

<form action="{{config path="web/unsecure/base_url"}}/index.php/es/customer/account/create/">
    <input type="submit" value="Go to registering page" />
</form>

But it's not working. I tried to use single (") quotations and normal quotations (') but it's not working anyway.

What is the proper way to define the URL in this case? Is there a better way to insert this button?


texts: Magento 2 - php fatal error class not found

texts:
Whatever I try to run on my SSH-Server it displays the same error:
$ php bin/magento cron:install [--force]
PHP Fatal error:  Uncaught Error: Class 'Magento\Setup\Mvc\Bootstrap\InitParamListener' not found in /var/www/vhosts/myurl.de/httpdocs/neu/setup/config/application.config.php:29
Stack trace:
#0 /var/www/vhosts/myurl.de/httpdocs/neu/vendor/magento/framework/Console/Cli.php(72): require()
#1 /var/www/vhosts/myurl.de/httpdocs/neu/bin/magento(22): Magento\Framework\Console\Cli->__construct('Magento CLI')
#2 {main}
  thrown in /var/www/vhosts/myurl.de/httpdocs/neu/setup/config/application.config.php on line 29

I already tried to check the PHP files but I am a beginner at PHP...
Does someone know a solution?


texts: How to sort the options of the dropdown attribute in magento 2

texts:
I am using the following code to get the options of the select attribute.

Now I want to get the options that should be ordered alphabetically.

file.php

$eavConfig = $object_Manager->get('\Magento\Eav\Model\Config');
    $attribute = $eavConfig->getAttribute('catalog_product', 'color');
    $options = $attribute->getSource()->getAllOptions();

    $optionsExists = array();

    foreach($options as $option) {
        $optionsValues[] = $option['value'];
        $optionsExists[] = $option['label'];
    }

    return $optionsExists;

I am using the above code. Can anyone guide magentoe2


texts: how to do reindexing and cache clear with external file

texts:
I m seeking code for reindexing and cache clear via external php file in magento 2. but i m not succeed.

Can anyone helps me to achieve this.

Any help will appreciated.


texts: Catalog Price Rules, how to make them apply to tier prices?

texts:
so say ive got products with different tier prices due to quantity purchased, is the any way to make a catalog price rule that for example takes 10% off all price tiers and not just the product price value ??

thanks.


texts:
From 2.1 Magento has introduced Magento/Framework/Model/EntityManager

I may be wrong here but from my  understanding it is to replace Magento/Framework/Model/AbstractModel which was implementing the feature via inheritance and solve this via composition (FYI : https://en.m.wikipedia.org/wiki/Composition_over_inheritance )

You can get an example here in the core files: https://github.com/magento/magento2/blob/59671558ecdab652b40db2d1a7c63d5b1dea0a92/app/code/Magento/Cms/Model/ResourceModel/Block.php

Basically all the CRUD operations are explicitly declared in the class and deferred to the EntityManager class. Before 2.1, the parent method was called via inheritance.

So my questions are:

what are the benefits of the EntityManager over the pre 2.1 inheritance system?
is simply declaring the CRUD methods (like the example above) enough to start implementing it in a custom CRUD module or is there more?


texts: Getting same url for all product load by id

texts:
i am tring to get product name and url according to product id but get return  first product url for all but product names are getting right.here is my code.please help me.thank you.

in phtml page

 <?php  foreach ($question_list as $value){ ?>

<?php echo __('Q : ');?><?php echo $value->getQuestionNote(); ?>

                        <?php
                            $id = $value->getProductId();
                            if($value->getQuestionStatus() == 0){
                                echo  __('Status : pending');
                            }elseif($value->getQuestionStatus() == 1){
                                    echo  __('Status : published');
                            }else{
                                    echo  __('Status : rejected');
                            }
                            $productObj = $block->getProductDetails($id);
                            echo  __('  || Product name : ').$productObj->getName();
                            echo  __('  || Producturl  : ').$productObj->getProductUrl();
                        ?>

<?php      } ?>

in block page

public function getProductDetails($id){

    $objectManager = \Magento\Framework\App\ObjectManager::getInstance();
    $productObj = $objectManager->get('Magento\Catalog\Model\Product')->load($id);
    return $productObj;
}


texts: get store categories inside phtml file magento2

texts: I want to customize topmenu.phtml file but I see, I can customize limited html. How I can create my own menu and get store categories inside phtml?


texts: Remove payonline & cash on delivery option if we checkout for wholesale magento 1.9

texts:
I have try to do remove pay online & cash on delivery option if we sign in for wholesale Magento 1.9.4.0

thanks


texts: Magento 2: Use widget with standard product list template

texts:
Is there way to use the same template like the "new products" widget magento already has but with my own product collection?

I know how to make a widget but i don't how to attach the standard template and how to pass my productdata to it.

Any ideas where to start?


texts: How to get current configurable product sku in controller - Magento 2

texts:
I am trying to get current product SKU in controller using the below code:

namespace Test\ProductsToCart\Controller\Product;

class Styles extends \Magento\Framework\App\Action\Action
{
    protected $data;
    protected $_registry;

    public function __construct(
        \Magento\Framework\App\Action\Context $context,
        \Magento\Framework\Controller\Result\JsonFactory $resultJsonFactory,
        \Magento\Framework\Registry $registry,
        array $data = []
    ) {
        $this->resultJsonFactory = $resultJsonFactory;
        $this->_registry = $registry;
        parent::__construct($context, $data);
    }

    public function execute()
    {
        $objectManager = \Magento\Framework\App\ObjectManager::getInstance();
        $prid = $this->_registry->registry('current_product');
        $pr1id = $prid->getSku();
        echo $pr1id;
    }
}

but couldn't get the result.

Is there any problem with this line of code?

 $prid = $this->_registry->registry('current_product');

Also tried:

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$product = $objectManager->get('Magento\Framework\Registry')->registry('current_product');
echo $product->getId();
$product->getSku();

Getting error like:

  Call to a member function getId() on null


texts: How can I remove the feature that makes you whitelist blocks ( part of SUPEE-6788 )

texts:
Where is the code located so I don't have to whitelist blocks? I hate this feature. I know it's security stuff but I don't want it on my local environment. Can someone please tell me how to remove it on the Magento  1.14.2.4.

Thanks

vagrant@precise32:/var/www/n98-magerun$ php n98-magerun.phar media:sync

  [Symfony\Component\Console\Exception\CommandNotFoundException]
  Command "media:sync" is not defined.
  Did you mean this?
      media:dump


texts: Prevent abandoned cart and guest cart merge

texts:
I have made Observer on event "sales_quote_merge_before" to remove abandoned cart items when customer logs in (from Go to Checkout).
After login Minicart shows only guest cart items (no items from abandoned cart), but on checkout/cart and checkout/ carts are still merged and show all items (guest and abandoned combined)

Any ideas what I'm doing wrong?

public function execute(Observer $observer) {
     $this->_logger->debug('SingleVendorMergeObs:sales_quote_merge_before');
       $event = $observer->getEvent();

     /** @var $quote \Magento\Sales\Model\Quote */
     $quote = $observer->getQuote();
     $quote->removeAllItems();
     $quote->save();
}


texts:
Does anyone know a good module that can use HTTP VERBS like POST and PUT ?. I tried this one magento2 but only managed to use GET and DELETE ...

Hope someone has a few ideas !


texts: Magento2: Error client denied by server configuration:

texts:
After I migrate data on magento2 from 1.9.1, I get an error on the home page, admin is functional, error is

The page isn't redirecting properly

Firefox has detected that the server is redirecting the request for this address in a way that will never complete.

In /var/log/httpd error_log  client denied by server configuration: /var/www/html/magento2/app/etc/config.php


texts:
I want to add MAP in contact us page. To do this I want to override it's phtml.

How can I get it's phtml and how can I override it?

Thanks


texts: Weird issue tab id coupons_section is not instanceof Mage_Adminhtml_Block_Widget_Tab_Interface

texts:
I am struggling with weird problem when go to admin and click for add new rule code or edit a previously created shopping cart price rule en error is coming out

a:5:{i:0;s:29:"Test Wrong tab configuration.";i:1;s:2443:"#0 [internal function]: Mage_Adminhtml_Block_Widget_Tabs->addTab('coupons_section', 'promo_quote_edi...')
#1 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Model/Layout.php(347): call_user_func_array(Array, Array)
#2 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Model/Layout.php(213): Mage_Core_Model_Layout->_generateAction(Object(Mage_Core_Model_Layout_Element), Object(Mage_Core_Model_Layout_Element))
#3 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Model/Layout.php(205): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#4 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Model/Layout.php(209): Mage_Core_Model_Layout->generateBlocks(Object(Mage_Core_Model_Layout_Element))
#5 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(345): Mage_Core_Model_Layout->generateBlocks()
#6 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(270): Mage_Core_Controller_Varien_Action->generateLayoutBlocks()
#7 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Adminhtml/Controller/Action.php(263): Mage_Core_Controller_Varien_Action->loadLayout(NULL, true, true)
#8 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Adminhtml/controllers/Promo/QuoteController.php(43): Mage_Adminhtml_Controller_Action->loadLayout()
#9 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Adminhtml/controllers/Promo/QuoteController.php(92): Mage_Adminhtml_Promo_QuoteController->_initAction()
#10 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Controller/Varien/Action.php(420): Mage_Adminhtml_Promo_QuoteController->editAction()
#11 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Controller/Varien/Router/Standard.php(250): Mage_Core_Controller_Varien_Action->dispatch('edit')
#12 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Controller/Varien/Front.php(176): Mage_Core_Controller_Varien_Router_Standard->match(Object(Mage_Core_Controller_Request_Http))
#13 /var/www/vhosts/beadsofcambay.com/magento/app/code/core/Mage/Core/Model/App.php(349): Mage_Core_Controller_Varien_Front->dispatch()
#14 /var/www/vhosts/beadsofcambay.com/magento/app/Mage.php(640): Mage_Core_Model_App->run(Array)
#15 /var/www/vhosts/beadsofcambay.com/magento/index.php(87): Mage::run('', 'store')
#16 {main}";s:3:"url";s:70:"/index.php/admin/promo_quote/new/key/accf713773b40d7a8531a365ea28cabe/";s:11:"script_name";s:10:"/index.php";s:4:"skin";s:5:"admin";}

I have looked into the app/code/core/Mage/Adminhtml/Block/Widget/Tabs.php

under the function addTab($tabId, $tab)

This condition is giving error where $tabId is coupon_section

 if(!($this->_tabs[$tabId] instanceof Mage_Adminhtml_Block_Widget_Tab_Interface)){
                    throw new Exception(Mage::helper('adminhtml')->__('Test Wrong tab configuration.'));
                }

It was previously running perfect but don't know why this is giving error now?


texts: Which observer method is used to determine, whether the payment made through paypal or not?

texts:
I need to send another mail when the order is placed...in majority cases it works fine but the issue comes with paypal. When I select paypal in payment method tab & then in next step of checkout when I hit submit then it redirects to the paypal at that time itself the another mail which I stated above fired.

I want it to be fired when payment is done on paypal. I am using this observer event - sales_order_place_after

I also searched & got the below link but it says the same thing...I mean same observer event.

How to Change Order Status After Successful PayPal Express Order

Can anyone please help with this?


texts: How to set ifconfig for di.xml magento 2

texts:
I want set ifconfig configuration for below code:

First code in di.xml

<virtualType name="searchFilterList" type="Magento\Catalog\Model\Layer\FilterList">
    <arguments>
        <argument name="filters" xsi:type="array">
            <item name="attribute" xsi:type="string">KM\LayeredNavigation\Model\Layer\Filter\Attribute</item>
            <item name="price" xsi:type="string">KM\LayeredNavigation\Model\Layer\Filter\Price</item>
            <item name="decimal" xsi:type="string">KM\LayeredNavigation\Model\Layer\Filter\Decimal</item>
            <item name="category" xsi:type="string">KM\LayeredNavigation\Model\Layer\Filter\Category</item>
        </argument>
    </arguments>
</virtualType>

i was tried to put ifconfig on virtualtype tag but it's not working.

Second Code in di.xml

<type name="Magento\Catalog\Controller\Category\View">
    <plugin name="ajax_loader" type="KM\LayeredNavigation\Plugin\CategoryView" sortOrder="1" />
</type>

same as process above code.

can you please suggest how can i set the configuration or is there any alternative solution so please provide to me. It will helpful to me and also others.

Thanks


texts: Magento 2: How to hide an HTML element in the checkout page?

texts:
I have a datepicker block on the checkout shipping step that I would like to be able to hide based on a condition. If the user doesn't qualify for a certain shipping method, I would like for the datepicker to be hidden. I tried adding this logic to the js file associated with the datepicker block, but nothing worked.

HTML

Delivery Date

    <input class="input-text" type="text" data-bind="datepicker: true"  name="delivery_date" id="delivery_date" readonly="true"/>

Comment

    <textarea name="delivery_comment" id="delivery_comment" ></textarea>

JS

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

    return Component.extend({
        defaults: {
            template: 'SR_DeliveryDate/delivery-date-block'
        },
        initialize: function () {
            this._super();
            var disabled = window.checkoutConfig.shipping.delivery_date.disabled;
            var noday = window.checkoutConfig.shipping.delivery_date.noday;
            //var hourMin = parseInt(window.checkoutConfig.shipping.delivery_date.hourMin);
            //var hourMax = parseInt(window.checkoutConfig.shipping.delivery_date.hourMax);
            var format = window.checkoutConfig.shipping.delivery_date.format;

            if(!format) {
                format = 'yy-mm-dd';
            }
            var disabledDay = disabled.split(",").map(function(item) {
                return parseInt(item, 10);
            });

            ko.bindingHandlers.datepicker = {
                init: function (element, valueAccessor, allBindingsAccessor) {
                    var $el = $(element);
                    //initialize datetimepicker
                    if(noday) {
                        var options = {
                            minDate: 0,
                            dateFormat:format

                        };
                    } else {
                        var options = {
                            minDate: 0,
                            dateFormat:format,
                            beforeShowDay: function(date) {
                                var day = date.getDay();
                                if(disabledDay.indexOf(day) > -1) {
                                    return [false];
                                } else {
                                    return [true];
                                }
                            }
                        };
                    }

                    $el.datepicker(options);

                    var writable = valueAccessor();
                    if (!ko.isObservable(writable)) {
                        var propWriters = allBindingsAccessor()._ko_property_writers;
                        if (propWriters && propWriters.datepicker) {
                            writable = propWriters.datepicker;
                        } else {
                            return;
                        }
                    }
                    writable($(element).datepicker("getDate"));
                },
                update: function (element, valueAccessor) {
                    var widget = $(element).data("DateTimePicker");
                    //when the view model is updated, update the widget
                    if (widget) {
                        var date = ko.utils.unwrapObservable(valueAccessor());
                        widget.date(date);
                    }
                }
            };

            return this;
        }
    });
});


texts: Run magento2.2.3 on Local Machine - MAMP

texts:
I downloaded my live magento 2.2.3 based website into my local desktop Mamp directory.

I imported the database into the local phpmyadmin.
I edited the app/etc/env.php file to have the correct localhost cridentials
for the phpmyadmin database

Now when i go to the website on http://mysite:8888
I get an error that says

Zend\Uri\Exception\InvalidArgumentException: no class registered for scheme "mysite" in /Applications/MAMP/htdocs/mysite/vendor/zendframework/zend-uri/src/UriFactory.php:102 Stack trace: #0

so i am not sure what step I am missing to get a local version of the live site working.
I have My Mamp setup to use apache/php7.1.3/mysql5.6.38


texts: Im gettin this error in Magento 1.9.3.10: "Unknown old style column type definition: smallint unsigned."

texts: Im getting the error: "Unknown old style column type definition: smallint unsigned." when I try to reindex the "Product flet data.". The discription of the index is "Reorganize EAV product structure to flat structure". All of this is magento 1.9.3.10


texts: Magento 2.3.2 Unable to send the cookie. Size of 'mage-messages' is 4191 bytes

texts:
Last two days suddenly my logs are filled with this in Magento 2.3.2:

report.ERROR: Unable to send the cookie. Size of 'mage-messages' is 4191 bytes.

  In Stores>Configuration>General>Web

My Default Cookie Settings are:

  Cookie Lifetime: 3600(default)

  Cookie Path:

  Cookie Domain:

  Use Http only: Yes

  Cookie Restriction Mode: No

Does anybody have this issue?
Can't find something related when I searched about


texts:
I am having this problem with magento 2.x. Whenever I go to a product page, I get redirected to /customer/account. I have debugged it with firebug and I discovered this:

301 Moved Permanently (BFCache)

From what I understand it's varnish that's redirecting. However running bin/magento cache:clean/flush doesn't really help. Is there something I'm not seeing? Thanks for any help!


texts: MySql Query Convert to Magento Collection Format

texts:
How to convert below MySql Query to Magento collection :

I trying to show, which product have less then 50% of Final Prices in product Price, should be shown in web page.

I have tried below query working fine in MySql its working fine, I need to convert in Magento collection format.

SELECT `e`.*, `at_category_id`.`category_id`, IF(at_status.value_id > 0, at_status.value, at_status_default.value) AS `status`, IF(at_visibility.value_id > 0, at_visibility.value, at_visibility_default.value) AS `visibility`, `at_special_price`.`value` AS `special_price`, `price_index`.`price`, `price_index`.`tax_class_id`, `price_index`.`final_price`, IF(price_index.tier_price IS NOT NULL, LEAST(price_index.min_price, price_index.tier_price), price_index.min_price) AS `minimal_price`, `price_index`.`min_price`, `price_index`.`max_price`, `price_index`.`tier_price` FROM `catalog_product_entity` AS `e`
 LEFT JOIN `catalog_category_product` AS `at_category_id` ON (at_category_id.`product_id`=e.entity_id)
 INNER JOIN `catalog_product_entity_int` AS `at_status_default` ON (`at_status_default`.`entity_id` = `e`.`entity_id`) AND (`at_status_default`.`attribute_id` = '273') AND `at_status_default`.`store_id` = 0
 LEFT JOIN `catalog_product_entity_int` AS `at_status` ON (`at_status`.`entity_id` = `e`.`entity_id`) AND (`at_status`.`attribute_id` = '273') AND (`at_status`.`store_id` = 1)
 INNER JOIN `catalog_product_entity_int` AS `at_visibility_default` ON (`at_visibility_default`.`entity_id` = `e`.`entity_id`) AND (`at_visibility_default`.`attribute_id` = '526') AND `at_visibility_default`.`store_id` = 0
 LEFT JOIN `catalog_product_entity_int` AS `at_visibility` ON (`at_visibility`.`entity_id` = `e`.`entity_id`) AND (`at_visibility`.`attribute_id` = '526') AND (`at_visibility`.`store_id` = 1)
 INNER JOIN `catalog_product_entity_decimal` AS `at_special_price` ON (`at_special_price`.`entity_id` = `e`.`entity_id`) AND (`at_special_price`.`attribute_id` = '567') AND (`at_special_price`.`store_id` = 0)
 INNER JOIN `catalog_product_index_price` AS `price_index` ON price_index.entity_id = e.entity_id AND price_index.website_id = '1' AND price_index.customer_group_id = 0 WHERE (IF(at_status.value_id > 0, at_status.value, at_status_default.value) = '1') AND (IF(at_visibility.value_id > 0, at_visibility.value, at_visibility_default.value) = '4') AND (at_special_price.value != '') AND (at_category_id.category_id = '35') and price_index.final_price < (price_index.price * .5)

Thanks.


texts: Is static content ever stored in the di / generated folders?

texts:
I'm doing some theme development, which I am somewhat new to.  I am making changes to some files, and I like to test if they can compile correctly, so I run the setup:static-content:deploy somewhat regularly.

Prior to doing so, I purposely wipe the pub/static folder as well as var/page_cache & view_preprocessed folders respectively. The one thing that I do not know, if static-content is ever deployed into the generation/di folders ?

So if I'm doing compilation testing for .less file changes, do I need at all to wipe di & generation folder and re-run setup:di:compile ?

Just curious.


texts: Get all dropdown and multi select attrinbutes in system configuration

texts:
I have to get all the attributes which have type dropdown or multiselect in system configuration.

<field id="test" translate="label" type="multiselect" sortOrder="0" showInDefault="1" showInWebsite="1" showInStore="1">
    <label>Test</label>
    <source_model>Vendor\Module\Model\Config\Source\AttSource</source_model>
</field>

AttSource.php

<?php

namespace Vendor\Module\Model\Config\Source;

use \Magento\Framework\Data\OptionSourceInterface;

class AttSource implements OptionSourceInterface {

    protected $_attributeFactory;

    public function __construct(

\Magento\Catalog\Model\ResourceModel\Eav\Attribute $attributeFactory
) {

    $this->_attributeFactory = $attributeFactory;
}

public function toOptionArray() {
    $arr = [];
    $attributeInfo = $this->_attributeFactory->getCollection()->addFieldToFilter(\Magento\Eav\Model\Entity\Attribute\Set::KEY_ENTITY_TYPE_ID, 4);

    foreach ($attributeInfo as $attributes) {
        $attributeId = $attributes->getAttributeId();
        // You can get all fields of attribute here

        $arr[$attributes->getAttributeId()] = $attributes->getFrontendLabel();
    }
    return $arr;
}
}

But above code is not working.


texts: What are the best practices for persisting the customer address(es) at checkout?

texts:
I'm working on a flow that would allow for a one page checkout for one of my clients and we might consider a plugin but there's a requirement to persist the addresses(shipping/billing) when the logged-in customer reaches a certain step at checkout, abandons and returns to complete the checkout. Is it a good practice to persist the addresses for these scenario so that the customer doesn't have to go through the trouble of re-entering all of their addresses or should the returning customer re-enter that information?

Will appreciate your help with this and perhaps point me to a post that provides details around best practices.

Thanks


texts: Magento 2.2.1 - Unable to save changes in product category

texts:
Need your help to assist me on this problem. I have been working on this for almost 3 hour.

I click save button but nothing appear plus the product is not saved.

As my effort..
1) Flush the magento cache
2) clear the cache in browser too
3) restart my laptop

It still doesn't work. Need your help guys..


texts:
I have activated the new order rss feed via my Magento config.  However when trying to access the feed (https://domain.com/rss/order/new/) a login prompt asks for user and password.  After some searching this is supposed to be the same username as password as the admin, however my credentials do not work, and I am trying to access with an admin login with full permissions.

In order to make sure the RSS is working I disabled the authentication in the controller and the RSS now works fine but obviously this is not an ideal solution.

Any ideas as to why my admin login is not working or how to setup proper credentials that can easily access the new order RSS?


texts: Set up separate stores with different quantities of the same items

texts:
I have 4 stores with different stores with some similar and some different products.

I want different inventory for all stores, I tried to add the inventory of stores it changes Globally, I'm using the below code.

$sku='123asd';
$qty=12;
$exitProduct = Mage::getResourceSingleton('catalog/product')->getIdBySku((string)$sku);

if ($exitProduct) {

        $product = Mage::getModel('catalog/product')->load($exitProduct);
        $product->setStoreId(2)->setPrice($xmlDatas['preco'])->save();

        $productId = $product->getId();
        $stockItem = Mage::getModel('cataloginventory/stock_item')->loadByProduct($productId);
        $stockItem->setData('manage_stock', 1);
        $stockItem->setData('qty', (integer) $qty]);
        $stockItem->save();
} else {
    continue;
}

How can I set different Qty for different stores?


texts:
I want to override getCustomizedOptionValue function in

Magento\Sales\Block\Adminhtml\Items\Column\DefaultColumn

In etc\adminhtml\di.xml:

 <preference for="Magento\Sales\Block\Adminhtml\Items\Column\DefaultColumn" type="XXX\ProductInfo\Block\Adminhtml\Items\Column\DefaultColumn" />

In block:

<?php

namespace XXX\ProductInfo\Block\Adminhtml\Items\Column;

    class DefaultColumn extends \Magento\Sales\Block\Adminhtml\Items\Column\DefaultColumn
    {
        public function getCustomizedOptionValue($optionInfo)
        {
            echo "dgggggggggggggfgd";exit;

        }
    }

Not working ..

If anything i want to do that..

Thanks.


texts:
i want to add custom option for all product say ring size:7,6,5,4,3

i want to show if for all product types with attribute set as ring , i tried adding as custom option but in this way we have to add for all products , any easy way too show it as drop down fro all product

Bascially it drop down and user have to select it


texts:
Magento Community Version 1.9.0.1
Patched Up till 10888

I just applied patch SUPEE-10975 and now when I go to the checkout pages I am getting some serious console errors:

prototype.js:5653 Uncaught TypeError: element.attachEvent is not a function
    at Function.observe (prototype.js:5653)
    at js.js:627
observe @ prototype.js:5653
(anonymous) @ js.js:627
prototype.js:5644 Uncaught TypeError: element.attachEvent is not a function
    at observe (prototype.js:5644)
    at HTMLDocument._methodized [as observe] (prototype.js:438)
    at captcha.js:1
observe @ prototype.js:5644
_methodized @ prototype.js:438
(anonymous) @ captcha.js:1
prototype.js:5644 Uncaught TypeError: element.attachEvent is not a function
    at observe (prototype.js:5644)
    at HTMLDocument._methodized [as observe] (prototype.js:438)
    at common.js:300
observe @ prototype.js:5644
_methodized @ prototype.js:438
(anonymous) @ common.js:300
prototype.js:5653 Uncaught TypeError: element.attachEvent is not a function
    at observe (prototype.js:5653)
    at HTMLDocument._methodized [as observe] (prototype.js:438)
    at livepipe.js:133
    at livepipe.js:135
observe @ prototype.js:5653
_methodized @ prototype.js:438
(anonymous) @ livepipe.js:133
(anonymous) @ livepipe.js:135
window.js:87 Uncaught Control.Window requires IframeShim to be loaded.
(anonymous) @ window.js:87

I assume it has to do with the inclusion of the newer version of jquery 1.12.1

But not sure what to do?
I've reverted it and not getting these errors anymore.

Thanks for your help in advance!


texts: How can I cancel processing order from frontend in Magento 2?

texts:
I have an extension to cancel order fro frontend customers but it is useful for only pending orders when COD available.

I want to cancel processing order from frontend. Is it possible?


texts: Thumbnail image not showing for new added product

texts:
I have migrated my website form Magento 1.9, i have manage to import all products and orders but i have a problem.
When i add a new product, it won't show the thumbnail on product page, there is no image created on that link, if u click on the default magento thumbnail it will show the big gallery image ok.
The only solutions that i have is to copy all the images from the gallery to the thumbnail folder.
I have tried the usual deploy, cache flush, cache clean, reindex etc and even finished image resize command but w/o any luck.
For the migrated product i had the same problem but fixed it by copying the gallery folder to the thumbnail folder.
I'm using Magento 2.3.4 version and i migrated from 1.9.


texts: How can I change the persistence message that shows when a customer logs out?

texts:
I am trying to change the persistence message that shows in the header when a customer logs out.

(Not Mr Foo?)

I've tried changing it via translation file:

"Not %s?","Log In / Register"

I've also tried rewriting the block class:

class Mycompany_Persistent_Block_Header_Additional extends Mage_Persistent_Block_Header_Additional
{
    /**
     * Render additional header html
     *
     * @return string
     */
    protected function _toHtml()
    {
        $text = $this->__('Log In / Register');

        $this->setAnchorText($text);
        $this->setHref($this->getUrl('persistent/index/unsetCookie'));

        return parent::_toHtml();
    }
}

The above doesn't have an effect on changing the link as it still displays as if the rewrite doesn't exist even though I can see the my class is being loaded.

Has anyone managed to change this bit of text? All i want to do is replace it with Log In / Register

Many thanks


texts: I know how to use fillfield and click, but is there any way to click the radio button?


texts: Product Filtering—all Products with attribute value based on the admin value name

texts:
I have created a custom attribute for a Product, with the code »gender«, as a dropdown list. I has, unsurprisingly, two possible values: »male« and »female« and the properties table looks like this:

I have created a custom block, extending Mage_Catalog_Block_Product_List and added a method addFilterAttribute($key, $value), so that I can instantiate the block like that in the modules layout update:

<reference name="content">
  <block type="mymodule/page_filtered" name="mymodule.men.content">
    <action method="addFilterAttribute">
      <key>gender</key>
      <value>male</value>
    </action>
  </block>
</reference>

So as one might expect, I would like to create a list/grid of Products containing all the products for male customers. But since the value I pass to the block is the admin label for the corresponding value, I do not get any products listed.

Here is the code I am using in the block:

class Namepace_Module_Block_Page_Filtered
    extends Mage_Catalog_Block_Product_List
{
    private $attributes;

    public function _construct()
    {
        $this->attributes = array();
        $this->setTemplate = 'page/list.phtml';
    }

    public function addFilterAttribute($key, $value)
    {
        $this->attributes[$key] = $value;
    }

    public function getProducts()
    {
        $collection = Mage::getModel('catalog/product')->getCollection();
        $collection->addAttributeToSelect('*');

        foreach($this->attributes as $key => $value)
        {
            $collection->addAttributeToFilter($key, array('eq' => $value));
        }

        $collection->load();
        return $collection;
    }
}

But as I said, the list is empty, what can I do?

EDIT

I tested some values, and if I change the xml to:

<reference name="content">
  <block type="mymodule/page_filtered" name="mymodule.men.content">
    <action method="addFilterAttribute">
      <key>gender</key>
      <value>9</value>
    </action>
  </block>
</reference>

I does the Job, but I do not want to fiddle with numerical attribute values, since the would be very inconvenient in configuration.


texts: How do i add the discount percentage to my products' page?

texts:
I've been trying to add the discount percentage to each product's page without using any extensions. I am working with Magento 2.3.5. and I'm having a hard time finding any research that works with the same file path since im using my localhost. Can someone provide some assistance?

i wish to edit in the field referenced by this file path
vendor/magento/module-catalog/view/frontend/templates/product/view/attributes.phtml


texts:
I have a fresh installation on a hosted environment and setting up my store. In an attempt to see if email is working i tried using the contact us page (default). However i get an error "We can't process your request right now. Sorry, that's all we know.". I am trying to locate the error log in directory var/log, but unable to find in any of the files there. Is there anything i am doing wrong.

I am using community edition version 2.1.

Thanks


texts: How to overwrite magento1 image compression quality?

texts:
Im having trouble finding the way to make some product images look better as they look dull and not sharp at all. I believe this has to do with the image compression code in Magento1.
I've realized it is quite a common issue as I found a lot of answers (all similar to each other) on this topic.

I've tried ->setQuality(100) in the catalog/product/list.phtml file but didnt work.
I also tried setting the property $_quality to 100 in Magento/Catalog/Model/Product/Image.php but didnt work either.

I'm running out of ideas as most of the answers I found are several years old.

Can anyone help?


texts: Why is my shopping feed exporting the sale price wrong?

texts:
I am on Magento ver. 1.7.0.2 and I can't figure out why my shopping feed is exporting the wrong sale price. All of my attributes are mapped correctly and the sale price shows correctly on the product page but when I export my feed it's doing some sort of calculation and raising the price. I thought maybe it was tax but I don't why it would be automatically adding tax. I am including an image of the product page and the same product in my Google Merchant Center. You can see that the regular price is correct, but the sale price is higher. Any ideas what could be causing this?

We figured out that for some reason there is a tax rate of 7.975% being applied behind the scenes. I found this on a code in the product page:

var optionsPrice = new Product.OptionsPrice(
{
"productId":"21387",
"priceFormat":{
    "pattern":"$%s",
    "precision":2,
    "requiredPrecision":2,
    "decimalSymbol":".",
    "groupSymbol":",",
    "groupLength":3,
    "integerRequired":1
},
"includeTax":"false",
"showIncludeTax":false,
"showBothPrices":false,
"productPrice":65.99,
"productOldPrice":69.99,
"priceInclTax":65.99,
"priceExclTax":65.99,
"skipCalculate":1,
"defaultTax":7.975,
"currentTax":0,
"idSuffix":"_clone",
"oldPlusDisposition":0,
"plusDisposition":0,
"plusDispositionTax":0,
"oldMinusDisposition":0,
"minusDisposition":0,
"tierPrices":[

],
"tierPricesInclTax":[

]
}
);

Would it require a code modification to disable this or do we possibly just have a setting wrong?


texts: Move "More info tab" and it's content to "details"

texts:
For SEO reason I would like to move the product attributes from "More info" Tab to details.

I could move them above and under the price info, but I want to move them below description (main content)

<page layout="2columns-left" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<head>
    <css src="mage/gallery/gallery.css" media="all"/>
</head>
<body>
    <move element="page.main.title"             destination="product.info.price" before="product.price.final"/>
    <move element="product.info.review"         destination="product.info.price" after="page.main.title"/>
    <move element="product.info.overview"       destination="product.info.price" after="product.info.review"/>
    <move element="product.info.mailto"         destination="product.info.addto" after="view.addto.compare"/>
    <move element="product.attributes"         destination="product.info.details" after="product.info.description"/>
</body>


texts: On clicking Reorder from admin form is coming empty

texts:
When I click reorder from admin panel order section , I believe there should be a form which should have all the details of old order I don't see any error on console but the reorder form is coming empty .

Can anyone help.

UPDATE -

I debugged more and find that disabling Xtento_CustomAttribute module reorder page shows all the previous order details . does any one have idea what should I do ?

Thanks


texts:
I'm getting so mad that it literally hurts with a problem related to attribute option collection on Magento 1.8.1
I have a dropdown type attribute populated with dozens of values and frequently updated with new values, wich is used for layered navigation purposes.
What im trying to do is actually change de default behaviour and sort NUMERICALLY all theese options if "position" is not set.

Magento sorts my values like this (alphabetically)

  100 Watt
  1000 Watt
  1200 Watt
  200 Watt
  300 Watt

I need to sort them this way

  100 Watt
  200 Watt
  300 Watt
  1000 Watt
  1200 Watt

I tried to edit class Mage_Eav_Model_Resource_Entity_Attribute_Option_Collection in any way.
Maybe i'm pretty close adding in public function setStoreFilter

    $this->getSelect()->reset(Zend_Db_Select::ORDER);
    $this->getSelect()->order(new Zend_Db_Expr("CAST('value' AS SIGNED) ASC"));

Hope someone can help me understand how to achieve this.


texts: Magento 2.4 - Element 'plugin', attribute 'sortorder': The attribute 'sortorder' is not allowed. Line: 14

texts:
i've just updated Magento to 2.4 all went well but when i put Magento into dev mode i got the error
Element 'plugin', attribute 'sortorder': The attribute 'sortorder' is not allowed. Line: 14
Fatal error: Uncaught Magento\Framework\Exception\LocalizedException: Invalid Document Element 'plugin', attribute 'sortorder': The attribute 'sortorder' is not allowed. Line: 14 in /home/public_html/staging/vendor/magento/framework/Config/Reader/Filesystem.php:169 Stack trace: #0
i have been to the file location for the error but can not find anything or any answers online
many thanks


texts: how to keep recent order section on dashboard in magento 2

texts: how to keep recent order section on dashboard even if there is no order placed. Magento version 2.1.8 theme ultimo


texts: Difference between Mage::getModel('core/email_template_mailer') and Mage::getModel('core/email_template');

texts: What is difference between Mage::getModel('core/email_template_mailer') and Mage::getModel('core/email_template');?


texts: Check if user is older then 18 in Checkout

texts:
We have the problem that a customer needs to enter his Date of Birth.

The DOB field is selected as required, however, theres no check for the age itself.

How can I modify templates in order to check if the entered age is >= 18? Checkout process should throw an error if the customer is not at least 18.


texts: How to increase the size of Editor text box in magento 2.3.2

texts:
I have added custom module and i want to increase the size of the editor as shown here. https://prnt.sc/pbmbfw.
This is my code.

 <field id="tc_content" translate="label" type="editor" sortOrder="14" showInDefault="1"
                   showInWebsite="1" showInStore="1">
                <label>Enter Terms and Condition Content</label>
                <config_path>ced_csmarketplace/general/tc_content</config_path>
                <frontend_model>Ced\CsMarketplace\Block\Adminhtml\System\Config\Form\Field\Editor</frontend_model>
                <depends>
                    <field id="enable_tc">1</field>
                </depends>
            </field>


texts: How to add Form Fields to a custom Report?

texts:
I'm new to Magento and PHP in general.
I made a simple extension with a custom report based on the Products/Ordered report that shows a few extra fields and does some simple calculations based on certain product attributes.

I wanted to add a form field to filter the result in addition to the already present date range filter (In my case filter by the artist product attribute as a select)

I couldn't figure out how to add the field in the frontend nor how to properly access the value in the controller and pass it down to the Grid classes (I've seen an example reading the value from the $_SESSION global(?) that doesn't look like the proper way to do this though)

EDIT: didn't really work on this anymore till now, I tried adding a custom form block to the report following this guide: http://codegento.com/2011/03/creating-custom-magento-reports/ (lower half... complex report)

All I got is an empty admin page though... and var_dump in the Controller returns bool(false) for both blocks. So I guess they are not found?

Totally unsure if I got the layout file and declaration of these files right:
The module name is Customreport the action for the report is called commissionAction, the Controller is defined in controllers/Report/CustomController.php and has the according name.

Here is the layout file declaration in etc/config.xml:

<adminhtml>
        <layout>
            <updates>
                    <customreport>
                                <file>customreport.xml</file>
                </customreport>
            </updates>
        </layout>
    </adminhtml>

and this is the content of the customreport.xml in app/design/adminhtml/default/default/layout:

<adminhtml_report_custom_commission>
        <update handle="report_customreport">
                <reference name="content">
                            <block type="customreport/adminhtml_report_commission" template="report/grid/container.phtml" name="customreport.report.grid.container">
                                            <block type="adminhtml/report_filter_form" name="grid.filter.form">
                                                        <action method="setFieldVisibility">
                                                                <field>report_type</field>
                                                                <visibility>0</visibility>
                                                            </action>
                                     </block>
                         </block>
                 </reference>
</update>
</adminhtml_report_custom_commission>

unsure about the first node... adminhtml_report_controller_action is correct, no?

same for the <update handle=-value from the example and the source I guess it's report_modulename but can't really tell.

Any ideas where I went wrong?
Is there an easier way to add another form field? Are all the changes in the example necessary (e.g. the changes to the collection... I actually don't want to touch this one since, it already does what I want)


texts: Magento 2 Can't submit custom form with custom controller-action in admin order detail page

texts:
I am creating custom form in admin order detail page with form action as like below but it's redirecting to Dashboard from my action with 302.

My script is:

sales_order_view.xml

<?xml version="1.0"?>
 <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="admin-2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">

    <referenceBlock name="order_additional_info">
        <block class="Sample\Serialcode\Block\Adminhtml\Order\View\Pdf" name="sales_order_view_pdf" template="order/view/pdf.phtml" />
    </referenceBlock>

</page>

Phtml file:

    &times;
    <form method="post" action="<?php echo $block->getUrl('sample/serialcode/index/');?>">
        <input type="hidden" name="orderid"  class="orderid" value="<?php //echo $incrementId?>"/>

        Serial Codes <textarea rows="4" cols="30" name="newserialcodes"></textarea>

Serial Codes are not empty

Note: Each serial code seperated by '|' symbol like "121|122|123"

        <button type="submit" class="form-submit">Submit</button>
    </form>

Block File:

namespace Sample\Serialcode\Block\Adminhtml\Order\View;

 use Magento\Backend\Block\Template;

 class Pdf extends Template
 {

protected $order;

protected $orderitemSerialcode;

protected $orderData;

public function __construct(Template\Context $context,
                            \Magento\Sales\Model\Order $order,
                            \Sample\Serialcode\Model\OrderitemSerialcode $orderitemSerialcode,
                            array $data = [])
{
    $this->orderData = array();
    $this->order = $order;
    $this->orderitemSerialcode = $orderitemSerialcode;
    parent::__construct($context, $data);
}

 }

My Controller:

namespace Sample\Serialcode\Controller\Adminhtml\Serialcode;

use Magento\Backend\App\Action;

class Index extends \Magento\Backend\App\Action{

    protected $orderObj;

    private $coreRegistry = null;

    private $resultPageFactory;

    private $backSession;

    protected $sage;

    public function __construct(Action\Context $context,
                                \Magento\Framework\View\Result\PageFactory $resultPageFactory,
                                \Magento\Framework\Registry $registry
                               ){

        $this->resultPageFactory = $resultPageFactory;
        $this->coreRegistry = $registry;
        $this->backSession = $context->getSession();

        parent::__construct($context);

    }

    public function execute(){
        echo  "hello";exit;
    }
  }

routes.xml

Sample\Serialcode\etc\adminhtml\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">
<router id="admin">
    <route id="sample" frontName="sample">
        <module name="Sample_Serialcode" />
    </route>
</router>

When i used this url for menu it's redirection but it's not working from order detail page


texts: Mage_Eav_Model_Entity_Setup subclass - 'visible' v 'is_visible'

texts:
I'm looking at a setup/install script which extends from Mage_Eav_Model_Entity_Setup and noticed that some of the attributes in the return array of the getDefaultEntities method have a 'visible' key (e.g. 'visible' => true) while others have an 'is_visible' key.

Is there a difference between the two? Is one just an unsupported typo that didn't get noticed and got copied and pasted too much?

None of the other Setup.php files in app/code/community or app/code/local use 'is_visible'.

I'm loath to change anything, but I'd like to understand what the differences might be.


texts: Magento 2 change max image height and width of image uploader in Admin?

texts:
I want to change the MAX_IMAGE_WIDTH and MAX_IMAGE_HEIGHT constants of image uploader in Admin.

I think we should override vendor/magento/framework/File/Uploader.php. Can anyone give me a suggestion?


texts: Magento 2.3.4 - Get a list of all custom attributes for Categories

texts:
how I can get a list of all custom attributes that exist in backend for Categories? Is there anyway to do it from phpMyAdmin?

Thank you


texts: How to add product short discription in mini cart magento 2?

texts:
First of all I've found mini cart phtml and tried paste code from the product page template but it didn't help.
This method also doesn't work for me:
Show short description under product title on mini cart
Does anybody know how to do that?


texts: How can i solve image import not working after hosting its good working in localhost

texts:
Am not able to import image into my site, before am using localhost working good, after hosting not Working.

Magento version : 1.9.2.3

Note : After i import i got positive response in Admin, right after check into back end its not saved.

My image path :


texts: SQL to get customer email and size attribute (max count) of orders

texts:
We sell fashion. I was reading this. Now how do I get a list of all customers who bought a size S shirts? (filter on size S).

Size is the attribute to define the simple product from configurable. In addition there may me weird cases where a customer ordered both 43 and 44 size, bit 44 size more often, so this is why we are suggesting to using a max to identify a customers favorite size

Question: How can we identify a customers favorite size using a query?

Help appreciated


texts: Customer receiving "Recoverable Error: Object of Class" message on checkout in Magento 2

texts:
A customer has reported that they are receiving an error when they try to check out in our Magento 2.3.2 site. The message is as follows:

  Recoverable Error: Object of Class Magento\Customer\Model\Data\Region
  could not be converted to string in
  /var/www/vhosts/mywebsite.com/httpdocs/vendor/magento/framework/DB/Adapter/Pdo/Mysql.php
  on line 3101

And there is also a message in shipping which states

  Sorry, no quotes are available for the order at this time

This is happening intermittently for a few customers and I would like to know what is causing it and, if possible, how to fix it.


texts:
I'm trying to create a custom indexer for a particular product attribute.
I need to:

read the product attribute value
process it in some way ( not relevant )
save it in a index table

The above steps could be implemented in a custom script but I would like integrate the indexer using the patter used by other indexer in Magento.

I can see that Magento default indexer implement this abstract class Mage_Index_Model_Indexer_Abstract
... It looks not easy to understand the process from the code and I cannot find any documentation for it.

Any help is appreciate thanks.


texts: Accessing the Magento REST API in Magento Enterprise Edition 1.14

texts:
We are working on multi technologies application, where user authentication will be handeled by LDAP, UI will be handled by Liferay.

Magento will keep track of orders and product catalogues and communicate via REST APIs.

Anybody please advise how to avoid the need of request token and access tokens.

Application should be able to authenticate using the consumer secret and consumer key generated while registering the application.
Basically I want authentication should happen in backend, user should not be asked to key in the user credentials/ authorize to get access tokens as magento will not have any user authentication details

Many thanks in advance


texts: Shopping cart pricing rule condition is not visible on orders total in order page

texts:
Shopping Cart Pricing rule logic applied successfully but not visible on orders total in order page,

FYI Front end showing the Shopping Cart Pricing rule,

  How to get Shopping Cart Pricing rule on orders total in order page?


texts: How to build a custom image gallery in an admin form?

texts:
I'm in the process of building a custom module to handle our customer's submitted product testimonials. I'm mostly done with the admin management portion of the module but am hitting a major stumbling block in understanding how to best implement the image management portion.

Just like the product management, when you edit a story, you can edit or add images associated with that story.

What I want is this:

Though it will need to be custom built to suit my module's needs.

I'm using catalog_product as a reference for obvious reasons, but I don't understand how the catalog_product image grid and file uploader are being added to the attribute's fieldset.

What I have in the my image tab's class so far (not much) is:

class MyModule_Stories_Block_Adminhtml_Stories_Edit_Tab_Image
    extends Mage_Adminhtml_Block_Widget_Form
    implements Mage_Adminhtml_Block_Widget_Tab_Interface
{
    protected function _prepareForm()
    {
        $model = Mage::registry('current_story');
        $_data = $model->getData();

        $form = new Varien_Data_Form();

        $fieldset = $form->addFieldset('image_fieldset', array(
            'legend' => $this->_translate('Story Images'),
        ));

        $form->addValues($_data);
        $this->setForm($form);
        return parent::_prepareForm();
    }

I'm just asking for a point in the right direction to proceed.   Should I be creating the image grid in a custom block and add it to the form fieldset (and how do I add a block to a fieldset)? And if I did add that block to the fieldset would I still be able to populate the any text fields in that block with the $_data?

I'm kind of lost and any help would be appreciated.
Thanks in advance.


texts: Mage_Ajaxsddto_Helper_Data' not found in app\Mage.php on line 547

texts:
unable to open permissions_role page I get below error

  -Class 'Mage_Ajaxsddto_Helper_Data' not found in E:\CUBE9-XAMPP\htdocs\boxed\app\Mage.php on line 547

already added below code
4/ Add it on the  node like this:

<helpers>
    <ajaxsddto>
        <class>Vendor_Ajaxsddto_Helper</class>
    </ajaxsddto>
</helpers>

5/ Create folder app/code/{community/local}/{Vendor}/Ajaxsddto/Helper folder if it doesn't exists and create file Data.php:

class Vendor_Ajaxsddto_Helper_Data extends Mage_Core_Helper_Abstract
{

}

any other resolution.

config.xml file

            0.1.0

                standard

                    Etheme_Ajaxaddto
                    ajax

                    ajaxaddto.xml

<global>
    <models>
        <ajax>
            <class>Etheme_Ajaxaddto_Model</class>
            <resourceModel>ajax_mysql4</resourceModel>
        </ajax>
        <ajax_mysql4>
            <class>Etheme_Ajaxaddto_Model_Mysql4</class>
            <entities>
                <ajax>

ajax

                </ajax>
            </entities>
        </ajax_mysql4>
    </models>
    <resources>
        <ajax_setup>
            <setup>
                <module>Etheme_Ajaxaddto</module>
            </setup>
            <connection>
                <use>core_setup</use>
            </connection>
        </ajax_setup>
        <ajax_write>
            <connection>
                <use>core_write</use>
            </connection>
        </ajax_write>
        <ajax_read>
            <connection>
                <use>core_read</use>
            </connection>
        </ajax_read>
    </resources>
    <blocks>
        <ajax>
            <class>Etheme_Ajaxaddto_Block</class>
        </ajax>
    </blocks>
    <helpers>
        <ajaxaddto>
            <class>Etheme_Ajaxaddto_Helper</class>
        </ajaxaddto>
    </helpers>
    <events>
        <controller_action_postdispatch>
            <observers>
                <etheme_ajaxaddto_observer>
                    <type>singleton</type>
                    <class>Etheme_Ajaxaddto_Model_Observer</class>
                    <method>getListproduct</method>
                </etheme_ajaxaddto_observer>
            </observers>
        </controller_action_postdispatch>
    </events>
</global>


texts: Magento 2 How to Add a New Column to Orders Grid

texts:
I've added a new column to the table sales_order called export_status, now I want to add new order grid column with the data from the new sales_order column.

I've managed to add column to the sales_order_grid table.

$installer->getConnection()->addColumn($installer->getTable("sales_order_grid"), "xml_exported", [
     'type' => \Magento\Framework\DB\Ddl\Table::TYPE_TEXT,
     'comment' => 'XML Exported'
]);

How can I now make it actually show in the orders grid with the value from the sales_order export_status column?