texts: After clicking on add to cart Lotus Breath - One Step Checkout hanges. It keep loading for a long time

texts:
To   Bypass cart and go to checkout  i used these files

app/etc/modules/Maddy_Cart.xml

     <?xml version="1.0"?>
<config>
    <modules>
        <Maddy_Cart>
            <active>true</active>
            <codePool>community</codePool>
        <depends>
            <Mage_Checkout/>
        </depends>
        </Maddy_Cart>
    </modules>
</config>

app/code/community/Maddy/Cart/etc/

<?xml version="1.0"?>
<config>
    <modules>
        <Maddy_Cart>
            <version>0.1.0</version>
        </Maddy_Cart>
    </modules>
    <frontend>
        <events>
            <checkout_cart_add_product_complete>
                <observers>
                    <maddy_cartbypass_observer>
                        <type>singleton</type>
                        <class>Maddy_Cart_Model_Observer</class>
                        <method>afterAddToCart</method>
                    </maddy_cartbypass_observer>
                </observers>
            </checkout_cart_add_product_complete>
        </events>
    </frontend>
</config>

app/code/community/Maddy/Cart/Model

<?php

class Maddy_Cart_Model_Observer extends Varien_Object
{
    public function afterAddToCart(Varien_Event_Observer $observer) {
        $response = $observer->getResponse();

        $response->setRedirect(Mage::getUrl('checkout/onepage'));
        Mage::getSingleton('checkout/session')->setNoCartRedirect(true);
    }
}

There is no error in console.


texts: Order tracking, different url based on selected carrier

texts:
I have added tracking link to default carrier by adding the following code to [mytheme]/template/email/order/shipment/track.phtml

<?php $i=0; foreach ($_shipment->getAllTracks() as $_item): $i++ ?>
    <tr <?php echo $i%2?'bgcolor="#F6F6F6"':'' ?>>
        <?php echo $this->escapeHtml($_item->getTitle()) ?>
        <a href="https://sporing.posten.no/sporing.html?q=<?php echo $this->escapeHtml($_item->getNumber()) ?>" ><?php echo $this->escapeHtml($_item->getNumber()) ?>

<?php endforeach ?>

However.. my tablerate shipments are shipped with another carrier, and should have another url. How can I edit the above code to use different tracking url for tablerate shipments? I kind of know what to do, but not how to code it correctly...

But something like this (Pseduo code):

For each shipment;
 if shipment method is tablerate
   use tracking url http://my_tablerate_carrier+tracking number
 else if shipment method is all others
   use tracking url http://my_current_carrier+tracking number

All help appreciated, thanks


texts: Discounts are not working if we hide Javascript code

texts:
To display discounts for each associate simple products we used this module

after installing, only for configurable Products we didn't got shipping charges for normal "Add to cart" button, but worked for Ajax add to cart button. [custom shipping method]

when we hide below JS code , than we are getting shipping charges for normal "Add to cart" also.

But if we hide , than we don't get proper discounts for each associate simple products.

    Product.OptionsPrice.prototype.reloadPriceLabels = function(productPriceIsKnown) {
        var priceFromLabel = '';
        var prodForm = $('product_addtocart_form');

/* This code is mainly responsible - start*/
        if (!productPriceIsKnown && typeof spConfig != "undefined") {
            priceFromLabel = spConfig.config.priceFromLabel;
        }
/* This code is mainly responsible -end */

        var priceSpanId = 'configurable-price-from-' + this.productId;
        var duplicatePriceSpanId = priceSpanId + this.duplicateIdSuffix;

        if($(priceSpanId) && $(priceSpanId).select('span.configurable-price-from-label'))
            $(priceSpanId).select('span.configurable-price-from-label').each(function(label) {
            label.innerHTML = priceFromLabel;
        });

        if ($(duplicatePriceSpanId) && $(duplicatePriceSpanId).select('span.configurable-price-from-label')) {
            $(duplicatePriceSpanId).select('span.configurable-price-from-label').each(function(label) {
                label.innerHTML = priceFromLabel;
            });
        }
    };

Particularly below 2 lines of code is responsible for this :

if (!productPriceIsKnown && typeof spConfig != "undefined") {
        priceFromLabel = spConfig.config.priceFromLabel;
 }

complete code is here


texts: How to add copyright theme designer company

texts:
How to add copyright with logo in footer with logo ?

  ( copyright for company which has designed the website )

Thank You.


texts:
I have the above code on the homepage and this form adds the product to the cart. However, unlike the same form on the product listing page, it does this through a page refresh instead of asynchronously. How can I prevent this page refresh?

<form action="/checkout/cart/add/uenc/[key]/product/1/" method="post" id="product_addtocart_form">

<input type="hidden" name="product" value="1" tabindex="0">
<input name="form_key" type="hidden" value="[form_key]" tabindex="0">
<button class="action tocart primary" type="submit" title="Add to Cart" tabindex="0">
Add to Cart
</button>

</form>

There seem to be various script blocks that affect the add to cart form but

I have tried inserting these with no effect.


texts: Decrease the size of "light box" image in product view page

texts:
Please visit this link : http://demo.kidsdial.com/boys-toys/bikes-trikes-ride-ons/toysbox-mind-builder-construction-set-37-models-44-pcs.html

On the bottom right of the image there is "+ with balloon" image, if you click on that the real product image will open.

Is it possible to decrease the size of that image?

What I am saying is that if we download the products list and related products image and all it will download the image with "what size we set in admin panel".

But on the product view page, if we click on "+ with balloon" image, the real product image with the big size will open.

Can we reduce the size of that image?


texts:
I am new to Magento 2 Theme Development; I have gone through the frontend development guide.
I set my child theme to Magento Blank theme. I have done all that the guide says and added my CSS file but it is not showing on the frontend.
I have cleared all the caches and deployed static content.
Below is my setup. Any help would be great!
Local theme path: design/frontend/Speedcrete/speedcrete
Inside the folder speedcrete the structure is:
 |-etc |  |-view.xml | |- Magento_theme |  |-layout |      |-default_head_blocks.xml |       | |-media |   |-preview.jpg | |-web |   |-css |      |-custom.css |   |-fonts |   |-images |   |-js | |-registration.php |-theme.xml
Here is the code for default default_head_blocks.xml:
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd"> <head> <!-- Add local resources --> <css src="Magento_Theme::css/speedcrete.css"/>  </head> </page>
Here is the code for the theme.xml file:
<theme xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:Config/etc/theme.xsd">
 <title>speedcrete</title> <!-- your theme's name -->
 <parent>Magento/blank</parent> <!-- the parent theme, in case your theme inherits from an existing theme -->

Let me know if I need to supply more files.
I have tried to run the following commands and then clear the cache and no joy.
php bin/Magento setup:upgrade --keep-generated
php bin/Magento setup:static-content:deploy
Only another thing it might be is that there are no files under design/frontend/Magento/blank. I looked at another forum and they said it was ok as it is stored elsewhere. It seems to be the case as the "blank" theme is showing when I have my custom theme activated. Only cannot see any custom CSS I add.


texts:
In phtml file these comment used

// @codingStandardsIgnoreFile

e.g vendor/magento/module-sales/view/frontend/templates/email/items.phtml line 7

Anyone know why it is used and can i use that too in my Extensions?


texts: How to debug Call to a member function dispatch() on null ininternal\Magento\Framework\App\Action\Action.php on line 91

texts:
I am getting

  Call to a member function dispatch() on null in C:\xampp\htdocs\magento2x_6\lib\internal\Magento\Framework\App\Action\Action.php on line 91

How to debug the error?  i wont get any logs!!

Doesnt enter the execute() of the controller

my etc/module

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../lib/internal/Magento/Framework/Module/etc/module.xsd">
<module name="Vendor_Module" setup_version="2.2.0">
    <sequence>
        <module name="Magento_Catalog"/>
        <module name="Magento_CatalogSearch"/>
        <module name="Vendor_Module2"/>
    </sequence>
</module>

etc/frontend/routes.xml

<?xml version="1.0"?>
<config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:App/etc/routes.xsd">
<router id="standard">
    <route id="merchandisingpage" frontName="merchandisingpage">
        <module name="Vendor_Module"/>
    </route>
</router>

Controller/Result/Index

namespace Vendor\Module\Controller\Result;

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

    protected $tglssearchClientConnector;

public function __construct(
    // \Magento\Framework\App\Action\Context $context,
    \Magento\Catalog\Model\Session $catalogSession,
    \Magento\Store\Model\StoreManagerInterface $storeManager,
    /*\Magento\Search\Model\QueryFactory $queryFactory,
    \Magento\Catalog\Model\Layer\Resolver $layerResolver, */
    \Magento\Framework\App\Request\Http $request,
    \Magento\Framework\View\LayoutInterface $layout,
    \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig,
    \Vendor_Module3\Model\Client\Connector $tglssearchClientConnector,
    \Magento\Catalog\Model\CategoryFactory $catalogCategoryFactory,
    \Magento\Framework\Registry $registry,
    \Magento\Framework\View\Result\PageFactory $resultPageFactory
)
{
    $this->request = $request;
    $this->layout = $layout;
    $this->scopeConfig = $scopeConfig;
    $this->catalogSession = $catalogSession;
    $this->storeManager = $storeManager;
    $this->tglssearchClientConnector = $tglssearchClientConnector;
    $this->catalogCategoryFactory = $catalogCategoryFactory;
    $this->registry = $registry;
    $this->resultPageFactory=$resultPageFactory;
}


texts: How do I override a nested js file in a theme?

texts:
I have a custom module that uses a js file defined in:

Vendor/Module/view/frontend/web/js/sub/directory/myfile.js.

Works fine. I want to use a different file within a theme; from the documentation it looks like I should drop the new js file in

app/design/frontend/vendor/theme/Vendor_Module/web/js/sub/directory/myfile.js

but it does not seem to be working. After running setup:static-content:deploy the pub/static/etc directory contains the same myfile.js that is in the Vendor/Module rather than in the theme. (pub/static/frontend/vendor/theme/en_US/Vendor_Module/js/sub/directory/myfile.js)

How do I override a modules javascript file (contained in a sub directory) in a theme?


texts: How to fix skip to content option in magento 2

texts: I have issue with the magento2. When we open a website the skip to content appear before loading the complete website . How i remove this option. Image is atatched.


texts: Url uppercase converted to lowercase letter Magento 2

texts: I installed a template and i noticed that when i use uppercase it's converted to lower case. The module name is sm mega menu and the template name is Shop4u so where to search and what to change to change this treatment of this module. please any help and thanks in advance


texts:
We have noticed that a page opened for the first time is loading longer (from 8s), than a second time (1-3s). If the same page is loaded on a different computer for the first time on that computer (so no local cache exist yet), the page is also loaded faster (1-3s). So my question: why is the first load of a page so long (from 8s)?

I have another question: how does full page cache in magento 2 work?

