texts: how to create a ui_form selector by triggering ajax call on previous selector selected option (create dynamic selectors in ui_form) in magento 2

texts: I'm going to a controller through ajax and calling block file from there and in that block file i have set the template file where I'm trying making selector and setting options in it and returning a block file result to controller


texts:
My products are not on one line at this page: http://www.graffitistiften.nl/index.php/alpha-design-marker.html

How can is change this?


texts: How do I get all of the customer which has a specific customer attribute value

texts:
I want a collection with all of the customer which has a specific customer attribute value. This is my code:

$collection = Mage::getModel('customer/customer')->getCollection();
        $collection->addAttributeToFilter("my_customer_attribute_code", array('eq' => "prospect"));
        $collection = $collection->toArray();
        var_dump($collection);

The result of the var_dump is an empty array. What did i do wrong?


texts: Composer issues while upgrading Magento 2.0rc to 2.0

texts:
I have installed Magento 2.0 rc in AWS and tried to update my composer.json to update it to Magento 2.0.

Ran the command sudo composer config composer.json but received an red box with the error

  [RuntimeException]  composer.json is not defined.

I've also tried to run the following command with no response from bash.
composer config repositories.magento composer http://repo.magento.com

Your help is much appreciated.
George Ng


texts: Deploy magento package design view in user's theme

texts:
I created a module on magento connect and I have a question about it. How to do to tell magento connect to deploy my module'views (phtml files) into my user's magento folder?

Maybe it's a stupid question but I did not find any answer to this.

Thank you


texts:
I have 5 stores, each store with 3 categories.

Every store has it's own CMS page. I want to show the products of a given category of those 3 categories in store's CMS page (e.g. categories 12, 13, 27, or just category 12).

I tried all of these :

http://www.templatemonster.com/help/magento-display-products-from-the-category-on-the-home-page.html#gref
Show products on homepage breaks page 1.9
Show Specific Categories On Magento Home Page

Unfortunately, unsuccessfully...

Result is absolutely nothing... Inspecting the page, I get blank divs where the code were supposed to appear.

Products are in stock and available, yet they appear in "new_products" widget.

I've followed every single question and tuto about this, and it simply doesn't work...

Points of interest:

My Magento version is 1.9.2.
The block code that I'm using right now is this:
{{block type="catalog/product_list" category_id="12" template="catalog/product/list.phtml"}}
I've cleaned magento's cache hundreds of times

If you need further information, please let me know. I'll be waiting hopefully for your help.


texts: In Magento 2.2.5, Update the cart items with custom options

texts:
In Magento 2.2.5, I want to update the cart products with custom options.

While adding to cart, It is added correctly and updated in quote_item_option table. While updating only qty is updated, other than no other custom options are not updated.

Any way to achieve this.


texts: Magento 2.3 - Newb question - custom test beside the Place Order Button

texts: I would like to place custom bold text beside the place order button in the checkout payment page. I am new to the Magento framework and I want to make sure to make the change the proper way. I assume editing the core template is not the way, so is there a way to override the template with a custom template? or some sort of hook to insert before or after the Place Order button?


texts: Is it possible to serve images from Magento 2 using a URL reference?

texts:
I want to serve images from an external CDN. This means:

I don't want to store images on Magento's server or use its image cache
I want to store image URLs in the database and use them to serve images directly in the browser via CDN
I want to use transformations (width/300/height/300/foo.jpg) (this is not related to Magento, but I'm adding it here in case it complicates things)

Is Magento 2 prepared to serve images via URL out of the box, or does it require development work or changing anything in Magento's innards? If so, how much effort is required to configure Magento to serve images as such?

To be clear, I already have an Asset Management system with a CDN that furnishes image URLs. I want Magento to consume it.


texts: How get ROWs in product Custom option (drop-down)?

texts:
Need get Sub options with id 38, 39
Easy get options $_product->getOptions() but how get sub options (row) ?


texts: Dependency Injection and constructor parameters

texts:
Lets suppose I have extended a class from magento core and used some extra classes to have a specific functionality. Here is the code (just example).

// core code
public function __construct(
    \Magento\Framework\Model\Context $context,
    \Magento\Framework\Registry $registry,
    array $data = []
)

Now in my module I have added an extra class. Say it's catalog session. Now it looks like this

// module code
public function __construct(
    \Magento\Framework\Model\Context $context,
    \Magento\Framework\Registry $registry,
    \Magento\Catalog\Model\Session $catalogSession, //newly added
    array $data = []
)

  Now I know Magento will go through all extended classes until it finds
  out a constructor and those parameters will only use to inject
  dependencies. So now here it will find the constructor in my module
  first so it wont go to parent class at all and i need to ensure that I
  will add all parameters from my parent class.

Now my question is what will happen if Magento will change or add or delete any parameters of its core class which we are extending?


texts: I need to reset my password but never receive an email

texts: I have clicked on the link for "Forgotten Password" but I never receive an email with the link to reset the password. I have checked my junk folder but nothing gets sent to me. Is there another way to get a new password for the back office? The email address on Magento is correct.


texts: Can I get store config value in layout xml file?

texts:
In my extension I want to add custom link to the customer account page menu.
there is my xml layout update file

<customer_account>
    <reference name="customer_account_navigation">
        <action method="addLink" translate="label" module="remarks"><name>remarks</name><path>remarks/remarks</path>Remarks</action>
    </reference>
</customer_account>

<remarks_remarks_index translate="label">
    Remarks
    <update handle="customer_account"/>

</remarks_remarks_index>

So the problem is that value for link label is configured in system store config. How can I get it and pass to the  tag?


texts: Event in Vagrant works but not in production

texts:
I can't think of the reason why this is happening.  I have a custom module in a vagrant box, which works perfectly.  When I migrate my code/database to an actual server, the magento event does not seem to fire. I put a tracer on dispatchEvent in Mage.php to prove that the event is firing, which it is. The custom module looking for that event doesn't seem to fire.

My code is as follows: /app/code/local/Company/collectBillToCode/Model/Observer.php

<?php
//fires after billing info is saved
class Company_collectBillToCode_Model_Observer{
    public function captureBillTo(Varien_Event_Observer $observer){
        $customerGroupId=Mage::getSingleton('customer/session')->getCustomerGroupId();
        $customerGroupName=Mage::getModel('customer/group')->load($customerGroupId)->getCustomerGroupCode();

        //confirm this is an international order, and then collect the information as needed
        if($customerGroupName=='Internal_International'){
            $billingInfo=Mage::app()->getFrontController()->getRequest()->getParams()['billing'];
            //save $billingInfo['bill-to'] to session so that it can be retreived by all components

            Mage::getSingleton('core/session')->setBillToCode($billingInfo['bill-to']);
        }
    }
}
?>

Config.xml: /app/code/local/Company/collectBillToCode/etc/config.xml

<?xml version="1.0" encoding="UTF-8"?>
<config>
   <modules>
        <Company_collectBillToCode>
            <version>0.0.1</version>
        <Company_collectBillToCode>
   </modules>
   <global>
        <models>
            <company_collectbilltocode>
                <class>Company_collectBillToCode_Model</class>
            <company_collectbilltocode>
        </models>
        <events>
            <controller_action_predispatch_checkout_onepage_saveBilling>
                <observers>
                    <company_collectbilltocode>
                        <class>company_collectbilltocode/observer</class>
                        <method>captureBillTo</method>
                        <type>singleton</type>
                    <company_collectbilltocode>
                </observers>
            </controller_action_predispatch_checkout_onepage_saveBilling>
        </events>
   </global>
</config>

And the module: /app/etc/modules/Company_collectBillToCode.xml

<?xml version="1.0" encoding="UTF-8"?>
<config>
    <modules>
        <Company_collectBillToCode>
            <active>true</active>
            <codePool>local</codePool>
        </Company_collectBillToCode>
    </modules>
</config>

I have cleared caches, sessions, recompiled, reindexed permissions are set to www-data with 775. Instance is completely patched. My other custom module looking for a similar event controller_action_postdispatch_checkout_onepage_saveBilling DOES fire. I'm stumped. -_-

To be clear, this works 100% in my vagrant instance of magento, when I copy the code from git it stops working.  What step is missing?!


texts: How to List out product collection in simple table using knowckout js

texts:
I have code like below i have tried to implement it with magento custom module.but didn't get it working as it should can any one please guide me how can i implement this.Here i just want to list down product name,price,sku in the below html table.How can i achieve this by pure knockout js.

PHTML file

    <?php $_productCollection = $block->getLoadedProductCollection(); ?>

Component js code.

     define(['ko'], function(ko) {
    return function(config) {
        this.message = ko.observable(config.exampleMessage);
         var self = this;
        self.items = ko.observableArray();
        self.columnNames = ko.computed(function () {
            if (self.items().length === 0)
                return [];
            var props = [];
            var obj = self.items()[0];
            for (var name in obj)
                props.push(name);
            //return props;

        });
        var vm = new VM();

          ko.applyBindings(vm);

          vm.items.push({
              'Name': 'John',
              'Age': 25,
              'test':125
          });
          vm.items.push({
              'Name': 'Morgan',
              'Age': 26
          });
    }
});

I have imlimented like this but it gives error like this.
Erorr Screenshot from Browser console


texts:
Keeping the configuration across multiple environments ( live / stage / dev ) is obviously very important, especially when you have multiple developers. Nobody likes the whole 'well it works on my machine' situation. In an attempt to avoid this issue we try to make sure that configuration changes that are required get done as a migration file.

I've found myself unsure on where exactly we should put these migrations. We tend to have a Client_Core module, which seems a fairly logical module to make the changes in, but are configuration changes a data migration (and as such sit in the 'data' directory) or should they be located in the sql directory? Is there actually a 'best practice' / 'Magento way' place for these migrations, or is it just a matter of it doesn't really matter, go with whatever you feel better?


texts: Magento 2 : Event when customer in backend is created and updated

texts:
I want to know how to solve this problem:

I need to trigger an observer when a customer is created and one different when customer is updated.

I was using customer_save_before event which works everytime you press Save Customer, the problem with this event is that I don't know if the user is created or updated. I have tried to get the ID of the customer and do something like this:

$customer = $observer->getEvent()->getCustomer();

if($customer->getId() == null){

    $event = $CREATE_ACCOUNT_EVENT;
}
else {
    $event = $UPDATE_ACCOUNT_EVENT;
}

The problem is that it always sends event $UPDATE_ACCOUNT_EVENT; It's like if the ID is created always before accessing to the observer.
Is there any other event which just triggers when customer is created? so I can use that one for $CREATE_ACCOUNT_EVENT;

If not how can I check if the ID of the customer exists or not?

Greetings!


texts: How to do repeated API calls to another server, with a threshold timer (in order to give up)?

texts: I am looking for a good way to implement a module which will repeatedly call an API web service for about an hour let's say, after which it needs to break and log an error to a file. I know that I can use a cron job in Magento, so which do you recommend? Thanks!


texts: Magento 2: Product collection with filters

texts:
Can anyone tell me how can i get product collection with filters?
I'm use magento 2 sample data now. So i'm trying to get in product collection like selected on picture

with attribure style=backpack and activity=yoga;
My code:

$productcollection = $objectManager->create('Magento\Catalog\Model\ResourceModel\Product\Collection')
        ->addAttributeToSelect('style_bags','activity')
        ->addAttributeToFilter(
            array(
                array('attribute'=>'style_bags','eq'=>24),
                array('attribute'=>'activity','eq'=>8)
            )
        );

echo $productcollection->count();

But i'm get 4 products instead 2. But if i'll live only

  array('attribute'=>'style_bags','eq'=>24)

without

  array('attribute'=>'activity','eq'=>8)

it will works correct.

Can anyoune explain me how it works?
Thank you.

UPD: It's seems to me, that in that case products selects with OR condition. But i need AND. If i change my code to

$productcollection = $objectManager->create('Magento\Catalog\Model\ResourceModel\Product\Collection')
            ->addAttributeToSelect('style_bags','activity')
            ->addAttributeToFilter('style_bags',['eq'=>24])
            ->addAttributeToFilter('activity',['eq'=>8]);

I'ce got emty set.


texts:
Can I defined SKU in this way:

let's say I got a lot of M&M chocolates products, all the same chocolates product, and they got different bar code. Can I say that the sku works like the bar code, it's unique for every products with different ID??

But I can't seem how SKU will helped on tracking products, should I export the whole product list?? I mean when I want to track a products, I just input the products title to search it, right? If I want to search the certain specific product, it means I need to have specific SKU to search it, it this the function of SKU??


texts: Where is the product gallery stored in the database?

texts:
I can't to set it from admin.

 And I must set it by SQL query. So how I can do it? Or where stored url from picture in database? Picture in media already exists.


texts: magento change the completed order status into custom order status

texts:
I have a order with the 'complete' status. I need to change it to a custom status.

I tried below code;

$orderId = '1000000055';
$order = Mage::getModel('sales/order')->load($orderId, 'increment_id');
$order->setState('custom_status_code', true);
$order->save();

But that not working. Can anyone please help me to solve this issue.


texts: how to refresh a part of the page when configurable variation is selected in magento 2.3

texts:
I want to reload a div section on the product detail page of the configurable product when the configurable variation is selected. How do I achieve that?

require(['jquery','jquery/ui'],function($){
    jQuery(document).on('click', '.swatch-option',function(){
        $('#points-refresh').load(document.URL +  ' #points-refresh');
    })
});

points-refresh is the id of the div section I want to reload whenever I switch one configurable child product to another.

I have tried this. But this does not work. Can anyone tell me the proper way to achieve this?


texts: Magento 2 Cannot install sample data without blank pages or permission errors

texts:
I am on day 3 of trying to successfully install and use Magento 2 sample data.

The Magento installation goes fine but the trouble is all after installing the sample data.

This is what I'm doing:

1. Set the swap:

    /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024
    /sbin/mkswap /var/swap.1
    /sbin/swapon /var/swap.1
    sudo composer update

2. Set Developer Mode:

    sudo php bin/magento deploy:mode:set developer

3. Download Sample Data:

     sudo php bin/magento sampledata:deploy

4. Install Sample Data

After this I always get a blank page...

So I do this:

    sudo php bin/magento setup:static-content:deploy
    sudo php bin/magento setup:upgrade
    sudo php bin/magento setup:di:compile
    sudo php bin/magento cache:clean

This I get lots of permission errors etc...

So I give up and start again.

Can anyone help on how to successfully do this?


texts: I have a module that has some input fields in admin. One of the input is an ID that will use the same value every time, so I don't want to display that input in admin anymore to avoid changing or deleting it (i'm not the only one who has access to the admin panel). I talk to a friend and he tells me to put it in a configuration xml file and take it from there. It is possible to do that? How can I create a new xml file and take that value from there? Can anyone help me please?


