texts:
I'm setting up a Magento Community install and this site creates orders but does not take any payments. hen checking out, it should ask for customer details, but not ask for payment details or show Paypal links etc. It has nothing to do with Paypal's Bill Me Later feature. Everything is handled on the company side as far as payments and invoicing. So I would just need customer adds items to their cart, they go to checkout, it asks to login or enter their customer details, then it just creates the order.

Is this possible with configuration or do you need a separate module?


texts: Magento2: How to get guest email address in checkout?

texts: Please, how to get guest email address in checkout?


texts: How to change template path hints colour and font size

texts:
Which file is responsible for the style of magento template path hints?
How can I change the colour and font size of the hints that are highlighted by a red background?


texts:
This is my situation:

I have a backup of an old website wich i used.
I'm creating a new website for a new purpose so i don't want to restore the old backup.

What i do want is to use a few extensions and a theme that was used in this website.
The company that created the website for us doesn't exist anymore, but the extensions were paid extensions, and also is the theme i want to use again.

How do i export these extensions and the theme so i can use it in my new website?

Thanks!


texts: Filter category products by quantity - Magento 2.3

texts:
My store allows backorders, so some of the products have quantity of 0.
I want to create a switch on the category page on front-end for "hide out of stock products" which filters out products

if quantity is <= 0 (or shows only products with qty between 1 and 9999999).

Is this possible?
All products are set "in stock" so I can't use the in stock / out of stock filter.


texts: how do I bootstrap a mysql upgrade installer?

texts:
I would appreciate help on this, I'm having trouble bringing these two together.

I am basically familiar with the mysql upgrade process in magento.

In a folder's etc/config.xml file you update the version

<Mycompany_Myextension>
    <version>0.1.4</version><!-- update from 0.1.3 -->
..