Magento 2.0.8,
Apache 2.2,
php 7.0.7,
Mysql 5.6.

Thank you


texts: Databse Backup output is gibberish when opening in a text editor

texts:
Whenever I try and make a database backup and then try to view it in a text editor (notepad++) the data comes out as completely unreadable. Here's what it looks like:

I've tried different encoding, and different language selections, but nothing works. Is the database corrupted?

Any help would be much appreciated!


texts: How to remove  tags from short description programmatically in Magento 2?

texts:
I am using Magento 2.3.1

I have 8000 products which are migrated from Magento 1. The issue is that the  tags are added in short and long description in Magento 2. Please see below content for reference:

This is how short description looks like in the front end. Below content is added in the product in admin:

This is the short description migrated from Magento 1

short description

• This is the point 1
• This is the point 2
• This is the point 3
• This is the point 4
• This is the point 5
•This is the point 6

I have used the below code:

<?php
  $short_description = strip_tags( $short_description, 'li' );
  $short_description = "

" . preg_replace( '/[\r\n]+/', '

',
  $short_description ) . "

";
  $short_description = str_replace('

', '', $short_description );
?>
<?= $short_description ?>

But the whole content is displayed in one
 tag after implementing the above code.

Now I want to add each bullet points in
 tags and also I want to remove
 tag from the content as well. how can I do this?


texts: Future Support of Magento 1.9 - Coming Magento 2.0

texts:
We want to upgrade our current Magento 1.4.0.1 installation to 1.9.1.0 till autumn this year. The only thing we are unsure about is the future support of 1.9.1.0 since Magento 2.0 will be released end of 2015 (perhaps fully functional mid of 2016).

Do you assume that 1.9.1.0 will be supported for the coming 4-5 years by the developers or third party providers? Or do you think that it will be much shorter?


texts: Magento2.3.0 For configurable product attribute variation display this type

texts:
I am using Magento2.3.0 an i want to display swatch color and drop-down color name display this type of and after swatch color first attribute selected automatically color name choose in drop-down after add to cart working on it.if this type of anyone implement please reply me.

below first image display

second image selected option this type showing

if anyone know how to achieve this


texts: Customers couldn't login from Safari In magento 1.9

texts:
customer login don't works with Safari, only if i activate incognito mode in Safari.

After click on login, page reload itself without error massage.

I have take:

Clear Cookies in Safari
Clear var/cache & var/sessions
Insert formkey in login template
Remove Cookie params in Varien.php

Using Magento 1.9

The Magento shop works fine in months, this problem appeared last week without any changes at shop.

If i clear var/sessions and clear Cookies in safari i can login, but only one time. If i log out and try a new log in, do not work.

Update: I have found a solution

All possible ways are not fix the login problem at my shop, this one works:

Go to:

app/code/core/Mage/Customer/Model/Session.php

Around line: 224

Comment out:

$this->renewSession();

    public function setCustomerAsLoggedIn($customer)
{
    $this->setCustomer($customer);
//  $this->renewSession();
    Mage::dispatchEvent('customer_login', array('customer'=>$customer));
    return $this;
}

Better Solution without works on core files::

Backup your databases (you should always do this before making any modifications).
Build the following directory hierarchy: app/code/local/Mage/Customer/Model/.
Put a copy of session.php into this new directory.
Comment out the appropriate line, shown above, and save your file.

Found here: http://www.novusweb.com/fix-for-passing-magento-session-ids/


texts: Correct way to change the magento 1.9 admin url

texts:
Correct way to change the Magento 1.9 admin url

anyone can provide me the correct way. I see a lot of different suggestion online.


texts:
I have a site made on Magento 2.1, which sales proteins product for bodybuilders. I have to provide 2 option for product

sale product with Pouch with no additional cost
sale product with Jar which will have some cost.

My question is how can I provide such options also If jar option is selected it should automatically get added to product price.

Any help would highly be appreciated.

Thanks


texts: Suggestions on How to Migrate from Magento 1.1.7 to 1.9?

texts:
I've been tasked with upgrading a now non-functional web site using very old Magento 1.1.7 to a more recent version (latest currently being 1.9).  I'm an experienced web developer but am brand spanking new to Magento.

While doing my homework and getting up to speed on Magento, I thought I'd ask the experts how to best go about doing this?  Support from the company hosting the site suggested that it would probably be necessary to stand up a new site with an up-to-date version and then try to migrate the old data.

Do you agree that this is the best approach?  If so, can someone please point me toward resources (if any) that might help me better understand how to map/migrate data between these two versions?  Or provide any general advice that may help me accomplish this?


texts: how to hide a success message after some time in magento1.9

texts:
how can I hide messages after certain time. I'm using a custom model.

$redirectMsg = Mage::getSingleton('customer/session')->addSuccess('hii');


texts: Magento 2 add to cart button text when added

texts:
I want to change the add to cart button text, when a product is successfully added to the cart. I want to add soms custom html (a icon) to the button.

I tried to change the following, but that does not work. It does not read the HTMl but add it as plain text.

How can I solve this?

File: /app/design/frontend/Theme/theme/Magento_Catalog/web/js/catalog-add-to-cart.js

setTimeout(function () {
    var addToCartButtonTextDefault = self.options.addToCartButtonTextDefault || $t('<i class="fad fa-shopping-cart"></i>Add to Cart');

    addToCartButton.removeClass(self.options.addToCartButtonDisabledClass);
    addToCartButton.find('span').text(addToCartButtonTextDefault);
    addToCartButton.attr('title', addToCartButtonTextDefault);
}, 1000);


texts: If I have an SKU like 45-6789-10 and enter it into the search. The 10 drops off the end when I hit search and also does not appear in the search results as what was searched. I've tried changing the catalog search to full text and that does not work.


texts: Add free product to cart - heavy bug triggered if there are 3 rules and over 31 articles in cart

texts:
I am using the extension "Add Free Product to cart". I noticed that customers can't use the website anymore, if they have more than exact 31 articles in their cart. If they put more than 31 articles in their cart, then the website is starting to download instead of getting rendered.

There are 3 Add free product to cart rules set at the moment which are all bound to category id 18. If I disable one rule, then it works again and the customer can visit the site normally without it getting downloaded. The bug is even then triggered if the articles are not matching the category specified as condition in the rule, so the problem must be related to the cookies and not to the rules itself which are working fine.

A cookie is set for each article which describes if the conditions from a rule are true for that article or not, if there are three rules then there will be three cookies, for each article.

Normaly the value of the response Header content-type should be set to  text/html; charset=UTF-8, but if the bug is triggered and the website is downloaded instead of getting rendered in the browser, then the content-type is set to application/x-httpd-ea-php70 (even though magento 1.8 uses Php 5 btw...`?)

I think the error happens because magento or the extension can't handle more than 100 set-cookie requests?


texts: How do I remove the + sign from mini-cart bundle options in Magento 2

texts: How can I remove the leading '+' sign from mini-cart bundle options in Magento 2


texts: Upgrade options via Magento Connect is not available on Magento version 1.7.0.2

texts:
I'm working on upgrading one of Magento site version 1.7.0.2 to 1.9.1.1 via Magento Connect. For some reason after I click on "check for upgrade" button, the page does not show any drop options except "reinstall" and "uninstall" on the available column, all fields are empty where they were supposed to version 1.9.1.1 or the latest version of modules.

This issue doesn't occur on another Magento site that I upgrade from 1.9.0.1 to 1.9.1.1.

Could this be permission issue or glitch on Magento connect? or does upgrading from 1.7.0.2 to 1.9.1.1 has be done manually outside Magento Connect at this point?

Thank you,


texts: 'sales_flat_order_grid' shows wrong data

texts:
In my clients store there are 4 orders that are displaying wrong data, all four consecutive orders are displaying the same billing and shipping name in the order grid, all other data is correct.

I've gone through all 3rd party extensions and none seem to mutate that table so I guess the issue originates from somewhere in the Magento core code.
I was wondering if anyone else has ever encountered this.
It's only those 4 orders and in the order grid, orders after them have not had this issue and invoice and shipping grid do show the correct data.


texts: On the login page button "register" don't work (1.5 Magento)

texts:
After applying security patches I'm receiving error on login page:

  Call to undefined method Mage_Checkout_Helper_Data::isContextCheckout() in app/design/frontend/base/default/template/persistent/customer/form/login.phtml on line 92

And login button doesn't work.


texts:
I am using magento 1.8.0. I have added new toplink in header. I have added following code in customer.xml file of my theme :

<default>
    <reference name="top.links">
      <action method="addLink" translate="label title">
        <label>Track</label>
        <url>track-order-status</url>
        <title>Track Your Order</title>
        <prepare>true</prepare>
        <liParams/>
        <aParams>class="top-link-tracking"</aParams>
        <beforeText></beforeText>
        <afterText></afterText>
      </action>
    </reference>
</default>

I have added the css for the "top-link-tracking" class in style.css properly and cleared all caches. Link is visible at the toplinks portion but with NO CSS. Any solution?


texts: Where do static library initializations go?

texts:
Suppose that I have a library located in:

  lib/Acme/

This library has to be statically initialized (once!) through the following call:

  AcmeBootstrap::init($data);

$data in the above call is obtained through the system configuration table and augmented through XML configurations found in both the community and local pools.

The Acme library is (currently projected to be) only used in a single helper class.  Immediately, my instincts tell me to perform lazy-initialization in the helper file, but like everything else in Magento -- the "norm" goes against all reason.  I really do not want to add anything to the Magento bootstrap -- everything should be handled inside the module itself.

Am I going about this correctly, or am I gonna get roasted for even asking?


texts: How can I add headings to the WYSIWYG Editor in Magento 2

texts: I try to add headings (h1 h2 and h3) to the WYSIWYG editor in the field product description. But I can't find a configuration option for that.


texts: Product description is shown in a custom block

texts: The custom blocks are empty in the product configuration, but the product description is displayed in a custom block. That is, twice, how can I disable it?


texts:
Currently all Magento default imports of currency are not working for a fresh demo install of Magento 2.2.4 and a couple of my active Magento 2.2.X projects.

I've tried with Yahoo Finance Exchange, WebserviceX and Fixer.io, but all return errors:

Yahoo Finance Exchange

  We can't retrieve a rate from http://query.yahooapis.com/v1/public/yql?format=json&q=select+*+from+yahoo.finance.xchange+where+pair+in+%28%22USDCHF%22%2C%22USDCNY%22%2C%22USDEUR%22%2C%22USDHRK%22%2C%22USDKMF%22%2C%22USDUSD%22)&env=store://datatables.org/alltableswithkeys for CHF.

Webservicex

  We can't retrieve a rate from http://www.webservicex.net/CurrencyConvertor.asmx/ConversionRate?FromCurrency=USD&ToCurrency=CHF.

Fixer.io

  We can't retrieve a rate from
  http://api.fixer.io/latest?base=HRK&symbols=EUR,HRK for EUR.

I've tried testing by changing the base currency and additional currencies in Configuration -> General -> Currency setup but every time it's showing the above errors for all services.

Seems that the Fixer.io API endpoint is deprecated. And the new endpoint can't be used without a Fixer.io account. I guess Magento didn't adjust the endpoint yet...

Webservicex is returning a "Page not found" JSON response and Yahoo is returning a null value for the query.

I presume their APIs changed and Magento didn't adjust to the changes yet...

Can anyone suggest or provide a quick fix for one of the services?

EDIT
After installing the shopgo module for additional currency import services you get Google Finance as a new import option.

But it returns this error:

  We can't retrieve a rate from http://www.google.com/finance/converter?a=1&from=USD&to=CHF.

When using the direct link you get this error:

I presume it's generic since my server isn't "sending automated requests to Google Finance API".


texts: Set all child products to not visible individually

texts: How to set all associated products in the entire store to 'not visible individually' I've been scrolling through other answers but I can't seem to find a solution.


texts: Magento 2 place order redirecting to the cart page

texts:
When I am trying to "Place Order" -> it is redirecting to cart page,
the order is not placed and cart items are in the cart.

I tried this solution, but unsuccessfully.

I use Mageplaza_Osc

  .../checkout/onepage/success -> Status Code: 302 Found

Do you have some ideas?


texts:
I'd like to add a new page layout in Magento that will be an option that can be selected in CMS pages. I have copied the 1-column.phtml code and adapted it slightly and changed it to 1-column-version2.phtml.

I'd like to know please how I would go about referencing the new file so that it appears in the CMS page layout options.

.


texts: How can I Change the store language after switching the store

texts:
I have two store one is English and one is French.

Create a product and category in English and French also, but I am not able to  create category  or product for french.

Please help, How can I create content like category,product for french store in french language?


texts:
I'm trying to set a custom shipping amount to my cart under a specific condition. (My [lovely] client wants to skip the normal shipping rules).

How could this be done in the cleanest way possible?

Currently I'm hooking to sales_quote_address_collect_totals_after and doing the following:

$quote_address = $observer->getEvent()->getQuoteAddress();
$quote_address->setShippingAmount($shipping_price);
$quote_address->setBaseShippingAmount($shipping_price);
$quote_address->setGrandTotal($quote_address->getGrandTotal() + $shipping_price);
$quote_address->setBaseGrandTotal($quote_address->getBaseGrandTotal() + $shipping_price);

Whilst the shipping amount looks good, I am getting the custom shipping amount added 3 times to the grand total. I've also noted that sales_quote_address_collect_totals_after is triggered 3 times as well.

How could I go about this?


texts: Please help! How can you display individual quantity for each variation?

texts: I have a configurable product with 3 variations. The quantity for each is 1,3 and 5. I want these quantities showing when selecting the relevant variation, but it currently shows the total 9, no matter what I select. Our dev says magento doesn't do this natively, but it doesn't make any sense, when would someone want to know that you have 20 total t-shirts is all sizes, when they just want to buy 2 medium t-shirts. I had a look at configuration and I can't see a setting for this, but I am just familiarizing myself with magento, so not sure if I'm just not seeing it. Thank you


texts: Magento, Adding external  and  in cms blocks?

texts:
I already done my static blocks and linked them to category pages, but now every block has its css and script inside the every page, I want to move them to one css file and one script file, so if I need to make any change it will be done in all pages at ones rather that doing it one by one.

I hope I was clear.

Thanks in Advance


texts: Magento 2: Product is not displayed on category and search after indexing

texts:
I'm facing an issue with the specific product visibility on the Magento 2.2.9 website. The configurable product is not visible to the assigned categories or search page but accessible with its URL.

When I manually saved the product from the admin then the product is displaying on the category page but after indexing the product has gone from the category and search page.

I've checked all the below possibilities causing this issue but didn't get any luck.

Status must be Enabled (under General tab)
Visibility should be Catalog OR Catalog, Search (under General tab)
Stock Qty (quantity) of the associated products (under Inventory tab)
Stock Availability must be IN STOCK
The category should be assigned (under the Categories tab)
The website must be assigned (I'm using the single store mode)

Any help will be appreciated.


texts: Magento resource model catalog product filter with attributes and category id

texts:
I am trying to develop custom filter navigation. Below is the code for product collection by category id

$category = Mage::getModel ('catalog/category')->load($category_id);
    $products = Mage::getResourceModel('catalog/product_collection')
                  // ->addAttributeToSelect('*')
                  ->AddAttributeToSelect('name')
                  ->addAttributeToSelect('price')
                  ->addFinalPrice()
                  ->addAttributeToSelect('small_image')
                  ->addAttributeToSelect('image')
                  ->addAttributeToSelect('thumbnail')
                  ->addAttributeToSelect('short_description')
                  ->addUrlRewrite()
                  ->AddCategoryFilter($category);

    Mage::getSingleton('catalog/product_visibility')->addVisibleInCatalogFilterToCollection($products);

    //$products->addAttributeToFilter('color', array('eq' => '27')); /* here color attribute */

Product collection by category id is working as expected. But when i tried with single color attribute, it always returns an empty array. Same color 27 attribute gives one product as result when i check on default navigation.

What is the best way to achieve multiple attribute code filter with resource model catalog product collection?


texts: Magento 2 : Add custom validation to shipping address

texts:
When user enters shipping address I want to validate it using an external API (for example: USPS street-level validation API)..

Which file do I extend to add this validation in the checkout? checkout_index_index.xml does not have the specific address fields.


texts:
I am currently facing a problem with the below error and was hoping if someone could help.
Notice: Undefined index: quantity in /public_html/Magento/vendor/magento/module-inventory-sales/Model/IsProductSalableCondition/IsSalableWithReservationsCondition.php on line 87

I have found solutions to other Undefined Index problems but not to mine.
This error happens on the product page when I edit certain products. Please note it only happens to a few products.
I've tried to go into the attribute settings, re-saving and then reindexing but this has not worked. I've had a look into the database and couldn't find anything that stands out as wrong.
Any helps is appreciated, I am also getting a "Something went wrong with processing the default view and we have restored the filter to its original state." error when searching for some products but I believe these problems are related.
Screenshots below
Something went wrong https://pasteboard.co/Jhs7D2g.png
Undefined Index https://pasteboard.co/Jhs7JPU.png
Line 87 https://pasteboard.co/Jhs95Pm.png
Thanks


texts: How to Add a custom Email to Core_Email_template table

texts: What are the steps to adding a template to core_email_template. I created a new template in en_US/emails/...and created a system config field HOWEVER nothing is showing up in the table. What step am I missing? What are the FULL steps to doing this???


texts: Magento2 reference a block and call method from it in layout.xml

texts:
I have a file Vendor_Module/view/rontend/layout/catalog_product_view.xml
in my custom module.

The content of the file is as fallows:

<referenceBlock name="product.info">
    <block class="Vendor\Module\Block\CustomBlock" name="my_custom_block" template="custom_template.phtml">
        <action method="customMethod">
            <argument><--call public method method from parent block 'product.info'--></argument>
        </action>
    </block>
</referenceBlock>

I want to define a method to my custom block inside the catalog_product_view.xml file of my module and pass argument to that method that is the result which is returned by calling of a public method from the reference block. Is that possible ?


texts: Magento 2 : make category name searchable

texts:
I would like to make the category name searchable, for example when a user is searching furniture I would like to display all products in furniture category.
I looked into CatalogSearch but I was not able to make something working.

Thanks !


texts: Shipping code showing in Paypal Express Account in Magento2

texts: I want to show only shipping title not shipping code in Paypal express checkout in Magento2.


texts: Magento 2.2.3 Order variables in success page

texts:
This question has been asked a few times and I still don't get it. Relatively new to Magento and not very good with PHP.

I would like to customize the checkout success page. So I overrode it by placing it in my theme (worked). But I would like to display the ordered items / the full address and the name of the customer.

Tried to write a module, but failed on that. Now I'm using the object manager (not recommended, I know):

$objectManager =  \Magento\Framework\App\ObjectManager::getInstance();
              $orderData = $objectManager->create('Magento\Sales\Model\Order')->loadByIncrementId($block->getOrderId());

This works fine, I can get my order amount or status. But I can not get the name or address. I can get things like

[entity_id] => 78
[state] => new
[status] => pending

But I can't use this, because it is empty:

<?php echo($orderData->getCustomerFirstname()) ?>

[customer_firstname] =>
[customer_lastname] =>
[customer_middlename] =>

Also, I wold like to display the items grid like on the card.

Can anyone help? Would really appreciate it.

Cheers
Valentin


texts: Magento 2 Stock update API Postman error (Consumer is not authorized to access %resources)

texts:
I am trying to update the product quantity using postman. But i am getting the following errors

{
"message": "Consumer is not authorized to access %resources",
"parameters": {
"resources": "Magento_CatalogInventory::cataloginventory"
} }

Please see the following screenshots

I am missing something ?
I have seen this documentation https://devdocs.magento.com/swagger/#/catalogInventoryStockRegistryV1/catalogInventoryStockRegistryV1UpdateStockItemBySkuPut
But when I put Pre request I am getting following errors. Please help


texts:
I got this error message in category page.

Fatal error: Call to undefined method Mage_Catalog_Model_Product_Type_Simple::getUsedProducts() in /var/www/xxx/app/code/core/Mage/Catalog/Block/Product/View/Type/Configurable.php on line 92.

How to fix this error...?


texts: How to get configurable child product by attribute

texts:
I have a configurable product "T-Shirt" with id = 1.

I want to get the object for the simple product with size of "medium" so I can then query the stock value.

What is the syntax for:

  "Get the medium value of attribute size from configurable parent
  T-shirt"


texts: Error Filtering grid from joined table collection

texts:
I successfully create a custom customer grid which use select join, the problem is i concat customer first name and customer last name as a new column alias, and when i filter the column it shows error

this is how i join the collection:

$this->getSelect()->join(
                ['secondTable' => $this->getTable('customer_entity_varchar')],
                'main_table.entity_id = secondTable.entity_id AND secondTable.attribute_id = 159 AND secondTable.value = 1',
                ['customer_name'=>'CONCAT(main_table.firstname," ",main_table.lastname)']
            );
$this->addFilterToMap('customer_name', 'CONCAT(main_table.firstname,main_table.lastname)');

this is my grid column:

  <column name="customer_name">
        <argument name="data" xsi:type="array">
            <item name="config" xsi:type="array">
                <item name="filter" xsi:type="string">text</item>
                <item name="bodyTmpl" xsi:type="string">ui/grid/cells/html</item>
                <item name="label" translate="true" xsi:type="string">Name</item>
            </item>
        </argument>
    </column>

var/log/execption.log

  [2018-08-23 15:06:25] main.CRITICAL: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'CONCAT(main_table.firstname,main_table.lastname)' in 'where clause', query was: SELECT COUNT(*) FROM customer_entity AS main_table


texts:
Im trying to update the stock of my products programmatically, using this code:

$stockItem = $this->stockRegistry->getStockItemBySku($sku);
$stockItem->setQty($qty);
$this->stockRegistry->updateStockItemBySku($sku, $stockItem);
$this->logger->info($stockItem->getQty())

$stockItem->getQty() logs the right qty amount, however all stock in backend is updated to 0 when I run this loop. Anyone have an idea how this is possible?


texts:
I am looking to show a larger lifestyle product image at the top of a grouped product and show all the individual simple products belonging to that grouped product underneath.

Something similar to this link

http://goo.gl/XDzs9C

I need the larger image to almost full width of the page and would like to have a short description underneath the image and above the products as is shown in the sample link.


texts: Magento2 : How to show success message in checkout page on page load

texts: Magento2:How to show success message in checkout page on page load.


texts:
When I am trying to export customer csv file then following error is show:

  The requested component ("varchar") is not found. Before using, you
  must add the implementation.


texts: Magento 2 - Pub/Static files create everything EXCEPT mage folder with important js files (like mixins.js or common.js)

texts:
I am using Magento 2.4.1 CE. I am not sure what changed, but since about a week when I create my static files the front- and backend break because two folders including important files are missing (e.h. mixins.js require.js) and the javascript files crash.
I have checked all the files and realized that every file and folder is available except the "mage" folder. I use the bin/magento s:s:d -f  command.
So whats missing is

pub/static/frontend/theme/name/de_De/mage/

and

pub/static/adminhtml/theme/name/de_De/mage/

I have found a workaround by manually uploading the two mage folders from an old stage server into the static theme folders. Then both back- and frontend are fine. This however works only until the next static deployment of course...
I have already checked my file permissions, but since I did not change them, I don't think it has something to do with it.
When I try to open the files by URL as in this example de_DE/mage/requirejs/mixins.js I get the following error message:
 Unable to resolve the source file for 'frontend/theme/name/de_DE/mage/requirejs/mixins.js'
<pre> #1 Magento\Framework\App\StaticResource->launch() called at [vendor/magento/framework/App/Bootstrap.php:263]
#2 Magento\Framework\App\Bootstrap->run(&Magento\Framework\App\StaticResource#0000000069ad91c00000000031b30d8d#) called at [pub/static.php:13]
</pre>


texts: only absolute definition (instead of relative) of path to Models in custom module is working for me. Why?

texts:
I know that definition of path to Models and other stuff in Magento config.xml must be in absolute way. But in my case that didn't worked. Magento did not found my models. When I change definition in relative way Magento found my Models and module is now working fine.

Can anybody explain me why? Because I want develop Magento in correct way :).

Here is my example. path to Model:

  /app/code/local/Devpassion/Rowtotal/Model/Quote/Address/Total/Totalpopust.php

I try relative definiton which not worked for me:

            <quote>
                <totals>
                    <rowtotal>
                        <class>rowtotal/quote_address_total_totalpopust</class>
                    </rowtotal>
                </totals>
            </quote>

And here is absolute way definition which works for me:

            <quote>
                <totals>
                    <rowtotal>
                        <class>Devpassion_Rowtotal_Model_Quote_Address_Total_Totalpopust</class>
                    </rowtotal>
                </totals>
            </quote>


texts:
I am trying to create a custom module in Magento2 2.2.6 but I am facing the following error.

Element 'add', attribute 'resource': [facet 'pattern'] The value 'bcode_Bapp::helloworld' is not accepted by the pattern '[A-Z]+[A-Za-z0-9]{1,}_[A-Z]+[A-Z0-9a-z]{1,}::[A-Za-z_0-9]{1,}'.


texts: New customer registration emails sent from server not received by some customers

texts:
New customer registration emails that send out the link to confirm account are logged as sent from server in the linux server logs but are not received by some customers. For example: new account with caitlin.havener@gmail.com sent and I received it right away. New account with email chavener@directtoschools.com sent and I never received. I figured that this is an email filter issue on the receivers end, but obviously we want ALL of our customers to receive the email. Does the following extension help with that issue too or please advise.

http://www.magentocommerce.com/magento-connect/aschroder-com-smtp-pro-email-free-and-easy-magento-emailing-for-smtp-gmail-or-google-apps-email.html


texts: How to override protected function in Magento 2

texts:
I'm trying to override one protected function in Magento 2 but I am not able to achieve it. I have edited following files:

  <preference for="Magento\Checkout\CustomerData\DefaultItem" type="XYZ\Checkout\CustomerData\DefaultItem" />

    <?php

    namespace XYZ\Checkout\CustomerData;

    class DefaultItem extends \Magento\Checkout\CustomerData\DefaultItem
    {

but still not working


texts: How to load an UI Component template within payment method section in checkout page?

texts:
I am trying to load my component within the payment method section on checkout page.

As of now it appears below Apply Discount section.

I was wondering if its even possible to load my component just after billing-address within payment method section.

I know checkout is a complex implementation and I am asking a lot here but any kind of help would be appreciated.

This is my code for now.

module.xml

<module name="RB_VerifyOtp" setup_version="1.0.6">
        <sequence>Magento_Checkout</sequence>
        <sequence>Magento_OfflinePayments</sequence>
        <sequence>Clicksend_Sms</sequence>
</module>

I have even tried to place my complonent in the offline-payment node under Magento_OfflinePayments module. Somehow component appeared for time being even in COD payment section but after sometime I could not load that again. That's why module.xml contains dependency for Magento_OfflinePayments.

checkout_index_index.xml

<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <body>
        <referenceBlock name="checkout.root">
            <arguments>
                <argument name="jsLayout" xsi:type="array">
                    <item name="components" xsi:type="array">
                        <item name="checkout" xsi:type="array">
                            <item name="children" xsi:type="array">
                                <item name="steps" xsi:type="array">
                                    <item name="children" xsi:type="array">
                                        <item name="billing-step" xsi:type="array">
                                            <item name="children" xsi:type="array">
                                                <item name="payment" xsi:type="array">
                                                    <item name="children" xsi:type="array">
                                                        <!-- merge payment method renders here -->
                                                            <item name="afterMethods" xsi:type="array">
                                                                    <item name="children" xsi:type="array">
                                                                        <item name="otp-verfn" xsi:type="array">
                                                                            <item name="component" xsi:type="string">RB_VerifyOtp/js/view/checkOtp</item>
                                                                        </item>
                                                                    </item>
                                                            </item>
                                                    </item>
                                                </item>
                                            </item>
                                        </item>
                                    </item>
                                </item>
                            </item>
                        </item>
                    </item>
                </argument>
            </arguments>
        </referenceBlock>
    </body>
</page>


texts:
I'm trying to add a block to product pages by way of my theme's local.xml file, only to have turpentine blow up.

Here's the relevant local.xml (which works if I omit the setEsiOptions):

...
<catalog_product_view>
    <reference name="product.info">
        <block type="catalog/product_view" name="wholesale.grid" as="wholesale_grid" template="wholesale/wholesalegrid.phtml">
            <action method="setEsiOptions">
                <params>
                    <access>customer_group</access>
                    <registry_keys>
                        <current_product/>
                    </registry_keys>
                </params>
            </action>
        </block>
    </reference>
</catalog_product_view>
...

When the setEsiOptions action is omitted, the proper content is displayed.  When it's included, the following shows up in the error logs:

2015-12-21T21:19:46+00:00 WARN (4): TURPENTINE: No block node found with @name="wholesale.grid"

Here's a link to the line responsible in Turpentine


texts: Magento 2 - hide & disable add type product (Simple product ... etc)

texts:
On Magento 2, and product page, there's a list of product type,

I want to hide and disable and block a user to access an additional type of product,

for example: hide Configurable product and Bundle product and block the routes of it ( so, you can't add a configurable if you using the URL directly )


texts: Programatically update cart item quantity

texts:
Below is my code:

namespace Ves\Productlist\Controller\Cart;
use Magento\Quote\Model\QuoteRepository;
class CartUpdate extends \Magento\Framework\App\Action\Action
{
    protected $quoteRepository;

    public function __construct(
    \Magento\Quote\Api\CartRepositoryInterface $quoteRepository
    ) {
    $this->quoteRepository = $quoteRepository;
    }

    public function execute()
    {
    $objectManager = \Magento\Framework\App\ObjectManager::getInstance();
    $cart = $objectManager->get('\Magento\Checkout\Model\Cart');
echo $cartId=$cart->getQuote()->getId();

    $itemId = 720;
    $itemQty = 1;

    $quote = $this->quoteRepository->getActive($cartId);
    $cartitems->setquoteId($cartId);
    $cartitems->setitemId($itemId);
    $cartitems->setqty($itemQty);

    $quoteItems[] = $cartitems;
    $quote->setItems($quoteItems);
    $this->quoteRepository->save($quote);
    $quote->collectTotals();

    }

}

But I am getting the below error:


texts:
I have a module that converts page information (product, basket, transaction) from their blocks to javascript objects.

We are having some issues using it on sites that have full site cache enabled. Things like users email addresses being cached and showing for other people. Obviously bad,

Is there a way to punch through the cache for an entire module (i.e if the module asks for the product information block, it won't get a cached version of it?


texts:
For test and development, I duplicated our Magento shop to a sub-domain. Everything works, but not the admin Login. On the login page we get it. After entering my user name and password we don't log in. A new login Page is coming from our main site, so NOT the sub-domain. what can I do?

Thanks from germany

Alex


texts: Magento 2: How to get Product Id from Cart Item Id

texts:
In Minicart, we have products

<input id="cart-602-qty" maxlength="12" name="cart[602][qty]" size="4" type="number">

This is not Product Id. So how to get actual product id from cart item id?

Lastly, can override template & put product id in hidden.


texts:
I am trying to install Patch 9767 but using following command

~$ sh PATCH_SUPEE-9767_CE_1.9.3.0_v1-2017-05-25-09-09-56.sh

But i got below error and patch is not install

: not found-9767_CE_1.9.3.0_v1-2017-05-25-09-09-56.sh: 7: PATCH_SUPEE-9767_CE_1.9.3.0_v1-2017-05-25-09-09-56.sh:
PATCH_SUPEE-9767_CE_1.9.3.0_v1-2017-05-25-09-09-56.sh: 10: local: not in a function

So i am trying to install patch using php file using following code

$result = shell_exec('sh PATCH_SUPEE-9767_CE_1.9.3.0_v1-2017-05-25-09-09-56.sh');

but i got below error

ERROR: "/app/etc/" must exist for proper tool work.


texts: magento 2 system.log error - Invalid template file: in module Infortis_UltraMegamenu

texts:
from system.log

[2019-05-10 08:48:48] main.CRITICAL: Invalid template file: 'categories_searchresult.phtml' in module: 'Infortis_UltraMegamenu' block's name: 'sidebar.main_schedule_block0' [] []

from exception.log

[2019-05-10 08:30:02] main.CRITICAL: The file "/home/myusername/public_html/pub/media/captcha/base/03eb4921b9d19cdc3d1a531fe41b1069.png" cannot be deleted Warning!unlink(/home/myusername/public_html/pub/media/captcha/base/03eb4921b9d19cdc3d1a531fe41b1069.png): Permission denied {"exception":"[object] (Magento\\Framework\\Exception\\FileSystemException(code: 0): The file \"/home/myusername/public_html/pub/media/captcha/base/03eb4921b9d19cdc3d1a531fe41b1069.png\" cannot be deleted Warning!unlink(/home/myusername/public_html/pub/media/captcha/base/03eb4921b9d19cdc3d1a531fe41b1069.png): Permission denied at /home/myusername/public_html/vendor/magento/framework/Filesystem/Driver/File.php:382)"} []

how can i resolve these issue?


texts: Magento 2: get Nextpage, Lastpage Url in list.phtml file

texts:
How to get Next page, Last Page url in magento 2?

I have try in template file with below codes,

   <?php
$_productCollection = $block->getLoadedProductCollection();
$_helper = $this->helper('Magento\Catalog\Helper\Output');
?>
<?php if (!$_productCollection->count()): ?>

<?php /* @escapeNotVerified */ echo __('We can\'t find products matching the selection.') ?>

<?php else: ?>
    <?php echo $block->getToolbarHtml() ?>
    <?php echo $block->getAdditionalHtml() ?>
    <?php
        $viewMode = 'grid';
        $image = 'category_page_grid';
        $showDescription = false;
        $templateType = \Magento\Catalog\Block\Product\ReviewRendererInterface::SHORT_VIEW;

    $pos = $block->getPositioned();
    ?>
    <?php //echo $this->getLayout()->createBlock("Manadev\LayeredNavigation\Blocks\Navigation")->setTemplate("Manadev_LayeredNavigation::navigation.phtml")->toHtml();
        $pagerBlock = $this->getLayout()->createBlock("Magento\Theme\Block\Html\Pager");
       echo $pagerBlock->getLastPageNum().' test';exit;

        echo $pagerBlock->getNextPageUrl().' sssss';exit;

How to get next and last page url in magento 2 custom template file.
only getting current page url.

Is there missing for override pager block?

I have to pass nextpage url value inside my custom code.
Also how to check how many page for current category listing?

Any help would be appericiated.


texts: Magento 1.9.0.1 blank page on Orders and Returns after turning off breadcrumbs

texts:
In my local.xml file, I added the code to hide the breadcrumbs and all pages show fine without the breadcrumbs except Orders and Return page does not display at all. After removing the breadcrumbs code in local.xml, the page displays fine. I'm using Magento 1.9.0.1. How can I solve this issue?

Here is the local.xml file

<?xml version="1.0" encoding="UTF-8"?>
<layout>
    <default>
        <remove name="right.reports.product.compared" />
        <!--recently compared prod-->
        <remove name="left.reports.product.viewed" />
        <!--removes recently viewed sidebar-->
        <reference name="header">
            <remove name="breadcrumbs"/>
        </reference>
    </default>
</layout>


texts: Event sales_order_invoice_save_after in magento 2

texts:
Does in magento 2 exists event similar to event sales_order_invoice_save_after from magento 1?

Or, where should plugin "listen", to get similar functionality?

Thanks.


texts: Magento ver. 2.1.4 : How to Install a magento Theme

texts:
I am trying to install the new theme in my Magento store.

I could not do it correctly.

I use Magento Ver. 2.1.4, I was able to do with the fresh installation of Magento but not able to update the theme in existing Magento store.

after my installation all my Front end design is Falling apart. Please suggest me best practice to install new theme. I would like to try that.


texts: Accessing Magento admin cookie in a custom file inside a folder

texts:
I have a magento installation I want to access the logged in admin credentials in a file inside a subfolder.
I make a file and keep it in the root (the same folder where the magento index.php resides). It shows me the logged in user data perfectly. Now when I copy the same file inside a subfolder it returns the data but the data array(which contains the loggedin user information) is empty. Below is the code

require_once ('app/Mage.php');
Mage::app();
$user = Mage::getSingleton('admin/session');
print_r($user);


texts: Add Pagination for Magento Catalog Toolbar in custom module magento 2

texts:
How to override the pagination, sort by, Show per page in the phtml of magento2?

How to override the same in our custom module?

Need help in overriding the correct phtml and layout files!

This is what i tried!

Had overridden :
Vendor\Module\Block\Product\ProductList\Toolbar.php

public function getPagerHtml()
{
   //as is
}

Vendor\Module\view\frontend\layout\catalog_category_view.xml

<?xml version="1.0"?>
  <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<body>
    <!-- <referenceBlock class="Magento\Catalog\Block\Product\ProductList\Toolbar" name="product_list_toolbar" >
      <action method="setTemplate">
        <argument name="template" xsi:type="string">Vendor_Module::product/list/toolbar.phtml</argument>
      </action>
    </referenceBlock> -->
    <block class="Magento\Catalog\Block\Product\ListProduct" name="product_list" template="Magento_Catalog::product/list.phtml">
        <block class="Magento\Framework\View\Element\RendererList" name="category.product.type.details.renderers" as="details.renderers">
            <block class="Magento\Framework\View\Element\Template" as="default"/>
        </block>
        <block class="Magento\Catalog\Block\Product\ProductList\Toolbar" name="product_list_toolbar" template="Vendor_Module::product/list/toolbar.phtml">
            <block class="Magento\Theme\Block\Html\Pager" name="product_list_toolbar_pager"/>
         </block>
         <action method="setToolbarBlockName">
             <argument name="name" xsi:type="string">product_list_toolbar</argument>
         </action>
    </block>
</body>
</page>

But for this i only get the pagination and other controls as shown:


texts:
There are new problems with static blocks in 1.9.2

  there is one more problem with CMS blocks caching, that is not fixed.

  If you are using secure urls and {{media}} tags in your CMS blocks,
  you will receive "Insecure content warning" message from browser, as
  Magento serves insecure links from cache.

  To resolve it, you need to add one more cache info tag, as

  (int)Mage::app()->getStore()->isCurrentlySecure(),

Does anyone know where to add this code-snippet?

KNOWN BUG: http://www.magentocommerce.com/bug-tracking/issue/index/id/870


texts: Force all products in store to have default value of "taxeable goods"

texts:
I have a relatively large database and every now and again I find products that when imported were not assigned to a tax class. While I agree that this should be addressed when products are imported, it can still cause a problem if a product is overlooked for one reason or another and a visitors happens to purchase an affected product.

Since all products in my store are taxeable and of the same tax class, how can I force magento to have a default value of taxeable goods instead of "none" for all store products?


texts: Newsletter Subscriber - Grid not loading

texts: I am using magento 1.9, under news letter ---- newsletter subscriber --- grid is missing, its blank


texts:
I have create script which create product feed csv file and it’s working properly with 10k products.

Now admin have added 50k products in admin panel so now product feed file is created but not contains all product data.

Can anyone suggest how can i get all product data if products are more than 50k?

I have also try to export all product using data profile from admin panel but it’s also not working.

I have also try with sql query to get data from tables but it’s also break after some data.


texts: Target parent product on bestseller query if best selling product is a child

texts:
How would I get the top 10 bestsellers like targeting the parent if the best seller is a child product.

I use the following code to get the bestsellers

 public function getBestsellerCollection()
    {
        $collection = $this->_collectionFactory->create()->setModel(
            'Magento\Catalog\Model\Product'
        );

        $collection->getSelect()->limit(10);

        return $collection;
    }

but if the targeted product is a child product this would break with the following sql error

SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'LIMIT 10) AS `t`' at line 1, query was: SELECT COUNT(*) FROM (LIMIT 10) AS `t`


texts:
I'm Working on a Website That Sells WallPapers stickers
I want My Products to have Dynamic Prices as Follows:

DropDown Which will specify the Material Of the wallpaper
2 text Fields ("Width", "Height")

and Based on The Material will Be the Multiply Value in the square space

Example:

Materials :

(1) wallpaper = 5$ per 1 square feet
(2) vinyl Sticker = 7$ per 1 square feet

so the price of a Product of Wallpaper material with width 5 and Height 6
will be ((5 * 6) * 5$)

any Idea how can i achieve that ?


texts: How to know the code base of a Magento mobile site?

texts:
The magento store, I am working, has a mobile site for mobile users. like, example.bmobilized.com. I can't find the code base of this mobile site. However I have searched and come up with the following..
1.There is no exception theme in System > Configuration > Design
2.There is a menu called "mobile" in admin section under which "manage app", "submission history","message template","message queue" are present with no records.
I doubt it has completely a different code base.
But How can I find that ? Is it using magento or any other platform ?


texts: Magento 1.9 : send multiple images as attachements in Email

texts:
I have implemented send email in single image file as attachment. but now i want to send multiple images as attchment in email.How can i acheive that? if anyone can help me.

I have tried below code for single image send in email and that is working fine.

I have used a request quote folder as requestquote in media directory for saving for uploaded images. There is an array of custom variables to be passed to transactional email.

$uploadfilename = '';

if( !empty($_FILES["rfloorplanattachment"]["name"])  )
{

    $image_ext = end(explode('.',$_FILES["rfloorplanattachment"]["name"]));
    $allowed_ext =  array('gif','png' ,'jpg','jpeg','pdf','doc','docx','rtf','odt');

    $uploadfilename = md5(substr(str_shuffle("0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"), 0, rand(1,100).rand(1,100))).str_replace(" ","_",$_FILES["rfloorplanattachment"]["name"]);
    $source_upl         = $_FILES["rfloorplanattachment"]["tmp_name"];
    $target_path_upl = Mage::getBaseDir('media').DS.'requestquote'.DS.$uploadfilename;
    if(in_array($image_ext ,$allowed_ext ) ) {
        @move_uploaded_file($source_upl, $target_path_upl);
    }
}

$senderName = Mage::getStoreConfig('trans_email/ident_general/name');
$senderEmail = Mage::getStoreConfig('trans_email/ident_general/email');

$templateId = 3;
$sender = Array('name' => $senderName,'email' => $senderEmail);

$requestquotesvars = array(
            'firmname'     =>  $customer->getFirstname()
        );

$emaiName = 'Request Quote Firms';

$storeId = Mage::app()->getStore()->getId();

$translate = Mage::getSingleton('core/translate');
$transactionalEmail = Mage::getModel('core/email_template');
if(file_exists(Mage::getBaseDir('media').DS.'requestquote'.DS.$uploadfilename) )
{
$transactionalEmail->getMail()
                ->createAttachment(
        file_get_contents(Mage::getBaseDir('media').DS.'requestquote'.DS.$uploadfilename),
        Zend_Mime::TYPE_OCTETSTREAM,
        Zend_Mime::DISPOSITION_ATTACHMENT,
        Zend_Mime::ENCODING_BASE64,
        basename($uploadfilename)
    );
}
$transactionalEmail->sendTransactional($templateId, $sender, $companymail, $emailName, $requestquotesvars, $storeId);
$translate->setTranslateInline(true);

   unlink(Mage::getBaseDir('media').DS.'requestquote'.DS.$uploadfilename);


texts: Export then import products with images to different server

texts:
I only have admin panel access to magento 2 site.  I need to export all products to a new site on different hosting where I have full access.

I ran a product export but the image URLs are local paths so the import doesn't include the images.  I have read documentation and can't see anyway to make it use external links for the images.

How do I export with the external image URL?


texts: Adding a tab to customer information in Magento 2.3.5

texts:
I'm trying to add a tab to the customer information section in the admin from my custom module. For some reason it is not adding the tab

Here is my view/adminhtml/layout/customer_index_edit.xml

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

        <referenceBlock name="customer_form">
            <block class=" XX\XX\Block\Adminhtml\Customeredit\Tab\View" name="customertab_panel">
                <arguments>
                    <argument name="tab_label" xsi:type="string" translate="true"> Custom Tab Label</argument>
                    <argument name="sort_order" xsi:type="number">100</argument>
                </arguments>
            </block>
        </referenceBlock>

</page>

view/adminhtml/templates/tab/customtab_view.phtml

        <?php echo __('Customer Custom Tab Information') ?>

            <?php echo __('Customer ID:') ?>
            <?php echo $block->getCustomerId(); ?>

            <?php echo __('Custom Details :') ?>
            <?php echo __('Customer Details') ?>

Block/Adminhtml/Customeredit/Tab/View.php

<?php

namespace xx\xx\Block\Adminhtml\Customeredit\Tab;

class View extends \Magento\Backend\Block\Template implements \Magento\Ui\Component\Layout\Tabs\TabInterface
{
    protected $_template = 'tab/customtab_view.phtml';

    public function __construct(
        \Magento\Backend\Block\Template\Context $context,
        \Magento\Framework\Registry $registry,
        array $data = []
    ) {
        $this->_coreRegistry = $registry;
        parent::__construct($context, $data);
    }
    public function getCustomerId()
    {
        return $this->_coreRegistry->registry(\Magento\Customer\Controller\RegistryConstants::CURRENT_CUSTOMER_ID);
    }
    public function getTabLabel()
    {
        return __('Custom Tab');
    }
    public function getTabTitle()
    {
        return __('Custom Tab');
    }

    public function canShowTab()
    {
        if ($this->getCustomerId()) {
            return true;
        }
        return false;
    }
    public function isHidden()
    {
        if ($this->getCustomerId()) {
            return false;
        }
        return true;
    }
    public function getTabClass()
    {
        return '';
    }

    public function getTabUrl()
    {
        return '';
    }
    public function isAjaxLoaded()
    {
        return false;
    }
}

Can anyone see the issue here?


texts: Magento 2 - How to extend wysiwyg setup.js to add language settings?

texts:
i need to modify:

setup: function (mode) {
        if (this.config['widget_plugin_src']) {
            tinyMCE.PluginManager.load('magentowidget', this.config['widget_plugin_src']);
        }

        if (this.config.plugins) {
            this.config.plugins.each(function (plugin) {
                tinyMCE.PluginManager.load(plugin.name, plugin.src);
            });
        }

        if (jQuery.isReady) {
            tinyMCE.dom.Event.domLoaded = true;
        }

        tinyMCE.init(this.getSettings(mode));
    },

of the mage/adminhtml/wysiwyg/tiny_mce/setup.js file.
I created a requirejs-config.js with this code:

var config = {
"map": {
"*": {
  "mage/adminhtml/wysiwyg/tiny_mce/setup": "js/custom_tinymce_setup"
}

}
};

Magento recognize my file, but i have copied all the content of the setup.js to custom_tinymce_setup.js becouse i could not find the way to only replace that function named above.

If anyone can help me, i'll appreciate it.


texts: Authorize.net Error: Unable to read response, or response is empty

texts:
I am getting a seemingly sporadic error from Authorize.net calls. This is the error that is logged.

     [result] => Array
    (
        [response_code] => -1
        [response_reason_code] => 0
        [response_reason_text] => Unable to read response, or response is empty
    )

The error started after several months of trouble free operation (~5 orders/day). The customers will get the error and most will just try again. It is usually successful after 2-3 tries. Some customers are successful on their first. This issue has been present for a week now, but it is not consistent. We have had several day long stretches without the error.

I am logging the request and response timestamps and it does not hit the 30 second timeout set in the Magento Authorize.net code. Is there a timeout on the Authorize.net side?

We are on a two server cluster, The error is only happening on one of the servers.

Any clues? I have exhausted my knowledge on this.

Magento Community Edition 1.8.0
Authorize.net (Not Direct Post Method)


texts: Using Dependency Injection in Magento 1?

texts:
I would love to use Magento 2's DI in some of my Magento 1 modules.

I'm not entirely sure how can I approach that and more importantly, if Magento 1 will allow me to do so ?

Most of the M1 classes extend Varien_Object. Thus, would injecting the classes the exact same way as M2 be enough to start using DI on M1 ? Something like this:

class Vendor_Module_Model_Test extends Mage_Core_Model_Abstract {

    protected $_productCollection;

    public function __construct(
        Mage_Catalog_Model_Resource_Product_Collection $productCollection
    ) {
         $this->_productCollection = $productCollection;
         parent::__construct();
    }

    public myFunction($productId)
    {
        return $this->_productCollection->addIdFilter($productId);
    }
}


texts: I am trying to upgrade my Magento 1 site to Magento 2. Here I am using this tool. Now my question is "how is it possible for me to know that my site is migrated successfully??"


texts: Magento 1.9 - Uncaught Error: Call to a member function canCapture() on boolean in

texts:
Over the weekend, a product purchase seems to of triggered an error. The result of which means the orders page is displaying on the one order, with all previous orders being no longer accessible?

The following error message is displayed in the Default field of Sales / Order page.

Fatal error: Uncaught Error: Call to a member function canCapture() on boolean in

/home/WEBSITE/public_html/app/code/core/Mage/Adminhtml/Block/Sales/Items/Abstract.php:481 Stack trace: #0
/home/WEBSITE/public_html/app/code/core/Mage/Adminhtml/Block/Sales/Items/Abstract.php(176): Mage_Adminhtml_Block_Sales_Items_Abstract->canEditQty() #1
/home/WEBSITE/public_html/app/design/adminhtml/default/default/template/sales/order/view/items.phtml(59): Mage_Adminhtml_Block_Sales_Items_Abstract->getItemHtml(Object(Mage_Sales_Model_Order_Item)) #2
/home/WEBSITE/public_html/app/code/core/Mage/Core/Block/Template.php(241): include('/home/180498.cl...') #3
/home/WEBSITE/public_html/app/code/core/Mage/Core/Block/Template.php(272): Mage_Core_Block_Template->fetchView('adminhtml/defau...') #4
/home/WEBSITE/public_html/app/code/core/Mage/Core/Block/Template.php(286): Mage_Core_ in
/home/WEBSITE/public_html/app/code/core/Mage/Adminhtml/Block/Sales/Items/Abstract.php on line 481
Product
Item Status
Original Price
Price   Qty Subtotal
VAT Amount
VAT Percent
Discount Amount
Row Total

I'm really unsure as to what I should do to resolve this, any help would be very much appreciated


texts:
We've been trying to import a csv of products on to our Magento store, Magento doesn't show any errors when it checks the file, and it reports the import as successful once it has "finished".

The products aren't anywhere to be found though, not on the frontend, nor in our catalog in the backend. I've compared the settings in the csv to those on working products they should have been identical to and these are all right, so there's no reason for them to not be uploaded. Are there any logs kept for imports, or a way to enable such logs, so that we can see what Magento is trying to do with each product in the csv, and hopefully find out why they aren't being uploaded.

Thanks


texts:
I have this code:

foreach ($skuScope as $sku)
{
    $object = Mage::getModel('catalog/product');
    $product = $object->loadByAttribute('sku', $sku);

    $attributes = $product->getAttributes();
    foreach ($attributes as $attribute) {
        $attributeCode = $attribute->getAttributeCode();
        $value = $attribute->getFrontend()->getValue($product);
}}

I can get all attributes, all values, but I don’t know how to rewrite values for an attribute

Help me, please! Thanks!


texts: How to create PDF from HTML in Magento 2?

texts:
I am facing issue creating PDF file from HTML text stored in a variable.
I have tried zendpdf but it directly prints tags also.

Here's my code:

$pdf = new \Zend_Pdf();
$page = $pdf->newPage(\Zend_Pdf_Page::SIZE_A4);
$pdf->pages[] = $page;
$page->setFont(\Zend_Pdf_Font::fontWithName(\Zend_Pdf_Font::FONT_HELVETICA), 20);
$page->drawText('
hello
', 100, 510);
$pdfData = $pdf->render();
header("Content-Disposition: inline; filename=result.pdf");
header("Content-type: application/x-pdf");
echo $pdfData;


texts: Error in applying SUPEE-8788 in EE 1.13.1.0 - malformed patch at line 6139

texts:
My Magento version is 1.13.1.0 and had SUPEE-1533 installed.

As per Magento guidelines I have reverted this patch and then applied SUPEE-3941 (previously not applied). These step went successfully. Now when I tried to apply PATCH_SUPEE-8788_EE_1.13.1.0_v2-2016-10-14-11-52-21.sh throwing below error output -

$ ./PATCH_SUPEE-8788_EE_1.13.1.0_v2-2016-10-14-11-52-21.sh`
Checking if patch can be applied/reverted successfully...
/usr/bin/patch:  malformed patch at line 6139:
ERROR: Patch can't be applied/reverted successfully.

I have downloaded patch file directly from Magento server.


texts: Product Attribute option values has 100's of empty option values, using Magento 1.9.1

texts:
I am using Magento 1.9.1 and facing a weird issue for long time, our attribute option values has 100's of  empty option values and the new issue is in some attributes which have more values it is not allowing to deleting the empty values similarly adding new values in those fields are also not possible.

I am attaching the screenshot:

Looking for help how to remove these empty spaces, either external script or any sql query.

I also checked this link but it is not helping me :

  Delete Empty Null Attribute Options


texts:
I'm running magento 2.3.1 with MSI and There's no filter,reports available based on sources.

Like, I would like to know which source has how many stock left or specific SKU has how many qty available in various sources.

How can I create filter for sources at products listing back end ?

Any ideas ? Maybe other possible solution will be helpful.


texts: Magento 2 : Get Shipping price below min. amount

texts:
I need to get a quote in Magento2 cart page shipping estimation like Magento 1.x.

How to show all the shipping methods when entering any zip code.

I'm using webkul marketplace extension for sellers shipping so I need min amount is there else I need to add an amount to the particular method, display in the frontend.

  Example shipping method 1 having min. order value $200 after it's free. Below $200 I need to add some amount.

Any help would be appreciated.


texts: Magento 2.3 - Special price automatically applied when order is programmatically set to status Complete

texts:
I am on a bit of a strange bug.
I am using a Magento 2.3 installation with No Stock Management and no rules for special prices or discounts.
I programmatically set the orders through a cron job to STATUS_COMPLETE.
The problem is that when the orders were on status "processing" && were paid by bank card, a special price is suddenly shown on the front-end for the products that were in these orders.
Could you please tell me what could possibly trigger this behavior?
Thank you all very much in advance!


texts: Display drop down box on product front end

texts:
I want to add a drop down box that allows the customer to specify what we should do if an item doesn't have the specified amount (Ship what you have, Cancel item, or Contact me).

I would like to display this on the product page and have the info captured with their order.

What is the best way to go about this?


texts:
I've got a big product collection about 68.000 items, when I loop through
the collection I'm trying to get all attributes by using $collection->getAttributes() but it returns nothing.

When I load the products attributes like

$catId=604;
$collection = Mage::getModel('catalog/category')->load($catId)
    ->getProductCollection()
    ->addAttributeToSelect('*')
    ->addAttributeToFilter('category_id', $catId)
    ->addAttributeToFilter('type_id', 'simple')
    ->addAttributeToFilter('status', 1)->load();

foreach($collection as $col) {
    $prod = Mage::getModel('catalog/product')->load($col->getId());
    $prod->getAttributes();
}

the performance is horrible so I want to get the attributes by using the collection but it doesn't work at all.

Any suggestions ?


texts: Add custom menu in existing(Catalog) menu magento 2

texts: I'm using magento 2 and I would like to add a custom menu to my existing(catalog) menu. Basicly , I have my category CLOTHING that has DRESSES , PANTS ecc as subcategories, so basicly my navigation will show CLOTHING in the main menu. What I want is to have also DRESSES in the main menu , even if is not a category , I just want to have it twice (once inside clothing as subcategory , and once outside , next to clothing ) but I don't want to create it twice (once as subcategory and once as category , cause dresses is just a subcategory). How can I achieve this ?


texts: Programatically create product not showing in catalog product grid

texts:
I created a product using below script :

$product = Mage::getModel('catalog/product');
$product->setStoreId(1);
$product->setWebsiteIds(array(1));
$product->setTypeId('simple');
$product->addData(array(
    'name' => 'Custom Name',
    'attribute_set_id' => $product->getDefaultAttributeSetId(),
    'status' => Mage_Catalog_Model_Product_Status::STATUS_ENABLED,
    'visibility' => Mage_Catalog_Model_Product_Visibility::VISIBILITY_NOT_VISIBLE,      // because I don't want to show on frontend
    'weight' => 1,
    'sku' => 'custom123',
    'tax_class_id' => 0,
    'description' => 'desciption',
    'short_description' => 'short desciption',
    'stock_data' => array(
        'manage_stock' => 1,
        'qty' => 999,
        'is_in_stock' => 1
    ),
));
$product->save();

Above script create a row in database tablecatalog_product_entity but this product not showing in magento catalog product grid.

What do I do for showing product only in magento backend?


texts:
Right now i am using Mangeto 1.9.1 and i am trying to get the GrandTotal value of the session order in external php file in the main Magento directory.

Here is my php file:

<?php
    error_reporting(E_ALL | E_STRICT);
    $mageFilename = 'app/Mage.php';
    require_once $mageFilename;
    $app = Mage::app('default');
    Mage::app();

    $quote = Mage::getModel('checkout/session')->getQuote();
    $quoteData= $quote->getData();
    $grandTotal=$quoteData['grand_total'];

    echo "Grand: - $grandTotal";
?>

But it's not printing the value of the grand total.
Where is my mistake how i can make this thing work ?

Thanks in advance!


texts: Why magento used deprecatedNode tag in model resource declaration in wishlist

texts:
I have seen an interesting thing in model configuration in config.xml. I was unknown about the tags  <deprecatedNode>   in model class declaration and is want to know  about this tags.

In a custom extension we just need this type of model class declaration..

 <models>
            <[module]>
                <class>[Namespace]_[Module]_Model</class>
                <resourceModel>[module]_mysql4</resourceModel>
            </[module]>
            <[module]_mysql4>
                <class>[Namespace]_[Module]_Model_Mysql4</class>
                <entities>
                    <[module]>

[module]

                    </[module]>
                </entities>
            </[module]_mysql4>
        </models>

Reference -http://www.magentocommerce.com/wiki/5_-_modules_and_development/0_-_module_development_in_magento/custom_module_with_custom_database_table

But in magento existing modules like Wishlist 's config.xml define model with deprecatedNode and resourceModel declare with this pattern

<wishlist>
                <class>Mage_Wishlist_Model</class>
                <resourceModel>wishlist_resource</resourceModel>
            </wishlist>
<wishlist_resource>

    <class>Mage_Wishlist_Model_Resource</class>
                <deprecatedNode>wishlist_mysql4</deprecatedNode>
                <entities>
                    <wishlist>

wishlist

                    </wishlist>
                    <item>

wishlist_item

                    </item>
                    <item>

wishlist_item

                    </item>
                    <item_option>
wishlist_item_option
</item_option>
                </entities>
            </wishlist_resource>

WHY THIS TYPE OF CODE USED IN MAGENTO

 <resourceModel>wishlist_resource</resourceModel>
                </wishlist>

                <wishlist_resource>

                    <class>Mage_Wishlist_Model_Resource</class>
                    <deprecatedNode>wishlist_mysql4</deprecatedNode>


texts: Magento 2 Disable/Enable Place Order Button on checkout

texts:
I want to disable the "Place Order" button in certain conditions.
 I have tried a lot but not getting exact information.
 Give some idea for same


texts: Forbid access to a file by url but allow through browser

texts:
how can I prevent the user to access my /v folder in my website where I have some video, but allow them to be display on frontend thanks to  the <\video> tag from HTML 5 ?

I tried this and other stuff in my /v folder :

RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http://sub.domain.com [NC]
RewriteRule \.(mp4)$ - [F]

but the fill is not forbidden (cache already cleared)


texts:
I have got a issue with Order Number in Magento2.

Order Number not increment by 1
it should be like this
000000241
000000240
000000239
but not.kindly identify the issue.


texts: How to overwrite .php file of lib directory?

texts:
Any one tell me how i can overwrite this file in magento 2.3

Path:

  Magento2\lib\internal\Magento\Framework\Webapi\Rest\Response\Renderer\Json.php


texts: How to use ko.observable on change of data and run a js function Magento 2

texts:
How can I run a js function on change of data, So I have heard of knockoutjs ko.observable

define([
 'uiComponent',
 'ko',
 'Magento_Checkout/js/model/totals'
], function (Component, ko, totals) {
'use strict';
 var quoteItemData = window.checkoutConfig.quoteItemData;
 var finalSaleData = totals.totals().items;

return Component.extend({
    defaults: {
        template: 'Magento_Checkout/summary/item/details'
    },
    quoteItemData: quoteItemData,
    finalSaleData: finalSaleData,

    /**
     * @param {Object} quoteItem
     * @return {String}
     */

    getItems: function(item_id) {
        var itemElement = null;
        _.each(this.finalSaleData, function(element, index) {
            if (element.item_id == item_id) {
                itemElement = element;
            }
        });
        return itemElement;
    },
    getFinalSale: function (quoteItem) {
        var item = this.getItems(quoteItem.item_id);
        var tagText = '';

        if((((item.price*item.qty) - item.discount_amount)/(item.base_old_price*item.qty))< 0.5){
            var tagText = 'Final Sale';
        }else{
            if(item.base_old_price && item.price){
                // && item.price < item.price && item.base_old_price / item.price <= 0.5){
                if(((item.base_old_price - item.price)/item.base_old_price)>0.5){
                    var tagText = 'Final Sale';
                }
            }
        }
        return tagText;
    },
    initObservable: function () {
        totals.totals.subscribe(function (total) {

        }, this);

        return this;
    }
getFinalSaleObs: ko.observable(this.getFinalSale(quoteItem))
});

});

But my ko.observable and subscribe is not working.
I am trying to run getFinalSale function every time the totals.totals data is changed or window.checkoutConfig.totalsData.item data.

How to achieve that.


texts:
I want to upgrade the Magento cloud version from 2.2.4 to 2.3.1. We cloned a branch to the local environment and then upgraded the site. Running the site in the local and it's confirmed that the version is upgraded to 2.3.1. We moved the required files from GitHub to the cloud rebuild branch. The version of the file is 2.3.1 but we are getting an error that DB is not upgraded.

  "{"0":"Please upgrade your database: Run \"bin/magento
  setup:upgrade\" from the Magento root directory.\n"

As we cannot run setup upgrade, not sure how to resolve this issue.
Can anyone help us with this?


texts:
I have created New Custom Header Template from admin.

This email template i want to use in my custom email template in custom module.

Currently i am using this below code to add header.

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

So now how can i add my custom created template as shown in above image instead of this default header, can any one guide me for this?

Thanks in advance.


texts:
we are noticing a strange behaviour on a CE 2.2.6 which we can't interpret. We didn't do any updates, it's possible that an OpCache/Redis flush let come up an error from an update before. Each time we are calling a URL in an XHR Request with a timestamp included like ?_=1540374954091, we are receiving an Error 500 from nginx.

If we replace the underscore with a regular var name like ?a=b the error doesn't come up, so there's a possible relation with non-cachable requests.

The log says:

2018/10/24 14:20:06 [error] 2924#2924: *2225 FastCGI sent in stderr: "PHP message: PHP Fatal error:  Uncaught TypeError: Argument 2 passed to Magento\Theme\Controller\Result\MessagePlugin::afterRenderResult() must implement interface Magento\Framework\Controller\ResultInterface, null given, called in /var/www/html/vendor/magento/framework/Interception/Interceptor.php on line 146 and defined in /var/www/html/vendor/magento/module-theme/Controller/Result/MessagePlugin.php:79
Stack trace:
#0 /var/www/html/vendor/magento/framework/Interception/Interceptor.php(146): Magento\Theme\Controller\Result\MessagePlugin->afterRenderResult(Object(Magento\Framework\Controller\Result\Json\Interceptor), NULL, Object(Magento\Framework\App\Response\Http\Interceptor))
#1 /var/www/html/vendor/magento/framework/Interception/Interceptor.php(153): Magento\Framework\Controller\Result\Json\Interceptor->Magento\Framework\Interception\{closure}(Object(Magento\Framework\App\Response\Http\Interceptor))
#2 /var/www/html/generated/code/Magento/Framework/Controller/Result/Json/Interceptor.php(91): Magento\F" while reading response header from upstream, client: 93.131.xx.xxx, server: www.xxx.com, request: "GET /popup/Popup/Index/?_=1540374954091 HTTP/1.1", upstream: "fastcgi://unix:/run/php/php7.1-fpm.sock:", host: "www.xxx.com"

It's a composer based installation, the Magento\Framework\Controller\ResultInterface is in place. Any ideas how to debug etc.?

Thanks
Jan


texts: Removing Blocks from Layout Best Practice?

texts:
In our specific situation, we are seeing duplicate tracking code blocks with Fooman Google Analytics+ with Magento Enterprise 1.13.1.0 (see code below). I assume Fooman should be overwriting the default tracking code block -- but it's not doing that. Outside modifying core code OR the fooman module, what is the best practice way to remove a default block?

== BEGIN GOOGLE ANALYTICS ==
google tracking code here.
== END GOOGLE ANALYTICS ==

== BEGIN GOOGLE ANALYTICS ==
google tracking code here.
== END GOOGLE ANALYTICS ==


texts: Controller override code doesn't execute

texts:
I need to override a controller (../Mage/Customer/controllers/AccountController.php) in order to enable user to upload a photo from "Account Information" form. I've manually created "photo" file upload field and added "enctype=multipart/form-data" to form .phtml file.

Now I need to handle submisison so that the actual file is saved on the server and path is saved into my database.

When I put Varien_File_Uploader code into original AccountController.php the file is saved on the server. I don't want to modify core files so I've created my own module with "etc/config.xml" and "controllers/AccountController.php".

etc/config.xml

<?xml version="1.0"?>
<config>
<modules>
    <Abcdef_Photoupload>
        <version>0.1.0</version>
    </Abcdef_Photoupload>
</modules>

<frontend>
    <routers>
        <customer>
            <args>
                <modules>
                    <Abcdef_Photoupload before="Mage_Customer_AccountController">
                        Abcdef_Photoupload_Frontend_Customer
                    </Abcdef_Photoupload>
                </modules>
            </args>
        </customer>
    </routers>
</frontend>

</config>

for now, in my controllers/AccountController.php I've put

<?php
echo "test";
exit;

require_once Mage::getModuleDir('controllers', 'Mage_Customer').DS.'AccountController.php';

 class Abcdef_Photoupload_Frontend_Customer_AccountController extends Mage_Customer_AccountController
 {[my code]}

neither "echo", nor [my code] get executed. Module is enabled and visible in back-end. How do I get my customized controller to work?


texts: Elasticsuit. How to search products by tags?

texts: Is it possible to search products by tags (assigned to product) using Elasticsuit for Magento 2. If not, how can implement this feature?


texts: How to get the final sql query from the grid incl. filters?

texts:
I'm trying to get the raw sql query Magento is running on the database to select the data for the report grid. I can print the collection query string with

$collection->getSelect()->__toString()

but this does not contain the filters. But I need the query with filters.
Thanks for any help


texts:
i already run commands
setup:upgrade
static-content:deploy
indexer
di:compile
cache:flush
why my admin dashboard looks like this ?


texts: CCAvenue payment navigation back to Magento 2.3 on react native issue

texts:
I'm building Magento v2.3 project in react-native. Also, it has multiple stores.

For payment gateway I'm using CCavenue using webview.

Navigation to CCavenue is done perfectly, but while returning back to the return URL, it doesn't consider the return URL instead goes to homepage URL inside web view giving invalid formkey error.

I have used CSRF interface in the controller but it still gives the same formkey error.

On website the same code and navigation work flawlessly.

Any help would be appreciated.


texts:
Does anyone else find Magento bundles confusing?

It says like quantity 20 of 20 x single product even though you are only buying one bundle that contains 20 of a certain product.

Is this normal? It seems very confusing to me, is there a way to at least make this make more sense on the invoice?

See screenshot


texts: How to override default Magento (1.9.2.4) controller /customer/account/create with controller in my module?

texts: I want to create a new controller for the registration page. How can I do this in my own controller? The allegedly duplicate question is actually not about overriding a controller.


texts: Size attribute not visible for configurable products

texts:
I have a magento site with clothing apparels as products. I felt the need to revamp the website and so I am in the process of changing the website's theme. Everything worked perfect until I tested the product view page. There, for the earlier theme, the page looked like this (see the size select dropdown)

After applying the new theme, the page looks like this below image (the size dropdown is nowhere to be seen). I am unable to find out where I am going wrong. Some tutorials suggested to edit the catalog.xml file for the theme, but since I am a newbie and the tutorial doesn't had enough explanation for someone like me, I refrained from going ahead.


texts: My Magento ver. 1.9.0.1 site is no longer loading the css

texts:
I'm not sure what's caused it but my Magento ver. 1.9.0.1 site is no longer loading the css. I didn't make any changes to the site whatsoever, one day it was fine the next it had fallen over.

All of the css looks fine and checking it out with firebug everything looks to be pointing to the right place.

My site is http://www.geckoclothing.com/ and here's what it currently looks like:

http://1.9.0.1/
1.9.0.1


texts: Create Custom Attribute Group Within Custom Attribute Set Programatically On The Fly

texts:
I currently have a working method which allows me to create an attribute set on the fly. This works well:

public function createAttributeSets($attribute_set_name) {

    $attr_set_id = $this->getAttrSetId("generated_" . $attribute_set_name);

    if (!$attr_set_id) {
        $entityTypeCode = 'catalog_product';
        $entityType = $this->eavTypeFactory->create()->loadByCode($entityTypeCode);
        $defaultSetId = $entityType->getDefaultAttributeSetId();

        $attributeSet = $this->attributeSetFactory->create();
        $data = [
            'attribute_set_name' => $attribute_set_name,
            'entity_type_id' => $entityType->getId(),
            'sort_order' => 200,
        ];
        $attributeSet->setData($data);

        try {
            $this->attributeSetManagement->create($entityTypeCode, $attributeSet, $defaultSetId);
        } catch (Exception $e) {

        }

        return $attributeSet->getId();

    } else {
        return $attr_set_id;
    }

}

Now I'd like to create an attribute group within this attribute set so that it's ready to place my new attributes within it.

Is this group automatically created if I assign a new attribute to a non-existing group name when I create it?


texts: Difference Between Magento Community and Enterprise Editions

texts:
I Have worked with Magento Community Edition but never worked in Enterprise Editions.

Before The Start New Project in Enterprise Editions. I Need to Know Major Differences Between Them.


texts: Magento 2 how to add if or else statement to email template?

texts: I want to add an if or else statement to the invoice email template to check if the order shipping method is courier delivery order or self pick up order. How can I do this?


texts: Magento 1.9 change price on textbox change product page

texts:
I how can we change the price on product page based on a text box on the product page. Example of what I am thinking is if I have a text box on product page then my price should be base price multiplied by the value entered in the textbox. Qty box is different from the another text box and price will depend on both.

Thank you


texts: Passing an array from block file to template file

texts:
I have a collection of Dealer Stores. I have implemented a function that calculates the distance of all stores from the location of the customer and i have an array of respective distances. I have added the logic in Block.php file.

Now I want this array to be accessed from a template file. How do i implement this?

All answers i get from web are exact opposite of what is want - Passing data from template file to block file

Any help would be appreciated..


texts:
how to show custom error message if billing/shipping(section) address is not valid .

or

How to create an observer before save billing & shipping address on checkout page in magento?

So for that I will fire an event.

Thanks.


texts: Add pagination to any block's collection

texts:
I have a number of collections which have blocks that output the contents to frontend routes (My Account, frontend features).

I have need to paginate some of these. I know that pagination methods exist on collections but is there a way to handle the querystring portion as well? I hate to reinvent the wheel...


texts:
I am trying to reindex using the following command from public_html folder (root directory):

  php bin/magento indexer:reindex

I have even tried

  bin/magento indexer:reindex

I receive the following message:

  Magento supports PHP 5.0 or later ...

Another error message:

  -bash: bin/magento: Permission Denied.

I am not a programmer. Could someone kindly explain in simple words how to solve this. Many thanks!


texts: How to add expression in collection query magento 2?

texts:
I want to write this query into Magento 2 formate

SELECT vendor_id, vendor_name, (
    6371 * ACOS( COS( RADIANS( 45.4102961 ) ) * COS( RADIANS( vendor_latitude ) ) * COS( RADIANS( vendor_longitude ) - RADIANS( - 93.2434978 ) ) + SIN( RADIANS( 45.4102961 ) ) * SIN( RADIANS( vendor_latitude ) ) )
    ) AS distance
    FROM udropship_vendor
    HAVING distance <30
    ORDER BY distance
    LIMIT 0 , 20

Here is my query

$collection = $this->vendor->create();
    $collection->addFieldToSelect(array('vendor_id', 'vendor_name', 'vendor_latitude', 'vendor_longitude', 'zip', 'street', 'city'));
    $collection>addExpressionFieldToSelect('distance', new Zend_Db_Expr('( 6371 * acos( cos( radians('.$latitudeFrom.') ) * cos( radians( {{vendor_latitude}}) ) * cos( radians( {{vendor_longitude}}) - radians('.$longitudeFrom.') ) + sin( radians('.$latitudeFrom.') ) * sin( radians( {{vendor_latitude}}) ) ) )'), array('vendor_latitude'=>'vendor_latitude', 'vendor_longitude'=>'vendor_longitude'));

    $collection->getSelect()->having('distance > 10');

    return $collection;


texts:
I am trying to get it so that once a user types in name of product the results will show in order by product name.
I have already done

Store > Configuration > Catalog > Product List sort by | Product name

and results still show out of order.
and they will still show out of order


texts: Change the CSS for every different languages that are divided by the views scope

texts:
I have a menu generated by Magento category. And every link is an image. Here is a screenshot of what it looks like (it's in french):

I was wandering how can I code my CSS so that when it's another language the background-image changes?

I though there was way to define a class or id when creating a category but I did not see anything.


texts: Magento 2 DHL Shipping Method is not working into the Different store view

texts:
I have configured the DHL Shipping into the Website (Magento 2.3.3).

The website has 3 store view. All the stores have the same configuration as the DHL Shipping Method. In the Main Store, DHL Shipping is working great.

But into another 2 stores, it is not working. I have checked the shipping log. The request is generated and also get the response from the DHL Server. But in the checkout page no shipping rates are displayed.

Please check the below screenshot:

Can you please tell me what is the problem.


texts: How to get customer name and adress through order increment id/order id in magento 2?

texts:
I want to fetch and show which customer bought which product and from where on front end. The issue is i am unable to fetch the above details through order increment id/order id.

So how can i get customer details on checkout_onepage_success page.