texts: How to make address fields not required in checkout?

texts:
In the onepage checkout the next fields are required by default:

Address
City
Zipcode
country

I don't want that this fields are required. Add the moment we only send virtual products so we don't need the fields.

I have tried to remove the required class in the billing.html but that does not work. I get a popup message that het address field is required and has to have a minimal length of 1.


texts: Which setup is best for domains and languages in magento?

texts:
How do I get this setup best as possible?

We have multi domains like .com .co.uk, .de, .es, .fr and so on. Why we do this is so people can shop on their respective country specific domain, language, currency.

All domains should have the same products, but the prices are not exactly the same.

Lets say base price is 34.99, then in euro it would be 26.15 but we want 25.99 and so on, so we are getting an easy pricing structure for each domain.

What is the best set up?

Different websites to each domain or is it possible to the above with just storeviews?


texts: I have an issue with the adyen-magento module. When the payment is successful in adyen, the order status doesn't updated in Magento, so the order is not getting processed. Even though when the payment is confirmed in adyen, the order status doesn't updated in Magento. Can someone help me to figure this out please?


texts: Factory methods, should I manually create them?

texts:
So when I develop extensions I usually do this outside of Magento and just pull in the packages I need. Once I have developed the extension I integrate it at the end.

Because of this I manually create factory methods, is this best practice or not? I don't really want to couple to Magento so I'm not sure what to do in this scenario.

I'm coupled to the Magento/Framework module. Do you know if it generates these for you when not plugged into Magento?


texts: How do I add a custom block to the very top of every page Magento 2

texts:
I have been searching for hours on this topic and did not find any comprehensive answers.

I want to display a block at the very top of every page. Ideally, this block's content would be editable from the Magento 2 interface (e.g. in Content > Elements > Blocks).

This block would be used for sales promotions etc.

This is for a (minimally) customized version of the Luma theme.


texts: Catalog price rule - Original price vs. new in order backend?

texts:
I have set a catalog price rule that gives 30% off on all products. Everything works fine, but I would like to see the normal price in backend when looking at an order.

Is this a missing functionality that needs custom modding or have I somehow messed something up in settings or with my custom modifications?

Preferably it should be in the order item list next to price, original price etc. - in my mind original price would be the price before catalog rules, but I guess that is not the case.


texts: Changing Status of Review creates duplicate in "review_detail" table

texts:
I've deleted my previous question and narrowed down the true issue causing this problem. For some reason, the review_detail table is creating duplicates whenever a review has it's status changed.

Review IDs 6 was left by my test customer account before i saw the issue

Reviews with ID 7 through 11 were left via admin and auto approved as such.

Review IDs 12 was me testing the theory of duplicates in this table.

I noticed that the detail_id field is NULL, but in my other stores has a value - is this a problem with a foreign key? How can I re-establish this link and hopefully stop the duplicates from being created?

This is the broken table:

This is what a working table looks like:

Not only am I missing information in the "detail_id" column, but the table is not editable and missing all the per-row controls.

Is there some master script I can run to re-establish all foreign keys between tables?

----- EDIT August 30 -----

I may have fixed the issue, but am not sure it's the best way to do it. It seems like the table's structure was lost/broken - so I did a fresh install of Magento in a separate folder, went to the new database and exported just the "review_detail" table with structure (no data), renamed the broken table, and imported the clean table into the database.

This seems to have fixed the problem but more testing needs to be done.


texts: Is there a quick way to update stock levels in Magento 2?

texts:
We need to update the stock levels of lots of products following off-site sales. Rather than click though to the details of every product, is there a way of quickly updating the stock figure from a table view without having to leave the table?

Or is the best way to export/import and amend via a spreadsheet?

I'd be grateful for any pointers.

Thanks


texts: not valid category url rewrite in the same category name

texts:
I have the problem with category URL rewrites.

$category1 = Mage::getModel('catalog/category')->load(2495);
$category2 = Mage::getModel('catalog/category')->load(5966);

First output (not valid friendly url):

  http://www.my-website.com/catalog/category/view/s/category-name/id/2495/

Second output, total valid friendly url like:

  http://www.my-website.com/category-name

I would also like to mention that these categories has the same value in catalog_category_entity_url_key. Might it be the problem?
I executed URL redirects reindex and cleared cache.
Do you have any ideas for this?


texts: Different PDF Invoices Magento1 - Shipping tax in total tax included/excluded

texts:
there are two ways, to create an invoice pdf, right?

The first is: Sales->Orders, open an order, go to "Invoices" on the left menue, choose the invoice and hit the button "print".

The second is: Sales->Orders, then check the Order you need the invoice of. Then go to the Actions-drow-down-field on top and choose "Print invoices".