Write a file called `mysql4-upgrade-0.1.3-0.1.4.php
in that file have something like this:

  $installer = $this;

  $installer->run("Some SQL query here");

I want to run that outside of the Magento App, however...

So I have created a bootstrap file in /shell, but how do I instantiate $installer?  My bootstrap.php file is outside the same instantiation path as the mysql upgrade file.

Just for full docs, here is the shell file code (I have noted "throws fatal error" where the problem is):

<?php
/*
 * COMPANY-9047
 * @author: me
 * @date: 2016-04-29
 * Used to run a MySQL upgrade script outside of Magento
 */

require_once 'abstract.php';

class Company_Shell_Genericscript extends Mage_Shell_Abstract
{
    protected $_argname = array();

    public function __construct() {
        parent::__construct();

        // Time limit to infinity
        set_time_limit(0);

        // Get command line argument named "argname"
        // Accepts multiple values (comma separated)
        if($this->getArg('argname')) {
            $this->_argname = array_merge(
                $this->_argname,
                array_map(
                    'trim',
                    explode(',', $this->getArg('argname'))
                )
            );
        }
    }

    protected function _getConnection($type = 'core_read'){

        if ($this->blnUseMyEnvironment != false){
            return Mage::getSingleton('core/resource')->getConnection($type);
        }

        if (!$objConnection = Mage::getConfig()->getNode('global/resources/replica/connection') ) {
            Mage::throwException('Replica connection info is missing.');
        }

        try {
            $arrConnection = $objConnection->asArray();

            $objReplicaDb = new Zend_Db_Adapter_Pdo_Mysql(
                array(
                    'host' => $arrConnection['host'],
                    'username' => $arrConnection['username'],
                    'password' => $arrConnection['password'],
                    'dbname' => $arrConnection['dbname']
                )
            );

            return $objReplicaDb;

        }catch(Exception $e){
            echo $e->getMessage().", in ".__FILE__." on line ".$e->getLine()."\n\n";
        }

    }

    // Shell script point of entry
    public function run() {
        $db = Mage::getSingleton('core/resource')->getConnection('core_write');

        $this->startSetup(); //throws fatal error
        exit('end');

    }

    // Usage instructions
    public function usageHelp()
    {
        return <<<USAGE
Usage:  php -f scriptname.php -- [options]

  --argname <argvalue>       Argument description

  help                   This help

USAGE;
    }
}
// Instantiate
$shell = new Company_Shell_Genericscript();

// Initiate script
$shell->run();


texts: Upload image using Generic Form in Magento 2.3

texts:
I'm using Magento 2.3.4 to create a custom form this form I created is generated using generic form not the UiComponent form ,in this form i need to be able to up How to add an image input to Magento 2 generic form?

    $fieldset->addField(
        'title',
        'file',
        ['image' => 'title', 'label' => __('Image'), 'title' => __('Image'), 'required' => true]
    );


texts: SQL to get order items straight from the database?

texts:
How do we get a list of order items and their data (name, sku, quantity, price, weight, and dimensions)? Without using Magento's own framework components.

The problem is if the order contains 5 products I would get maybe 7 items from querying the table. This is caused by the different product types (simple, group, voucher, configurable, etc.) and different product ids so cannot be combined.

$items = array();

$sql = (
  "SELECT oi.name, oi.sku, oi.qty_ordered, oi.price, oi.weight
  FROM {$db->prefix}sales_flat_order_item oi
  WHERE oi.order_id = ". (int)$order_entity_id .";"
);

if ($result = $mysqli->query($sql)) {

  while ($row = $result->fetch_assoc()) {

    $items[] = [
      'name'                   => $row['name'],
      'sku'                    => $row['sku'],
      'quantity'               => (float)$row['qty_ordered'],
      'unit_price'             => (float)$row['price'],
      'unit_weight'            => (float)$row['weight'],
      //'unit_length'            => (float)$row['length'], // Not present?
      //'unit_width'             => (float)$row['width'], // Not present?
      //'unit_height'            => (float)$row['height'], // Not present?
    ];
  }

  $result->close();
}

If I pass a filter AND product_type = 'simple' to get only the simple products, they do not contain price.


texts: I need to know how can I display products in a page like (cart, below total) only few products by ID. Eg: products with id 2,3,4 and 5.


texts: Magento 2 how to create two controllers in the same module?

texts: I have created new module called 'Vendor/Modulename' in magento2. It is working fine. But i was unable to create a new custom controller and action in the same module.


texts: Creating custom attribute programmaticaly default value

texts:
How to set default value to "Yes" in generated select element? I created installation script and attribute is created perfectly. But on create/edit page of product I get No selected attribute for option.

<select class=" select" name="product[abroad_shipping]" id="abroad_shipping">
<option value="1">Yes</option>
<option selected="selected" value="0">No</option>
</select>

<?php

/* @var $this Mage_Core_Model_Resource_Setup */

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

/* @var $setup Mage_Eav_Model_Entity_Setup */
$setup = new Mage_Eav_Model_Entity_Setup('core_setup');

$entityTypeId = $setup->getEntityTypeId('catalog_product');
$setup->removeAttribute($entityTypeId, 'abroad_shipping');

$attributeData = array(
    'type' => 'int',
    'input' => 'select',
    'label' => 'Possible abroad shipping',
    'source' => 'eav/entity_attribute_source_boolean',
    'global' => Mage_Catalog_Model_Resource_Eav_Attribute::SCOPE_GLOBAL,
    'required' => false,
    'user_defined' => true,
    'default_value' => '1',
    'default' => array('1'),
//  'default' => '1',
//    'option' => array(
//        'values' =>
//        array(
//            0 => 'Yes',
//            1 => 'No'
//        )
//        ),
);

$setId = $setup->getAttributeSetId($entityTypeId, 'my_custom_set');
$groupId = $setup->getAttributeGroupId($entityTypeId, $setId, null);
$setup->addAttribute($entityTypeId, 'abroad_shipping', $attributeData);
$setup->addAttributeToGroup($entityTypeId, $setId, $groupId, 'abroad_shipping', 90);

$installer->endSetup();

I tried default, default value, integer default, string default, array. Nothing worked.


texts: Magento 2: Update the validation message on first name,last name,company, street address, city, state

texts: I want to update the validation message like by default we get This is required field but i want to update like for the firstname i want to fire the First name is required how can i do that?


texts: Remove Price Filter on certain categories

texts:
How can you remove the Price filter on certain categories?

The price filter doesn't always apply, so I need a way to remove it under certain conditions, such as the category name.

I've looked at the catalog_controller_category_init_after event, which I can then create an if statement for when the category name matches. But I've been unable to find a way to actually remove the price filter.


texts: How to display color swatch on home page slider magento 2

texts:
i have create custom module for product slider and i am using that module on homepage.
i want to display color swatch on home page , please guide me how to do that.
i am using getProductDetailsHtml($item) method for display swatch images , but this method not working
Thanks


texts: Notes don't show in Guest Order Lookup page

texts:
My site has the ability for logged-in customers to see orders in their Order History page and also a Guest Lookup where they can lookup an existing order putting in order number and last name.
The two reports are identical with one exception: Order Notes that we put in with "Visible On Storefront" checked will show up if you're looking at the order while logged in, but they do not show up when looking at the Guest Lookup page. I would like to change that so that the notes do show, but so far I'm having trouble tracking down where to make that change.
How could I change that setting that hides comments / notes while looking at the order through Guest view?


texts: In Magento2 RC, does every module and theme need to be pulled via composer?

texts:
I added registration.php to my custom (project specific) modules and themes. But those files do not end up in vendor/composer/autoload_files.php after composer.phar dumpautoload - so the modules are not registered.

How can I make my code in app/code and app/design known to Magento and/or composer to load the registration.php ?


texts: how can i update custom attribute value from customer

texts:
i need to update custom customer attribute value programmatically, i tried this:

  public function userapprove($id){
      $objectManager = \Magento\Framework\App\ObjectManager::getInstance();
      $customerobj = $this->objectManager->getById($id);
      $customerobj->setData('approve_account', 1);
      $this->objectManager->save($customerobj);
  }

but i see this error:

  Exception #0 (Exception): Notice: Undefined property: Module\custom\Block\Admin\Approve::$objectManager

what I am doing wrong?


texts: While configuring magento for the first time. When I try to set my base url to http://localhost it gives me an error.


texts: Magento 2 foreign key error saving configurable product

texts:
I created a Magento 2.0.2 store and used :

https://github.com/ubertheme/magento2_data_migration/releases

to import from my 1.9.2 store.  When i try to save one of my configurable products I get this error.

SQLSTATE[23000]: Integrity constraint violation: 1452 Cannot add or update a child row: a foreign key constraint fails (`gaxle_magento2`.`catalog_product_entity`, CONSTRAINT `CAT_PRD_ENTT_ATTR_SET_ID_EAV_ATTR_SET_ATTR_SET_ID` FOREIGN KEY (`attribute_set_id`) REFERENCES `eav_attribute_set` (`attribute_set_id`) O), query was: UPDATE `catalog_product_entity` SET `attribute_set_id` = ?, `type_id` = ?, `sku` = ?, `has_options` = ?, `required_options` = ?, `created_at` = '2013-02-07 06:18:07', `updated_at` = '2015-11-30 20:57:16' WHERE (`entity_id`=44)

I don't get this error saving all configurable products. Just this one from what i can tell.  Any ideas?


texts: Magento 2: Remove "active" class of search-bar on-click of mini cart?

texts: My problem is when I click on search button search bar open but when I click on mini cart search bar is still open, How to close search bar when I click on the mini cart, please help me.


texts:
In cms - pages there isn't a page for sites homepage. There is one that should be the homepage but disabling/editing it does nothing.

How to figure out where the homepage is getting it's content/design?


texts: Magento 2 : How to Change Product Price With Plugin

texts:
I want to change the product price on frontend programmatically with plugin in Magento 2.
Here is what I have done so far.

  app/code/Vendor/ModuleName/etc/frontend/di.xml

<config>
   <type name="Magento\Catalog\Model\Product">
       <plugin name="cache_price" type="Vendor\ModuleName\Plugin\Product" sortOrder="1" disabled="true"/>
   </type>
</config>

  app/code/Vendor/ModuleName/Plugin/Product.php

<?php
namespace Vendor\ModuleName\Plugin;

class Product
{
   public function afterGetPrice(\Magento\Catalog\Model\Product $subject, $result)
   {
    return $result + 100;
   }
}

  app/code/Vendor/ModuleName/etc/module.xml

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

But when I see the product page on frontend, nothing is changed in product price.
What I am doing wrong?


texts:
I need Quick Order button at product page like this website
Example Website
I have created button at my website using attribute and the following code

  app/design/frontend/Smartwave/theme/Magento_Catalog/templates/product/view

but button not open popup modal window like above example mention website

        <?php if($_product->getCustom_button()){ //yes or no button?>
    <button type="button"
                        title="<?php echo $_product->getCustom_button_name() ;?>"
                        class="action primary"
                        onclick="window.onload('<?php echo $_product->getCustom_button_url() ;?>')"><?php echo $_product->getCustom_button_name() ;?></button>
    <?php } ?>

my product page test url is URL Here
and image


texts:
Hi I'm trying to cxreate an API test for my custom  module and I'm getting this error:

  Fatal error: Class 'Magento\TestFramework\TestCase\WebapiAbstract' not
  found in
  /var/www/html/app/code/Wakanda/QuoteApi/Test/Api/CustomerQuoteTest.php
  on line 8

<?php

namespace Wakanda\QuoteApi\Test\Api;

use Magento\TestFramework\TestCase\WebapiAbstract;
use Magento\Framework\Webapi\Rest\Request;

class CustomerQuoteTest extends WebapiAbstract
{
    public function testGetList()
    {
        $serviceInfo = [
            'rest' => [
                'resourcePath' => '',
                'httpMethod' => Request::HTTP_METHOD_GET,
            ],
        ];

        $response = $this->_webApiCall($serviceInfo);

        $this->assertArrayHasKey('search_criteria', $response);
        $this->assertArrayHasKey('item', $response);

        $this->assertTrue($response['total_count'] > 0);
        $this->assertTrue(count($response['total_count']) > 0);

        $this->assertNotNull($response['items'][0]['name']);
    }
}

Any help will be appreciated


texts:
We have submitted the Magento 2 extension today, and it's failed the reason below result.
Earlier we Magento shown list of possible errors to rectify, Now can't find the same.
The result file as shown below.

 "commands": [
      {
        "command": "composerConfigRepository0",
        "output": "Finished with the \"0\" exit code."
      },
      {
        "command": "composerConfigKeys0",
        "output": "Finished with the \"0\" exit code."
      },
      {
        "command": "echo \"127.0.0.1 magento2.docker\" >> /etc/hosts",
        "output": "Finished with the \"0\" exit code. Process output: \"\"."
      },
      {
        "command": "cp /usr/share/eqp/VarnishMftfTool/etc/varnish-config/magento-fixtures-profile.xml /usr/share/eqp-varnish-mftf/magento/magento-fixtures-profile.xml",
        "output": "Finished with the \"0\" exit code. Process output: \"\"."
      },
      {
        "command": "docker-compose -f docker-compose.yml down --volumes",
        "output": "Finished with the \"0\" exit code. Process output: \"\"."
      },
      {
        "command": "docker-compose -f docker-compose.yml up --detach --no-color",
        "output": "Finished with the \"0\" exit code. Process output: \"10.2: Pulling from library/mariadb\nDigest: sha256:187b02ad495b0cc95662f3382bf8a811319b54d224bd12d24919988137de7cb9\nStatus: Downloaded newer image
        for 126150169089.dkr.ecr.us-east-1.amazonaws.com/library/mariadb:10.2\n5.0: Pulling from library/redis\nDigest: sha256:12664f201c777d41247ec863bf92cb8145381c0de4fcabfb58f3c61f6ff2dd3e\nStatus:
        .......................
        ....
                    Pulling from mailhog/mailhog\nDigest: sha256:8d76a3d4ffa32a3661311944007a415332c4bb855657f4f6c57996405c009bea\nStatus: Downloaded newer image for 126150169089.dkr.ecr.us-east-1.amazonaws.com/mailhog/mailhog:latest\n\"."
      },
      {
        "command": "docker-compose -f docker-compose.yml run --rm build composer require --no-ansi abcsolutions/module-dynamics365:2.2.0",
        "output": "Finished with the \"0\" exit code. Process output: \"composer/package-versions-deprecated: Generating version class...\ncomposer/package-versions-deprecated: ...done generating version class\nStarting schema dist file generation\nDist file was successfully generated: /app/.magento.env.md\n\"."
      },
      {
        "command": "docker-compose -f docker-compose.yml run --rm build cloud-build",
        "output": "Finished with the \"1\" exit code. Process output: \"Creating magento_build_run ... \r\n\u001b[1A\u001b[2K\rCreating magento_build_run ...
        .. - Installing abcsolutions/module-dynamics365 (2.2.0): Loading from cache\nPackage container-interop/container-interop is abandoned, \n\nrun <scenario>...\n\n\"."
      }

    ]

I am unable to know the exact error.
Can you please suggest me what is the issue/reason? here


texts: Displaying Call for Price on configurable products

texts:
I have many configurable products on a site and some of the options on those

products need to say Call for Price instead of having a price.

From a previous question I added the following code:

<?php if ($_product->getFinalPrice() == 0) : ?>

Call For Price

<?php else: ?>
    <?php echo $this->getPriceHtml($_product); ?>
<?php endif; ?>

This works for simple products but not for configurables because it doesn't change when the ajax updates the price.


texts: Time to first Byte takes over 3 seconds on home page, Fully load time 14s - Magento 2

texts:
The site was working fine until recently, the loading speed has dramatically increase, visitor get Internal 500 from time to time. First i thought it was the recent extension I installed, Marisvit Rewards, but after i disabled the extension, it is still very slow to load. Right now, i'm running out of ideas, below are what i done. Hopefully someone can direct me where to look into. Thank you.

I am using SiteGround Cloud hosting 3 CPU with 8G RAM, and made sure .htaccess and .phi.ini memory_limit are correct
I have use magento js and css merging, minify, and bundling to decrease the request from ~300 to ~100.
I have enabled gzip compression
I am using CDN from cloudflare
I have enabled memcached
I have cloned the exact site to develop.gofanco.com on the same hosting, installed the same extension ( without further js/css optimization & without CDN), even that it runs faster than my live site! very weird..

below is from gtmetrix:
https://gtmetrix.com/reports/www.gofanco.com/wAMHMWR4 ( live site)
https://gtmetrix.com/reports/develop.gofanco.com/FkZg8iIV ( test site)

below is output from magento profiler, i'm not exactly sure how to find the cause of the issue.


texts:
We are facing the issue While importing the categories

The header field store is not a valid one.

Can anyone help me how to resolve this issue.

Thanks..!


texts: Magento 2 : From where and how does knockout retrieve data on checkout

texts:
I know the following:

That checkout is done with knockoutjs.
Somehow data from PHP is passed to knockoutjs

Where is this passing made ?

If we look at project-root/vendor/magento/module-checkout/view/frontend/web/js/checkout-data.js

getData = function () {
            var data = storage.get(cacheKey)();

            if ($.isEmptyObject(data)) {
                data = {
                    'selectedShippingAddress': null, //Selected shipping address pulled from persistence storage
                    'shippingAddressFromData': null, //Shipping address pulled from persistence storage
                    'newCustomerShippingAddress': null, //Shipping address pulled from persistence storage for customer
                    'selectedShippingRate': null, //Shipping rate pulled from persistence storage
                    'selectedPaymentMethod': null, //Payment method pulled from persistence storage
                    'selectedBillingAddress': null, //Selected billing address pulled from persistence storage
                    'billingAddressFromData': null, //Billing address pulled from persistence storage
                    'newCustomerBillingAddress': null //Billing address pulled from persistence storage for new customer
                };
                saveData(data);
            }

            return data;
        };

What/Where is this persistence storage and how can I manipulate the data that is being fed to knockout


texts: Random display of products in a category, filter , or search

texts:
how to show products in a category randomly, as well as when using a filter, also show products randomly by default.
And displaying Search results in a random order


texts: How to get product name and image name from database using query?

texts:
I want to get product name and it's image url from the database in single query. I am using following query. I am able to get product name using attribute_id 73 but i have problem to fetch image name using attribute_id 88.

Query

select product.value as name from catalog_product_entity_varchar as product join catalog_category_product as category on product.entity_id=category.product_id where product.store_id=0 and product.attribute_id=73 and product.attribute_id=88 and category.category_id=3


texts:
So I have made a new category and copied all settings from another working category with a new name and url etc but I get a 404 when hitting the category frontend.

When trying to debug this I have found the following...

#File: app/code/core/Mage/Catalog/controllers/CategoryController.php
if (!Mage::helper('catalog/category')->canShow($category)) {
    return false;
}

The CanShow function above returns false when I hit the category.

When looking at the below file you can see my comments regarding what is happening:

#File: app/code/core/Mage/Catalog/Helper/Category.php
public function canShow($category)
{
    if (is_int($category)) {
        $category = Mage::getModel('catalog/category')->load($category);
        //THIS $category VARIABLE IS NOT SET
    }

    if (!$category->getId()) {
        return false;
        //NOT RETURNED FASLE
    }

    if (!$category->getIsActive()) {
        return false;
        //NOT RETURNED FASLE
    }
    if (!$category->isInRootCategoryList()) {
        return false;
        //NOT RETURNED FASLE
    }

    return true;
    //RETURNS TRUE BUT NO $category IS SET
}

If I visit a product inside the category it works fine and the category URL is in the URL e.g. /shop/categoryname/product-url/

I have flushed the cache and reindexed etc.

Can anyone offer any advice on what I can do to stop this 404? Other categories created in the past are working fine, only new ones are affected!


texts: CE1.9.2 - Custom Menu - Replace Layout block

texts:
I've just written a small custom menu module for a site I'm working on, and need it to replace the current base/default catalog.topnav. My module's config.xml looks like this:

<?xml version="1.0"?>
<config>
    <modules>
        <Magz_MyMenu>
            <version>0.1.0</version>
        </Magz_MyMenu>
    </modules>
    <frontend>
        <layout>
            <updates>
                <mymenu module="mymenu">
                    <file>magz_mymenu.xml</file>
                </mymenu>
            </updates>
        </layout>
    </frontend>
    <global>
        ...
        <blocks>
            <page>
                <rewrite>
                    <html_topmenu>Magz_MyMenu_Block_Html_Topmenu</html_topmenu>
                </rewrite>
            </page>
        </blocks>
        ...
    </global>
</config>

... and my layout update file magz_mymenu.xml is as follows:

<?xml version="1.0"?>
<layout>
    <default>
        <reference name="top.menu">
            <action method="unsetChild"><name>catalog.topnav</name></action>
            <block type="page/html_topmenu" name="catalog.topnav" template="magz/page/html/topmenu.phtml"/>
        </reference>
    </default>
</layout>

Now this currently works and renders as it should on the frontend, but I want to know:

Am I doing this correctly?
Is there a difference between action method="unsetChild" and remove name=?

Thank you


texts: I have a client who recently implemented SAP using the "Insync" module. The Magento app is showing the timezone correctly but the db is showing the timestamps in UTC. The folks at Insync say we need to correct the issue. Is there a way to change how timestamps are created?


texts: Check condition in the email templates in magento

texts:
I had passed custom variable to invoice email template and i checked by calling that variable in the invoice template with following code

{{var isused}} and the values is printing in the email template.

Now actually what i want to do is i want to check the variable and accordingly if it is true i need to print the text in the email template.

so i had used following code in the text area in the email template

{{if isused == 'yes'}}

        Hello I m in the if

{{/if}}

now i isused variable value is yes i am sure but the condition is not getting true and not printing the text

Please Help Me


texts: Remove fields and validations for street and city in checkout

texts: I am trying to remove street and city field from checkout on Magento 2.3.5-p1 but the validation is throwing me an error for required city and street. I have tried to add a value in the DB eav_attribute for city and street but nothing. I have added lines in billing and shipping at vendor/magento/module-checkout/... False for city and street as mentioned in other questions here on stack but nothing... Did anyone has a working solution?


texts: Displaying a "smart" search box in your website's header

texts:
I am working on a Magento 2.1.7 shop. To achieve this, I have created a child-theme of Magento Blank.

I have installed and enabled the Magento 2.0 SmartSearch and I want to display the search bar, which currently does not display anywhere, above the top links, like the screenshot indicates:

In app/code/Sebwite/SmartSearch/view/frontend/layout/default.xml I have added this line <move element="top.search" destination="header-wrapper" before="top.links"/>:

<referenceContainer name="header-wrapper">
  <referenceBlock name="top.search">
    <arguments>
      <argument name="template" xsi:type="string">Sebwite/SmartSeach/templates/form.mini.phtml</argument>
    </arguments>
  </referenceBlock>
</referenceContainer>
<move element="top.search" destination="header-wrapper" before="top.links"/>

But no change occurred.

Inside the same file, the logo blook looks like this:

<referenceContainer name="header.container" htmlId="siteHeader" htmlClass="panel wrapper fullwidth">
  <container name="header-wrapper" label="Page Header" as="header-wrapper" htmlTag="div" htmlClass="header content">
    <block class="Magento\Theme\Block\Html\Header\Logo" name="logo">
      <arguments>
        <argument name="logo_file" xsi:type="string">images/logo.png</argument>
        <argument name="logo_img_width" xsi:type="number">263</argument>
        <argument name="logo_img_height" xsi:type="number">85</argument>
      </arguments>
    </block>
  </container>
</referenceContainer>

Is there anything I can add to it to display the search box, who's template is app/code/Sebwite/SmartSearch/view/frontend/templates/form.mini.phtml inside the logo block? I would then only have to float it right.


texts: Difference between $this->helper and Mage::helper

texts:
Is the following codes in the  phtml $this->helper('catalog/category') and Mage::helper('catalog/category') returns the same object?

What is the meaning of using $this->helper() and Mage::helper()?


texts:
This is in Magento 1.9.x.

I just edited the contents of a transaction email, added some HTML code into it, but the email is still rendering as plain text.

How do I make that email into a HTML email?

Here is how it looks in Magento:

The email contains HTML tags, but it's template type is Text.

I cannot find anywhere to either (a) change this template type to HTML OR (b) create a new HTML template.

This is the email content:

Web Enquiry Form

Name:	{{var data.name}}

Email:	{{var data.email}}

Telephone:	{{var data.telephone}}

Company:	{{var data.company}}

Interested in:	{{var data.interest}}

Quote Required:	{{var data.request_quote}}

Info Required:	{{var data.request_info}}

Call-back Required:	{{var data.request_callback}}

Message:	{{var data.comment}}

And this is what it looks like in my email client. None of the HTML is being rendered. My problem here is I cant find anything in Magento's Admin Panel that could create a HTML email or change this to a HTML email.

Can anyone help?


texts: isntalling marketplace extension on magento 2.2

texts:
i want to install marketplace extension on magento 2.2 but don't know how.
i've opend my ssh but what to do now?
or do i have to upload this extension's files directly on cPanel? If yes, then please tell me the path where the file of extension should be uploaded.
can anyone help me with this?


texts:
I'm trying to use the model in magento to show a listing of a custom table within my module. The model works and shows the listing table in the model. I can see that the get request is getting data, but it appears to be in an incorrect format. I have tested first with an example from the Magento documentation that set the data in the file UI/Component/CustomDataProvider.php as follows.

/**
 * Get data
 *
 * @return array
 */
public function getData()
{
    return [
        'items' => [
            [
                'id' => 1,
                'name' => 'First Item'
            ],
            [
                'id' => 2,
                'name' => 'Second Item'
            ],
            [
                'id' => 3,
                'name' => 'Third Item'
            ]
        ],
        'totalRecords' => 3
    ];
}

This populates the form as expected. After this I have tried to manipulate the file to show data from my custom table. The code is as follow:

<?php

declare(strict_types=1);

namespace Dsssolutions\Management\Ui\Component\Listing;

use DssSolutions\Management\Model\ResourceModel\VendorProducts\CollectionFactory;
use Magento\Framework\App\Request\DataPersistorInterface;
use Magento\Framework\View\Element\UiComponent\DataProvider\DataProvider;

/**
 * Class CustomDataProvider
 */
class CustomDataProvider extends \Magento\Ui\DataProvider\AbstractDataProvider
//class CustomDataProvider extends DataProvider
{
protected $dataPersistor;

protected $collection;

protected $loadedData;

/**
 * Constructor
 *
 * @param string $name
 * @param string $primaryFieldName
 * @param string $requestFieldName
 * @param CollectionFactory $collectionFactory
 * @param DataPersistorInterface $dataPersistor
 * @param array $meta
 * @param array $data
 */
public function __construct(
    $name,
    $primaryFieldName,
    $requestFieldName,
    CollectionFactory $collectionFactory,
    DataPersistorInterface $dataPersistor,
    array $meta = [],
    array $data = []
) {
    $this->collection = $collectionFactory->create();
    $this->dataPersistor = $dataPersistor;
    parent::__construct($name, $primaryFieldName, $requestFieldName, $meta, $data);
}

/**
 * Get data
 *
 * @return array
 */
public function getData()
{
    if (isset($this->loadedData)) {
        return $this->loadedData;
    }

    $items = $this->collection->getItems();
    foreach ($items as $model) {
        $this->loadedData[$model->getId()] = $model->getData();
    }

    $data = $this->dataPersistor->get('dsssolutions_management_vendorproducts');

    if (!empty($data)) {
        $model = $this->collection->getNewEmptyItem();
        $model->setData($data);
        $this->loadedData[$model->getId()] = $model->getData();
        $this->dataPersistor->clear('dsssolutions_management_vendorproducts');
    }

    //return $this->loadedData;
    return array('totalRecords' => $this->collection->count(), 'items' => $this->loadedData);
}
}

This does not populate the form and give the message "No data found" while I do see data in the request. The difference I see between the Magento 2 example and the data from my script is that the items in the get is in my example an object. I believe that this is the root cause, but do not understand how to change this.

Outcome get with preset data

Outcome with my script

Hopefully somebody can help me to understand what I need to change to get the products displaying in the listing.

PS I noticed that when I filter on name I also don't get results, but when I disable the filter again I do get 2221 lines in the table, but all with the same name.

Thanks in advance.


texts:
I want to run indexing in magento 1.3 but i dont find indexing option in system tab.
Whats the issue?
how can we run indexing through command in magento 1.3


texts: Why is custom component not displayed in checkout in Magento2

texts:
I thought adding a simple text to the checkout is easy. I read the docs and this also seemed to be easy.
Now I'm stuck..
I want it to show after the shipping methods first. Now I would be happy if it at least shows up anywhere on checkout :)

I created a module with is registered correctly (it contains two plugins which are already working).

Now I added my checkout_index_index.xml in app/code/Me/Mymodule/view/frontend/layout/ with the following content:

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
        xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">

        <referenceBlock name="checkout.root">
            <arguments>
                <argument name="jsLayout" xsi:type="array">
                    <item name="components" xsi:type="array">
                        <item name="checkout" xsi:type="array">
                            <item name="children" xsi:type="array">
                                <item name="steps" xsi:type="array">
                                    <item name="children" xsi:type="array">
                                        <item name="shipping-step" xsi:type="array">
                                            <item name="children" xsi:type="array">
                                                <item name="me-mymodule-notice" xsi:type="array">
                                                    <item name="component" xsi:type="string">Me_Mymodule/js/view/checkout/shipping/item-notice</item>
                                                </item>
                                            </item>
                                        </item>
                                    </item>
                                </item>
                            </item>
                        </item>
                    </item>
                </argument>
            </arguments>
        </referenceBlock>

</page>

For the component I created a JS File here: app/code/Me/Mymodule/view/web/js/view/checkout/shipping/item-notice.js using this code:

define([
    'uiComponent',
    'Magento_Shipping/js/model/config'
    'mage/translate'
], function (Component, config, $t) {
    'use strict';
    return Component.extend({
        defaults: {
            template: 'Me_Mymodule/checkout/shipping/notice'
        },
        config: config()
    });
});

As of the template definition above, I created a template in: app/code/Me/Mymodule/view/web/template/checkout/shipping/notice.html:

        THIS IS A TEST

What am I missing?


texts: i am trying to update JQuery on mageneto 1 but i don't know complete steps can someone guide me for that


texts: custom redirect to home page not working in magento 1.7

texts:
what iam trying to achieve is : to redirect a cms page to home page;
the cms page is accessible by domain.com/home
what i need is to redirect to domain/

i had already created a custom url rewrite rule from magento admin

ID Path :home(this is the url key of the cms page & this page is accessible via domain/home)
Request Path :domain/home
Target Path : domain
Redirect : Permanent 301

But no luck ! im still getting the same cms page (No redirection ) tried clearing cache but still the same result.


texts: PHP 7.0.12 to PHP 7.0.1 Image upload broken "Upload HTTP Error"

texts:
OK so for the last year I have been using PHP 7.0.1 with my Magento website and it has been great. now all of a sudden, Plesk has updated it to 7.0.12 and now the image upload is not working.

Is there a way to specify that I want it to use PHP 7.0.1 or am i too late?

Failing that, I am guessing some code in my magento uploader is outdated. What Can I change to get My Magento website(uploader) to work with PHP 7.0.12.

I am sure this will be asked a lot in the next few months but I think this issue is a new issue.


texts: how to remove the customer login page text

texts:
how do I remove the text? or how should I overwrite existing xml file?
Please help. I did try to override the file, but not work. Not sure I place the file into correct place or not. If I update XML, seems I have to run the setup:upgrade right?
Please help, thanks


texts: Exception error while uninstalling extensions

texts:
I have installed couple of extensions in my project ,but later i
uninstalled by deleting folders from app/code and also from the database.now im getting exception  errors on frontend.


texts:
I need to a CSS file based on customer attribute when the user is logged.

How can I do this ?

Readed this : https://mage2.pro/t/topic/140 but it's based on backend config.


texts: Full Error Message Not Truncated Magento 2

texts:
Basically the same as this question: https://stackoverflow.com/questions/12356260/magento-how-to-show-full-error-message-instead-of-truncated-one but for Magento 2

I searched for this function but didn't see it not sure where the errors are being truncated at.


texts: HTML files not being overwritten in app/Design

texts:
I'm trying to override html files the same way that I would override a phtml file, but it doesn't seem to be working. Same with Javascript.
I'm trying to change some logic in minicart.js.
I put my file into app/design/frontend/<Vendor>/<Theme>/Magento_Checkout/view/frontend/web/js/view/minicart.js
Original file in vendor/magento/module-checkout/view/frontend/web/js/view/minicart.js
I cleared all of the caches and disabled my browser cache, but when I search for minicart.js in the network tab, it's still the original file.
Same issue with HTML files.
No issue at all with phtml files at all.
Based on the docs, this sounds like it should work seamlessly
Any ideas?
Thanks


texts: Magento 2 : Call Model Class in the default value for UpdateData.php

texts:
I have part of setup code in the setup/upgradeData.php to be like this :

 $dataSetup->addAttribute(
            'vendor', 'allowed_type', array(
                'group'             => 'General Information',
                'visible'           => true,
                'required'          => false,
                'global'            => \Magento\Eav\Model\Entity\Attribute\ScopedAttributeInterface::SCOPE_GLOBAL,
                'type'              => 'text',
                'input'             => 'multiselect',

                'source'            => 'Test\Market\Model\Vendor\Attribute\Source\Offer',
                'backend'           => 'Magento\Eav\Model\Entity\Attribute\Backend\ArrayBackend',
                'default'           => <some_of_values>,

                'label'             => 'Allowed Type',
                'sort_order'        => 300
            )
        );

then in the default part, I want to add value by calling model like this :

'default' => [VendorName]\[ModuleName]\Model\ClassName,

is it possible? if yes how can I write the class?


texts: Magento 2.3 Single Page in Admin will not load

texts:
I am trying to access Content -> Configuration -> Edit (my theme name) but as soon as i hit edit the page will load but get stuck on an Ajax loader gif. See screenshot.

I have cleared out the cache, cleared static content etc to no avail. Any idea?

Here's a copy of the browser console

JQMIGRATE: Migrate is installed with logging active, version 1.4.1
file-uploader.js:173 Uncaught ReferenceError: Base64 is not defined
    at UiClass.processFile (file-uploader.js:173)
    at Array.map (<anonymous>)
    at UiClass.setInitialValue (file-uploader.js:78)
    at UiClass.initialize (abstract.js:77)
    at UiClass.initialize (wrapper.js:109)
    at new UiClass (class.js:49)
    at Object.initComponent (layout.js:137)
    at fire (jquery.js:3232)
    at Object.fireWith [as resolveWith] (jquery.js:3362)
    at Object.deferred

(/maxcb/theme/design_config/edit/scope/stores/scope_id/1/key/ce4569e5b0258a5cf79d478b35922f4fd13fef7de215572ccdbf1bba235d09f6/anonymous function) (http://www.xxx.co.uk/pub/static/version1546980063/adminhtml/Magento/backend/en_GB/jquery.js:3461:37)


texts: Maximum execution time of 300 seconds exceeded error

texts:
When I delete many products, I got this error

  Fatal error: Maximum execution time of 300 seconds exceeded in
  /magento_1.8.1/www/lib/Zend/Cache/Backend/File.php on line 655

Server php and .htaccess setting value are 1800

  cat /php/lib/php.ini |grep max_execution_time

  max_execution_time = 1800

  cat /magento_1.8.1/www/.htaccess|grep max_execution_time

  php_value max_execution_time 1800

What should I check?

php 7.0.16 , Magento 1.8.1

Thanks!


texts: Why i ran bin/magento cache:flush after need sudo chmod -R -v 777 generated var pub

texts:
I am using 2.2.4 Magento when I ran the this command every time bin/Magento cache:flushafter. I need  sudo chmod -R -v 777 generated var pub, if not it will error.

how can I Solve this problem, thank you very much!!


texts: How do I load custom CSS for a widget only when the widget is used?

texts:
I have a custom widget for the product page (catalog product view). How can I load the custom CSS file into the head only when the Widget is actually placed on the page?
I am looking for a best practice method.


texts: Magento 2: Mass Delete PHP code not Working

texts:
I'm very new to Magento, i created a Mass Action for Delete i write this code in /EC/Downloads/view/adminhtml/ui_component/ec_downloads_items.xml

<?xml version="1.0"?>
<listing xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Ui:etc/ui_configuration.xsd">
    <listingToolbar name="listing_top">
        <settings>
            <sticky>true</sticky>
        </settings>
        <paging name="listing_paging"/>
        <filters name="listing_filters"/>

        <massaction name="listing_massaction">
            <action name="delete">
                <settings>
                    <confirm>
                        <message translate="true">Delete selected items?</message>
                        <title translate="true">Delete items</title>
                    </confirm>
                    <url path="*/items/MassDelete"/>
                    <type>delete</type>
                    <label translate="true">Delete</label>
                </settings>
            </action>
        </massaction>
    </listingToolbar>

    <columns name="ec_downloads_items_columns">
        <selectionsColumn name="ids">
            <argument name="data" xsi:type="array">
                <item name="config" xsi:type="array">
                    <item name="resizeEnabled" xsi:type="boolean">false</item>
                    <item name="resizeDefaultWidth" xsi:type="string">55</item>
                    <item name="indexField" xsi:type="string">downloads_id</item>
                    <item name="sortOrder" xsi:type="number">10</item>
                </item>
            </argument>
        </selectionsColumn>

        <column name="downloads_id">.......</column>

    </columns>
</listing>

and this code in /EC/Downloads/Controller/Adminhtml/Items/MassDelete.php

<?php
namespace EC\Downloads\Controller\Adminhtml\Items;

use Magento\Backend\App\Action;

/**
 * Class MassDelete
 */
class MassDelete extends \Magento\Backend\App\Action
{
    /**
     * @return \Magento\Backend\Model\View\Result\Redirect
     */
    public function execute()
    {
        $ids = $this->getRequest()->getParam('downloads_id');
        echo $ids;
        exit;

        if (!is_array($ids) || empty($ids)) {
            echo 'Bad';
            exit;

            $this->messageManager->addError(__('Please select Item.'));
        } else {
            echo 'Good';
            exit;

            try {
                foreach ($ids as $id) {
                    $emp = $this->_objectManager->get('EC\Downloads\Model\Downloads')->load($id);
                    $emp->delete();
                }
                $this->messageManager->addSuccess(
                    __('A total of %1 record(s) have been deleted.', count($ids))
                );
            } catch (\Exception $e) {
                $this->messageManager->addError($e->getMessage());
            }
        }
        return $this->resultRedirectFactory->create()->setPath('downloads/index/items');
    }
}

code in /EC/Downloads/Model/ResourceModel/Items.php

<?php

namespace EC\Downloads\Model\ResourceModel;
/**
 * Class Items
 * @package EC\Downloads\Model\ResourceModel
 */
class Items extends \Magento\Framework\Model\ResourceModel\Db\AbstractDb
{
    /**
     *
     */
    protected function _construct()
    {
        $this->_init('downloads', 'downloads_id');
    }
}

When i try to delete more items it's not working, when i try to echo|exit, i found that i dosen't go to the delete part coz ids is empty.


texts: Magento 2.4 Commerce cloud - After push the code from dev to live server less not compiled to css file

texts:
I have created a custom theme, for the listing page i have created custom less file,
app\design\frontend\Zero\my_theme\Magento_Catalog\web\css\source\ _custom_listing_page.less
On the Website listing page my _custom_listing_page.less not working. which means not compiled into CSS file.
I have declared my _custom_listing_page.less in app\design\frontend\Zero\sleepworld\my_theme\layout\catalog_category_view.xml
   <head>
   <css src="Magento_Catalog::css/source/_custom_listing_page.css" rel="stylesheet" type="text/css" />
   </head>

Console error - CSS file : canceled

Note : Local working good, when i move to live then i am getting the error.


texts: Export functionality not working properly with EAV UI Grid

texts:
I have added Export button on UI grid in my custom module. Module is create with EAV structure. But when i try to export in CSV only ID Column's data is export, Other column's data are missing.

I have added code for export button on Grid in listing file.

  ../view/adminhtml/ui_component/demo_templatetext_templatetext_listing.xml

<exportButton name="export_button">
    <argument name="data" xsi:type="array">
        <item name="config" xsi:type="array">
            <item name="selectProvider" xsi:type="string">demo_templatetext_templatetext_listing.demo_templatetext_templatetext_listing.demo_templatetext_templatetext_columns.ids</item>
        </item>
    </argument>
</exportButton>

I'm using eav structure for my custom module & csv exported only one column

Can anybody help me to solved this issue? Thanks.


texts: Flash messages always are empty after call AJAX POST

texts:
I used Full Page cache for my page. After I register newsletter I get flash message "successfully" and its ok

But after I installed some modules, they can ajax POST and the private-cache-content via is invalidate with empty messages so the Flash Message is disappeared.

Example when I call POST ajax, they also call customer/section/load/?sections=&update_section_id=true&_=1520414104652 and response data is messages:
{messages: [], data_id: 1520414104652}

I read how customer sections.xml work, and I found on Magento\Theme\etc\frontend\sections.xml always update messages with any action

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

So how can i keep my messages?

Thank you!


texts: Is it possible to show the ordered items and shipping method on the success page?

texts:
I wanna customize the success page because is very poor of information, so I would like to bring on page the order status, ordered items table, shipping address and shipping method details, like here: http://www.magentocommerce.com/magento-connect/media/catalog/product/cache/9/image/725x680/9df78eab33525d08d6e5fb8d27136e95/f/r/fr_1.png

Additionally, I've heard that some things changed on the magento 1.9 core, so, how to break session in order to edit CSS and refresh the page without redirects?

Can someone help me?


texts: How to remove items from quote using observer whenever quote is loaded?

texts:
My cart page is broken because of disabled products in the cart. The disabled products remained in the cart for some of my customer in below scenario:

Customer added product (enabled product) in his cart and left the cart.
The product was disabled next day as it was out-of-stock.
Customer returned back after a week using the same session/cart.
Since the product that was already in his cart was disabled the cart page is some how broken.

I want to remove those disabled  product from quote items when ever cart is loaded for the customer.Please let me know what observer i can use to know the cart is loaded or any other better way to resolve the issue?

Whenever there is disabled product in the cart, the sales_flat_quote_item table has only one record (for configurable only) for the product. In normal case this table will have two records one as configurable and another as simple for each quote. I actually wanted to remove such single record line form the table caused because of disabled products but i  do not want to do this through SQL.


texts: How to replace froogaloop2.min.js for product videos?

texts:
The videoes on my products have stopped working. And I have found that it's froogaloop2.min.js being the problem. The trouble is, this is an external file and I have seen that it has been retired here and how to update it...

But the problem is, I don't know where I update this in magento. Would anyone be able to provide some guidance/a tutorial on how to do this? I just can't find any file that even calls the froogaloop file.

I am on Magento 2.2.0


texts: Difference between Session and SessionFactory in Magento 2

texts:
While working i found there are two methods of getting customer data using two session classes
1.) \Magento\Customer\Model\SessionFactory $customerSession
2.) \Magento\Customer\Model\Session $customerSession

Most posts prefers to use the second one but does not work when Full Page Cache is enable.

So what is the best method for practice.

Thanks.


texts: magento2 how to order email template in order id pass in anchor tag

texts:
I want to dynamic order id pass in anchor tag

        {{trans 'To make changes to your order, you can  whatsapp us' with your order number
        increment_id=| raw after 123}}

and whatsapp link text like

  Order ######  Hello, Magento. I have an order and would need some
  assistance with it

how can achieve that?

Any help would be appreciated.

Thanks.


texts:
I have implemented free shipping with minimum order order 40.00 and also flat shipping for when free shipping not apply but when free shipping case true then it is shipping all methods.but i need only free shipping there.

On true condition of free shipping don't show other methods in magento , kindly help me how to do here is my site link
http://rainegoh.com/meirenstudio/index.php/

I am not aware of magento code


texts: Magento 2.1.2 Adding product will result to exception errors

texts:
When I go to the backend of the site and navigate to products>catalog and click the add product button it will generate some errors.

I hope someone can help me with this problem.

Thanks.


texts: Does the shopping cart model encapsulate shopping cart items?

texts:
I'm currently preparing to take my Magento Certified Developer test next Tuesday. A couple of the practice tests I have encountered have the following question:

  Which object never encapsulates any shopping cart items?
  A. Mage_Checkout_Model_Cart
  B. Mage_Sales_Model_Quote
  C. Mage_Sales_Model_Quote_Address<type=shipping>
  D. Mage_Sales_Model_Quote_Address<type=billing>
  Answer: B

Why would that be the correct answer? Mage_Sales_Model_Quote has shopping cart items that are associated with it ($_items property, getAllItems() and getItemsCollection() methods). Perhaps I don't properly understand what is meant by encapsulation - what would be the meaning of encapsulation in this context?


texts: How to test/debug Ess_M2ePro Amazon integration?

texts:
How do you create test orders and test the workflow of this extension for Amazon integration in a test environment?

I was told there is no possibility to create test orders and although I was told by support that it is possible to import the real orders into multiple environments without affecting the live system (means: if an order is imported in the test environment it still will also be imported in the live environment) this doesn't work like I imagine it should at all.

When I execute the cron job in the test environment sometimes a few orders are imported but I cannot tell why sometimes orders are imported and sometimes not. The cronjob runs quite some time (> 100 seconds) but I end up without any new orders most of the time.

At the same time hundreds of orders are created by customers so there should be plenty to import.

[Update] It was pointed out to me that the frequency / delay of imports may be influenced by the load at Amazon. I didn't think about that. The other points (is it possible to create test orders / is there a sandbox / how do you debug the extension) are still valid. [/Update]

This makes it impossible to debug problems with the extension. The support returns not-so-helpful one-line answers so I'm turning to the community to help me out on this: what are your best practices?


texts: How to create an email shot in magento 2?

texts: Guys I need to create a type of e-mail trigger, that I don't think is in magento 2. I need the user to click on a button, so that it should send an e-mail to the user. I don't know where to start, does anyone know any content that I can read about, about how to create a module to send e-mail? I tried to find it and I couldn't, if anyone knows of any content or something that I can read, it will help me a lot.


texts:
I added the GA tracking code on my website. I see users in real time. Then I enable the e-commerce module. I would like to see all the purchases in GA in our store.
Unfortunately, this data is not transferred to GA. How can I do this?

GA:


texts: Prototype keep checkbox selected after page reload

texts:
I am using prototype in Magento custom module and have a requirement to keep the checkbox selected after page reload if its clicked. The scenarios are as under:

Keep checkbox unchecked when the page loads first time.
If user clicks on checkbox and reload the page, keep the checkbox
selected.
If user unchecks and reload the page, keep the checkbox unchecked.

How could I achieve this using prototype ?

Thanks


texts:
On Magento 1, I can create a promotion to apply a discount with a discount step quantity. How can I create a discount for price steps?

For example:
every 500$ of 50$ discount.

501$ = Total 451$
1020$ = Total 920$
1300$ = Total 1200$
etc.


texts: help with adding custom fields to invoice pdf

texts:
I want to add custom field to invoice pdf I am able to do it.

But problem is that my text gets overlapped with previous content. I think I need to increase rectangle with to do it but could not figure it out.

Ii just want to add text in the format :

Custiomer  Vat/ Tax number : ABD

below order date.

What I did to make it work:

/app/code/core/Mage/Sales/Model/Order/Pdf/Abstract.php

changed this

$page->drawText(
    Mage::helper('sales')->__('Order Date: ') . Mage::helper('core')->formatDate(
        $order->getCreatedAtStoreDate(), 'medium', false
    ),
    35,
    ($top -= 15),
    'UTF-8'
);

to

    $page->drawText(
        Mage::helper('sales')->__('Order Date: ') . Mage::helper('core')->formatDate(
            $order->getCreatedAtStoreDate(), 'medium', false
        ),
        35,
        ($top -= 15),
        'UTF-8'
    );

$page->drawText(
            Mage::helper('sales')->__('Tax/Vat Number: ') .'ABC',
            35,
            ($top -= 15),
            'UTF-8'
        );

but my content gets cut pls help


texts: How can we apply ACL for an attribute in product edit form

texts:
Hello I have an query I have created a new product attribute
Stores - Attributes - Product

I wonder how can make my attribute visible only for special admin user (not for all: even they can use product edit form).
What if I create this attribute programmaticlly


texts: Magento 2.3 removed Webservicex and Yahoo Finance Exchange

texts:
What i see in magento 2.2 and 2.3 is that Webservicex and Yahoo Finance Exchange are removed.

Why are they removed?
What are the alternative to them?
How can i add them back?


texts: How can I change the position of my menu and top links without screwing everything up?

texts:
I've moved my main menu navigation into the header panel using this;

<move element="navigation.sections" destination="header.panel" after="-"/>

I've done so in order to set the position of the heaeder panel to fixed and have the menu always on screen during scrolling.

I've also moved the logo, search and cart up to the panel wrapper in order to vertically compress the layout; ie; remove excessive white space in the header.

<move element="logo" destination="header.panel" before="top.links"/>
<move element="top.search" destination="header.panel" before="top.links"/>
<move element="minicart" destination="header.panel" before="top.links"/>

Unfortunately I now have elements that were previously hidden on desktop visible under the menu. Also; when rendering for mobile, the Account and Settings tabs are empty.

I can't figure out why this is happening? How can I get the header the way I want it without messing up one thing or another?


texts: In Magento 2 Rest Api, status codes how to use?

texts:
I would like to return json responseobject via a status codes and messages for the creating customer account using  magento2 REST API.

I found some documentations below:-

1) https://restfulapi.net/http-status-codes/

2) http://devdocs.magento.com/guides/v2.1/get-started/gs-web-api-response.html

API Url:- rest/V1/customer/signup

Method:- POST

Screenshot:- http://prntscr.com/ho6moe

Model code:-

<?php

namespace Test\Custom\Model;
class CustomerSignupAccount implements \Test\Custom\Api\CustomerSignupInterface
{

    /**
     * @var \Magento\Store\Model\StoreManagerInterface
     */
    protected $storeManager;

    /**
     * @var \Magento\Customer\Model\CustomerFactory
     */
    protected $customerFactory;

     /**
     * @param \Magento\Store\Model\StoreManagerInterface $storeManager
     * @param \Magento\Customer\Model\CustomerFactory    $customerFactory
     */
    public function __construct(
        \Magento\Store\Model\StoreManagerInterface $storeManager,
        \Magento\Customer\Model\CustomerFactory $customerFactory
    ) {
        $this->storeManager     = $storeManager;
        $this->customerFactory  = $customerFactory;

    }

    /**
     * {@inheritdoc}
    */

     public function customerSignup($customerData)
     {
        // Perparing Customer Data
        $firstName      = $customerData['firstname'];
        $lastName       = $customerData['lastname'];
        $email          = $customerData['email'];

        // Validate Customer EmailAddress
        if(!\Zend_Validate::is(trim($customerData['email']), 'NotEmpty'))
        {
            return 'Please check your email, it should not empty';
        }
        if(!\Zend_Validate::is(trim($customerData['email']), 'EmailAddress'))
        {
            return 'Please check your email formate and try again';
        }

        try{

            // Get Website ID
            $websiteId  = $this->storeManager->getWebsite()->getWebsiteId();
            $customerData = $this->customerFactory->create();
            $customerData->setWebsiteId($websiteId);
            $customerData->loadByEmail($email);
            if($customerData->getId())
            {
                return 'Customer account has been already registered with this email '.$email ;

            }else
            {
                //Instantiate object (this is the most important part)
                $customer   = $this->customerFactory->create();
                $customer->setWebsiteId($websiteId);
                // Preparing data for new customer
                $customer->setEmail($email);
                $customer->setFirstname($firstName);
                $customer->setLastname($lastName);
                // Save customer data
                $customer->save();

                return 'Your account has been created successfully.';
            }

        }
        catch(\Exception $e){

            return 'Something bad happend please try again';
        }

    }

}

Note:- Here i am able to create an account it's working fine.

Please suggest me how to  show response in the form of status codes and messages?

thanks


texts: Magento Add Information in Checkout Shipping method Progress Block

texts:
I would like to add Delivery instructions info under Shipping Method in progress block of the checkout page.

Please advise where to start.


texts: In magento 1.6.2.0, generating "maintenance.flag" file when site down and site stop working

texts:
I am facing a problem in Magento 1.6.2.0. It stops running and creates a "maintenance.flag" file. When i delete "maintenance.flag", the site is working again.

In log file it is showing the below error:

exception log:

ERR (3): exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 2006 MySQL server has gone away' in lib/Varien/Db/Statement/Pdo/Mysql.php:82
ERR (3): exception 'Mage_Core_Exception' with message 'Parent directory does not exist: catalog' in app/Mage.php:563

System log:

ERR (3): Strict Notice: Only variables should be passed by reference  in app/design/frontend/default/themename/template/page/1column.phtml on line 47
ERR (3): Deprecated functionality: Function split() is deprecated  in app/design/frontend/default/themename/template/catalog/layer/filter.phtml on line 40

How can I fix this issue.

Please help!


texts:
How can I add a JavaScript snippet to the head of a CMS page?

I don't want to reference a JS file.

Instead I would like to add the piece of JS directly (it is to preload an image so only 2 lines).


texts: css not loading when change admin language

texts:
After I changed the language in admin panel the css in backend didn't load. I have tried different language
Any ideas?


texts: Magento 2:Show category name in cart page

texts:
I have a custom module. I want to display category name of each product in the cart

Please see my code

checkout_index_index.xml

<body>
    <referenceBlock name="additional.product.info">
        <block class="Company\Module\Block\Showcategory" name="showcategory" template="Company_Module::checkout/cart/categoryname.phtml"/>
    </referenceBlock>
</body>

categoryname.phtml

<?php $quoteItems = $block->getCheckoutSession(); ?>
<?php echo count($quoteItems); ?>
<?php foreach ($quoteItems as $item):
    $pid = $item->getProductId();
    $product = $block->getProductRepository()->getById($pid);
    $cats = $product->getCategoryIds();
    foreach ($cats as $category_id) {
        $_cat = $block->getCategoryRepository()->get($category_id, $block->getStoreId());
        echo $_cat->getName();
    }
?>

<?php endforeach; ?>

Showcategory.php

<?php

namespace Company\Module\Block;

use Magento\Framework\View\Element\Template\Context;
use Magento\Checkout\Model\Session;
use Magento\Catalog\Api\ProductRepositoryInterface;
use Magento\Catalog\Api\CategoryRepositoryInterface;
use Magento\Store\Model\StoreManagerInterface;

class Showcategory extends \Magento\Framework\View\Element\Template
{
    /** @var CheckoutSession */
    private $checkoutSession;

    /** @var ProductRepository */
    private $productRepository;

    /** @var CategoryRepository */
    private $categoryRepository;

    /** @var StoreManager */
    private $storeManager;

    /**
     * @param CheckoutSession $checkoutSession
     * @param ProductRepository $productRepository
     * @param CategoryRepository $categoryRepository
     * @param StoreManager $storeManager
     */
    public function __construct(
        Context $context,
        Session $checkoutSession,
        ProductRepositoryInterface $productRepository,
        CategoryRepositoryInterface $categoryRepository,
        StoreManagerInterface $storeManager,
        array $data = []
    ) {
        parent::__construct($context, $data);
        $this->checkoutSession = $checkoutSession;
        $this->productRepository = $productRepository;
        $this->categoryRepository = $categoryRepository;
        $this->storeManager = $storeManager;
    }
    public function getCheckoutSession() {
        $quote = $this->checkoutSession->getQuote();
        $items = $quote->getAllVisibleItems();
        return $items;
    }

    public function getProductRepository() {
        $product = $this->productRepository;
        return $product;
    }

    public function getCategoryRepository() {
        $category = $this->categoryRepository;
        return $category;
    }

    public function getStoreId() {
        $storeId = $this->storeManager->getStore()->getId();
        return $storeId;
    }
}

But it is showing all category names under each product. Please refer the image

Please advice


texts: Invalid Form Key. Please refresh the page. error on product save

texts:
Hello AllI am getting this error "Invalid Form Key. Please refresh the page." whenever I try to save my product on admin panel. I have gone through this link here but no success. When I looked at my log file it displayed me this

2013-09-03T07:07:43+00:00 ERR (3): Notice: Undefined index: httponly  in /var/www/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 94
2013-09-03T07:07:43+00:00 ERR (3): Notice: Undefined index: secure  in /var/www/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 96
2013-09-03T07:07:43+00:00 ERR (3): Notice: Undefined index: domain  in /var/www/app/code/core/Mage/Core/Model/Session/Abstract/Varien.php on line 98

I commented out the lines in the file as suggested in this article here. And the errors in log files were gone. But still not able to save my product and the error "Invalid Form Key. Please refresh the page." is as it is.
I checked the post data in firebug and it showed me

form_key    THJDhxajLIZnzrHt
form_key    {{formKey}}

as form key variables passing when I save my product. When I checked it in my local machine it displays me

form_key    prvOwOCGjSKG6DpF
form_key    {{formKey}}
form_key    prvOwOCGjSKG6DpF

something like this.
Does anyone have any idea what is wrong here. Here I can see that the last value for "form_key" passing in live is "{{formkey}}" while in local it is "prvOwOCGjSKG6DpF". Any help is appreciated.


texts: What real world items do ShippingAssignment objects correspond to

texts:
I've been looking at the class \Magento\Sales\Model\Order\ShippingAssignment and I have absolutely no idea what it represents.
The OrderInterface has a shippingAssignments attribute set through extension attributes. shippingAssignments is an array of shippingAssignment objects, which contain shipping objects and an items array.
When you ship an order in multiple shipments, its still has a single shippingAssignment in its shippingAssignments attribute. If you create an order with multishipping, it shows up as two unique orders, each with a single shippingAssignment each.
Basically, I have no idea how to interpret the shippingAssignment class and to know when the shippingAssignments attribute might ever have more than a single shippingAssignment object in it.


texts:
magento 1.9.1.1 show multiple products with custom options on product page and be able to select them and add them all or some to cart

for example, I want a product page to show one main product, bundle prod, and then add multiple other products on the same page, all, or a few of them with custom options, and be able to select and add them to the cart, so also price on product page is updated based on selection

Some of the additional product will have data dropboxes, others a click box and some additional products will have their own custom options

Anyone any idea ? or knows a good extension for this?


texts: Deleted products still showing on my website

texts:
I really need help.
I have deleted some products on my admin panel but it still shows on my website.
and when I try to add new products they don't show on the website either,
is there something i'm doing wrong?
I have followed all the steps to delete and add products strictly but still
please help.


texts: How to change the validation message in my account information section in myaccout page in Magento 2

texts:
I wish to add custom validation message in my account information section

Please provide me a solution to add custom message in below template.

vendor/magento/module-customer/view/frontend/templates/form/edit.phtml


texts: Confusion with order id, order increment id and I am not getting order id as 20001201

texts:
I am bit confused with order id and order increment id, So can any one help me to understand the difference between these two?

I have an observer for sales_order_place_after where I store sales details in a custom table.

But with

$orderId = $observer->getEvent()->getOrder()->getId();

I get the order ids as normal ids like 112 or 113 or 110 etc not like 20001201

So which is the real order id, 20001201 or 112?

I need to further process order data based on this order id, I use 112, 113 etc. and it works, but I need to clarify this.


texts: Magento 2 - How do I create a voting poll?

texts:
I would like to create a voting poll inside one of my pages. I've researched online and found a tutorial for Magento 1 and I was wondering if there was a similar way to achieve this in Magento 2.

https://docs.magento.com/m1/ce/user_guide/marketing/polls.html

Thanks in advance :)


texts: Magento 2 product_form.xml ovevride existing field . Duplicate Entry generated

texts: Override the product_form.xml file for the existing Product to add search filter option. But duplicate entry generated


texts:
This question has been asked before, but the answer to it which was updating a UAV attribute did not help. Product images use default value

Is there a way to make all store views always use the default sort order values for it's images ? There is no checkbox, I tried implementing something similar to the other default values, but got lost because there is quite a lot of code for it.


texts: What does the Magento_Ui/js/lib/knockout/extender/bound-nodes RequireJS Module Do?

texts:
The Knockout.js bootstrap module in Magento 2 includes the following module via a define dependency.

 Magento_Ui/js/lib/knockout/extender/bound-nodes

Technically speaking, this module creates wrappers for the ko.applyBindings and ko.cleanNode methods. These wrappers will stash certain view models and nodes in a private javascript WeakMap, and then return a single registry object that will let you access items in the WeakMap.

However, it's not clear what end-user-programmer facing features this enables.  Does anyone here know what the Magento_Ui/js/lib/knockout/extender/bound-nodes module is actually for?  Or is familiar enough with Knockout.js internals to figure things out?


texts:
I have take a clone from bitbucket ,did composer update and create a database and thn while running setup , its stop on 50% and throgh
Magento\Framework\Exception\LocalizedException: Invalid entity_type specified: customer error


texts: Can I alphabetize the images in the media storage?

texts:
It is time consuming to search for images in the media storage files.

Can I alphabetize the images in the media storage files?


texts: Sort by Each Price Magento 2 via \Zend_DB_expr

texts:
I've had this working previously however seems to be causing me some difficulty now, basically i have a unit of sale attribute that I am using to get an each price from the sale price:

if ($currentOrder == 'each_price') {
    $subject->getCollection()->addAttributeToSelect('unit_of_sale', 'catalog_product_entity_varchar');
    if ($subject->getCurrentDirection() == 'desc') {
        $subject->getCollection()->getSelect()->order(array(new \Zend_Db_Expr('(minimal_price / IFNULL(unit_of_sale,1)) DESC')));
    } elseif ($subject->getCurrentDirection() == 'asc') {
        $subject->getCollection()->getSelect()->order(array(new \Zend_Db_Expr('(minimal_price / IFNULL(unit_of_sale,1)) ASC')));
    }
}

This creates the below query:

SELECT `e`.*, `price_index`.`price`, `price_index`.`tax_class_id`, `price_index`.`final_price`, IF(price_index.tier_price IS NOT NULL, LEAST(price_index.min_price, price_index.tier_price), price_index.min_price) AS `minimal_price`, `price_index`.`min_price`, `price_index`.`max_price`, `price_index`.`tier_price`, `at_unit_of_sale`.`value` AS `unit_of_sale` FROM `catalog_product_entity` AS `e` INNER JOIN `catalog_product_index_price` AS `price_index` ON price_index.entity_id = e.entity_id AND price_index.website_id = '2' AND price_index.customer_group_id = 0 INNER JOIN `catalog_product_entity_varchar` AS `at_unit_of_sale` ON (`at_unit_of_sale`.`entity_id` = `e`.`entity_id`) AND (`at_unit_of_sale`.`attribute_id` = '207') AND (`at_unit_of_sale`.`store_id` = 0) ORDER BY (minimal_price / IFNULL(unit_of_sale,1)) DESC

However then spits out another seperate query that seems to be for the current page like below:

SELECT `e`.*, `price_index`.`price`, `price_index`.`tax_class_id`, `price_index`.`final_price`, IF(price_index.tier_price IS NOT NULL, LEAST(price_index.min_price, price_index.tier_price), price_index.min_price) AS `minimal_price`, `price_index`.`min_price`, `price_index`.`max_price`, `price_index`.`tier_price`, `stock_status_index`.`stock_status` AS `is_salable` FROM `catalog_product_entity` AS `e` INNER JOIN `catalog_product_index_price` AS `price_index` ON price_index.entity_id = e.entity_id AND price_index.website_id = '2' AND price_index.customer_group_id = 0 INNER JOIN `cataloginventory_stock_status` AS `stock_status_index` ON e.entity_id = stock_status_index.product_id AND stock_status_index.website_id = 0 AND stock_status_index.stock_id = 1 WHERE (stock_status_index.stock_status = 1) AND (e.entity_id IN (634, 611, 610, 609, 608, 624, 622, 734, 620, 1606, 736, 606))

This however does not include the order by like the previous. The first query in SQL does seem to return the results in the correct order of each price but 6000 results when this is a 34 product category. The second just returns the page but without my ordering.

So am doing something wrong here. I have tried numberous versions of above code in different ways however nothing seems to work for me so was hoping someone could see my issue?


texts: Getting Blank Page on Shopping Cart And Checkout When Logged in Magento 1.9.3.6

texts: We have Magento 1.9.3.6, customer logs are on to enable comparison feature. If compilation is on and customer is logging in and clicking to shopping cart it goes to blank page. Nothing in system.log neither in php_errorlog. Please advise


texts: How can i change text in checkout page and emails? Please see screenshot.


texts:
I want to load a set of products, given as an array:

<?php
$productSkus = array('sku-1','sku-2');

foreach($productSkus as $productSku) :
    $productId = Mage::getModel("catalog/product")->getIdBySku($productSku);
    $_product = Mage::getModel('catalog/product')->load($productId);
    $productName = $_product->getName();
    echo $productName;
endforeach;
?>

As I am a rookie I'm wondering if this set is not a lot of database requests. Is there a way to do the loading before the loop at once?


texts: Mage_Core_Model_Session_Exception in login code magento 1.9

texts:
I am working on custom login using below code, before it was working fine now its giving error.

Error:

  An uncaught Exception was encountered
  Type: Mage_Core_Model_Session_Exception
  Message: (null)

I don't know what caused this error. Please help me to fix this error

Thank you

<?php
function loginUser( $email, $password )
require_once ("app/Mage.php");
umask(0);
ob_start();
session_start();
Mage::app('default');
Mage::getSingleton("core/session", array("name" => "frontend"));

$websiteId = Mage::app()->getWebsite()->getId();
$store = Mage::app()->getStore();
$customer = Mage::getModel("customer/customer");
$customer->website_id = $websiteId;
$customer->setStore($store);
try {
    $customer->loadByEmail($email);
    $session = Mage::getSingleton('customer/session')->setCustomerAsLoggedIn($customer);
    $session->login($email, $password);
}catch(Exception $e){

}

}
?>


texts:
At some point recently our site stopped returning results for searches of product by part number.  So far I've reindexed, I've tried all the different search modes, we've removed all disabled products (I heard there's a bug in the disabled products code that can cause whole categories to disappear from search), I've even disabled the extension that was updated recently.  I've flushed the caches after each change just to make sure.  Still no luck.

Searches for part numbers come up with "Your search returns no results."  Searches for some other terms that are in part descriptions will find some, but not all the items with those terms in the description.

I'm not sure how to proceed from here.  Ideas?

edit

Perhaps a better question is: "How does Magento search function?".  What are the dependencies/expectations for an item to be found via search?


texts:
I want to show a different logo if a user is redirected from a specific site. This logo should show the reset of the session. The problem I'm facing is that we're using Varnish, and the logo shows up to other users (that are not redirected from the specific site).

How can I show this logo (with Varnish in mind) based on the URL, for example: https://domain.com?ref=1

I tried different solutions:

With Cookie (Cookie is not always set and we still have the problem with Varnish)
Added a Http Vary


texts: Get available filters of category by category ID

texts:
I have been trying to write rest api to retrieve available filters of particular category by its ID.

I have a category which has two filters price and brands.

Both price and brands are visible in frontend. I can filter products by either price or brand from frontend.

I wanted to get available filters of this category in my rest request.
But unfortunately my code is not working. This code returns null.

  When i browse the url on browser i get desired result

  But this code returns empty on both postman and private window.

I think this is happening due to session. how do i resolve this?

<?php

class BAR_Restapi_Model_Api2_Filterlist_Rest_Admin_V1 extends BAR_Restapi_Model_Api2_Filterlist_Filterlist
{

    /**
     * Retrieve filter by category ID
     *
     *
     */
    protected function _retrieve()
    {

    $layer = Mage::getModel("catalog/layer");

    //category_id=112
    $category = Mage::getModel("catalog/category")->load(112);
    $layer->setCurrentCategory($category);
    $attributes = $layer->getFilterableAttributes();

    foreach ($attributes as $attribute) {
        if ($attribute->getAttributeCode() == 'price') {
            $filterBlockName = 'catalog/layer_filter_price';
        } elseif ($attribute->getBackendType() == 'decimal') {
            $filterBlockName = 'catalog/layer_filter_decimal';
        } else {
            $filterBlockName = 'catalog/layer_filter_attribute';
        }

        $result = Mage::app()->getLayout()->createBlock($filterBlockName)->setLayer($layer)->setAttributeModel($attribute)->init();
        echo "

";
        echo $attribute->getAttributeCode();
        echo "
";
        foreach($result->getItems() as $option) {
            echo $option->getLabel().'
';
            echo $option->getValue();

        }
}

  }

}

How do i get available filter of a particular category by its Id?


texts: unable to checkout with paypal express when using a discount code

texts:
never seen this problem before on any other website but when we try to checkout via paypal express when trying to use a discount code we get an error

Transaction refused because of an invalid argument. See additional error messages for details.(10413)

I enabled paypal logging but the long message just says:

  The totals of the cart item amounts do not match order amounts.

I have checked the magento configuration but I can't see anywhere I can remove this check like I can with other payment providers, any advice?

Theres an option to transfer cart line items over to paypal but that's set to "no"

please help.


texts:
Using this code i have create new customer and also it will login

$customerFactory = $objectManager->get('\Magento\Customer\Model\CustomerFactory');
$websiteId = $storeManager->getWebsite()->getWebsiteId();
$store = $storeManager->getStore();
$storeId = $store->getStoreId();

$customer = $customerFactory->create();
$customer->setWebsiteId($websiteId);
$customer->setEmail($user_e);
$customer->setFirstname($_fname);
$customer->setLastname($_lname);

$customer->setPassword($pass);
$customer->save();

$CustomerModel->setWebsiteId($websiteId);
$CustomerModel->loadByEmail($user_e);
$customerSession = $objectManager->create('Magento\Customer\Model\Session');
$customerSession->setCustomerAsLoggedIn($CustomerModel);

Now i want to send create account email, above script is not sending create account email.

How can i send create account email? Please Reply as soon as


texts: Magento 2.3 - Product Attribute Options Sort

texts:
I want to sort the product attribute option, can anyone help me which file I need to change for it.

Ex. The brand attribute has so many options, I want to sort it alphabetical order in the admin side.


texts:
Well first of all We have using the Porto theme and using the mega menu. we currently running magento 2.2.3.

It's seems that when we Enabled varnish on my Current Magento and configure everything that it's working except can't display navigation menu. kindly help me
Advance Thank you


texts: Real time update cart based on the number of uploaded images

texts:
Good morning,

I need a system to uploads multiple images in front end, but I would like based on the number of images uploaded, it can be updated in real time the cart with the right amount.

That is, if the customer charge 1 photos the price will be $ 10.00
but I would like that if the customer charge 3 photos the price is updated to $ 30.00

Is possible to do this? There is already an extension?

Many thanks!


texts: Magento 2 Add text in checkout page via XML

texts:
I'm trying to add custom text in checkout page via XML. I have my custom checkout_index_index.xml file with this inside:

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="checkout" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
    <referenceBlock name="checkout.root">
        <arguments>
            <argument name="jsLayout" xsi:type="array">
                <item name="components" xsi:type="array">
                    <item name="checkout" xsi:type="array">
                        <item name="children" xsi:type="array">
                            <item name="sidebar" xsi:type="array">
                                <item name="children" xsi:type="array">
                                    <item name="summary" xsi:type="array">
                                        <item name="children" xsi:type="array">
                                            <item name="totals" xsi:type="array">
                                                <item name="text" xsi:type="string" translate="true">Custom text here</item>
                                            </item>
                                        </item>
                                    </item>
                                </item>
                            </item>
                        </item>
                    </item>
                </item>
            </argument>
        </arguments>
    </referenceBlock>
</body>
</page>

The text is not added. I've tried with a block but an error is displayed.
How can I display a custom text or a CMS Block?


texts:
I was added feedback form code in manual every layout (1column.phtml, 2col-left.phtml and etc). Now Feedback form will be showing on every page of my site.

I need to configure email sent options. I tried normal html/php form action it will return blank. No email was received from feedback form.

My Feedback code is,

Can you help me?. Thanks in Advance.


texts: How do you get only visible items in a credit memo

texts:
I'm trying to get the products from a credit memo but they are duplicated if configurable, so instead of 3 products I get 6, configurable and the associated simple one.

$creditmemo = $observer->getEvent()->getCreditmemo();
foreach ($creditmemo->getAllItems() as $key => $item) {

//gets products configurable and simple ones

}

var_dump($item->getData())

shows it as an array with 6 products, the only difference is that the simple ones don't have a price associated.

How do I get only simple ones or only configurable ones with the superattribute option?

Thanks!


texts: Change "Request Method" of a request (controller) Magento 1

texts: Where the type of request "POST & GET" is defined in Magento 1 for controller requests ?


texts:
What is the difference between a THEME And Module in Magento 2 ?

Theme Registration.php

\Magento\Framework\Component\ComponentRegistrar::register(
    \Magento\Framework\Component\ComponentRegistrar::THEME,
    'Inchoo_Helloworld',
    __DIR__
);

Module Registration.php

 \Magento\Framework\Component\ComponentRegistrar::Module,


texts: How to add a product with two line items

texts:
I want to add a product with two line items.
Say for example if i add Product A with qty of 4.
I need to split cart into two line items.
3 qty as one line item and 1 is in another.

How Can I achieve this?

  I have overridden Checkout/Controller/Cart/Add.php

and here is my sample code.

foreach ([3,1] as $qty) {
    $objectManager = \Magento\Framework\App\ObjectManager::getInstance();
    $_control = $objectManager->create('\Vendor\Module\Observer\Custom');
    $additionalOptions = [];
    if($value == 1){
        $additionalOptions[] = array(
            'label' => 'Discount',
            'value' => 'No'
        );
    }else{
        $additionalOptions[] = array(
            'label' => 'Discount',
            'value' => 'Yes'
        );
    }
    $product->addCustomOption('additional_options',$_control->unserializeCustomOption($additionalOptions));
    $v_params = array(
        'product' => $product->getId(),
        'qty' => $qty,
        'price' => ($qty == 3 ? 76 : 86)
    );
    $this->cart->addProduct($product, $v_params);
}

Request which is coming to Quote model is correct only.

{"product":"727","qty":3,"price":76}
{"product":"727","qty":1,"price":86}

But in the cart its not correct.

Thanks in advance!


texts: Magento2.3: The attribute 'data-requiremodule' is not allowed

texts:
I upgraded the Magento version 2.1 to 2.3, the following error has occurred in the backend.

1 exception(s): Exception #0 (Magento\Framework\Config\Dom\ValidationException): Element 'script', attribute 'data-requiremodule': The attribute 'data-requiremodule' is not allowed. Line: 186


texts: Magento CE 1.9.1.0 - sticky Layered Navigation

texts:
I am using the Magento default Layered Navigation on my category pages and I want to make it be sticky, so when you scroll down the page each "shop by" filter will always be visible. So to the code

I added a css style to the sidebar-left class
The style I added is position:fixed;

My issue is when you scroll down the page and get to the bottom the layered navigation goes over the top of the footer. So I am not sure how to change the sidebar-left class (or to create a new class name) that would change the layered navigation to not scroll over the top of the footer.


texts:
I'm working on an upgrade project with an older Magento site, running an old version of Apache.  This version of Apache fails to set a UTF-8 character encoding.  Instead, the content type header omits an encoding type

Content-Type: text/html

and the browser is left to guess the mystery meat encoding.  Firefox reports it as Windows-1252.

We've moved to a new web server, and this new web server is configured to send along the UTF-8 header

Content-Type: text/html; charset=UTF-8

So, we're doing the right thing here, joel is happy, but there's one problem: 5+ years of data entered under mystery meat encoding means there's all sorts of special characters in the database, and when they're served as UTF-8 this happens

For those with images off, that's "Lots of munged encoding".

Are there known solutions for this sort of problem, or am I looking at a lot of manual data scrubbing and/or switching the server back to ambiguous character encoding?


texts:
I am not able to edit the product area in admin. I am getting the following error -

Element 'fieldset', attribute 'sortOrder': The attribute 'sortOrder' is not allowed.

I have cleared cache and it worked twice. I am not sure if the issue is for cache or something else. Exception.log is not showing anything.


texts: How to show first character in a string in invoice?

texts:
<?php
$ship= "{{var shipping}}";
echo $ship;
?>

I have used this code to show "Delivery date" in invoice. And output is "Priority Delivery(withing 2 WD)".Now i want to show first character in this string. such as . Out put is "P".


texts: after update to Magento 1.9.1 PayPal is disabled!

texts:
after update from 1.7.2 to the version 1.9.1 the PayPal payment is disabled.
I cannot activate it. Look to the picture.

The select box is grey and I cannot activate it. :(

Can anybody give me a help.


texts: Label in Catalog view for Special Price (Magento 2)

texts:
I want to put a label for Special Price in caltalog view. Therefore I tried some code from final_price.phtml like this:

<?php if ($block->hasSpecialPrice()): ?>
    test
<?php endif; ?>

I try to use it in my list.phtml here:

app/design/frontend/name/theme/Magento_Caltalog/templates/product/list.phtml

But it doesen't work that way here. How ist the the correct if statement to do that in list.phtml?


texts:
Mangeto - sigh what a pos sometimes
with that out of my system im getting this error
all im using is authorized.net on magento 2.1.7 after 10 hours of trying to upgrade im forced to try and figure out how to resolve this.
ive changed the code in the paymentinformatimanagement.php but it doesnt show me any debug when checking out.
An error occurred on the server. Please try to place the order again.

so fustrated with this software i regret moving to it.

https://codeblog.experius.nl/magento-2-checkout-debuggen/

[2018-08-18 00:31:02] main.CRITICAL: exception 'Magento\Framework\Exception\LocalizedException' with message 'The transaction was declined because the response hash validation failed.' in /home/devclvigilant1/public_html/vendor/magento/module-authorizenet/Model/Directpost.php:542

so i logged into authorized created md5 applied to site
the site seamed to go to a new page heres a custom addon trying to remove.
1 exception(s):
Exception #0 (Exception): Warning: mkdir(): Permission denied in /home/devclvigilant1/public_html/app/code/Aitoc/CustomProductDesigner/Observer/OrderCreateAfter.php on line 116

chown -R username: path i did the whole thing
site loads and was able to purchase!! jeeeez


texts: Dropdown product attributes: int vs. varchar

texts:
For an attribute set up as a dropdown, is that supposed to be an int or a varchar?

I'm fixing a catalog of products that someone else imported, and I'm seeing a size attribute set up as a dropdown as an int type (backend column in eav_attributes), but the integer values are stored in the catalog_product_entity_varchar table. So, the simple products think they have no sizes assigned.

Furthermore, I thought if the varchar EAV table had dropdown values, it stored it as a string, not an integer that points to the EAV table. I've seen a dropdown attribute stored its values in the ..._varchar table as actual strings values and not a number that refered back to the eav attriute table because it was created as a varchar during an extension installation.

So, my questions are..

A dropdown attribute gets a backend type of int if created in the admin, but if you create an attribute via an extension, you can install this column as a varchar. Does it really matter if a dropdown attribute is an int or a varchar type?
Regarding the catalog that I'm fixing, I'm not quite sure what the original developer did. He didn't use a text file to import the products; from the scripts I have that were used in the product import, he programmatically saved the products with data he had (i.e. via $product->save()). But how did this dropdown attribute get created as an int backend but ended up in the catalog_product_entity_varchar table with numerical strings that point to eav_attribute_option. I did verified these "varchar" values point to actual entries in eav_attribute_option.
IF the dropdown attribute was setup as a varchar backend type, how does Magento know to refer to the EAV options with the numerical varchar values instead of just assigning the attribute value as "1" or "2" (as in size 1, 2, etc. instead of Small, Medium, etc.)? I'm assuming this is because it was set up as a dropdown, but just wanted to check.


texts: How much need RAM of VPS for 1 store about 110 product pages and very low traffic?

texts:
I have 1 store with 110 products. Traffic is very low - max 40 visitors per day. Now i pay for a shared-hosting and all good, but reply of server is from 700 to 1200 ms.

I want rent VPS, but dont know about needed RAM for me. How much need? I want server reply to be very fast.

I have compressed js and css, optimized images, minimal images at product pages, sprites.


texts:
I need to display the average of all the product reviews in magento.

I need if you can view it in this way


texts: Magento 2.3.0 upgrade to 2.3.4, Admin not showing version update

texts:
I am updating my production site from 2.3.0 to 2.3.4. Updating goes smoothly with no errors at all.
Yet my backend(adminhtml) is not updated!!

It still shows the old number (2.3.0) in the bottom right.
Using php bin/magento -v on the cli I get the right version! 2.3.4

So I know that it seems to be on version 2.3.4, because the Export Products bug I was updating to fix is fixed!
Also I was running ElasticSearch 5, and 2.3.4 isn't compatible so it stopped working. Yet when I go try to change the catalog search ElasticSearch 6 or 7 are not options!!

First I updated via composer. I'll list the commands, but I had no errors.

php bin/magento maintenance:enable
cp composer.json composer.json.bak
composer require magento/product-community-edition=2.3.4 --no-update
composer update
php bin/magento cache:clean
php bin/magento setup:upgrade
php bin/magento setup:di:compile
php bin/magento setup:static-content:deploy -f
php bin/magento maintenance:enable

adminhtml seems to deploy just fine. I've tried clearing all caches. Applying the -area admin ti deploy.
I also tried installing via FTP. I downloaded the full version of 2.3.4 and uploaded it and ran setup:update. No luck.
I feel like I'm missing something really small.
Thanks!