magento2

Newly Modified file , created and list huge files in CMD

僤鯓⒐⒋嵵緔 提交于 2020-06-07 07:21:42
问题 I have magento 2.2.6 website in aws server (EC2).I am connecting to that aws sever using ssh in cmd From my windows 10 computer . I have a directory (folder) named Var in aws server. Inside var folder there are so many files and sub folder . Now i have the following question 1) I want to know the list of last modified files (or i want to get file modified after 2.00pm today ) 2) I want to know the list of last created files (or i want to get file modified after 2.00pm today ) 3) I want to

Add custom button on add/edit product page

ⅰ亾dé卋堺 提交于 2020-05-16 11:29:10
问题 https://i.stack.imgur.com/uHZ33.png How to add a custom button, in add/edit product page (magento2). I need to open popup on clicking of the button. 回答1: The product form is generated via ui-components . The ui component name for product form is view/adminhtml/ui_component/product_form.xml . You need to create a file with the same name and path in your own module with the following content: <?xml version="1.0" encoding="UTF-8"?> <form xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi

Magento 2: “The store that was requested wasn't found. Verify the store and try again.”

只谈情不闲聊 提交于 2020-05-16 05:42:31
问题 Everytime I'm switching from the English store view to the Italian's one and viceversa, it takes me to the equivalent homepage (no matters where I am) and it throws this error: Here's my setup: Magento 2.3.4 (fresh installation, self hosted) 1 website, 1 store, 2 store views For each store view one different domain (English store view --> example.com, Italian store view --> example.it) I added on top of main .htaccess these env: SetEnvIf Host ^(.*)\.example\.com MAGE_RUN_CODE=en SetEnvIf Host

Get saved value from browsers

浪尽此生 提交于 2020-04-11 11:55:13
问题 How to get saved value from browsers in jquery,Im Using this script. require(['jquery', 'jquery/jquery.cookie', 'jquery/ui'], function($){ setTimeout(function(){ console.log($('input#email').val()); var subjectLength = $('#email').val().length; if(subjectLength > 0) { console.log('Value Available'); } else { console.log('Value not Available'); } }, 3000); }); 回答1: It looks like you are trying to write to or update a cookie via JavaScript in Magento. You could also do this with PHP using

While running PHP bin/magento deploy:mode:set production I am getting error on magento 2.1

℡╲_俬逩灬. 提交于 2020-03-26 08:21:31
问题 I am using php7 with nginx Something went wrong while compiling generated code. See the error log for details. Command returned non-zero exit code: /usr/bin/php7.0 -f /var/www/magento2/bin/magento setup:di:compile 回答1: try to run the failing command with the -vvv switch (for very verbose output). /usr/bin/php7.0 -f /var/www/magento2/bin/magento setup:di:compile -vvv with this command you should at least get a better error message than "an error occurred..." very likely, it's just the memory

Minimal symbols amount for data upload in autocomplete

末鹿安然 提交于 2020-02-29 02:04:53
问题 I'm trying to create city autocomplete in checkout, but the problem is that amount of data that being sent is too large. So i was thinking about uploading data only after certain amount of symbols typed in field, lets say 3. But I don't know how to do this using native bindingHandlers. Here is js file: define([ 'Magento_Ui/js/form/element/abstract', 'mage/url', 'ko', 'jquery', 'jquery/ui' ], function (Abstract, url, ko, $) { 'use strict'; ko.bindingHandlers.shippingAutoComplete = { init:

Problem with Magento 2 REST authentication

橙三吉。 提交于 2020-02-25 13:50:52
问题 I am using some Magento 2.3 REST calls, and I am finding that for certain calls (and it seems to be consistently GETs) Magento is returning an authentication error, while for others (which seem to be consistently POST/PUTs) the call is succeeding. I am getting an Admin token (without any problem - this is a POST) and using Bearer authentication, then using the same token on calls that succeed and ones that don't. My user is defined to Magento as an Administrator, with access to All. I am

How can I move breadcrumb before main title on Magento 2

守給你的承諾、 提交于 2020-02-06 09:27:07
问题 I would like please your help. I am newbie on Magento 2 and still searching things. I would like to move breadcrumb before title (on category pages, product everywhere). I tried to change it on default.xml <move element="page.main.title" destination="page.top" after="breadcrumbs"/> but with no luck. Also i tried to do it from catalog_category_view.xml on vendor/magento/module-catalog/view/frontend/layout but no luck. Can anyone please guide me where can I find the order that is loading? Can

Pagination in Magento widget block

家住魔仙堡 提交于 2020-01-28 02:57:40
问题 Hi is there any way to do pagination in widget block . For example have a category with id 355 . I want to display that category product in a page . So i am using widget( following code ) {{widget type="Magento\CatalogWidget\Block\Product\ProductsList" show_pager="0" products_count="160" template="Magento_CatalogWidget::product/widget/content/grid.phtml" conditions_encoded="^[`1`:^[`type`:`Magento||CatalogWidget||Model||Rule||Condition||Combine`,`aggregator`:`all`,`value`:`1`,`new_child`:``^]

Why are the Luma Thema sample images from Magento2 sample data not visible when extending it to a custom theme?

[亡魂溺海] 提交于 2020-01-25 07:41:05
问题 I installed the Magento2 open source sample data and everything works fine. When I switch to the luma theme in the admin backend I can see everything. But when I create a custom theme based on luma theme the data/images is not visible anymore. What am I doing wrong? Should it be marked somewhere? 回答1: Ok, I figured it out. I had to make two sql queries in the database because it was a problem with the widgets assigned to the old theme: UPDATE layout_link SET theme_id = '[CUSTOM_THEME_ID]'