texts: module still works and making troubles after disabling it

texts:
I have disabled the module Inchoo_Notes in the app/etc/modules:

<?xml version="1.0"?>
<config>
    <modules>
        <Inchoo_Notes>
            <active>false</active>
            <codePool>community</codePool>
        </Inchoo_Notes>
    </modules>
</config>

I get the following error, when I go to configuration of admin panel:

( ! ) Fatal error: Class 'Mage_Inchoo_Notes_Helper_Data' not found in Unknown on line 0
Call Stack
#   Time    Memory  Function    Location
1   0.1100  272464  {main}( )   ..\index.php:0
2   2.4100  569040  Mage::run( ???, ???, ??? )  ..\index.php:83
3   2.4200  1607016 Mage_Core_Model_App->run( ??? ) ..\Mage.php:684
4   9.0870  13877440    Mage_Core_Controller_Varien_Front->dispatch( )  ..\App.php:365
5   9.8670  27413680    Mage_Core_Controller_Varien_Router_Standard->match( ??? )   ..\Front.php:172
6   9.9270  27414968    Mage_Core_Controller_Varien_Action->dispatch( ??? ) ..\Standard.php:254
7   15.3740 28651128    Mage_Adminhtml_System_ConfigController->editAction( )   ..\Action.php:418
8   16.3340 34068944    Mage_Adminhtml_Block_System_Config_Tabs->initTabs( )    ..\ConfigController.php:104
9   41.2180 66104432    Mage::helper( ??? ) ..\Tabs.php:92
Variables in local scope (#9)

$helperClass =string 'Mage_Inchoo_Notes_Helper_Data' (length=29)

$name =string 'inchoo_notes' (length=12)

$registryKey =string '_helper/inchoo_notes' (length=20)

I debugged the code and I am seeing that in configuration it is trying to load the tab of Inchoo notes still in here:

\app\code\core\Mage\Adminhtml\Block\System\Config\Tabs.php

foreach ($tabs as $tab) {
        $helperName = $configFields->getAttributeModule($tab);
        $label = Mage::helper($helperName)->__((string)$tab->label);

        $this->addTab($tab->getName(), array(
            'label' => $label,
            'class' => (string) $tab->class
        ));
    }

and then I debugged further which goes here in Mage.php:

public static function helper($name)
{
    $registryKey = '_helper/' . $name;
    if (!self::registry($registryKey)) {
        $helperClass = self::getConfig()->getHelperClassName($name);
        self::register($registryKey, new $helperClass);
    }
    return self::registry($registryKey);
}

I am seeing that self::registry($registryKey) is false and therefore it goes to  $helperClass = self::getConfig()->getHelperClassName($name); and instead of having Inchoo_Notes_Helper I will have Mage_Inchoo_Notes_Helper_Data

why is that????? why even it tries to load it! when I said disable this module? I am frustrated.

by the way cache is disabled, I flushed the cache so it is not a solution. Also I have the helper for this module, the helper is not missing, therefore this is not a solution either.


texts: How to Delete Customer Session From Admin

texts:
I have been working on a site that requires users to be logged in and approved before they can access the website. That element works fine, except if as an administrator I edit the customer's account to revoke their access.

Refreshing the page as that (already logged in) customer, I expect to be logged out and redirected to the login page. Instead, I am able to continue to remain logged in.

I have been looking for a way to try and programatically (on save of customer) to log that customer out.

$session = Mage::getSingleton('customer/session');
$session->loginById($customer->getId());

// Log Out the customer.
$session->logout();

This I have been trying to use, unfortunately, instead of logging out the customer, it logs me out from the admin instead.

So it seems that I need to have something like $customer->getSessionId() and load the session from that, but that doesn't seem to exist as a route.

As an alternative work around, I expect it might be possible to override the session itself on reinitialise on the customer view, but this feels like it might be unnecessarily convoluted.


texts: Problem with SQLSTATE[42S22]: Column not found


texts:
I want to get module name from a path

        $path =  Mage::helper('core/http')->getHttpReferer();

Any ideas?


texts: How to get the billing address from a quote instance: Magento 2

texts:
I have a custom module in which I need to get the order details. I am using the below code to get the orders from quotes in admin end,

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
$options = $objectManager->create('Magento\Quote\Model\Quote');
$_order = $options->load($_quoteId);

Here I am getting the quote and order details. I am getting the billing address In case I try to print it as below,

print_r($_order->getBillingAddress()->getStreet());
print_r($_order->getBillingAddress()->getFirstName());

However, when I am using the getFormattedAddress() like below, I don't get anything.

echo $block->getFormattedAddress($_order->getBillingAddress());

In my block I have added the getFormattedAddress() function as below,

    public function getFormattedAddress(Address $address) {
    return $this->addressRenderer->format($address, 'html');
}

This gives me an error as,

Uncaught TypeError: Argument 1 passed to Vendor\Module\Block\Adminhtml\Quotes::getFormattedAddress() must be an instance of Magento\Sales\Model\Order\Address, instance of Magento\Quote\Model\Quote\Address given

I tried to go through some of the belwo links but could not manage to get the solution of my problem,

Magento 2 Get Order Billing Details
Not getting order shipping address in magento2
How to get formated order addresses

The issue here is, getFormattedAddress() expects an instance of Magento\Sales\Model\Order\Address whereas, I am passing an address of Magento\Quote\Model\Quote\Address.

Is there any way to use getFormattedAddress() using the quote address?

PS: I know the using objectManager directly is not recommended and I have plans to change it once I get the billing and shipping address.

Please, can anyone help?


texts:
I have installed comodo ev certificate... no problem everything works.

The issue arises when i activate it in the store

i set the secure url as it is supposed to and also change for front an back end.

The issue is that when i go to account login page in chrome it displays the green address bar but in firefox i get a warning sign that the page would contain unsafe material, also in opera it gives a message that some material is blocked and in safari it doesn't show the certificate at all

What should i do to solve these issues?

in console i see this message, but when checking page source i can not find it at all... where would i need to check to adjust or remove this?

[blocked] The page at 'https://www.domain.com/customer/account/login/' was loaded over HTTPS, but ran insecure content from 'http://fonts.googleapis.com/css?family=Lato:400,100,300,700,100italic,900,400italic,300italic,700italic,900italic': this content should also be loaded over HTTPS.

thanks


texts: Dealing with collections from my model in Magento 2

texts:
I'm trying to follow Alan Storm's tutorial here.

The code works fine when I try to insert or retrieve a single record, but it cracks when I use collections. I followed all  steps he illustrated in the tutorial, which drives me crazy because only collections wouldn't work!!

 public function __construct(
    \Magento\Backend\App\Action\Context $context,
    \Vendor\Mymodule\Model\ConfigurationsFactory $myClass
) {
    $this->myClass = $myClass;
    parent::__construct($context);
}

public function execute() {

     $todo = $this->myClass->create();

     $collection = $todo->getCollection();

     foreach($collection as $item)
      {
        var_dump('Item ID: ' . $item->getConfigId());
        var_dump($item->getData());
      }
    exit;

}

This gives the following error:
 Vendor\Mymodule\Model\Configurations does not extend \Magento\Framework\DataObject

The code for configurations model is as below

namespace Vendor\Mymodule\Model;
use Magento\Framework\Model\AbstractModel;

class Configurations extends AbstractModel
{
    protected function _construct()
    {
        $this->_init('Vendor\Mymodule\Model\ResourceModel\Configurations');
    }
}

ResourceModel

namespace Vendor\Mymodule\Model\ResourceModel;
use Magento\Framework\Model\ResourceModel\Db\AbstractDb;

class Configurations extends AbstractDb
{
    protected function _construct()
    {
        $this->_init('vendor_configurations','config_id');
    }
}

Collection

namespace Vendor\Mymodule\Model\ResourceModel\Configurations;

class Collection extends \Magento\Framework\Model\ResourceModel\Db\Collection\AbstractCollection
{
    protected function _construct()
    {
        $this->_init('
             Vendor\Mymodule\Model\Configurations',
            'Vendor\Mymodule\Model\ResourceModel\Configurations');
    }
}

any hints would be really appreciated.

Thanks


texts: Not getting emails from Magento custom form

texts:
I made a custom form using instructions found at Inchoo. I've created the form and it's appearing properly but the mails are not sending at all. I get an error 'Unable to Send email' which comes from the catch part of the code. Nothing in the system.log or exceptions.log files to give me a clue.

The form has an action of domain.com/postajob/index/sendemail/ and my IndexController.php file looks like this

<?php
class BWD_JobForm_IndexController extends Mage_Core_Controller_Front_Action
{
public function sendemailAction()
{
    //Fetch submited params
    $params = $this->getRequest()->getParams();
    $from_email = Mage::getStoreConfig('trans_email/ident_general/email');
    $from_name = Mage::getStoreConfig('trans_email/ident_general/name');

    $mail = new Zend_Mail();
    $mail->setBodyText($params['role']);
    $mail->setFrom($from_email, $from_name);
    $mail->addTo($params['email'], $params['name']);
    $mail->setSubject('Test Post a Job Module for Magento');
    try {
        $mail->send();
    }
    catch(Exception $ex) {
        Mage::getSingleton('core/session')->addError($ex->getMessage());
    }

    //Redirect back to index action of (this) inchoo-simplecontact controller
    $this->_redirect('thanks/');
}
}
?>

I've also tried methods mentioned here and here but none of them work. For the record, mail sending is enabled in the configuration.


texts: CE1.9.2.4 - Prevent customer shipping address edit

texts:
As part of a B2B site, one of the business requirements is to prevent customers from editing their shipping address (customer accounts are created by an admin person).

What is the best (non-destructive) way to achieve this?

Thank you


texts: Ok to truncate report_viewed_product_index

texts:
I was reading through the list of tables that are ok to truncate (https://stackoverflow.com/questions/12205714/list-of-tables-to-safely-truncate-in-magento)  and I didn't see

report_viewed_product_index

The table is huge and it takes a very long time to restore the database. Is it safe to truncate this data or at least remove the oldest data?


texts: Magento2 : How to override checkout order summary default template

texts:
I want to add some custom content on checkout page below total in order summary, For this I want to override template file from where total is coming.

How can I override totals template?


texts: Magento database documentation version 1.9.3.2

texts:
I'm looking for documentation of the Magento database v1.9.

I once saw an online interactive tool that lets you browse the different versions of the database and look at table names and attributes. Can anyone give a URL for this or for other database documentation for 1.9.3.2?

I particularly need to find organization types and how they are stored for the customer account in the DB, also how the password for the customer account is stored. (Some of our custom code doesn't work after upgrade to 1932)

I found this so far
http://anna.voelkl.at/uploads/magento/ce1922.png


texts: How to create custom shipping charge module

texts: I want a create a module for shipping charge where shipping charge gets calculated as per my formula?


texts: How to get maching products based on rule conditions

texts:
how to get matching products based on rule conditions i need to filter product grid according to rule condition in my custom module I have used it as a filter

Array
(
    [conditions] => Array
        (
            [1] => Array
                (
                    [type] => Magento\CatalogRule\Model\Rule\Condition\Combine
                    [aggregator] => all
                    [value] => 1
                    [new_child] =>
                )

            [1--1] => Array
                (
                    [type] => Magento\CatalogRule\Model\Rule\Condition\Product
                    [attribute] => attribute_set_id
                    [operator] => ==
                    [value] => 15
                )

            [1--2] => Array
                (
                    [type] => Magento\CatalogRule\Model\Rule\Condition\Product
                    [attribute] => price
                    [operator] => <
                    [value] => 2000
                )

        )

)

I have this array of rule conditions and I need products based on conditions


texts: Magento media/js folder filled up with 500kb js files each minute

texts:
Our magento/media/js folder is being populated with js files sometimes 4-6 times a minute. We just checked and there were 10Gb worth of files in there.

Cron only runs each 5 minutes.

We have turned off our FPC, our CDN and looked everywhere. No idea where to look next.

What could possibly cause this behaviour? The contents of the js file is just the basic js files.

Any suggestion is highly appreciated.

Thanks.


texts: How can I edit a shipping address at checkout?

texts:
Is it possible to add an edit button for the addresses in the checkout section?

Thanks!


texts: How to get child categories using object manager?

texts:
For now I'm getting category name.

This is my code:

app/code/Vendor/Module/view/frontend/templates/storecategories.phtml

<?php
        $categoryId = 65;
        $_objectManager = \Magento\Framework\App\ObjectManager::getInstance();
        $category = $_objectManager->create('Magento\Catalog\Model\Category')
            ->load($categoryId);
        $parent = $category->getName();
        echo $parent?>

What would be next steps to get current categories subcategories?


texts: SUPEE-6788 - Call to a member function `isTypeAllowed()` on a non-object

texts:
I have applied patch SUPEE-6788 but this breaks my store and generates an error:
Call to a member function isTypeAllowed() on a non-object in Mage/Core/Model/Email/Template/Filter.php

I have whitelisted all blocks and variables, but this problem still occurs.

I found out that replacing Mage/Core/Model/Email/Template/Filter.php with code from before the patch solves the problem.

I can't find out how to track down the problem and solve this.
Any suggestions?


texts: I`d like to add some words in my language pack(csv file). But I got a error

texts:
I downloaded a Korean language pack(.zip) and unzipped it at \htdoc\magento\app\i18n/mageplaza\ko_KR
I added some words in my language pack(ko_KR.csv file)
and saved it. Then i got MSG from csv file 'it would be damage.....keeping doing?~~'
so I kept doing. And I entered my magento admin page or magento webpage.
How can I add or edit the words?
It shows
1 exception(s):
Exception #0 (InvalidArgumentException): Unable to serialize value. Error: Malformed UTF-8 characters, possibly incorrectly encoded
Exception #0 (InvalidArgumentException): Unable to serialize value. Error: Malformed UTF-8 characters, possibly incorrectly encoded
#1 Magento\Framework\Translate->_saveCache() called at [vendor\magento\framework\Translate.php:224]
#2 Magento\Framework\Translate->loadData('frontend', false) called at [vendor\magento\framework\App\Area.php:245]
#3 Magento\Framework\App\Area->_initTranslate() called at [vendor\magento\framework\App\Area.php:216]
#4 Magento\Framework\App\Area->_loadPart('translate') called at [vendor\magento\framework\App\Area.php:143]
#5 Magento\Framework\App\Area->load('translate') called at [vendor\magento\framework\View\DesignLoader.php:55]
#6 Magento\Framework\View\DesignLoader->load() called at [vendor\magento\module-theme\Plugin\LoadDesignPlugin.php:53]
#7 Magento\Theme\Plugin\LoadDesignPlugin->beforeExecute(&Magento\Cms\Controller\Index\Index\Interceptor#0000000010b2fe36000000001b12301c#) called at [vendor\magento\framework\Interception\Interceptor.php:121]
#8 Magento\Cms\Controller\Index\Index\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor\magento\framework\App\Action\Plugin\ActionFlagNoDispatchPlugin.php:51]
#9 Magento\Framework\App\Action\Plugin\ActionFlagNoDispatchPlugin->aroundExecute(&Magento\Cms\Controller\Index\Index\Interceptor#0000000010b2fe36000000001b12301c#, &Closure#0000000010b2fef9000000001b12301c#) called at [vendor\magento\framework\Interception\Interceptor.php:135]
#10 Magento\Cms\Controller\Index\Index\Interceptor->Magento\Framework\Interception\{closure}() called at [vendor\magento\framework\Interception\Interceptor.php:153]
#11 Magento\Cms\Controller\Index\Index\Interceptor->___callPlugins('execute', array(), array(array('designLoader', 'customerNotifica...', 'invalidate_expir...', 'tax-app-action-d...', 'weee-app-action-...', 'customer-app-act...'))) called at [generated\code\Magento\Cms\Controller\Index\Index\Interceptor.php:23]
#12 Magento\Cms\Controller\Index\Index\Interceptor->execute() called at [vendor\magento\framework\App\Action\Action.php:111]
#13 Magento\Framework\App\Action\Action->dispatch(&Magento\Framework\App\Request\Http#0000000010b2fdd8000000001b12301c#) called at [vendor\magento\framework\Interception\Interceptor.php:58]
#14 Magento\Cms\Controller\Index\Index\Interceptor->___callParent('dispatch', array(&Magento\Framework\App\Request\Http#0000000010b2fdd8000000001b12301c#)) called at [vendor\magento\framework\Interception\Interceptor.php:138]
#15 Magento\Cms\Controller\Index\Index\Interceptor->Magento\Framework\Interception\{closure}

.....


texts: How can I display a custom validation error using an observer?

texts:
This is my code:

if (Mage::app()->getRequest()->getPost('shipping')){
    $data = Mage::app()->getRequest()->getPost('shipping');
    if (strlen($data['firstname']) > 2){
         // here throw an error
    }
}

I am using this events :  <sales_quote_save_before>

I tried smth like this:

Mage::getSingleton('customer/session')->addError(Mage::helper('customer')->__('test error.'));

but nothing is displayed when press the place order button in the checkout. Any ideas?


texts: ReflectionException: Class does not exist

texts:
I am running into this error when compiling:

  [ReflectionException] Class
  \Rokanthemes\SlideBanner\Api\SlideRepositoryInterface does not exist

I checked and of course that class exists. Here is the content of the class: https://pastebin.com/LVxZgeqM

  Stack Trace:

  Exception trace:  () at
  /setup/src/Magento/Setup/Module/Di/Code/Scanner/PhpScanner.php:177
  ReflectionClass->__construct() at
  /setup/src/Magento/Setup/Module/Di/Code/Scanner/PhpScanner.php:177
  Magento\Setup\Module\Di\Code\Scanner\PhpScanner->collectEntities() at
  /setup/src/Magento/Setup/Module/Di/App/Task/Operation/ApplicationCodeGenerator.php:77
  Magento\Setup\Module\Di\App\Task\Operation\ApplicationCodeGenerator->doOperation()
  at /setup/src/Magento/Setup/Module/Di/App/Task/Manager.php:56
  Magento\Setup\Module\Di\App\Task\Manager->process() at
  /setup/src/Magento/Setup/Console/Command/DiCompileCommand.php:205
  Magento\Setup\Console\Command\DiCompileCommand->execute() at
  /vendor/symfony/console/Command/Command.php:242
  Symfony\Component\Console\Command\Command->run() at
  /vendor/symfony/console/Application.php:843
  Symfony\Component\Console\Application->doRunCommand() at
  /vendor/symfony/console/Application.php:193
  Symfony\Component\Console\Application->doRun() at
  /vendor/magento/framework/Console/Cli.php:104
  Magento\Framework\Console\Cli->doRun() at
  /vendor/symfony/console/Application.php:117
  Symfony\Component\Console\Application->run() at /bin/magento:23

  setup:di:compile

After removing the extension compilation goes through without problems. It worked in 2.1, after upgrading to 2.2.3 I am running into this error. Any idea what might go wrong?

I am using PHP 7.0.29

Thanks!


texts: How to create a youtube lightbox in CMS Block. Magento 2

texts:
can you help in on how to create a lightbox for youtube in CMS block of magento 2. I created something using lity but it will not work.

Thanks


texts: How to prevent cart price rules from applying to bundle products?

texts:
I can't find a way to prevent cart price rules from applying to bundle products that already have a discount. The Bundle product has Dynamic Price = No.

I have tried to exclude items with a special price but this doesn't work - I assume because the rule is applying to the simple products that make up the bundle, and not the bundle itself?

Anyone found a way round this?


texts: Varnish: Saving product clears all product pages

texts:
When I programmatically update a product, all cached products (varnish) seem to be cleared. This is the header from the purge request:

ReqHeader      X-Magento-Tags-Pattern: ((^|,)cat_p_3478(,|$))|((^|,)cat_p(,|$))

I think it's the cat_p tag that causes the clearing, but I don't understand why all pages tagged with this tag need to be cleared.
This simple code triggers the purge request:

$product = $productRepository->get($data->sku);
$product->setStoreId(0);
$product->save();

What can I do to fix this?


texts: What is GraphQl in Magento2 and Why use?

texts: What is GraphQl in Magento2? Why use GraphQl. I want to know detail about GraphQl.


texts:
I'm trying to fetch around 500 products from Magento, but the call is really slow.

    $startTime = microtime(TRUE);
    $collection = Mage::getModel('catalog/product_api')->items();

    $endTime = microtime(TRUE);
    $totalTime = $endTime - $startTime;
    $timePerProduct = $totalTime / count($collection);

    $benchmarking = array(
        "totaltime" => $totalTime,
        "timeperproduct" => $timePerProduct,
        "totalproducts" => count($collection)
    );

    $response = array($benchmarking, $collection);
    echo json_encode($response);

The total time is ending up being an entire second! I'm not sure if this is normal

{
    totaltime: 1.0537550449371,
    timeperproduct: 0.0018136919878436,
    totalproducts: 581
},

I'm currently running the server on Windows Azure A2 configuration. (2 cores, 3.5GB memory. PHP is 5.4, Centos 7.)


texts: What kind of risk will be there if Magento app/etc/local.xml file and release notes are publicly exposed?

texts:
I want some expert advice for the following.

Suppose a Magento site has exposed local.xml in browser like following way.

http://www.example.com/app/etc/local.xml

and

http://www.example.com/RELEASE_NOTES.txt

I know that local.xml contains sensitive information, but if release notes are also exposed what kind of and how severe security breach can happen?


texts: Magento 2 How to Disable Add to Cart Button for Out of Stock Products

texts:
Magento 2.3

I have a 3rd part software I use for stock management so dont need Mangeto to manage my stock.
If I set the manage stock option to no then the add to cart button on the product page is still displayed even if the stock quantity is zero.

How can I disable the add to cart button or even hide the product when stock reaches zero.

I have set the display out of stock products option to no already but this didn't help.

Any advice greatly appreciated


texts: Magento 2. Does Commerce offers more functionality than Open Source in term of Web APIs?

texts: Does Magento 2 Commerce offer something in addition to what M2 Open Source offers in terms of Web APIs?


texts: Magento 2 How to display custom text instead of shipping method title and carrier

texts: how to change the title of flat rate -fixed to Shipping


texts: Magento 1.9.x.x remove "freeshipping" option conditionally from checkout quote without editing any ".phtml" templates

texts:
Just need as I asked in the main question title.

Right now I have created the below function in my observer which executes on event sales_quote_collect_totals_before, with below code:

public function validateFreeShipping(Varien_Event_Observer $observer) {
    //$quote = $observer->getEvent()->getQuote();
    $quote = Mage::getSingleton('checkout/session')->getQuote();
    $quote->getShippingAddress()->setFreeShipping($setFreeShipping);
    $quoteItems = $quote->getAllItems();
    $setFreeShipping = true;
    foreach ($quoteItems as $quoteItem) {
        $itemSku = $quoteItem->getSku();
        $product = Mage::getModel('catalog/product')->loadByAttribute('sku', $itemSku);
        $prodCatIds = $product->getCategoryIds();
    }
    # echo "<pre/>";print_r($prodCatIds);
    foreach ($prodCatIds as $catId) {
        $category = Mage::getModel('catalog/category')->load($catId);
        $allowFreeshipping = $category->getAllowFreeshipping();
        if($allowFreeshipping == "194") $setFreeShipping = false;
    }
    $address = $quote->getShippingAddress();
    $quote->getShippingAddress()->setFreeShipping($setFreeShipping);
    $quote->collectTotals()->save();
}

But this never seems to work, and I always get "Free Shipping" method enabled no matter what.

Can anyone suggest a standard way to do this which involves event catching observers ?


texts: How can i redirect to homepage after login

texts:
I have used following code for redirect to homepage. But the page not redirecting after login.

<?php

namespace Vendor\Module\Controller\Account;

use Magento\Customer\Model\Account\Redirect as AccountRedirect;
use Magento\Framework\App\Action\Context;
use Magento\Customer\Model\Session;
use Magento\Customer\Api\AccountManagementInterface;
use Magento\Customer\Model\Url as CustomerUrl;
use Magento\Framework\Exception\EmailNotConfirmedException;
use Magento\Framework\Exception\AuthenticationException;
use Magento\Framework\Data\Form\FormKey\Validator;

/**
 * @SuppressWarnings(PHPMD.CouplingBetweenObjects)
 */
class LoginPost extends \Magento\Customer\Controller\Account\LoginPost {

    public function execute() {
        if ($this->session->isLoggedIn() || !$this->formKeyValidator->validate($this->getRequest())) {
            /** @var \Magento\Framework\Controller\Result\Redirect $resultRedirect */
            $resultRedirect = $this->resultRedirectFactory->create();
            $resultRedirect->setPath('home');
            return $resultRedirect;
        }

        if ($this->getRequest()->isPost()) {
            $login = $this->getRequest()->getPost('login');
            if (!empty($login['username']) && !empty($login['password'])) {
                try {
                    $customer = $this->customerAccountManagement->authenticate($login['username'], $login['password']);
                    $this->session->setCustomerDataAsLoggedIn($customer);
                    $this->session->regenerateId();
                } catch (EmailNotConfirmedException $e) {
                    $value = $this->customerUrl->getEmailConfirmationUrl($login['username']);
                    $message = __(
                            'This account is not confirmed.' .
                            ' Click here to resend confirmation email.', $value
                    );
                    $this->messageManager->addError($message);
                    $this->session->setUsername($login['username']);
                } catch (AuthenticationException $e) {
                    $message = __('Invalid login or password.');
                    $this->messageManager->addError($message);
                    $this->session->setUsername($login['username']);
                } catch (\Exception $e) {
                    $this->messageManager->addError(__('Invalid login or password.'));
                }
            } else {
                $this->messageManager->addError(__('A login and a password are required.'));
            }
        }

        $resultRedirect = $this->resultRedirectFactory->create();
        $resultRedirect->setPath('home'); // set this path to what you want your customer to go
        return $resultRedirect;
    }

}


texts: Magento 2 Multilanguage and Multi website with URL folder change

texts:
Hi guys I come here to get some light.. I'm gonna explain what I want to do.

I want to make a base Magento 2 platform ready to be expansive with more Websites focused on stores.

Each websites will have multilanguage option,

website1.es
website1.es/en/
website1.es/pt/

Another website...

website2.es
website2.es/en/
website2.es/pt/
...

I added in root .htaccess the following code:

SetEnvIf Host www\.website2\.es MAGE_RUN_CODE=**websitecode**
SetEnvIf Host www\.website2\.es MAGE_RUN_TYPE=website
SetEnvIf Host ^website2\.es MAGE_RUN_CODE=**websitecode**
SetEnvIf Host ^website2\.es MAGE_RUN_TYPE=website

The problem is that I do not get how to use folder structure for store views. I tried to enable Add Store Code to Urls but Store views folders in URL are like en_1, en_2 and they are not url friendly... that's because store views code are unique.

I tried to change Base URL, Base Link URL etc options in Configuration and CSS and media loads well but the funtionality of the website is not correctly (loop of loading php and strange things)

Base URL: website2.es/en/
Base Link URL: website2.es/en/
Base URL for Static View Files: website2.es/pub/static/
Base URL for User Media Files: website2.es/pub/media/

But I don't discard to work in the future with local domains for different projects focused more on brands (brand3.es, brand3.fr, brand3.com ...) I comment this to get you in the case.

So I would know what do you recommend to do to take flexibility and make for now accessible to a store view by folder URL. Thanks!

Why my post is not duplicated.
The suggested solution is for the same domain with multiple magento websites.
My request is different and propose a different flexibility. Mine is Magento2 and their 1.x


texts:
I can't get this small extension for rewriting Mage_Customer_Model_Customer_Api to work.

My files:
/app/etc/modules/EnaDva_CustomerInfoApi.xml

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

/app/code/local/EnaDva/CustomerInfoApi/etc/config.xml

<?xml version="1.0"?>
<config>
    <modules>
        <EnaDva_CustomerInfoApi>
            <version>0.1</version>
        </EnaDva_CustomerInfoApi>
    </modules>
    <global>
        <models>
            <enadva_customerinfoapi>
                <class>EnaDva_CustomerInfoApi_Model</class>
            </enadva_customerinfoapi>
            <customer>
                <rewrite>
                    <customer_api>EnaDva_CustomerInfoApi_Model_Customer_Api</customer_api>
                </rewrite>
            </customer>
        </models>
    </global>
</config>

/app/code/local/EnaDva/CustomerInfoApi/Model/Customer/Api.php

<?php

class EnaDva_CustomerInfoApi_Model_Customer_Api extends Mage_Customer_Model_Customer_Api
{

    /**
     * Retrieve customer data
     *
     * @param int $customerId
     * @param array $attributes
     * @return array
     */
    public function info($customerId, $attributes = null)
    {
        Mage::log('Hello from extended API call', null, true, 'success.log')

    }

}

Any suggestions to make this work?

EDIT:
I think I'm missing api.xml file in my extension etc folder.


texts: Unexpected end of JSON input after cache cleaned

texts:
I am always getting an Unexpected end of JSON input error after clearing my caches cache:clean | cache:flush.
But this error only happens on first page load.
When I reload the page again it is gone.

Here are some details:

Uncaught SyntaxError: Unexpected end of JSON input
    at JSON.parse (<anonymous>)
    at callback ((index):464)
    at Object.execCb (require.js:1651)
    at Module.check (require.js:867)
    at Module.<anonymous> (require.js:1114)
    at require.js:133
    at require.js:1157
    at each (require.js:58)
    at Module.emit (require.js:1156)
    at Module.check (require.js:918)

I couldnt figure out from where its coming. Does anyone of you has an idead how to fix this or what is causing the error?


texts: Payone Creditcard Problem and IWD Onestepcheckout

texts:
I'm using the IWD Onestepcheckout extension in combination with PAYONE (3.1.3). And I can't get PAYONEs payment method "Credit Card" to work.

The check of credit card data is always performed twice. The first time the system always throws an error "Parameter {} cardexpiredate faulty or missing", even though the expiration date is ok.

I suspect there is something wrong with the Javascript that does the data validation. But I can't figure out where exactly the problem occurs. I have contacted the developers, but because this problem is caused by the conflict of extensions, they were not able to help.

I'm working on Magento CE 1.7.0.2.

Any hints on how to solve this would be appreciated.


texts:
I have a magento 2 website where I want to share wishlist between websites (for logged in users and guest users). For ex. guest user added product1 to the wishlist from website1 and now user switches to website2 then user would be able to see the same product to wishlist already.
but now every website has own wishlist
magento is only providing sharing between stores not websites. I've tried some solutions but no luck,
i used this solution for sharing cart between websites Magento 2 + How to share cart for guest users between multi websites and working great.
i tried to use it with wishlist but didn't work
i extened the wishlist model and changed getSharedStoreIds function
    /**
     * @return int[]
     */
    public function getSharedStoreIds()
    {
        if ($this->_storeIds === null || !is_array($this->_storeIds)) {
                $_storeIds = [];
                $stores = $this->_storeManager->getStores();
                foreach ($stores as $store) {
                    $_storeIds[] = $store->getId();
                }
                $this->_storeIds = $_storeIds;
        }
        return $this->_storeIds;
    }

but still not working


texts: this->getAddToWishlistUrl is https vs. http and this causes conflict - how to change

texts:
Our e-commerce site runs non-secure (http) for all pages except essential pages such as checkout process pages.

I have some custom coding in a view.phtml file which a user clicks to add an item to their wishlist.  The line that I'm referencing is as follows:

mageglobal.product['saveToWishlistUrl']="<?php echo $this->getAddToWishlistUrl($_product) ?>";

which spits out an https URL, even though my current browser url is http.  My question is, how can I change core config data or settings so that this method call will mirror the current page's state (or i.e. the state of the page when the script was called)?  Thanks!


texts:
I am trying to override the order_items admin template in Magento with my custom module but it's working.
Layout file educertification.xml

<?xml version="1.0" ?>
<layout>
    <adminhtml_sales_order_view>
        <reference name="order_items">
            <action method="addColumnRender">
                <column>name</column>
                <block>adminhtml/sales_items_column_name</block>
                <template>educertification/sales/items/column/name.phtml</template>
            </action>
            <action method="addColumnRender">
                <column>name</column>
                <block>adminhtml/sales_items_column_name_grouped</block>
                <template>educertification/sales/items/column/name.phtml</template>
                <type>grouped</type>
            </action>
        </reference>
    </adminhtml_sales_order_view>
</layout>

I have created new template file with template directory educertification/sales/items/column/name.phtml

My config.xml of module

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

but it's not working. Please help


texts: Do exist extension to create promotion pages where customer can get rules?

texts:
Extension should have such functionality as:

Set period of page availability
General page for customer with all promotions (new and finished)


texts: Post 6788 Variables Permissions issue, allowed variable isn't working in block

texts:
I've added "design/header/logo_src" to allowed permissions, however in a static block I've made the following call and I'm getting the skin url but not the config path:

src="{{skin url="" }}{{config path="design/header/logo_src"}}"

What am I missing?


texts: Magento 2 - How to create new email template?

texts:
In magento 2, how to create new email template ?
When users forgot password, or user place new order and then received email.


texts: Some product pages show different theme - why?

texts:
I have inherited a site to finish that is proving to be difficult. There is a specific set of product pages that are not inheriting the theme set in the admin panel. I have checked all of the layout.xml files and nothing is set there. I have switched themes to make sure it's not theme-specific, and the issue remains. I installed CommerceBug, turned on profiling, you name it.

I looked through the list of options n98-magerun offers and noticed database logging. Turned that on and checked the output when I finally got a hit. See below:

SQL: SELECT `layout_update`.`xml` FROM `cart1_core_layout_update` AS    `layout_update`
 INNER JOIN `cart1_core_layout_link` AS `link` ON link.layout_update_id=layout_update.layout_update_id WHERE (link.store_id IN (0, :store_id)) AND (link.area = :area) AND (link.package = :package) AND (link.theme = :theme) AND (layout_update.handle = :layout_update_handle) ORDER BY `layout_update`.`sort_order` ASC
BIND: array (
  ':store_id' => '2',
  ':area' => 'frontend',
  ':package' => 'default',
  ':theme' => 'contest',
  ':layout_update_handle' => 'THEME_frontend_default_contest',
)

For reference, this is what it looks like for other pages:

SQL: SELECT `layout_update`.`xml` FROM `cart1_core_layout_update` AS `layout_update`
 INNER JOIN `cart1_core_layout_link` AS `link` ON link.layout_update_id=layout_update.layout_update_id WHERE (link.store_id IN (0, :store_id)) AND (link.area = :area) AND (link.package = :package) AND (link.theme = :theme) AND (layout_update.handle = :layout_update_handle) ORDER BY `layout_update`.`sort_order` ASC
BIND: array (
  ':store_id' => '2',
  ':area' => 'frontend',
  ':package' => 'ultimo',
  ':theme' => 'default',
  ':layout_update_handle' => 'default',
)

I have no clue where those values are being set. I've checked the core_layout_link and core_layout_update tables but they are empty. Any ideas?


texts:
Getting below error when applying giftcode in shopping cart page

  Error:  Invalid Form Key. Please refresh the page.


texts: How to sort recent orders after a specific column in Magento 1

texts:
I tried to use this event sales_order_grid_collection_load_after or sales_order_grid_collection_load_before in my function:

public function setRecentOrderGrid( Varien_Event_Observer $observer)
{
    $collection = $observer->getCollection();
    echo $collection->getSelect();
    if (!isset($collection)) {
        return;
    }
}

but I m getting this error:

Fatal error: Uncaught Error: Call to a member function getSelect() on null

I want to sort my grid  (in my case Recent Order grid) after a specific column DESC How can I do that ?


texts:
I have a Magento site (v2.3.2 CE) hosted on Nexcess. It has several extensions (paid and free) that are very outdated. There are also some custom backend extensions and a custom theme.
This site was made 1 year ago by a company that do not exists anymore and even if is in production is a little buggy.
I was called as project manager to fix the bugs and then to customize the shop, but before even do that I'm planning to upgrade to the latest stable (2.4.x) or at least to check its feasibility.
My fear is that something will break in the process.
The main idea right now is to use the Nexcess Dev Sites, try to upgrade and check if the update is successful.
Does Nexcess offer support for Magento upgrades (even with paid consultants)?
Does anyone have experience with nexcess consultants?
Do you have any idea of the possible timing or hourly prices?
Thanks
Any advices is welcome.


texts: Magento 2.3.2 Checkout redirecting to empty cart

texts:
we have onestepcheckout extension installed with Braintree as Payment Gateway.
Everything is working fine on sandbox mode of Braintree.
When I switch to Braintree production mode and place order using Credit card , it is redirecting to empty shopping cart. I still receive order email and order is showing up all good in admin.
While I was debugging for this issue I found when I switch Magento deploy mode to developer mode , it is working fine ,but when I switch deploy mode to production mode ,it is redirecting to empty shopping cart.

Any idea what could be the issue
we are using Nexcess cloud as hosting


texts:
we are using extension to upload the products
we are using the following code to display the error message :
"sku already exists" ,
for ex, if sku is "sku001" we are getting message :
Skip import row, sku "sku001" already exist

    if(trim($value) == '')
    {
    $errors[] = Mage::helper('mpmassuploadaddons')->__('Skip import row, is not valid value "%s" for field "sku"',$value);
    }
    else

        {
        $existProductId = Mage::getModel('catalog/product')->getIdBySku(trim($value));
        if($existProductId)
        $errors[] = Mage::helper('mpmassuploadaddons')->__('Skip import row, sku "%s" already exist',$value);
        else
        $data[$code] = $value;
        }
        break;

in the same way when we upload the product with wrong attribute value.
we are getting message as : "Skip import row, is not valid value " for field "nike" [nike is attribute value ] , here in this message, we need to add the "sku" also . this is the code we are using for displaying attribute value error message

if($errorFlag && $validationRequiredFlag)
$errors[] = Mage::helper('mpmassuploadaddons')->__('Skip import row, is not valid value "%s" for field "%s"',$attributeValue,$attributeCode);
}
else
{
if($validationRequiredFlag)
    $errors[] = Mage::helper('mpmassuploadaddons')->__('Skip import row, attribute "%s" does not exist',$attributeCode);
}
}
return array($data, $errors);
}

please help me to display the "sku" infront of error message as like :

'S001: Skip import row, is not valid value "" for field "nike"'

i am trying the following code :

if($errorFlag && $validationRequiredFlag && trim($value) == '')
$errors[] = Mage::helper('mpmassuploadaddons')->__('Skip import row, is not valid value "%s" for field "%s"',$value,$attributeValue,$attributeCode);
}
else
{
$existProductId = Mage::getModel('catalog/product')->getIdBySku(trim($value));
if($validationRequiredFlag)
$errors[] = Mage::helper('mpmassuploadaddons')->__('Skip import row, attribute "%s" does not exist',$sku,$attributeCode);
else
$data[$code] = $value;
}
}
return array($data, $errors);
}


texts: Magento - Add Product Expiry Date for Customer Group

texts:
Our store has few customer groups based on their purchase. We have requirement where admin will enter product expiry date i.e start/end date which will be shown on product detail page. Consider below case

Product A
Start date 01-JAN-2016
End date 31-JAN-2016

Product B
Start date 01-JAN-2016
End date 29-FEB-2016

Once the expiry date is over, the product should not be visible on frontend for specific customer group.

As shown in below image for Magento default Group Price, there will be a custom attribute where admin can set product expiry (start/end) date according to customer group.

Below is the sample image on how it should look like

I have created two date fields for expiry as custom attribute but do not know how to set it for customer groups

How do I approach this issue ?


texts: How to Remove Shopping cart from the footer on checkout page?

texts:
This is the code that I am added in checkout.xml

 <checkout_onepage_index translate="label">
    One Page Checkout

    <remove name="left"/>

    <reference name="root">
        <action method="setTemplate"><template>page/2columns-right.phtml</template></action>
    </reference>
    <reference name="right">
        <action method="unsetChildren"></action>
        <block type="checkout/onepage_review_info" name="checkout_review_sidebar" output="toHtml" before="-" template="checkout/onepage/review/info.phtml">
            <action method="addItemRender"><type>default</type><block>checkout/cart_item_renderer</block><template>checkout/onepage/review/item.phtml</template></action>
            <action method="addItemRender"><type>grouped</type><block>checkout/cart_item_renderer_grouped</block><template>checkout/onepage/review/item.phtml</template></action>
            <action method="addItemRender"><type>configurable</type><block>checkout/cart_item_renderer_configurable</block><template>checkout/onepage/review/item.phtml</template></action>
            <block type="checkout/cart_totals" name="checkout.onepage.review.info.totals" as="totals" template="checkout/onepage/review/totals.phtml"/>
            <block type="core/text_list" name="checkout.onepage.review.info.items.before" as="items_before" translate="label">
                Items Before
            </block>
            <block type="core/text_list" name="checkout.onepage.review.info.items.after" as="items_after" translate="label">
                Items After
            </block>

        </block>
     </reference>
</checkout_onepage_index>

Can any one pls help me to remove from the footer section


texts: Upgrading PHP to 5.4 Under a Magento Installation

texts:
I have Magento 1.9.0.1 installed on a server that still had PHP 5.2 on it. When I realised I upgraded to 5.4 as the Magento site states that it is compatible. Once I did this it occurred to me that Magento may install differently depending on what version of PHP you have.

Is this the case or am I safe upgrading PHP under Magento? I am assuming so as I cannot find anything about it, and after all you need to keep PHP up to date, but I feel I need to check.


texts: Enterprise 1.14.0.1 - Search index marked processing when not really processing

texts:
This has started to happen to me a few times on Enterprise 1.14.0.1 and I wondering if anyone has experienced the same issue. I have noticed the "Catalog Search Index" is listed as "Processing" in the admin. I do the usual steps of removing any stray lock files in "var/locks" and it still remains.

If I look at the index_process I can see that "catalogsearch_fulltext" has the "pending" status; however, if I look at the enterprise_mview_metadata I see that "catalogsearch_fulltext_cl" as a status of "3" or "working" which I determined by logging of the mysql query that is ran when the Index Management page is displayed.

So why the disconnect between these two tables? index_process says its not running, but enterprise_mview_metadata says it is running (status 3 = working).

It's my understanding the enterprise_mview_metadata tables handles the materialized views and triggers that in are in EE. I think there might be a bug in in somewhere where if cleans the tables.

I see in "app/code/core/Enterprise/Index/Model/Cron.php" there is a function called scheduledCleanup() which has the following comments:

  Clean changelog tables listed in enterprise_mview/metadata table.
  Cleanup would be executed in case the "index_clean_schedule" is set to
  "1"

Has anybody experienced this issue? Maybe something to do with a search index that is aborted prematurely and the status not getting reset in:
app/code/core/Enterprise/CatalogSearch/Model/Index/Action/Fulltext/Refresh.php

Edit:
Just so everyone is aware. I can manually set the search indexer back to the green "Ready" status by the following MySQL; however, what I'm trying to accomplish is to understand how the situation I encountered can occur.

UPDATE `enterprise_mview_metadata`
SET `status` = 1
WHERE `changelog_name` = 'catalogsearch_fulltext_cl'

Edit: I'm using SOLR for search if that helps.


texts: How to change qty of simple product after their creation magento 2

texts: I want to change dynamically the qty of simple product according to custom management so how to proceed using plugin or a certain event and is their a specific function to mention like afterGetName when we want to change the display of name. any help please


texts: How to add custom method in product interface.And how to overide productinterface and product model

texts: I want to add custom method in product interface and override product interface and product model.


texts: I am creating invoice and shipments pro-grammatically its working fine now i want to download PDF also how can i achieve this in magento2 ?


texts: Magento 2 - create a gift card product pro-grammatically for Magento Enterprise Edition

texts:
Does any one knows how to create a gift card product pro-grammatically in Magento 2?
Nothing found in similar questions for Magento 2.
I have a similar code for M1 but i want for Magento 2.4 EE.
M1 code
$gift_card = Mage::getModel('enterprise_giftcardaccount/giftcardaccount');
$gift_card
    ->setCode('ksjkskl-24k1ii1-67774k-231l')
    ->setStatus($gift_card::STATUS_ENABLED)
    ->setDateExpires('2021-04-15')
    ->setWebsiteId(1)
    ->setState($gift_card::STATE_AVAILABLE)
    ->setIsRedeemable($gift_card::REDEEMABLE)
    ->setBalance(25);
$gift_card->save();
return $gift_card->getId();


texts:
I'm trying to override salesRule module adding a new field customer_id for creating rules based on an unique customer.

I've already added the new field, but now, how this module applies the rules if it matches? I'm searching aroung the module and the only thing I found is this class: SalesRule\Model\Quote\Discount on the function collect seems it applies discount but only for the shipping. I don't know where I have to add some code, adding this conditionality of if matches customer_id

Days ago, I made the same thing with CatalogRule and things were a lot more intuitive, I had to made a few changes but the main goal was here:

CatalogRule\Model\ResourceModel\Rule on this function:

public function getRulePrices(\DateTime $date, $websiteId, $customerGroupId, $productIds, $customerId = 0)
{
    $connection = $this->getConnection();
    $select = $connection->select()
        ->from($this->getTable('catalogrule_product_price'), ['product_id', 'rule_price'])
        ->where('rule_date = ?', $date->format('Y-m-d'))
        ->where('website_id = ?', $websiteId)
        ->where('customer_group_id = ?', $customerGroupId)
        ->where('product_id IN(?)', $productIds)
        ->where('customer_id = ? OR customer_id = 0', $customerId)
        ->order('sort_order', 'ASC')
        ->limit(1);

    return $connection->fetchPairs($select);
}

As you can see, it was easy to find this query and manipulate it for achieve my objectives. But now with SalesRule seems more complicated.

Can anyone help? I can't find documentation about this. I need to know how works all this stuff.


texts: Magento EE 2.2.2 move store from one multi site instance to another multi site instance

texts:
What would be the easiest way to move a store from one multi site instance to another multi site instance on Magento EE 2.2.2?

Need to move store settings, products, product attributes, content blocks, etc, not worried about customers and orders.


texts: Why Magento addAttributeToSelect Never Works

texts:
Ok I have faced this issue in magento 1 too and I am not able to understand why addAttributeToSelect(*) never works.

When I call my product collection I want the collection will all the possible attributes.

Here is the product code

    protected $productCollection;

    public function __construct(
        ...
        \Magento\Catalog\Model\ResourceModel\Product\CollectionFactory $productCollectionFactory,
        ...
    ) {
        $this->productCollection = $productCollectionFactory->create();
    }

    public function execute() {

        //this does not works
        $this->productCollection->addAttributeToSelect(['*']);

        $this->productCollection->addAttributeToSelect('*');

        $this->productCollection->addAttributeToSelect(['*'], 'inner');

        // If I call each attribute individually it will work
        $this->productCollection->addAttributeToSelect(['name', 'image'], 'inner');
    }

If I see the magento Magento\Catalog\Model\ResourceModel\Product\Collection class it has the code but still it does not work

public function addAttributeToSelect($attribute, $joinType = false)
    {
        if ($this->isEnabledFlat()) {
            if (!is_array($attribute)) {
                $attribute = [$attribute];
            }
            foreach ($attribute as $attributeCode) {
                if ($attributeCode == '*') {
                    foreach ($this->getEntity()->getAllTableColumns() as $column) {
                        $this->getSelect()->columns('e.' . $column);
                        $this->_selectAttributes[$column] = $column;
                        $this->_staticFields[$column] = $column;
                    }
                } else {
                    $columns = $this->getEntity()->getAttributeForSelect($attributeCode);
                    if ($columns) {
                        foreach ($columns as $alias => $column) {
                            $this->getSelect()->columns([$alias => 'e.' . $column]);
                            $this->_selectAttributes[$column] = $column;
                            $this->_staticFields[$column] = $column;
                        }
                    }
                }
            }
            return $this;
        }
        return parent::addAttributeToSelect($attribute, $joinType);
    }

why It does not works and what can be the way around that I need not load each and every item of collection again to get all data.


texts:
Unfortunately, the profiler is not outputting data on my own controller actions, but those (including how magento comes to execute this action) I would like to profile.

Is there a code I can run in the end of my action to output the collected profiler data?


texts:
I created a module which I can see in the menu where I wanted to show it unfortunately it is not redirecting to the page, this module suppose to show the Grid
I also enabled and write down the module in app/etc/modules and it is enabled no worry about that I am seeing the module in my menu
the page it should go is:

http://website.com/index.php/report/adminhtml_report/

but it is a not found page
here is the structure:

Report.php

class Report_ReserveMenu_Block_Adminhtml_Report extends Mage_Adminhtml_Block_Widget_Grid_Container
{
    public function __construct()
    {
        parent::__construct();
        $this->_removeButton('add');
        $this->_controller = 'adminhtml_report';
        $this->_blockGroup = 'report';
        $this->_headerText = Mage::helper('report')->__($navigation);

    }

    protected function _prepareLayout()
    {
        $this->setChild( 'grid',
            $this->getLayout()->createBlock( $this->_blockGroup.'/' . $this->_controller . '_grid',
            $this->_controller . '.grid')->setSaveParametersInSession(true) );
        return parent::_prepareLayout();
    }
}

here is config.xml:

<?xml version="1.0" encoding="UTF-8"?>
<config>
    <modules>
        <Report_ReserveMenu>
            <version>0.0.1</version>
        </Report_ReserveMenu>
    </modules>
    <global>
        <helpers>
            <Report_ReserveMenu>
                <class>Report_ReserveMenu_Helper</class>
            </Report_ReserveMenu>
        </helpers>
        <blocks>
            <Report_ReserveMenu>
                <class>Report_ReserveMenu_Block</class>
            </Report_ReserveMenu>
        </blocks>
    </global>
    <adminhtml>
  <menu>
      <catalog>
          <children>
                <inventory>
        <children>
          <module name="Report_ReserveMenu">
            <title>03 Product Reserves</title>
            <sort_order>100</sort_order>
            <action>report/adminhtml_report</action>
          </module>
        </children>
        </inventory>
        </children>
      </catalog>
    </menu>
        <layout>
            <updates>
                <Report_ReserveMenu>
                    <file>report_menu.xml</file>
                </Report_ReserveMenu>
            </updates>
        </layout>
 </adminhtml>
</config>

also I have the update layout in app\design\adminhtml\default\default\layout\report_menu.xml

<?xml version="1.0"?>
<layout version="0.1.0">
     <report_adminhtml_report_index>
        <reference name="content">
            <block type="report/adminhtml_report" name="report" as="events.codes.edit.report"/>
        </reference>
</report_adminhtml_report_index>
</layout>

the controller:

class Report_ReserveMenu_Adminhtml_ReportController extends Mage_Adminhtml_Controller_action
{
protected function _isAllowed()
    {
        return Mage::getSingleton('admin/session')->isAllowed('catalog/report/report');
    }

public function indexAction() {

    $this->loadLayout();
    $this->getLayout()->createBlock('report/adminhtml_report');// <---- then this
    $this->renderLayout();

}
public function gridAction()
    {
        $this->getResponse()->setBody(
        $this->getLayout()->createBlock('report/adminhtml_report_grid')->toHtml()
        );
    }
}

and also the grid which doesn't seem to be wrong. please tell me what is wrong with this module, if you need to see other files just let me know and I will update the question, I don't want somebody to create me a nice module and say ok use this I wanna know my problem because everytime I have the problem creating my own module and I have to copy paste some other module like a goooooof


texts: Product page Script Not Pulling SKU, Magento 1.9

texts:
Having trouble inserting a pretty simple tracking code into each product page.  I am not having any luck pulling the SKU from the product page to populate the product_id (see below).  I am attempting to do so via a widget - which may be causing an issue, though I have inserted code this way before.

<script type="text/javascript">
        var sidecar = sidecar || {};
        sidecar.product_info = {
        product_id: '1234'
        };
    </script>

Any idea on what code to use so '1234' will dynamically populate with our SKU?  Also, product id would be an acceptable substitute if, for whatever reason, it's easier to do so.


texts: How can I fix: Cannot save the credit memo?

texts:
I am trying to create a credit memo in my store but I keep getting this error

Cannot save the credit memo

I have checked the exception.log and can see the following:

Integrity constraint violation: 1062 Duplicate entry '100003910' for key 'UNQ_SALES_FLAT_CREDITMEMO_INCREMENT_ID

I wanted to ask if I should change the value in the database to the next increment or is there a better way to solve this problem?

I'd be greatful for any advice...


texts:
My website is taking too much time to load. When the site is loading, there are chances that the customer to click on the things which is not active yet. So I want to put a loader before the site is active.

In order to put a loader, where I have to update the code?


texts:
Config: Magento 1.8/CentOS

problem: Bots log up with CAPTCHA enabled (spam is sent in Name field)


texts: Magento2.3.2: Cache in Header links are not working properly

texts:
When I logged out from my website, its successfully getting logout on the current page. But, when I click any other page for example clicks on the logo to get the homepage, it still shows as logged instead of getting logged out. When I refresh the page, it's showing fine. My all cache types are enabled. Check once the screenshot.

Steps to reproduce the issue:

Open once the website Depoto
Click on login/signup from header links with the provided credentials below.
You can observe the account is logged in.
Now, click on log out from header links. Then you observe the account is logged out.
Now, click on the Logo then you will go to the homepage.
Here, you see the account is still logged in.
Now refresh the page by ctrl + shift + R.Then you see the account is logged out.

Website user credentials:
username: teja.bhagavan1@gmail.com
Password: Test@123


texts: Can we use lower case letters for vendor name

texts:
Facing an issue with the vendor name.
{"0":"Param resource doesn't pass validation: 'test_SimpleModule::test' does not match against pattern '/^[A-Z][A-Za-z0-9]+_[A-Z][A-Za-z0-9]+::[A-Za-z_0-9]+$/'","1":"#0
In the Magento marketplace, the vendor name is in lowercase, when I've updated my module vendor name to the lowercase I am getting the above error.
Can someone help me with this issue?


texts: event observer inventory change configuration

texts:
I tried to observe a quantity change event but I messed up with the config file a bit

config.xml:

    <events>
        <cataloginventory_stock_item_save_after >
            <observers>
                <unreal_bisn>
                    <class>unreal_bisn/observer</class>
                    <method>productBackInStock</method>
                </unreal_bisn>
            </observers>
        </cataloginventory_stock_item_save_after >
    </events>

Model/Observer.php

<?php

class Unreal_Bisn_Model_Observer
{

    public function productBackInStock()
    {
        die("Worked");
    }

}

When I change the qty of a product I see a warning that shows me I did a wrong configuration of namespaces somehow

Warning: include(Mage\Unreal\Bisn\Model\Observer.php):

It should be

Unreal\Bisn\Model\Observer.php

Please let me know what to adjust.

thanks


texts: Magento2: Dropdown option in contact page

texts:
We add custom option in contact page:

                                <input placeholder="<?php echo __('Order Number') ?>" name="ordernumber" id="ordernumber"
                                       title="<?php /* @escapeNotVerified */
                                       echo __('Order Number') ?>" value="" class="input-text" type="text"/>

                    <input placeholder="<?php echo __('Rodzaj zgloszenia') ?>" name="rodzajzgloszenia" id="rodzajzgloszenia"
                           title="<?php /* @escapeNotVerified */
                           echo __('Rodzaj zgloszenia') ?>" value="" class="input-text" type="text"/>

email Template:

           {{trans "Order Number"}}
        {{var data.ordernumber}}

           {{trans "Rodzaj zgloszenia"}}
        {{var data.rodzajzgloszenia}}

But how to create in field: Rodzaj zgłoszenia dropdown with select option and forward in email selected option?


texts: where is review.save()[ place order ] related code is present

texts:
I want to know how its redirecting to payment methods after we click on "place order" button

i can see "place order" button file here :

frontend/base/default/template/checkout/onepage/review/button.phtml

this is the code :

http://pastebin.com/auZAQJWZ

i want to know where is "review.save()" is present in magento folder path


texts: Catalog Price Rules conditions not working

texts:
When I create a catalog price rule everything works fine for a specific customer group.

As soon as I add a category condition nothing works. Has anybody experienced this before?

Conditions:
ANY are TRUE
Category (is, is one of, etc, tried all) is in category trying to target

Action
Reduce price by 15%

Products are in multiple categories.

Thanks


texts: Get order id from purchased downlodable product id

texts:
How can I get order id from purchased downlodable product ?

Please check my below code :

$purchased = Mage::getResourceModel('downloadable/link_purchased_collection')
        ->addFieldToFilter('customer_id', $customer_id)
        ->addOrder('created_at', 'desc');

$purchasedItems = Mage::getResourceModel('downloadable/link_purchased_item_collection')
        ->addFieldToFilter('purchased_id', array('in' => $purchasedIds))
        ->addFieldToFilter('status',
            array(
                'nin' => array(
                    Mage_Downloadable_Model_Link_Purchased_Item::LINK_STATUS_PENDING_PAYMENT,
                    Mage_Downloadable_Model_Link_Purchased_Item::LINK_STATUS_PAYMENT_REVIEW
                )
            )
        )
        ->setOrder('item_id', 'desc');

foreach ($items as $item)
{
    -- Here I wand to get Order id of each items ---
}


texts: Adding merchants/sellers to magento site

texts:
We have to add sellers/merchants to our site.

It means, through our site, sellers have to sell the products & we have to get commission

from the sellers.

demo example : https://seller.flipkart.com/

If there are 5 sellers , buyer have to see all 5 sellers in checkout page or

related page. Also Buyers have to check the nearest shop to buy the product using pin code or search box. after they selecting nearest store, than products list should display.

IS there any good extension for this. please guide me.


texts: Magento 2 Error - Failed to load resource: the server responded with a status of 403 (Forbidden)

texts:
I am overriding magento configurable.js to my theme and adding some function.i am getting an error of 403 forbidden url.any one can you please help me to short it out.

 _specifictionContent:function (productMainID) {
        var productMainID = parseInt(productMainID);
       //alert(productMainID);
       var url_data = "<?php echo $block->getUrl( 'getsku/sku/index/' ); ?>";
        if(typeof productMainID == 'number'){
            $("#common_specification").hide();

            jQuery.ajax({
                    url: url_data,
                    type: "POST",
                    data: {id:productMainID},
                    showLoader: false,
                    cache: false,
                    success: function(response){
                        $("#config_simple_specification").html(response);
                    }
                });
        }
    },

In above function i am passing simple product id of a configurable product.
and want to send it to my controller and get back some product specification to show/hide in configurable product page.

My controller file is like this.

<?php
namespace t5media\Quote\Controller\Sku;
use Magento\Framework\App\Action\Action;
use Magento\Framework\App\Action\Context;

class Index extends Action
{
protected $_productRepository;

public function __construct(
    Context $context,
    \Magento\Catalog\Api\ProductRepositoryInterface $productRepository
)
{
    $this->_productRepository = $productRepository;
    parent::__construct($context);
}

public function execute()
{
    $id = $this->getRequest()->getParam('id'); echo $id;
    //echo $this->_productRepository->getById($id)->getSku();
    $product = $this->_productRepository->getById($id);
    $attributes = $product->getAttributes();

        $remove_set = array("hm_mostpopular_prod_featured","hm_most_popular_product","quote_only");//This
        foreach ($attributes as $attribute) {
            $atr_code = $attribute->getAttributeCode();
            $user_defined = $attribute->getIsUserDefined();//user defined attribute or Magento default attribute
            if($user_defined==1){ //if user defined attribute it will show
                $attr_value = $product->getResource()->getAttribute($atr_code)->getFrontend()->getValue($product);
                if($attr_value !='' && !in_array($atr_code, $remove_set)){ //if have value and not in to removed attribute list it will show to table.
                    ?>

<?php echo $attribute->getFrontendLabel();?> <?php echo $attr_value;?>

                    <?php
                } //END of IF
            } //END of IF
        } //END of foreach

}
}

If i access the url http://127.0.0.1/tork/getsku/sku/index/?id=611 i can get the result.


texts:
After upgrading magento to 2.3.4 my checkout page is now broken, giving me an error

POST mydomain/checkout/ 404 (not found)
as well as defaultCaptcha.js cannot read property 'timestamp' of undefined'; and misc.js cannot read property of 'status' undefined.


texts: How to purge (delete) credit card numbers stored on Magento 1.9.1.0?

texts:
We used the 'Saved CC' payment method in our Magento 1.9.1.0 store and now we would like to delete the credit card numbers for security reasons.
What is the easiest procedure to delete all credit card numbers?

UPDATE ON SEPTEMBER 21st, 2018:
I just tried to do that. I go to phpMyAdmin in the cPanel. There are 2 databases:

mySITE_mySITE

information schema

I highlight either, click on SQL, and enter the following lines (one at a time):
UPDATE sales_flat_order_payment SET cc_number_enc=NULL;
UPDATE sales_flat_order_payment SET cc_type=NULL;
UPDATE sales_flat_order_payment SET cc_last4=NULL;
UPDATE sales_flat_order_payment SET cc_owner=NULL;
UPDATE sales_flat_order_payment SET cc_exp_month=NULL;
UPDATE sales_flat_order_payment SET cc_exp_year=NULL;

UPDATE sales_flat_quote_payment SET cc_number_enc=NULL;
UPDATE sales_flat_quote_payment SET cc_type=NULL;
UPDATE sales_flat_quote_payment SET cc_last4=NULL;
UPDATE sales_flat_quote_payment SET cc_owner=NULL;
UPDATE sales_flat_quote_payment SET cc_exp_month=NULL;
UPDATE sales_flat_quote_payment SET cc_exp_year=NULL;

But then it gives me the following Errors:
Error
SQL query:
UPDATE sales_flat_order_payment SET cc_number_enc=NULL
MySQL said:
#1146 - Table 'mySITE_mySITER.sales_flat_order_payment' doesn't exist

Error
SQL query:
UPDATE sales_flat_order_payment SET cc_number_enc=NULL
MySQL said:
#1109 - Unknown table 'sales_flat_order_payment' in information_schema

What am I doing wrong?

Another UPDATE on September 21st:
it turns out that all that I needed to do was to add mg_ in front of the code like this:
UPDATE mg_sales_flat_order_payment SET cc_number_enc=NULL;
UPDATE mg_sales_flat_order_payment SET cc_type=NULL;
UPDATE mg_sales_flat_order_payment SET cc_last4=NULL;
UPDATE mg_sales_flat_order_payment SET cc_owner=NULL;
UPDATE mg_sales_flat_order_payment SET cc_exp_month=NULL;
UPDATE mg_sales_flat_order_payment SET cc_exp_year=NULL;

UPDATE mg_sales_flat_quote_payment SET cc_number_enc=NULL;
UPDATE mg_sales_flat_quote_payment SET cc_type=NULL;
UPDATE mg_sales_flat_quote_payment SET cc_last4=NULL;
UPDATE mg_sales_flat_quote_payment SET cc_owner=NULL;
UPDATE mg_sales_flat_quote_payment SET cc_exp_month=NULL;
UPDATE mg_sales_flat_quote_payment SET cc_exp_year=NULL;

And now it works!


texts: Buy 1 get 10% discounts for selected products

texts: How can give buy 1 get 10% for selected products in selected categories.


texts: change the wishlist item collection in "My Wish list" tab in My Account in Magento EE ver. 2.4.1

texts:
I am using Magento EE ver. 2.4.1 and i want to override the wishlist item collection in my account. But i am facing the below issue :

PHP Fatal error: Uncaught Error: Call to a member function getFinalProduct() on null in vendor/magento/module-wishlist/CustomerData/Wishlist.php

I have created the following preference in etc/frontend/di.xml
<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">

    <preference for="Magento\Wishlist\CustomerData\Wishlist" type="Vendor\Module\CustomerData\Wishlist" />

</config>

Vendor/Module/CustomerData/Wishlist.php
<?php

namespace Vendor\Module\CustomerData;

use Magento\Catalog\Model\Product\Image\NotLoadInfoImageException;
use Magento\Customer\CustomerData\SectionSourceInterface;
use Magento\Framework\App\ObjectManager;

class Wishlist extends \Magento\Wishlist\CustomerData\Wishlist
{
     /**
     * @var string
     */
    const SIDEBAR_ITEMS_NUMBER = 3;

    /**
     * @var \Magento\Wishlist\Helper\Data
     */
    protected $wishlistHelper;

    /**
     * @var \Magento\Catalog\Helper\ImageFactory
     */
    protected $imageHelperFactory;

    /**
     * @var \Magento\Framework\App\ViewInterface
     */
    protected $view;

    /**
     * @var \Magento\Wishlist\Block\Customer\Sidebar
     */
    protected $block;

    /**
     * @var \Magento\Catalog\Model\Product\Configuration\Item\ItemResolverInterface
     */
    private $itemResolver;
    protected $wishlistFactory;
    /**
     * @param \Magento\Wishlist\Helper\Data $wishlistHelper
     * @param \Magento\Wishlist\Block\Customer\Sidebar $block
     * @param \Magento\Catalog\Helper\ImageFactory $imageHelperFactory
     * @param \Magento\Framework\App\ViewInterface $view
     * @param \Magento\Catalog\Model\Product\Configuration\Item\ItemResolverInterface|null $itemResolver
     */
    public function __construct(
        \Magento\Wishlist\Helper\Data $wishlistHelper,
        \Magento\Wishlist\Block\Customer\Sidebar $block,
        \Magento\Catalog\Helper\ImageFactory $imageHelperFactory,
        \Magento\Framework\App\ViewInterface $view,
        \Magento\Wishlist\Model\WishlistFactory $wishlistFactory
    ) {
        $this->wishlistHelper = $wishlistHelper;
        $this->imageHelperFactory = $imageHelperFactory;
        $this->block = $block;
        $this->view = $view;
        $this->wishlistFactory = $wishlistFactory;
    }
    /**
     * Get wishlist items
     *
     * @return array
     */
    protected function getItems()
    {
        $writer = new \Zend\Log\Writer\Stream(BP . '/var/log/mbPref2.log');
        $logger = new \Zend\Log\Logger();
        $logger->addWriter($writer);
        $logger->info("here");

        $this->view->loadLayout();

        $wishlist = $this->wishlistFactory->create()->load(162);

        // i have used this custom collection instead of the default item collection
        $collection = $wishlist->getItemCollection();

        //$collection = $this->wishlistHelper->getWishlistItemCollection();

        //show all wishlist items
        $collection->clear()->setInStockFilter(true)->setOrder('added_at');

        $logger->info(get_class($collection));

        $items = [];
        foreach ($collection as $wishlistItem) {
            $items[] = $this->getItemData($wishlistItem);
        }
        return $items;
    }
}


texts: Hi am new to ultimo and recently am trying to add my own custom CSS in order


texts: Remove "delivery-time-details" container from Template - produced by getPriceHtml

texts:
In the product View a function getPriceHtml displays the Product price, but it seems that apart form that it also displays the delivery-time-details. I can see it, since by removing this function call the delivery-time-details HTML container also disappears.
But even in the getPriceHtml method definition in Mage_Catalog_Block_Product_Abstract the delivery-time-details are not present.

Could someone tell me where to find the line, which prints the delivery-time-details after the price?


texts:
So we seem to have a very strange issue where certain Simple products are disappearing from the front end. Running bin/magento indexer:reindex doesn't seem to solve anything, the only solution we've found is to manually re-save the product (making no changes)
Trying to get to the bottom of this I've started to try and compare the data in the database, before and after save. The only issue is I'm not sure what tables I should be looking at?
I have found one different between before and after saving (product not showing and then showing)
SELECT * FROM magento.cataloginventory_stock_item where product_id = 1787
Outputs
item_id,product_id,stock_id,qty,min_qty,use_config_min_qty,is_qty_decimal,backorders,use_config_backorders,min_sale_qty,use_config_min_sale_qty,max_sale_qty,use_config_max_sale_qty,is_in_stock,low_stock_date,notify_stock_qty,use_config_notify_stock_qty,manage_stock,use_config_manage_stock,stock_status_changed_auto,use_config_qty_increments,qty_increments,use_config_enable_qty_inc,enable_qty_increments,is_decimal_divided,website_id 1946,1787,1,8.0000,0.0000,1,0,1,0,1.0000,0,2.0000,0,1,NULL,1.0000,1,1,0,0,1,0.0000,1,0,0,0
Has qty_increments = 0.0000 before save and then 1.0000 after save. However changing this value manually doesn't seem to have any effect
If anyone could help why this be happening or help with the debugging process it would be very appreciated.


texts: How to set clickAnalytics=true as an extra search parameter in magento 1?

texts:
I want to pass an extra parameter to search , this is the only way i can get query id in search response for agolia.

Let me know your thoughts this , thanks.


texts: Integrity constraint violation when reindexing after migration to Magento 2.3.5-p1

texts:
We are testing the migration of a store from Magento 1.9.4.5 to 2.3.5-p1 using the Magento Data Migration Tool (version 2.3.5).
The migration completes without issue, however when reindexing on the new M2 site we get the following error:
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '487-0-3-4-8' for key 'PRIMARY', query was: UPDATE `catalog_product_index_price_bundle_sel_tmp`
 INNER JOIN `catalog_product_index_price_bundle_tmp` AS `i`
 INNER JOIN `catalog_product_entity` AS `parent_product` ON parent_product.entity_id = i.entity_id
 INNER JOIN `catalog_product_bundle_option` AS `bo` ON bo.parent_id = parent_product.entity_id
 INNER JOIN `catalog_product_bundle_selection` AS `bs` ON bs.option_id = bo.option_id
 INNER JOIN `catalog_product_bundle_selection_price` AS `bsp` ON bs.selection_id = bsp.selection_id AND bsp.website_id = i.website_id
SET `catalog_product_index_price_bundle_sel_tmp`.`entity_id` = `i`.`entity_id`, `catalog_product_index_price_bundle_sel_tmp`.`customer_group_id` = `i`.`customer_group_id`, `catalog_product_index_price_bundle_sel_tmp`.`website_id` = `i`.`website_id`, `catalog_product_index_price_bundle_sel_tmp`.`option_id` = `bo`.`option_id`, `catalog_product_index_price_bundle_sel_tmp`.`selection_id` = `bs`.`selection_id`, `catalog_product_index_price_bundle_sel_tmp`.`group_type` = IF(bo.type = 'select' OR bo.type = 'radio', 0, 1), `catalog_product_index_price_bundle_sel_tmp`.`is_required` = `bo`.`required`, `catalog_product_index_price_bundle_sel_tmp`.`price` = LEAST(IF(bsp.selection_price_type = 1, ROUND(i.price * (bsp.selection_price_value / 100),4), IF(i.special_price > 0 AND i.special_price < 100, ROUND(bsp.selection_price_value * (i.special_price / 100),4), bsp.selection_price_value))* bs.selection_qty, IFNULL((IF(i.base_tier IS NOT NULL, IF(bsp.selection_price_type = 1, ROUND(i.base_tier - (i.base_tier * (bsp.selection_price_value / 100)),4), IF(i.tier_percent > 0, ROUND((1 - i.tier_percent / 100) * bsp.selection_price_value,4), bsp.selection_price_value)) * bs.selection_qty, NULL)), IF(bsp.selection_price_type = 1, ROUND(i.price * (bsp.selection_price_value / 100),4), IF(i.special_price > 0 AND i.special_price < 100, ROUND(bsp.selection_price_value * (i.special_price / 100),4), bsp.selection_price_value))* bs.selection_qty)), `catalog_product_index_price_bundle_sel_tmp`.`tier_price` = IF(i.base_tier IS NOT NULL, IF(bsp.selection_price_type = 1, ROUND(i.base_tier - (i.base_tier * (bsp.selection_price_value / 100)),4), IF(i.tier_percent > 0, ROUND((1 - i.tier_percent / 100) * bsp.selection_price_value,4), bsp.selection_price_value)) * bs.selection_qty, NULL)
WHERE (i.price_type=1)

This error occurs every time we reindex either manually via the CLI or via cron.
How do we troubleshoot and fix this?


texts: High-resolution square product images on product list pages

texts:
I'm trying to show square product images on the product list pages, where images for hundreds of products range in dimensions.

When I use this adaptive resize

<img id="product-collection-image-<?php echo $_product->getId();"
src="<?php echo $this
->helper('catalog/image')
->init($_product, 'small_image')
->constrainOnly(FALSE)
->keepAspectRatio(TRUE)
->keepFrame(FALSE)
->adaptiveResize(300,300); ?>" width="300" height="300"

it shows squares but the image quality is bad. When I set constrainOnly(TRUE), the quality is good, but the squares have some black in them to fill the rest of the square that the image doesn't fill.

How can I get as high as possible image resolution whilst also squaring the images (ideally showing the centre of the image)? Is there any alternative method?

(I tried this adaptive resize too)

Update

I accepted the solution below however I was still left with bad resolution on images. Because I am working with images of different dimensions, some landscape, some portrait, the best solution for me was to manually crop the images into squares (in gimp, change the relative scale so the smallest side is equal to the size of the image I need whilst retaining aspect ratio, then change canvas size). All the solutions I've seen don't work well on images like these.


texts: Cannot remove the layered navigation Block by using layout xml?

texts:
To call the layered navigation I use this call and it worked

<?php echo $block->getLayout()->getBlock('catalog.leftnav')->toHtml();?>

For remove it I use this in default.xml

<reference block name="catalog.leftnav" remove="true" />

But when I remove this above calling code fails because of what I do.


texts: Create product labels on product images in magento

texts:
Here, you can see "quality', best" Product labels on product images.

how to create new Product label "DEAL".

I used this "http://www.magentocommerce.com/magento-connect/product-labels-6.html"

but After using this extension, i am got following problem.

1)Product image on product-view page will disappear like as following link :

Is there any other free extension or solution to create Product labels.

please help me to find solution.


texts: Paypal Website Payments Pro Hosted Solution gives pending payment status in magento

texts:
We have set Website Payments Pro Hosted paypal in website. But after order, it shows as pending payment in admin and it says total due. But i noticed the payment is made in paypal. After some searching i found it might be the cause of ipn. So i have set magento ipn url in paypal. But still the issue is not fixed.

Now i have removed the ipn. Dont know what is the issue. I have tried checking with sandbox. But everytime i click place order it shows, your transaction cant be processed, please pay with another card.

I have checked the paypal log. But the [ACK] => Success is the status. When i checked the order detail page in magento admin, I can see the paypal last transaction id and other details are not showing: http://prntscr.com/6x5jay

Could anyone assist me in fixing this. Thankyou.


texts: Bug to configure a widget : impossible to select a block

texts:
I am currently working on an e-commerce website, running with Magento 2.4.0. I have to create a new widget, but at the end of the configuration, I have to select a block, which is impossible due to some mysterious reason ...
Here is a screenshot of the window I have. It is impossible to select any block ... Does someone know more about it ?
Thank you so much !


texts: Magento Open Source 2.3 / 2.2 - How many orders / inventary and SKU it can handle?

texts:
I'm about to start a project, But my concerned is on the data, the magento 2.2/2.3 can handle.  The traffic figures are in 1 Million to 5 million  and we are not interested in Enterprise model as of now. My questions are very straigth foward and open for technical also. My questions ...

How many Orders / inventory can Magento Open Source modal can handle? Figures is aroung 8,00,000 monthly
If we have 10 billion sales each year, will magento be able handle 5 or 10 years data. I know that backend we have MYSQL but will it ?
How many products details i.e SKU it can handle again the data is in billions.

So let me know your figures for this.


texts:
What appears to be commonplace and easy to do on just about every other platform, Im trying to source an extension that allows for order notifications via webhooks...

I've looked high and low but cant seem to find an extensions / app that allows for posting of order data to a remote endpoint without having to resort to writing my own extension / observer.

Can anyone recommend either paid or free extension that I can install and simply get transaction data posted to a remote endpoint?

thanks in advance


texts:
For some reason my product names looks really strange in Google analytics, when fetching data from my Magento2 installation.

For instance GEAR\u0020H\u00E5ndmixer\u0020Olivia\u00201.0\u0020Rosa when the real name in magento (and also in the database) is GEAR Håndmixer Olivia 1.0 Rosa

Any idea how to fix this?


texts:
I am running a Magento 1.9.3.7 store with the Ultimo theme. No matter what I enter in the qty box on the product page, the number is always 1 ion the cart.

I debugged a little and figured that there is no qty in the request. Any ideas where to keep looking?

I looked at Mage_Checkout_Model_Cart and there in the addProduct function. The $requestInfo object has no qty at all. When I change the qty in the cart it works as expected.

Thanks!


texts: Magento2 Passing Arguments to class in Construct

texts:
I am trying to instantiate the below class in my custom code

\Magento\Solr\Model\Client\Solarium

like

    public function __construct(
        \Magento\Solr\Model\Client\Solarium $solr
     )
{....}

However this is not working because this class requires arguments in its constructor and throws up error

  We were unable to perform the search because of a search engine
  misconfiguration.

But I am able to initialize using objectManager

$options = array(
            'hostname' => $this->_solrHelper->getSolrConfigData('server_hostname'),
            'login' => $this->_solrHelper->getSolrConfigData('server_username'),
            'password' => $this->_solrHelper->getSolrConfigData('server_password'),
            'port' => $this->_solrHelper->getSolrConfigData('server_port'),
            'path' => $path
        );
 $solrClient = $this->_objectManager->create('\Magento\Solr\Model\Client\Solarium', ['options' => $options]);

I am aware that using objectManager is not the right approach

So, how do I instantiate a class that requires parameters in its constructor?


texts: Request Parameters with php 7.4 and magento 2.4.1

texts:
After updating from 2.3.5p2 to 2.4.1 and from php 7.1 to php 7.4 I have strange trouble with request parameters.
I see, that there are parameters set, when I var_dump
$parameters=$this->request->getParams();

var_dump($parameters);

Output:
array(5) { ["key"]=> string(64) "4e10c465f6988a7fjdueia57dbac2407f7990206d27eb47d531c5a94311ca51fd" ["namespace"]=> string(10) "importgrid" ["filters"]=> array(1) { ["placeholder"]=> string(4) "true" } ["paging"]=> array(2) { ["pageSize"]=> string(2) "20" ["current"]=> string(1) "1" } ["isAjax"]=> string(4) "true" }

I can also access $parameters["key"]; but every other value gives me an error:
var_dump($parameters["paging"]);
Notice: Undefined index: paging in .....
Its like those array keys dont exist, even they show up in the dump $parameters...
Any ideas, what is happening here? Have I missed something big in php-arrays from 7.1 to 7.4?


texts: How to set Value to Checkbox in custom module created by module creator

texts:
I have created a module by module creator. I have added checkbox code in Form.php from Block/Adminhtml/modulename/edit/tab/form.php.

$fieldset->addField('title', 'checkboxes', array(
    'label'     => Mage::helper('custommodule')->__('Title'),
    'name'      => 'title',
    'values' => array(
        array('value'=>'aaa','label'=>'Checkbox1'),
        array('value'=>'bbb','label'=>'Checkbox2'),
        array('value'=>'ccc','label'=>'Checkbox3'),
    ),
    /* 'checked' => array('aaa','bbb','ccc'), */
    'onclick' => "",
    'onchange' => "",
    'disabled' => false,
    'tabindex' => 1
));

Now How should I add this checkbox values to Database and Vice Versa how to assign value to checkbox while editing.

Thanks in advance


texts: how do I change this sql query to magento get data method?

texts:
I have below sql query, how do I turn this to Magento get data method to retrieve data? Please help
SELECT sales_order.increment_id, sales_order_payment.additional_information FROM sales_order LEFT JOIN
            sales_order_payment ON sales_order.entity_id = sales_order_payment.parent_id
            WHERE sales_order_payment.method = 'opayment' AND sales_order.updated_at >= NOW() - INTERVAL 30 MINUTE


texts: Simple Product to Virtual Product Change?

texts:
If we have created a simple product in Magento but it was supposed to be a virtual product, is that a simple fix on the back end?

We created a large number of courses that do not require shipping and have no physical product.  Would a simple query to correct this and rewrite be possible?


texts: Adding child block inside static block not working

texts:
Adding block B inside block A as child block is not working for me. Block A is a static block in cms page.

A category page display mode is : Static block only > displays block A
The static block has {{block type="core/template" name="contactForm" template="contacts/form.phtml"}}.

I am trying to call a child block inside this contactForm, which is not working.

xml layout:

<cms_page>
    <reference name="contactForm">
        <block type="core/template" name="customblock" template="amodule/customblock.phtml"/>
    </reference>
</cms_page>

template: contacts/form.phtml has this code inside

<?php echo $this->getChild('customblock')?>


texts:
Block file

<?php

class Namespace_Modulename_Block_Modulename extends Mage_Core_Block_Template{

        public function __construct()
    {
        parent::__construct();
        $collection = Mage::getModel('module/model')->getCollection();
        $this->setCollection($collection);
    }

    protected function _prepareLayout()
    {
        parent::_prepareLayout();

        $pager = $this->getLayout()->createBlock('page/html_pager', 'mymodule.pager');
        $pager->setAvailableLimit(array(5=>5,10=>10,20=>20,'all'=>'all'));
        $pager->setCollection($this->getCollection());
        $this->setChild('pager', $pager);
        $this->getCollection()->load();
        return $this;
    }

    public function getPagerHtml()
    {
            return $this->getChildHtml('pager');
    }

}

Model/Mysql4/Module/Collection.php

class NameSpace_ModuleName_Model_Mysql4_ModuleName_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
{

    public function _construct(){

        parent::_construct();
        $this->_init('module/model');

    }

    public function addCustomFilter($customerId)
    {

        $sortByCustomer = 'customer_id = ?';
        $sortByOrder = 'order_id DESC';
        $this->getSelect()->where($sortByCustomer, $customerId)->order(new Zend_Db_Expr($sortByOrder));
        return $this;
    }
}

Model/Mysql4/Modulename.php

class NameSpace_ModuleName_Model_Mysql4_ModuleName extends Mage_Core_Model_Mysql4_Abstract
{

    public function _construct(){

        // Note that the id refers to the key field in your database table.
        $this->_init('module/model','id');
    }

}

My frontend .phtml file, I am using below code to call my custom collection

<?php
$customerId = 1;
$customerCollection =  $this->getCollection()->addCustomFilter($customerId);

?>

<?php if ($customerCollection->getSize()): ?>

                <?php foreach ($customerCollection as $collection): ?>

                        <?php echo $collection->someData(); ?>

                <?php endforeach; ?>

<?php endif; ?>

As far as I know, this will call the collection from custom DB table. The issue here is I have already specified the filter in my collection file, but it still not showing filtered results.

Or do I need to add my filter function in Model/Mysql4/Modulename.php file ?

It also throws an exception of Unrecognized method 'getSize()

Please Guide.

Thanks


texts: Magento 2, how to add more option in configuration attribute of product?

texts: Using Magento 2.2, Configuration Product - Attribute. I need to add more select option for Configuration Product example Multiple Select.


texts: How to remove default favicon completely?

texts:
Magento favicon showing in product images
How do I delete this favicon permanently?

I have changed it in Magento panel it's changed in homepage but I open image link in new tab it shows Magento favicon again.


texts: How to migrate Magento 1.9.2.3 Multi Store Website into Magento 2.3.4?

texts:
I have tried a lot of times to migrate the Multi-store website into Magento 2.3.4 and faced so many errors.

May I know the proper guide to migrate the Multi-Store Website into Magento 2.3.4?


texts:
TOPIC:
Looking to move Shopping Cart to Header-Right in Magento 1.8.1

ATTEMPTS + OTHER POSTS:

How to add a Cart Icon to header?

Move Cart to Header in Magento 1.7

Any contribution is greatly appreciated.

Shopping Cart Icon & # Of Products In Cart - DISPLAYED AT RIGHT-HEADER is the end goal.


texts: Help for redirect all default page magento to 404 or homepage with .htaccess

texts:
I'am on magento 1.9.3.8, i know it would be time for me to go on magento 2...

So i have this url by default in magento :

downloader/
catalogsearch/advanced/
catalog/seo_sitemap/product/
catalog/seo_sitemap/category/
rss/catalog/notifystock/
rss/order/new/
index.phprss/catalog/notifystock/
customer-service/
sales/guest/form/
privacy-policy-cookie-restriction-mode/

How i can redirect this url with .htaccess to my home page or 404 ?

Thank you for help


texts: Magento 2 How to retrieve all select attribute labels ids and/or names

texts:
Example "developer" attribute of the type select contains

 ID - LABEL
 12 - junior
 13 - regular
 14 - senior

How to retrieve all labels ids and/or names for this attribute. I need something like that

$attribute = $this->attributeRepository->get($attributeCode); //load select attribute

$labelsNames = $attribute->getLabelNames();
$labelsIds = $attribute->getLabelsIds();


texts: How can I make a new Admin menu item that is actually displayed in the left hand side menu (System -> Configuration)

texts: I want to make a menu item, and maybe even a section in admin. This item will link me to a new form in admin. How can I do that, with a new module? I know I need a new module, but what else do I need, what kind of setup of config.xml etc...?


texts: Products Grid Layout Bug Magento 1.9.1 CE in Safari iOS 8

texts:
I have encountered an issue with Magento 1.9.1 CE whilst browser testing a clients site in Safari on iOS 8 and 8.1 on iPad and iPhones (tested on iPad Mini, iPad Air, iPhone 5, iPhone 5s)

The product grid spacing breaks at random, it should for instance display 3 products in a row portrait and 4 products on a row landscape.

However at random the products display 1 per line, 2 per line, 1 and then 2 per line, basically all in random amounts per row.

This bug is present with my bespoke theme developed using correct convensions with the default rwd theme. It is also present if the bundled rwd theme is enabled. No changes to the template files, nor the css have been made to possibly effect this.

Also to air on the side of caution, I opened Magento's demo store: http://enterprise-demo.user.magentotrial.com/ which is essentially 1.9 CE theme and it has the same issue.

I have got the iPad connected to my Mac and I am using Safari Dev tools to try and narrow this down but am yet to find the root cause.

Just wanted to know if anyone has had this issue and found a fix? And also to make others aware of what seems a bug for the rwd theme in Magento 1.9 CE and enterprise in Safari on iOS 8 builds.

Some screen shots of the issue are below.


texts: Magento function that sends data to browser

texts:
I want to inspect and modify ALL output that is sent to the browser but rather than making hundreds of edits in the template files, I'd like to do this with one swoop by altering a function that send that data to screen.

Does this function exist?


texts: Grabbing storeview from cookie (after using language selector)

texts:
I have written a custom function to set our MAGERUNCODE based on the accept language and the uri request (beeing /). THis works fine.

Now I have 1 remaining issue. And this is when the customer uses the store switcher and 'forces' to see another language. I understand that the request storeview is then stored in a COOKIE.

Question: how can I grab the storeview from te Magento cookie (after the language switcher was used)

Many thanks, Sean


texts: Product Attribute sorting not applied when attribute relies on another

texts:
I'm currently building a site in Magento 2 and am trying to get sorting working for product attributes on the product listing page. I have a Size attribute which doesn't respect the sorting specified in the admin.

When it's the only attribute on the product the sorting is applied fine:

When the attribute is dependant on a parent attribute (you have to select another attribute before the size attribute is loaded) they are sorted in alphabetical order rather than the one specified in the admin.

I'm confident that it's not custom code causing this issue as the block is loaded from the Magento_Catalog module.


texts: Can I overwrite default Magento configuration?

texts:
in my local.xml I have the chance to configure, for example, the secure and unsecure URLs for specific shop setups. So I don't have to configure these settings in the database. That makes migration and version management of the code much easier.

My question is if I can overwrite other settings, like shipping/origin, in the default config.xml? My example don't work, only one setting was accepted.

Example of config.xml (identical in all my application realms)

<config>
 ...
 <default>
  <shipping>
  <origin>
   <country_id>DE</country_id>
   <region_id>82</region_id>
   <city>Berlin</city>
  </origin>
  </shipping>
 </default>
</config>

In this example only  is recognized in Magento-Admin-Backend, the other nodes not.

Have anybody an idea why this is happend?

Thanks and Greetings,
Pat


texts: RWD Default theme – configurable product options change prices on upsell products

texts:
I have a configurable Product in Magento, the theme is based on the rwd default, so it has all it's javascript included.

This configurable Product changes its price based on the selected option. That's fine but it also changes the price of the other configurable UPSELL products below. Why?

There is some javascript firing and i can't find anything where this is in and this makes absolutely no sense for me. I have configurable products as upsells below, with a "staring from ...$" prefix and the price should remain the same.

Anyone knows where this javascript is hiding?