The thing is: The pdfs are different, depending on the way I chose - in the first way the shipping tax is EXCLUDED in the field for 7% (that's exactly what I need the pdf to look like, both of them), in the second it's included.

Same with credit memos.

Why is that so? What could I have done wrong?
How can I change that? I tried several things to change the amount in the pdf but couldn't find a solution. It's really frustrating..

Just for information: I've got a fresh Magento 1.9.3.1. installation with no optional extentions.

Thank you very much.


texts: New products not showing until manually reindexing although cron is running

texts:
I am running Magento 2.1.2 and when creating new products they don't show up on the website until I manually run bin/magento indexer:reindex and flush the cache.

This sounds like a cron problem as all the indexs are set to update on schedule but other parts of the index are being refreshed without problems such as when creating a new attribute set it warns about the indexers being invalid and is fixed within a minute.

I don't believe this has always been a problem and may have been caused from recently restoring to a backup (rebuilt the Rackspace VM from an image) but I don't see how this could be the cause as the cron is running.

Any suggestions much appreciated.


texts: While uploading product image in admin got "A technical problem with the server created an error. Try again to continue what you were doing. "

texts:
While uploading product image in admin got "A technical problem with the server created an error. Try again to continue what you were doing. If the problem persists, try again later"
Note: While upload more than 10 images then got same error and some other product got first image also get error


texts: Magento2 - Redirect the customer dashboard after reset password success

texts:
I am new to Magento. Please look at my steps. I need to redirect the customer to the dashboard, after a successful password reset.

Click on the reset password link, and add customer email address.
Customer will receive the password reset link.
Once clicking the link, it will redirect to the password reset form.
Once change the password,

  "CUSTOMER SHOULD BE ABLE TO REDIRECT TO CUSTOMER DASHBOARD ITSELF.
  DON`T NEED TO LOGIN AGAIN."

Thanks


texts: Magento2 admin panel ordered product link

texts:
How to add products link in magento2 sales=> order tab in admin panel?
Also I want to add custom attribute to order grid in admin panel. for example want to add type(custom attribute) to admin panel sales=> order grid

More description: Login to admin panel, go to sales: order, open one of orders, you can see ordered items. I want to have item links and view products who ordered

also want to add one column in ordered items. want to show custom attribute like type or model in ordered items info


texts: How to set different prices for online and instore?

texts: I sell products on my store website, on ebay and in a physical store. I would like to discount online products as compared to my store products so I tried to use special pricing - but that reduces the price for everything. Is there a way to reduce the price online but keep the same price for checking goods out when customers are physically in the store?


texts: what are the steps to install magento module/extension, what is the state of compiler? on or off and is compiler should be on after module/ extension installation ?


texts: Magento 2 How to send data from one html template to another?

texts:
I'm developing 2 forms with knockout js and html template. This 2 forms templates need to be separated, however they share data in common, for example, coverages amounts (this templates are about insurances).
So I have my structure like this:
templates
 -portability.html
 -conversion.html
js
 -quote.js

The problem is that I feel that mixing methods of this 2 separated products in a single js file like quote.js will be a mess, because there will be methods applying just for portability.html and other methods applying just for conversion.html.
My idea:
Separate this methods in 2 different js, like portability.js and conversion.js
My problem:
I don't see how to send data from portability.js to conversion.js and vice versa.
This is how my phtml will look like when I get this 2 different js files communicated:

Greetings!


texts: Product image not displaying in Product listing Page

texts:
I have created one attribute called imageUrl for importing product image url. And made some changes in media.phtml and list.phtml. Now product images not displaying in product list page  but it displays images in product details page..

<img src="<?php echo $_product->getData('imageurl') ?>" />


texts: Change customer account create email template magento2?

texts: When a customer is registered a email is sent to customer.I want to set the styling of that templates.When i navigate from admin dashboard to Marketing->Email Templates.There are only two email templates for new order pickup order and new pickup order for guest.Where is the customer account email template?How i style that?


texts: install magento multi source Inventory after magento234 has been installed

texts:
I installed magento 234 and I have been using it . recently I tried to install a warehouse app and noticed it was giving me errors,
It specifically asked for
magento/module-inventory
magento/module-inventory-source-selection
I was told that the magento 234 did not come with inventory module in it.
How do i get this done? i have referred to other sites and I have been told to reinstall from scratch.
I need a way out
Urgent!


texts: How to create a refund with online in magento 2. I created the creditmemo but the transactions details are not showing in the transaction list. Please guide me, how to do it?


texts:
I am using Magento CE 1.9.2 and I am having some conflicts with Microsoft Edge:

Sometimes my cart and header links will just disappear (when I reload the page they appear again)
Sometimes the feedback messages (e.g.: Item added to cart) will be null

I did a lot of tests and could not find the cause of the problem. There is nothing in the log report and this is happening just with Microsoft Edge (I tested in Firefox, Chrome, Opera, Safari and all them works fine).

I also did some researchs on the internet and found few people talking about errors on Edge but didn't find any answer.

Does anyone know about possible conflicts between Magento and Microsoft Edge? Or any idea of how I could debug this to try find the error?

Thanks!


texts:
I changed the default on my Magento website for transactional emails and id like to set it back to default, but no longer have a copy of default HTML script.

Can someone please provide me that code snippet?

Go to System --> Transactional Emails -->  You will see a drop-down box to load default email templates. --> Select New Order and English) --> Load template. You will see below it will load.

Please copy and paste systems default name, subject, and template content so i can replace my changed template back to default.

I am using Magento ver. 1.9.0.1 Community if that makes a difference.

Curious on another note too, has anyone created their own templates that are clean and professional looking but better than the default? Please provide and I can take a look. Please let me know though it does not default template if you are sharing:


texts: Show custom Admin Messages In configuration section custom module Magento 1.x based on API response

texts:
I created a custom module which fetch data using third-party APIs.

In admin Dashboard after module installation.
I want to check few things form API( I am getting everything from API this is done , just need to show show message once admin activates the module ) If all is OK I want to show the message under the Enable/Disable button.

  If I try the below method ,  when I change the configuration values of my custom module. I hit API to validate few things

This works

  Mage::getConfig()->saveConfig('someotheremodule/debug/logenabled', '0', 'default', 0);
      Mage::getConfig()->saveConfig('smtpsomeotheremodulepro/debug/log_debug', '1', 'default', 0);

This is not working

  Mage::getConfig()->saveConfig('reviewrating/section_one/active', '1', 'default', 0);

How to change the config values by my custom module?
Currently I  attached  <backend_model>reviewrating/Statuswidget</backend_model>  to one of the fields. Is it the only way to get values and in this way i have to use same process for each field?

  In
  /var/www/html/magento16/app/code/local/Namespace/ReviewRating/etc/config.xml

     <!-- ... -->
            <admin_system_config_changed_section_sectionone>
                <observers>
                    <mymodule>
                        <type>singleton</type>
                        <class>Namespace_ReviewRating_Model_Observer</class>
                        <method>changeSystemConfig</method>
                    </mymodule>
                </observers>
            </admin_system_config_changed_section_sectionone>
        </events>
  </global>
        <!-- ... -->

  In /var/www/html/namespace/app/code/local/Namespace/ReviewRating/Model/Statuswidget.php

<?php
/**
 *
 * @author      inrsaurabh
 */

class Namespace_ReviewRating_Model_Statuswidget extends Mage_Core_Model_Config_Data
{

     protected function _beforeSave()
{
    $value = $this->getValue();
    Mage::log( $value );

    // if widget activated ( enable = 1 )

    $apidDataCheck = Mage::helper('reviewrating')->checkWidgetStatus( $value );
    $isError = $apidDataCheck['success'];
    Mage::log( $isError );

    if( $isError != 1 ){
        Mage::log('Disable module');

        Mage::getConfig()->saveConfig('reviewrating/section_one/active', '0', 'default', 0);
// above line dont change config value

        Mage::getSingleton('adminhtml/session')->addWarning( $isError );

    } else {
         Mage::getSingleton('adminhtml/session')->addSuccess('Widget Enabled');
    }

}

  In /var/www/html/magento16/app/code/local/Namespace/ReviewRating/etc/system.xml

 <sections>
        <reviewrating translate="label" module="reviewrating">
            <!-- -->
              <groups>
                <section_one translate="label">
              <!-- -->
              <active translate="label comment">
                        <label>Widget Status </label>
                        <frontend_type>select</frontend_type>
                        <sort_order>54</sort_order>
                        <source_model>adminhtml/system_config_source_enabledisable</source_model>
                        <backend_model>reviewrating/Statuswidget</backend_model>
                        <show_in_default>1</show_in_default>
                        <show_in_website>1</show_in_website>
                        <show_in_store>1</show_in_store>
              </active>
              <!-- ... -->
              </section_one>
              <!--- -->
             </groups>
        <!-- -->
      </section>

Please suggest how to proceed. I didn't find any link related to this in which I can hit API on enable/disable button and then show messages.

Thank You.


texts:
Hi I need to add custom button(like update wishlist, shere wishlist ...) to(frontend) "my account -> my wishlist". Please help me!

<wedding_gifts_index>
    <label>Customer My Account My Wishlist</label>
    <!-- Mage_Wishlist -->
    <update handle="customer_account" />
    <reference name="content">
  <block type="wedding/customer_wishlist_button" name="customer.wishlist.button.gifts" template="wedding/button/gifts.phtml" />
    </reference>
</wedding_gifts_index>


texts: Performance issue with 1k to 10k websites/ stores

texts:
I am trying to find a way to improve Magento performance when the amount of websites/ stores exceeds 1k, and my goal is around 10k. Here are some questions; any tips/ helps are extremely welcome!

Adding new websites/ stores is slow;
I comment out $this->cleanModelCache() in _afterSave() in Mage_Core_Model_Abstract, and the situation seems better but is getting slower with increasing number of websites/ stores. And I don't know what would this affect the whole system in the future.
Api calls become slow.
One of the main processes is to place order; my customized model deals with it by processing some data, and essentially using sales/quote model and sales/service_quote models. The process begins with Oauth. Both Oauth and placing order take longer when the number of website/ store grows, and the memory consumption seems larger. Does this have something to do with Mage loading the config xml, and the fact that config data gets bigger with increasing number of websites?
Opening up n98-magerun dev:console is taking longer; don't know the cause of it.
Saving configuration from admin panel takes longer; don't know how to improve it.

Is it possible to reconstruct the way Magento generate and load config data to lower its memory consumption? Is this one of the factors that cause performance issue for my situation?

Current Magento instance:
Version = Magento EE 1.14.2.4;
Config cache on; other cache off;
Using Mysql 5.6 and MongoDB( for catalog_category_entity, catalog_product_entity, core_website);
number of websites = number of stores = number of views = 1024;
number of product = 4501;

Thank you all in advance!


texts: Failed to Load Resource. Server Responded with a 404 on certain Products Images showing NULL!

texts:
I found this problem on our production site. Where any Config products that have a picture assigned to the config product with out of stock options return the image null when looking at the Product Page. Any help would be greatly appreciated. Images Below.
Error I am getting is Failed to load resource: the server responded with a status of 404 ()

Also I noticed when I look at Application Tab in Google Chrome Dev tools there is no Image to be found.


texts:
I added a service to my project in visual basic to connect to soap api of magento.
The connection seems to work but in my wsdl I havn't got the handler Mage_Api_Model_Server_V2_Handler. So I can't use it.

<service name="MagentoService">
<port name="Port" binding="typens:Binding">
<soap:address location="http://example.com/index.php/api/v2_soap/index/"/></port></service>

What I wrong?


texts:
I recently switched to client side less compilation to speed up development time. It's a lot faster than server side, but every time I want to do a page refresh, it breaks my theme, and I have to clear pub/static/frontend to fix it.

Are there any other settings that I need to change to fix that?

My errors in the console are
TypeError: require.config is not a function

and in network tab

TypeError: require.config is not a function. require.config(porto_config);

Thanks


texts: Magento 2 How do I override \vendor\magento\module-fedex\Model\Carrier.php?

texts:
I want to make changes on

  vendor\magento\module-fedex\Model\Carrier.php

How do I override this core file? I just want this completely override. Like what folder I should create and what files I have to create, and what Magento command I need to run after all files was created.

Thanks in advance.


texts:
After upgrade from v2.1.8 to v2.2.2, error is shown when i run Grunt exec

  $ grunt exec
  Loading "Gruntfile.js" tasks...ERROR

    Error: Cannot find file. Alias "themes" not set. Use "filesRouter.set" method to set it.
        at Object.get (/var/www/vhosts/default/dev/tools/grunt/tools/files-router.js:69:19)
        at Object. (/var/www/vhosts/default/dev/tools/grunt/configs/clean.js:8:47)
        at Module._compile (module.js:570:32)
        at Object.Module._extensions..js (module.js:579:10)
        at Module.load (module.js:487:32)
        at tryModuleLoad (module.js:446:12)
        at Function.Module._load (module.js:438:3)
        at Module.require (module.js:497:17)
        at require (internal/module.js:20:19)
        at module.exports (/var/www/vhosts/default/node_modules/load-grunt-config/lib/readfile.js:22:16)


texts:
I'm trying a page from a custom module, but the magento is showing me this message

The URL you request is not accessible.

This url is (usually) reachable, I made it over a year ago and didn't change anything in that module.
The weirdest, is that I've made a copy of the website 2 days ago (the problem is here since about 7 days), and I can't reproduce the bug on my dump the url is reachable...
I'm on Magento 2.2.4, and I can't easily rebuild the website on production...


texts:
I have controller file called Authorize.php, in this file i have check either the user is allowed to make request and i have other controller files like products.php and etc, i would like to call Authorize.php file in products.php or want to call Authorize function in my other controller files.

I would like to know, what will be the way to do so.


texts: Multiple taxes not applied on a checkout

texts:
I have a magento instance v 2.1.0.

I have created a tax rule as shown in the image below

I have created two tax rates CGST@9 and SGST@9 both at 9% rate and included in the tax rule GST@18 as shown above.

When I include a product with tax class as Taxable Goods and place order, at checkout only one tax is being applied on the product as shown in below image

Only SGST@9 tax rate is being applied i.e. only 9% tax is applied instead of 18%.

Why both of the tax rates are not applied?


texts: Issue with login customer create backend

texts:
I'm new here and I hope the community is able to help me out on starting with magento.

The issue I have is that the customer created via backend can't loging, while the frontend created user can.
I tried registering the same account via forntend and I receive a message that this profile already exists, meaning that the system acknoledge that customer created via backend.
I changed in phpmyadmin the ucustomer_entity website_id and is_active to the same specifics as the working customer. Saidly no effect.

Could anybody help me out about what would be the issue?


texts:
di.xml:

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:ObjectManager/etc/config.xsd">
    <preference for="Amasty\Reports\Block\Adminhtml\Navigation" type="Shop\Reports\Block\Adminhtml\Navigation" />
</config>

Block class:

<?php

namespace Shop\Reports\Block\Adminhtml;

class Navigation extends \Amasty\Reports\Block\Adminhtml\Navigation
{
    public function getConfig()
    {
    }
}

I'm trying to rewrite \Amasty\Reports\Block\Adminhtml\Navigation::getConfig method. However the original method is called when the page is loaded. When I try to rewrite other methods, they are rewritten successfully. What can be the cause of this? Thanks a lot!


texts: What is meant by "tier price" in magento?

texts: Can anyone explain what is the tire price in magento and how it is being calculated ?


texts: Does anyone know how the structure of products in magento is created? When creating a product which is the first table to receive values and its following .. I need to export my data to another magento, when I do a dump and step to a new bank the products are in the backend and everything else, the preview in the frontend also, but when I click on the product returns me 404, I opened the product in the backend and missing some product tabs, I came to the conclusion that in magento there are several foreign keys, so it depends on one table to be able to add another, would anyone have the order of these tables or do you have any source of which tables I have to insert? Example: catalog_product_entity after catalog_product_url_key after ...


texts: How to change the layout for a particular category page

texts:
I know that for the category page or product view page, we can change the layout in catalog_product_view.xml or catalog_category_view.xml.

But how do I change exactly for a single particular category page?


texts: Getting all the Carriers in dropdown menu

texts:
How do we get all the carriers available in Magento drop down menu? I want the carriers drop-down menu in user dashboard (not is Superadmin) so user can select and add the tracking no. I have gone through many post but unable to get the particular method.

Thanks in advance :)


texts: Calling minicart in phtml not showing dropdown on click

texts:
I'm calling minicart in my phtml like below
<?php  echo $this->getLayout()
          ->createBlock('Magento\Checkout\Block\Cart\Sidebar')
          ->setTemplate('Magento_Checkout::cart/minicart.phtml')
          ->toHtml(); ?>

But When I click on cart icon drop down is not showing. I inspected the dom there is not drop down ui widgets.


texts: Fedex - Shipping Label generation not working

texts:
I cannot identify the reason that cause Fedex Shipping Label not working on Magento (1.7.0.2).
Everytime I try to generate a new label, I got this message:

  An error occurred while creating shipping label.

Exception.log shows:

SoapFault exception: [SOAP-ENV:Server] Fault in app/code/core/Mage/Usa/Model/Shipping/Carrier/Fedex.php:1470

The exception is triggered by this call in Mage_Usa_Model_Shipping_Carrier_Fedex (1470)

$response = $client->processShipment($requestClient);

How can I go further ? Is it an issue on FedEx server side ?


texts: how correctly add HTML tags to setMessage

texts:
i have this code

 $result->setMessage(
                                Mage::helper('cataloginventory')->__('This item is not available and will be placed in a backorder queue. Please refer to the Backorder info page for details on how this order will be processed.', ($backorderQty * 1))
                            );

but result this code:

how correctly add HTML tags?


texts: Magento 2 Error while running Cronjob : Integrity constraint violation

texts:
I have 2 cronjobs that serve data from suppliers to a Magento store (Magento 2.2 (Community)).

This has been running for a few weeks without any issue, but this morning I got a whole list of error messages telling me :

  Uncaught PDOException: SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry '8718924885352.html-1' for key 'URL_REWRITE_REQUEST_PATH_STORE_ID'

I run both the jobs at the same time, maybe that is the problem?


texts:
I've gone around and around with this issue and moved no further. Just setting up a new store and if I go to https://wisevape.co.uk I get on page (not one that I can seem to edit) but if I go to https://wisevape.co.uk/home then I get my genuine home page that I can amend etc.

I've been playing with Stores/Config/General/Web and I can't make it go to the right place (I can't figure out where the other page is coming from either).

I'm new to Magento so it is probably something I'm missing. I'm running 2.2.6 CE and help on this would be gratefully received!

Thanks,
Adam


texts: Main content on homepage missing from time to time?

texts:
For no particular reason the main content of my shops homepage is missing. The footer and header are still there. I am not running any extra cache, just the basic Magento stuff.

I have no idea where to look. When I clean the Magento cache, it starts working again.

Any ideas what the problem could be?

Thanks!


texts: I want to use ADD TO CART via URL in Magento 1.8 but don't know which files to change

texts:
I have seen some suggested changes to make to call the FORM KEY to allow the ADD TO CART FROM URL to work.

<?php

$formKey = Mage::getSingleton('core/session')->getFormKey();?>

<form action="/checkout/cart/add/product/<?php echo $productid; ?>" method="post">
    <input type="hidden" name="form_key" value="<?php echo $formKey; ?>" />

    <input type="text" name="qty"> QTY

    <input type="submit" value="Add to basket" />
</form>

However, I don't know which files to change.  Can anyone help me?

Many thanks for any help given


texts: Magento 2 : My billing and shipping address the same checkbox is auto uncheck after reload payment block

texts:
In Checkout page ,
Magento 2 :
My billing and shipping address the same checkbox is automatically uncheck while reload process payment block during ajax process.


texts: upload migrate tool instead of composer - possible?

texts:
While trying to migrate, I have some complaints about magento not having source / destination documents mapped; however, they are in map.xml (default there, no need to tweak).

I'm using the correct migration tool (2.2.5) from 1.6.2.

←[0;31m[2018-07-10 00:52:26][ERROR]: Source documents are not mapped:core_store,core_store_group,core_website
←[0m←[0;31m[2018-07-10 00:52:26][ERROR]: Destination documents are not mapped: store ,store_group,store_website
←[0m←[0;34m[NOTICE]: You can use --auto or -a option to ignore not mapped differences between source and destination to continue migration

I have double checked source database and the tables are in the old magento database.

Any ideas?


texts: Can i use authorize.net payment method in indian currency?

texts: I have create 2 store INR and US Dollar.I want 2 create 2 separate payment methods store wise. Can i use authorize.net payment method in Indian currency?. I don't know which payment method use for Indian currency.Please let me suggest which one use of payment method.


texts: Detect change in system.xml field with observer

texts:
I need to config a observer to detect when a option created in system.xml change its value.

The field is made by the code above:

<config>
    <sections>
         <dev>
            <groups>
                <pico_group>
                    SGPico Configurações
                    <frontend_type>text</frontend_type>
                    <sort_order>250</sort_order>
                    <show_in_default>1</show_in_default>
                    <show_in_website>1</show_in_website>
                    <show_in_store>1</show_in_store>
                    <fields>
                        <ativo translate="label">
                            Pico está Ativo?
                            <frontend_type>select</frontend_type>
                            <source_model>adminhtml/system_config_source_yesno</source_model>
                            <sort_order>1</sort_order>
                            <show_in_default>1</show_in_default>
                            <show_in_website>1</show_in_website>
                            <show_in_store>1</show_in_store>
                        </ativo>
                    </fields>
                </pico_group>
            </groups>
        </dev>
    </sections>
</config>

I search and tried to config the observer like that:

<admin_system_config_changed_section_dev_pico_group>
    <observers>
        <auto_invoice_order>
            <type>singleton</type>
            <class>IsabelaFlores_SGPico_Model_Observer</class>
            <method>teste</method>
        </auto_invoice_order>
    </observers>
</admin_system_config_changed_section_dev_pico_group>

But it didn't work


texts: what is the difference between sorting blocks using after/before or sorting them in the xml file?

texts:
I think the answer should be to preserve upgradability, so I can sort blocks using a local.xml file instead of modifying the original xml layout. But, what if I copy my own xml file, for example page.xml and I just sort blocks in the footer?

Example:

<block type="page/html_footer" name="footer" as="footer" template="page/html/footer.phtml">
    <block type="page/switch" name="store_switcher" as="store_switcher" template="page/switch/stores.phtml"/>
    <block type="page/template_links" name="footer_links" as="footer_links" template="page/template/links.phtml"/>
</block>

to:

<block type="page/html_footer" name="footer" as="footer" template="page/html/footer.phtml">
   <block type="page/template_links" name="footer_links" as="footer_links" template="page/template/links.phtml"/>
   <block type="page/switch" name="store_switcher" as="store_switcher" template="page/switch/stores.phtml"/>
</block>

Any other advantage?

thanks


texts:
I want to create a different header template for sales emails i.e. header sales instead of the default header. The template files are defined in locale/LANG/template/email/html/ simply creating a new template file headersales.html and referencing it in the new order email template as

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

Doesn't work. Are the template names defined somewhere else?


texts: Change media template for single product

texts:
I am trying to update the media template via XML in Magento. Somehow my method is not working:

First I included <?php var_dump($this->getNameInLayout()); ?>in the template to get the correct block name. In this case the output is: "product.info.media"

Second step is to updated the product design via manage products > Product > Design > Custom Layout Update. Here I try to update the xml for this single product:

<reference name="product.info.media">
    <action method="setTemplate"><name>ecommerceteam/cloud-zoom/catalog/product/view/media-venst.phtml</name></action>
</reference>

This is not working.

Update:
This is what happens in the catalog.xml

    <reference name="content">
        <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"/>

Update:

I was not able to update a child block via the product xml layout. I resorted to switching the theme.


texts: not able see the navigation menu bar on my home page

texts: i installed 19.2 version through shared hosting, my home page showing no sign of menu (right or left) I have created category and products and put all the products under the respected category but no luck!!!!


texts: Stock Status in backend product overview

texts:
I have a simple question :)

In Backend, the products status is displayed (Active/Inactive) in the Catalog-> Manage Product section. it is also possible to mass-action wether products should be active or inactive.

See: http://screencast.com/t/5LHlczWjKr1

I would like the same for Stock Availability (in stock/out of stock)

two reasons:

To be able to mass-action "back in stock"
To get a better overview over, which products are out of stock

Hope someone have an answer :)

Jack


texts: Magento2 forgot password email takes two minutes to send

texts:
Hi I am using docker with magento.
For the sales email, I have configured the asynchronous email option. The CRON job runs every 1 minute, so the order process and emails are running very smooth.
But for the customer emails, it is taking around 2 minutes to save the forgot password and the email is taking the most time.

How can I solve this?


texts:
I have installed the World Pay extension on our Magento 2.1.8 with no issues. Everything seemed to be just fine. However, on both, live and test mode environments, we can’t successfully complete an order.

When we get to the checkout and want to pay using the World Pay Card payment. Once the credentials are in, press the Place Order button and we get an error message: “Error, please try again”. There is nothing in the Google Chrome Console, also nothing in the logs.

When I enable the 3D secure, I get this error in the var > report > api > 1020389781593 :

s:1152:"Fatal Error: 'Uncaught Error: Class 'Worldpay\Worldpay' not found in /domains/domain.co.uk/http/app/code/Magenest/Worldpay/Model/Methods/WorldpayPayments.php:260
Stack trace:
#0 /domains/domain.co.uk/http/app/code/Magenest/Worldpay/Model/Methods/Card.php(160): Magenest\Worldpay\Model\Methods\WorldpayPayments->setupWorldpay()
#1 /domains/domain.co.uk/http/app/code/Magenest/Worldpay/Model/Methods/Card.php(306): Magenest\Worldpay\Model\Methods\Card->createWorldpayOrder('000000026', Object(Magento\Sales\Model\Order\Payment\Interceptor), 'TEST_RU_0e19564...', '6.95', 'GBP', false, false, Object(Magento\Sales\Model\Order))
#2 /domains/domain.co.uk/http/app/code/Magenest/Worldpay/Model/Methods/Card.php(127): Magenest\Worldpay\Model\Methods\Card->createOrder(Object(Magento\Sales\Model\Order\Payment\Interceptor), '6.95', false)
#3 /domains/domain.co.uk/http/vendor/magento/module-sales/Model/Order/Payment/Operations/CaptureOperation.php(82): Magenest\Worldpay\Model\Methods\Card->capture(Object(Mage' in '/domains/domain.co.uk/http/app/code/Magenest/Worldpay/Model/Methods/WorldpayPayments.php' on line 260";

The  line 260 is this:

public function setupWorldpay()
{
    $service_key = $this->config->getServiceKey();
    $worldpay = new \Worldpay\Worldpay($service_key); ---- line 260

    $worldpay->setPluginData('Magento2', '2.0.25');
    \Worldpay\Utils::setThreeDSShopperObject([
        'shopperIpAddress' => \Worldpay\Utils::getClientIp(),
        'shopperSessionId' => $this->getShopperSessionId(),
        'shopperUserAgent' => '',
        'shopperAcceptHeader' => '*/*'
    ]);
    return $worldpay;
}

Anyone with similar error or knows how to solve it?


texts: How to download a image in magento admin panel from ordered items

texts:
I have been trying to give a link to admin panel for downloading the product image ordered in sales > order > view. Now its done and I have given the link to download as

www.example.com/namespace/index(mycontroller)/download(myaction)/name/screen.jpg

Inside my controller's action I get the file name as parameter, and I knew the location where the file has been located. Now what should I need to make the image downloadable?

This is my controller action code:

public function downloadAction() {
$name = $this->getRequest()->getParam('name');
$file = Mage::getBaseDir(). DS . 'media' . DS . 'catalog' . DS . 'upload' . DS . $name;
$content = readfile($file);
$this->_prepareDownloadResponse($name, $content);
}

When I try to run the above code I get the following error.

  Cannot send headers; headers already sent

Please help


texts: WYSIWYG Editor isn´t working after using a Subdomain for JavaScript

texts:
I made 3 subdomains for the Media, JS and Skin Path to improve the site loading speed.

After switching the unsercure URL paths in Backend under Configuration > Web > unserucre from

{{unsecure_base_url}}js/

to

http://js.myDomain.de/js/

the
WYSIWYG Editor in the Backend isnt working.
It Shows all Icons but when I click to enable the HTML view of a CMS page only an empty page without html code opens in a seperate window.

JS is working fine at the frontend. If I reset my changes the WYSIWYG Editor starts working agiain.

Any Ideas for a magento newbie?


texts: How to translate string text to amount in magento

texts:
I have develop a payment gateway where an admin can put their invoice fee. Problem is this, when user update fee 15.20 then its OK but when user insert price as 15,20 then its make problem means he is using comma(,) as decimal separated and dot(.) as thousand separated.

Please anyone suggests how to parse string 15.123,98 to 15,123.98 is their any magento function to do this?


texts: How Can I add a newsletter checkbox on magento2 checkout

texts:
Sorry, I'm new in Magento 2.3 and I need your help to create some code.

I need to build a newsletter checkbox the  on checkout page. I have tried many exemple but it doesn't work on Magento 2.
I don't understand the structure.

Anyone Can help me ? Thank you!


texts: checkout page not working on multi-lingual website

texts:
I am building on bilingual Magento website
Magento version 2.1.7 CE

I just realized the checkout page on page on our french website is not working :(

https://thailandfightgear.fr/checkout/

on the English website, the page is working (but pretty slow, even on production mode) :

https://thailandfightgear.com/checkout/

I tried to recompile the website

  php bin/magento setup:upgrade
  php bin/magento setup:di:compile

  php bin/magento setup:static-content:deploy
  php bin/magento setup:static-content:deploy fr_FR

but it didn't help.

Any idea how to fix the problem who be very useful. I would like to fix that soon :-)

Thanks in advance for your help.

while loading the checkout page I have these errors :

  theme.js:28 Uncaught TypeError: $(...).stellar is not a function
      at HTMLDocument. (theme.js:28)

at fire (jquery.js:3232)

at Object.add [as done] (jquery.js:3291)

at jQuery.fn.init.jQuery.fn.ready (jquery.js:3542)

at theme.js:27

at Object.execCb (require.js:1650)

at Module.check (require.js:866)

at Module.<anonymous> (require.js:1113)

at require.js:132

at require.js:1156 (anonymous) @ theme.js:28 fire @ jquery.js:3232 add @ jquery.js:3291 jQuery.fn.ready @ jquery.js:3542 (anonymous) @

  theme.js:27 execCb @ require.js:1650 check @ require.js:866

  (anonymous) @ require.js:1113 (anonymous) @ require.js:132 (anonymous)

  @ require.js:1156 each @ require.js:57 emit @ require.js:1155 check @

  require.js:917 enable @ require.js:1143 init @ require.js:774

  callGetModule @ require.js:1170 completeLoad @ require.js:1564

  onScriptLoad @ require.js:1671 (index):1200 Uncaught TypeError:

  $(...).swMegamenu is not a function

at (index):1200

at Object.execCb (require.js:1650)

at Module.check (require.js:866)

at Module.<anonymous> (require.js:1113)

at require.js:132

at require.js:1156

at each (require.js:57)

at Module.emit (require.js:1155)

at Module.check (require.js:917)

at Module.enable (require.js:1143) (anonymous) @ (index):1200 execCb @ require.js:1650 check @ require.js:866 (anonymous) @

  require.js:1113 (anonymous) @ require.js:132 (anonymous) @

  require.js:1156 each @ require.js:57 emit @ require.js:1155 check @

  require.js:917 enable @ require.js:1143 init @ require.js:774

  callGetModule @ require.js:1170 completeLoad @ require.js:1564

  onScriptLoad @ require.js:1671 dataPost.js:13 Uncaught TypeError:

  $.widget is not a function

at dataPost.js:13

at Object.execCb (require.js:1650)

at Module.check (require.js:866)

at Module.<anonymous> (require.js:1113)

at require.js:132

at require.js:1156

at each (require.js:57)

at Module.emit (require.js:1155)

at Module.check (require.js:917)

at Module.<anonymous> (require.js:1113) (anonymous) @ dataPost.js:13 execCb @ require.js:1650 check @ require.js:866

  (anonymous) @ require.js:1113 (anonymous) @ require.js:132 (anonymous)

  @ require.js:1156 each @ require.js:57 emit @ require.js:1155 check @

  require.js:917 (anonymous) @ require.js:1113 (anonymous) @

  require.js:132 (anonymous) @ require.js:1156 each @ require.js:57 emit

  @ require.js:1155 check @ require.js:917 enable @ require.js:1143 init

  @ require.js:774 callGetModule @ require.js:1170 completeLoad @

  require.js:1544 onScriptLoad @ require.js:1671

  jquery-ui-timepicker-addon.js:18 Uncaught TypeError: Cannot read

  property 'timepicker' of undefined

at jquery-ui-timepicker-addon.js:18

at Object.execCb (require.js:1650)

at Module.check (require.js:866)

at Module.enable (require.js:1143)

at Module.init (require.js:774)

at callGetModule (require.js:1170)

at Object.completeLoad (require.js:1544)

at HTMLScriptElement.onScriptLoad (require.js:1671)


texts:
I am trying to setup a Invoice email template in Magento, and I see that the most of the informations I want is displayed.

However, I would like to display the shopping cart content with only the item's name and summary of the cart. I have some kind of product description added in the cart with every product, I don't want that part to be displayed in the email template.

I see that the cart is displayed in email template with:

{{layout area="frontend" handle="sales_email_order_invoice_items" invoice=$invoice order=$order}}

Is there a way to display only items, and without the description for every product?


texts: how to upload video file through wysiwyg editor in magento?

texts:
My home page needs to be a promotional video to be embedded. I thought to create a static block which will contain the video file and I just add that block to the content by updating the layout in admin side.
 But the problem is that I cann't upload a video file through wysiwyg editor. Sometime it says "Disallowed Type" . Sometimes it simply don't do anything while uploading file.
 Kindly help me. Thanks.


texts: How to get All the active shipping methods and shipping rate and set minimum shipping rate method in quote programmatically in magento2?


texts: I'm trying to add a bank account number to the payment method in the checkout but i can't find the option in the magento back end, where should i look this up?


texts: Magento 2 : Change store view when currency is changed

texts:
Is it possible to change the store view when currency is changed?
For example, On my site, I have 3 currency and 3 stores view, Now when I'm switching my currency USD then storeview also needs to change to an English store view.
Can anyone help me to do that?
Any help would be appreciated thanks in advance.


texts: Checkout payment not working on different networks

texts:
I have a very strange problem on my new hots . I have  Magento site at: https://babybeddingdesign.com/
one of the buyers reports that on checkout he has no option of payment. I have tested it and I can see a very strange problem that i think related to IP block because i have no other way to explain it.
When i test it with my office wifi all work ok. When i test it with my mobile network it's not work ok and i am not getting PayPal payment as an option.
I have tested it also on my pc one time when i contact to wifi and the other time with a hotspot from my phone.
This has to be something with IP because this is something with security.


texts: How to refund a specific item of an order in Magento 2 programmatically?

texts:
Can anyone please help me to refund a specific order item of an order programmatically.
Currently, am using Magento 2.2 enterprise edition.


texts: "Use default value" with category in AvS/FastSimpleImport : how?

texts:
I'm trying to import a category array with AvS/FastSimpleImport where:

Index 0: the default scope
Index 1: values for the it store
Index 2: values for the en store

The goal is to set Use default value for the ###EMPTY### values.

This is my array, and it works like a charm:

$arrAvS
array (
  0 =>
  array (
    '_root' => 'Default Category',
    'is_active' => 'yes',
    'include_in_menu' => 'yes',
    'available_sort_by' => NULL,
    'default_sort_by' => 'position',
    'display_mode' => 'static block only',
    'code_category' => 'D',
    '_category' => 'My category',
    'url_key' => 'my-cat',
    'meta_title' => 'DEFAULT: meta-title',
    'meta_description' => 'DEFAULT: meta-descr',
    'description' => 'DEFAULT: descr',
  ),
  1 =>
  array (
    '_store' => 'it',
    'name' => 'IT: name',
    'url_key' => 'it-slug',
    'meta_title' => 'ITA: meta-title',
    'meta_description' => 'ITA: meta-descr',
    'description' => 'ITA: descr',
  ),
  2 =>
  array (
    '_store' => 'en',
    'meta_title' => 'EN: meta-title',
    'meta_description' => 'EN: meta-descr',
    'name' => 'EN: name',
    'url_key' => 'en-slug',
    'description' => 'EN: description',
  ),
)

Again, this works as expected.

The problem occurs  when I want to set the store value to Use default value. For example, i change the second array from 'name' => 'EN: name', to 'name' => '###EMPTY###' (description also). In this scenario, the name|description fields in the EN storeview simply get set to empty

The importing code is:

$import = Mage::getModel('fastsimpleimport/import');
$import->processCategoryImport($arrAvS);

Admin config:

The store is a july-SUPEE patched Magento ver. 1.9.2.4.

AvS is 0.7.1.

Any help is greatly appreciated

One more example:

````

    $data = array();
    $data[] = array(
        '_root' => 'Default Category',
        '_category' => 'Myyy Category',
        'description' => 'Myyy Category Description',
        'is_active' => 'yes',
        'include_in_menu' => 'yes',
        'meta_description' => 'Myyy Category Meta',
        'available_sort_by' => 'position',
        'default_sort_by' => 'position',
    );

    $data[] = array(
        '_store' => 'en',
        'name' => 'I don't want to put a custom text here, must use default',
        'description' => 'Myyy Category EN DESCR'
    );

    $this->import
        ->processCategoryImport($data);

````

To use default for name, I changed the second element to:

'name' => false

nope, still do not use default, displays empty text

'name' => null,

nope

'name' => Mage::getStoreConfig('fastsimpleimport/general/symbol_for_clear_field')

nope

I'm fresh out of ideas, thanks


texts: Magento 2. Make product page as first page

texts:
How to make a specific product page as homepage (first page) in Magento 2.1.11?

Any ideas ?


texts: How to display product attributes on products page magento 2.1

texts:
Please see attached screenshot:
[![enter image description here][1]][1]

I created one custom product attributes ETA_DATE and I want to display same as attached image.
How to display this attribute on product page?


texts: Magento 2: System.xml configuration shows blank

texts:
I have created system.xml file in my module but it is show me blank

Path:-app/code/Amitshree/Customer/etc/adminhtml/system.xml

Code:-

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Config:etc/system_file.xsd">
    <system>
        <tab id="bliss" translate="label" sortOrder="10">
            bliss
        </tab>

            <class>separator-top</class>
            Customer
            <tab>bliss</tab>
            <resource>Amitshree_Customer::customer_config</resource>
            <group id="general" translate="label" type="text" sortOrder="10" showInDefault="1" showInWebsite="0" showInStore="0">
                General Configuration
                <field id="your_email_template_field_id" translate="label comment" type="select" sortOrder="2" showInDefault="1" showInWebsite="1" showInStore="1">
                    Label Of Your Field
                    <source_model>Magento\Config\Model\Config\Source\Email\Template</source_model>

                </field>
            </group>

    </system>
</config>

Error:-

app/code/Amitshree/Customer/etc/email_templates.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Email:etc/email_templates.xsd">
    <template id="your_email_template_id" label="Label Of Your Template File" file="your_email_template.html" type="html" module="Amitshree_Customer" area="adminhtml"/>
</config>

app/code/Amitshree/Customer/etc/config.xml

<?xml version="1.0"?>

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../Store/etc/config.xsd">
    <default>
    </default>
</config>


texts: Data scaling in magento 2 like integration nosql to load product data from nosql

texts: How we can integrate nosql with magento to load pages data faster than mysql


texts: How to check category has grand children exist in any of its children using category id?


texts: Split order into seperate orders and calculate shipping seperately with ups and fedex and different origin addresses

texts:
When a customer comes to our store and goes to check out on multiple items, I need to write a module to calculate shipping based on several factors. I have determined from my research that the following should happen:

First, I need to separate the cart items into different orders for shipping calculation. I want the orders to be sorted by "vendor" attribute value. "Vendor" is an attribute that we added to the system that is applicable for all simple products. So say in the cart there is a pink shirt with "vendor" value "1", a pencil with "vendor" value "1", and a blue shirt with "vendor" value "2". All items with "vendor" value "1" need to be one order, while the item with "vendor" value "2" need to be a different order. I see this other question answers this dilemma, but then raises another. How do I do this but display the seperate orders as one order during checkout to customers and only collect payment once?

Second, I need to calculate shipping with Magento's default UPS and Fedex shipping functionalities but with an origin address that is determined by the "vendor" value number (stored in a separate database table). Any suggestions welcome!

I am using code snippets to get me started from here and here.

I will probably have several questions, but the first ones are those in bold above.

UPDATE
I decided it would be best to override the multiple shipments magento core module to do what I'm trying to do. Please help me find where and what to put to manipulate the multishipping Magento functionality to break up an order's items into shipments based on the "vendor" attribute! I'm struggling with this.


texts: How to add js file to module and insert it to module layout

texts:
I have a module which add layout to admin create order like this:

  app/design/adminhtml/default/default/layout/mymodule.xml

<?xml version="1.0"?>
<layout>
    <adminhtml_sales_order_create_index>
        <reference name="before_body_end">
            <block type="mymodule/adminhtml_order" name="mymodule_admin_order_create" template="mymodule/admin_order_create.phtml"></block>
        </reference>
    </adminhtml_sales_order_create_index>
</layout>

I want to add my js file to the adminhtml_sales_order_create_index, but I don't know where to put the js file in my module directory and how to put it in the layout.


texts: Send different email template to customer

texts:
I have a custom module which is a custom form for the user to book an appointment, this form works fine with no issues, the form once submitted sends and email to both the admin and user/customer but it uses the same template but what I'd like is the customer to receive a different email with a success message etc.
I have this is my email_templates.xml
<?xml version="1.0" encoding="UTF-8"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Email:etc/email_templates.xsd">

    <template id="video-appointment" label="Video Appointment Form" file="video-appointment.html" type="html" module="VideoAppointment_Appointmentform" area="frontend"/>
    <template id="video-appointment-customer" label="Video Appointment Success" file="video-appointment-customer.html" type="html" module="VideoAppointment_Appointmentform" area="frontend"/>

</config>

And I have this in my Post.php file
public function execute()
    {
        $post = $this->getRequest()->getPost();
        try
        {
            // Send Mail
            $this->_inlineTranslation->suspend();
            $storeScope = \Magento\Store\Model\ScopeInterface::SCOPE_STORE;

            $sender = [
                'name' => $post['name'],
                'lastname' => $post['lastname'],
                'email' => $post['email'],
                'phone' => $post['phone'],
                'byphone' => $post['byphone'],
                'bytext' => $post['bytext'],
                'byemail' => $post['byemail']
            ];

            $sentToEmail = $this->_scopeConfig ->getValue('trans_email/ident_custom1/email',\Magento\Store\Model\ScopeInterface::SCOPE_STORE);

            $sentToName = $this->_scopeConfig ->getValue('trans_email/ident_custom1/name',\Magento\Store\Model\ScopeInterface::SCOPE_STORE);

            $transport = $this->_transportBuilder
            ->setTemplateIdentifier('video-appointment')
            ->setTemplateOptions(
                [
                    'area' => 'frontend',
                    'store' => \Magento\Store\Model\Store::DEFAULT_STORE_ID,
                ]
                )
                ->setTemplateVars([
                    'name'  => $post['name'],
                    'lastname' => $post['lastname'],
                    'email'  => $post['email'],
                    'phone'  => $post['phone'],
                    'byphone' => $post['byphone'],
                    'bytext' => $post['bytext'],
                    'byemail' => $post['byemail']
                ])
                ->setFrom($sender)
                ->addTo($sentToEmail,$sentToName)
                ->addBcc($post['email'])
                //->addTo('owner@example.com','owner')
                ->getTransport();

                $transport->sendMessage();

                $this->_inlineTranslation->resume();
                $this->messageManager->addSuccess('Thankyou for your appointment booking request, we will be in contact with you shortly.');
                $this->_redirect('video-appointment/index/index');

        } catch(\Exception $e){
            $this->messageManager->addError($e->getMessage());
            $this->_logLoggerInterface->debug($e->getMessage());
            exit;
        }

I can see the amil template is being set by
->setTemplateIdentifier('video-appointment')

But how do I set another template ie the video-appointment-customer.html so that sends to the customer?


texts:
I am trying to create a single sign on module for my company within Magento. I've set up a connection to the OAuth guarded server and managed to log in on the authentication server.

What I would like to do now is create an admin user in Magento if one doesn't exist with the retrieved username. If there is an administrator user with the given username then I want to log them in.

Currently I'm having trouble finding the administraot user object by username. I've found the following code:

/** @var \Magento\User\Model\User $user */
$user = $this->_objectManager->get('Magento\User\Model\User')->loadByUsername('username');

Which returns an object regardless of the username I enter but the object doesn't seem to contain any usable administrator data.

Concretely my question is: how do I retrieve the user/admin model by its username and how do I verify if that model actually contains a user/admin object which I use to log in.


texts: Magento 2 module “data_version - not upgrading"?

texts:
In Magento 2.0 I have written UpgradeData and UpgradeSchema and I have changed the setup_version in module.xml. After that I run php bin/magento setup:upgrade After this in the database, schema_version is upgrading but data_version not upgrading. Any Ideas?

UpgradeData.php

namespace Vendor\Pawan\Setup;
use Magento\Framework\Setup\UpgradeDataInterface;
use Magento\Framework\Setup\ModuleContextInterface;
use Magento\Framework\Setup\ModuleDataSetupInterface;

/**
 * Upgrade data for SImple Google Shopping
 */
class UpgradeData implements UpgradeDataInterface
{

    /**
     * @param ModuleDataSetupInterface $setup
     * @param ModuleContextInterface   $context
     */
    public function upgrade(ModuleDataSetupInterface $setup, ModuleContextInterface $context)
    {

        // $context->getVersion() = version du module actuelle
        // 10.0.0 = version en cours d'installation

        if (version_compare($context->getVersion(), '10.0.0') < 0) {
            $installer = $setup;
            $installer->startSetup();
            // do what you have to do

            $installer->endSetup();
        }
    }
}

Module.xml

<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../lib/internal/Magento/Framework/Module/etc/module.xsd">
    <module name="Vendor_Pawan" setup_version="2.1.1">

    </module>
</config>


texts:
i am uploading product images through admin panel but when i upload image then error and not showing any error

i am use code for showing error

public function save($destinationFolder, $newFileName = null){
$this->_validateFile();

if ($this->_allowCreateFolders) {
    $this->_createDestinationFolder($destinationFolder);
}

if (!is_writable($destinationFolder)) {
    // Put a mage::log() and check what is the folder magento is looking for.
    Mage::log($destinationFolder);
    throw new Exception('Destination folder is not writable or does not exists.');
}

. . . . .

}

please help me


texts: Magento : Need a to change position of right side navigation

texts:
I have to change in right navigation categories , price filter and Popular tags positions.

As you show in Image I want change of popular tags(1) first to last means in last after top Rated Product(5) .

Ans just want to change 2-3 section position means First I want Filter By Price and Then after Categories.

I also use AFTER and BEFORE in XML file but is not woring.

Let me now proper and best way to set it.


texts: How do I customize the Terms and Conditions Page on Magento?

texts:
When I go to Sales -> Terms and Conditions -> the page to edit my conditions, there is no WYSIWYG to edit the content.
I have a responsive website. If I put unformatted text on the terms and conditions, it overflows the content box on the front office.

If I put HTML tags on the back office, it still overflows on the front office and when I inspect the element, I can see that Magento adds a  tag with "plain plain" class.

I tried to switch the "show content as" from text to HTML but it does nothing.

How can I customize the terms and conditions ?
How can I do so it doesn't overflow ?
Why is this  tag appearing ?

I have Magento ver. 1.9.1.0


texts:
In patch which implements DataPatchInterface there is a method "getDependencies()" which seems to be used if one patch need to be played before current one.
But problem is if required patch define in getDependencies was already played the cli setup:upgrade returns me "Patch xxx cannot be applied twice".

So how can I make sure that patch is played before another one if I init new  environment ?


texts: On hover instead of 'click' header account links RWD theme magento 1.9.4

texts:
I'd like to use hover instead of click to display the head-account drop down links. I added the javascript to the bottom of header.phtml

  app\design\frontend\rwd\default\template\page\html\header.phtml

    <script type="text/javascript">
    $j(document).ready(function(){
        $j(".skip-account").hover(function() {
            $j(this).addClass("skip-active");
            $j("#header-account").addClass("skip-active");
        }, function() {
            $j(this).removeClass("skip-active");
            $j("#header-account").removeClass("skip-active");
        });
        $j(".skip-content").hover(function() {
            $j(this).addClass("skip-active");
            $j(".skip-account").addClass("skip-active");
        }, function() {
            $j(this).removeClass("skip-active");
            $j(".skip-account").removeClass("skip-active");
        });
    });
</script>

But when I hover the head search box, there is a shadow under the search box. Also when I hover the main menu, the background has a shadow. Please advise. Thank you.


texts: City dropdown values on checkout page changes to other store cities on browser autocomplete

texts:
I am facing a very strange issue where the city dropdown shows the cities of KSA and when the user selects his dubai address from browser's autocomplete option in street address field

the city dropdown values also changes to show all UAE cities while the user is still in KSA store.

This is a 2 store website and I am using EAdesign ROMcity extension for city dropdown feature. Any help would mean a lot.


texts: Get zipcode inside track.phtml to track shipment of a order

texts:
How can I get the zipcode of the order inside the track.html file?

I tried this, but that does not work:

<?php echo $this->escapeHtml($this->getShippingAddress()->getPostcode()) ?>


texts: How i can regenerate magento products url keys

texts:
I run below script in browser but I have more products and all finish in internal server error. Can I change URL for only configurable products? How can i re-generate URL key based on product name for each store view?

<?php
    require 'app/Mage.php';
    Mage::app();
    Mage::getModel('catalog/product')->setStoreId(1);
    $amount = 0;
    $model = Mage::getModel('catalog/product');
    $products = $model->getCollection();
    foreach ($products as $product) {
        $model->load($product->getId());
        $product->setUrlKey($model->getName())->save();
        set_time_limit();
        $amount++;
    }


texts: magento 2: get verbose output from indexer

texts:
I am having an issue with the customer_grid indexer
php bin/magento index:reindex customer_grid

After running this command, the cli will wait indefinitely for the process to finish. I use update indexer_state set status='invalid' where status ='working' to reset the customer_grid index but then same thing happens after running the command again.

Is there a way to have a more verbose output or debug log for this command that I can refer to figure out what is causing the indexer to fail.


texts: Magento 1.9 multi website with language switcher enabled

texts:
I have a multilanguage and multicurrency installation: test.com and test.com/en

test.com has Italian language and euro currency
test.com/en has english language and dollars currency

I needed to create 2 websites instead of 2 stores because each language needs to have separate currency (200 euro by default are converted by magento but I want to be able to set 200 dollars without that magento converts nothing) so I enabled "

  system -> configuration -> catalog -> catalog- > price -> Catalog
  price scope

to website and now each product translation has different currencies and everything is fine

The problem is that now I only have 1 store on each website so the language switcher, the currency switcher and the alternate links does not work

I was able to convert the language switcher with this but for the others I can't find anything and I don't think it's the right way


texts: Missing coupon field in cart/checkout process

texts:
I have added coupon code for free shipping in the Shopping Cart Price Rules (Magento 1.4.1.1), but I don't see any coupon code field in a cart or checkout process.

I have checked checkout.xml file and proper line exists

<block type="checkout/cart_coupon" name="checkout.cart.coupon" as="coupon" template="checkout/cart/coupon.phtml"/>

Edit:

It looks like coupon functionality was removed from coupon.phtml file, which contains now only

<!-- coupon code removed-->

Can someone could to provide proper file for that Magento version?

Thanks


texts: Add compare products block to the left column 1.9 rwd theme

texts:
I am using the rwd theme in magento 1.9 and want to add the compare products block below the "shop by" section. I thought i could do it be editing the catalog.xml file and moving the code for the block from under the right section to the left, but it didn't seem to work even after flushing the cache.

from catalog.xml:

<!-- Mage_Catalog -->
        <reference name="left">
<block type="catalog/product_compare_sidebar" before="cart_sidebar" name="catalog.compare.sidebar" template="catalog/product/compare/sidebar.phtml"/>
            <!--<block type="core/template" name="left.permanent.callout" template="callouts/left_col.phtml">-->
                <!--<action method="setImgSrc"><src>images/media/col_left_callout.jpg</src></action>-->
                <!--<action method="setImgAlt" translate="alt" module="catalog"><alt>Our customer service is available 24/7. Call us at (555) 555-0123.</alt></action>-->
                <!--<action method="setLinkUrl"><url>checkout/cart</url></action>-->
            <!--</block>-->
        </reference>
        <reference name="right">

            <!--<block type="core/template" name="right.permanent.callout" template="callouts/right_col.phtml">-->
                <!--<action method="setImgSrc"><src>images/media/col_right_callout.jpg</src></action>-->
                <!--<action method="setImgAlt" translate="alt" module="catalog"><alt>Keep your eyes open for our special Back to School items and save A LOT!</alt></action>-->
            <!--</block>-->


texts: Magento2 translating Javascript (KO) template text

texts:
I am trying to add a translation for the text <!-- ko i18n: 'Store credit available' --><!-- /ko --> present in vendor/magento/module-customer-balance/view/frontend/web/template/payment/customer-balance.html, but if I try to change the text in my i18n/en_US.csv, still its not working.

I have flushed the cache and and used static content deploy.

Is there a different way to add translations for KO templates ?


texts: paypal only available until the amount x

texts:
I need a solution that paypal only is available until the amount x.

Like

If amount > 1234 then {
paypal = false ;
}else{
};

Has anyone a solution for this?

Many thanks


texts: Display Multidimensional Array of Custom Options from order

texts:
I created a script to export order information into a CSV but I'm unsure on how to display the contents of the array. What I'm trying to do is capture the custom options selected for a given order and display them. I'm new to PHP so having a hard time with this. So far I was able to display just the last option from each order but not all with this...

$_options = $block->getItemOptions();
     foreach ($_options as $option) {
         $str = $option['label'] . ' : ' . $option['value'];

     }

I then stored the value of $option into an array which when checking $array the output does contain all the selected options. I'm just unsure on how to extract the label & value of each custom option from an order to display in CSV. The below code doesn't work!

$_options = $block->getItemOptions();
     foreach ($_options as $option) {
         $array[] = $option;
         $str = $array['label'] . ' : ' . $array['value'];
     }


texts: Remove white background from thumbnail images in Magento 2.1.3

texts:
I want to remove white background from thumbnail images in my custom theme.

I have created custom theme for Magento 2.1.3
I made changes in order summary layout but when I try to load images on checkout page, it comes with white background at top and bottom.

I tried almost all solution available on stack overflow but no luck.
Any help would me appreciate.


texts: Magento 2 - Create new order number after updating an order

texts:
Create new order number after updating an order.
When order 0000123 was edited, magento created order 0000138 instead of 0000123-1


texts: Magento 2 resize category & product image

texts:
I want to resize category & product images for custom widget and I prefer Magento default function so I found following code to do so but I think it's for Magento 1

$imageObj = new Varien_Image ( $imageUrl );
$imageObj=$imageObj->constrainOnly ( true )
->keepAspectRatio ( true )
->keepFrame ( false )
->quality ( $quality )
->resize ( $width, $height )
->save ( $imageResized );

So I wish to know that does Magento 2 provide any function to resize,crop,scale any images including category,product etc.??


texts: I want to upload the magento Extension file in magento connect

texts:
Unable to save version. Filename is not valid. Expected filename without ext is instantalerts-1.1.0

extension key instantalerts

Upload package file for version "1.0.1" of extension "Spring Edge India - SMS Notification "


texts:
Magento Custom module saveAction is working Fine below code I used

public function saveAction()
{
    if ( $this->getRequest()->getPost()) {
        if (isset($_FILES['imageurl']['name']) && $_FILES['imageurl']['name'] != '') {
        try {
            $postData = $this->getRequest()->getPost();
            $uploader = new Varien_File_Uploader('imageurl');
            $uploader->setAllowedExtensions(array('jpg','jpeg','gif','png')); // Your Format Here
            $uploader->setAllowRenameFiles(true);
            $uploader->setFilesDispersion(false);
            $path = Mage::getBaseDir('media').DS.'Gallery'.DS;
            $img = $path. $_FILES['imageurl']['name'];
            $filename = $uploader->getNewFileName($img);
            $uploader->save($path, $filename);
            $galleryModel = Mage::getModel('gallery/gallery');
            $galleryModel->setId($this->getRequest()->getParam('id'))
                ->setTitle($postData['title'])
                ->setDescription($postData['description'])
                ->setStatus($postData['status'])
                ->setImageurl('/Gallery/'.$filename)
                ->save();
            //var_dump($uploader);exit();

            Mage::getSingleton('adminhtml/session')->addSuccess(Mage::helper('adminhtml')->__('Item was successfully saved'));
            Mage::getSingleton('adminhtml/session')->setgalleryData(false);

            $this->_redirect('*/*/');
            return;
        } catch (Exception $e) {
            Mage::getSingleton('adminhtml/session')->addError($e->getMessage());
            Mage::getSingleton('adminhtml/session')->setgalleryData($this->getRequest()->getPost());
            $this->_redirect('*/*/edit', array('id' => $this->getRequest()->getParam('id')));
            return;
        }
    }
}
    $this->_redirect('*/*/');
}

But Edit it's not working it's not update anything.

public function editAction()
    {
        $galleryId     = $this->getRequest()->getParam('id');
        $galleryModel  = Mage::getModel('gallery/gallery')->load($galleryId);

        if ($galleryModel->getId() || $galleryId == 0) {

            Mage::register('gallery_data', $galleryModel);

            $this->loadLayout();
            $this->_setActiveMenu('gallery/items');

            $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item Manager'), Mage::helper('adminhtml')->__('Item Manager'));
            $this->_addBreadcrumb(Mage::helper('adminhtml')->__('Item News'), Mage::helper('adminhtml')->__('Item News'));

            $this->getLayout()->getBlock('head')->setCanLoadExtJs(true);

            $this->_addContent($this->getLayout()->createBlock('gallery/adminhtml_gallery_edit'))
                 ->_addLeft($this->getLayout()->createBlock('gallery/adminhtml_gallery_edit_tabs'));

            $this->renderLayout();
        } else {
            Mage::getSingleton('adminhtml/session')->addError(Mage::helper('gallery')->__('Item does not exist'));
            $this->_redirect('*/*/');
        }
    }

Edit Not Update Anything


texts: Magento 2 : How to concat a string variable to option value in knockout template which already bind to i18n string?

texts:
I've knockout template which contains the following line:

<option value='industrial' data-bind="i18n: 'Industrial'"></option>

anyone knows how to add variable to 'Industrial' eg.

<option value='industrial' data-bind="i18n: 'Industrial' + window.checkoutConfig.hrFlag"></option>

the above line didn't work.


texts: I am using Magento 2.2.1. I want to do changes in my CSS file. After inspecting on the website I am finding the source of CSS is from somewhere in pub/static folder. I tried editing the CSS in that folder and after that I ran the deploy command. But again my CSS is reverting back to the older one. Kindly help anyone. I have tried all the solutions provided in this website but am unable to get a correct way out of my problem.


texts: Why do I get an exception when trying to append a block to a container in a parent theme?

texts:
I'm following an exercise in the ebook 'No-Frills-Magento-2-Layout' by Alan Storm (excellent book so far btw) and am coming across a slight issue for which I am not sure what I am doing wrong.

I am trying to create a new theme with the intention of adding a new block to the catalog_category_view layout template.

I have the following code structure:

/design
    /frontend
        /Pulsestorm
            /dram
                /Magento_Catalog
                    registration.php
                    theme.xml
                    /layout
                        catalog_category_view.xml
                    /templates
                        hello.phtml

The files contents are as follows:

registration.php:

<?php
\Magento\Framework\Component\ComponentRegistrar::register(
    \Magento\Framework\Component\ComponentRegistrar::THEME,
    'frontend/Pulsestorm/dram',
    __DIR__
);

theme.xml:

<?xml version="1.0"?>
<theme xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Config/etc/theme.xsd">
    <title>Pulsestorm Dram</title>
    <parent>Magento/luma</parent>
    <media>
        <preview_image/>
    </media>
</theme>

catalog_category_view.xml:

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

        <referenceContainer name="content">
            <block name="pulsestorm_magento_catalog_category_view_example" class="Magento\Framework\View\Element\Template" template="hello.phtml"/>
        </referenceContainer>

</page>

hello.phtml:

Hello Category Listing Page

I then registered the theme in admin in Content -> Design -> Themes for each website listed (the default websites that ship with Magento 2).

I then cleared the cache: magento cache:clean

and then navigated to: [development-web-address]/gear/fitness-equipment.html

but I then get the following exception:

1 exception(s):
Exception #0 (Magento\Framework\Exception\ValidatorException): Invalid template file: 'hello.phtml' in module: '' block's name: 'pulsestorm_magento_catalog_category_view_example'

Exception #0 (Magento\Framework\Exception\ValidatorException): Invalid template file: 'hello.phtml' in module: '' block's name: 'pulsestorm_magento_catalog_category_view_example'
#0 /srv/magento/vendor/magento/framework/View/Element/Template.php(300): Magento\Framework\View\Element\Template->fetchView(false)
#1 /srv/magento/vendor/magento/framework/View/Element/AbstractBlock.php(667): Magento\Framework\View\Element\Template->_toHtml()
#2 /srv/magento/vendor/magento/framework/View/Layout.php(557): Magento\Framework\View\Element\AbstractBlock->toHtml()
#3 /srv/magento/vendor/magento/framework/View/Layout.php(533): Magento\Framework\View\Layout->_renderBlock('pulsestorm_mage...')
...

I am expecting
Hello Category Listing Page
 to be displayed after the product listings.  Why am I getting this exception?  From the exception message, I'm guessing that it may have something to do with the blank module name but I'm not sure why it is blank.


texts: Magento 2: It is not recommended to specify supported PHP versions in dependencies

texts: It is not recommended to specify supported PHP versions in dependencies. If specified, it must at least match the PHP requirements of the supported Magento versions.


texts: How do I add a span inside a referenceBlock in Magento 2

texts:
I am attempting to add a fairly simple link to the top menu in a Magento 2 store. I have successfully added a standard link using a simple CSS class. But I am stuck on how to add a link with more complex spans within the link.

The link needs to look something like this in the output HTML:

<a href="<shop link here>" class="special-format">Request a Quote >

I have added the necessary elements to the layout/default.xml file like this:

<argument name="label" xsi:type="string" translate="false"><link text here></argument>
<argument name="path" xsi:type="string" translate="false"><link here></argument>
<argument name="class" xsi:type="string">special-format</argument>

I've tried to add a CDATA element into the label, but unfortunately it just outputs the contents of the CDATA on screen.

Anybody any ideas?