Questions tagged [widgets]

Administration, usage, and development of CMS Widgets

Filter by
Sorted by
Tagged with
7
votes
2answers
4k views

What is data-post, data-action in magento 2? Can anyone explain wishlist functionality?

Can anyone explain below code? How did it work? Is there any alternate way to do? <a href="#" data-post='<?php echo $this->helper('Magento\Wishlist\Helper\Data')->getAddParams($...
0
votes
3answers
1k views

Magento 2: add classes and icons to homepage widget

I am working on a Magento 2.1.7 shop. To achieve this, I have created a child-theme of Magento Blank. On the home page, I have inserted a "New Products" widget via the Magento admin. I am using ...
0
votes
1answer
470 views

Magento 2 accordion in onestepcheckout does not works

I have add accordion widget to Onestep Checkout following this guide http://devdocs.magento.com/guides/v2.0/javascript-dev-guide/widgets/widget_accordion.html but it does not works <div id="...
1
vote
2answers
495 views

How to resize product images in recently viewed widget

How can I resize the images rendered via the recently viewed product widget? I have tried editing multiple values inside app/design/frontend/VENDOR/THEME/etc/view.xml but none updated the ...
0
votes
0answers
664 views

Magento 2. How to remove widget on just one Product

I have a widget that is shown on all Category page and on all Product page. I want to hide that widget from one specific product pages. Can I do It with Layout Update XML, if So how ? The widget is ...
1
vote
0answers
88 views

What is the difference between the navigation and menu widgets

I've just noticed Magento 2 has two widgets that sound very similar, the menu widget and the navigation widget. They are both customised versions of the Query UI Menu widget and they both use the ...
0
votes
1answer
218 views

How to hide the out of stock products from a widget on home page

I am trying to hide the out of stock products from my homepage. I want them to display everywhere else but not in this widget. Hiding from admin configuration is not the solution. How can i achieve ...
0
votes
1answer
55 views

How do I get rid of multiple H1's on homepage?

I am relatively new to Magento with past experience of WordPress of few years. I'm trying to get rid of the multiple H1s on the homepage of a new client. sobefurniture.com The developer coded the ...
1
vote
1answer
248 views

Countdown timer in a static block with values from admin config

I want to create a widget/static block with a countdown to the next shipment. The shipment times should be changeable from the admin config, so I assume using PHP or PHTML are my options. (even ...
0
votes
1answer
625 views

Magento Widget block refrence

I want to display my custom block in the top of right column. I followed the below link Widget setup in backend - how do I move upwards I have a doubt in the second step,what is the [widget_id] ...
4
votes
0answers
477 views

Magento 2 Widget Condition on edit not display

I am working on the Magento ver. 2.1.7 and added Widget Type Catalog Product List in the Home Page Block, with the condition If ALL of these conditions are TRUE : Category is 6 When I edited ...
0
votes
1answer
109 views

Cannot Extend Widget Block Class

I have installed the Amasty ShopBy Extension and am trying to make my own modifications the correct way: using my own extension. I have created a preference in di.xml (tried in /etc and /etc/frontend)...
8
votes
3answers
1k views

Cannot edit widgets in WYSIWYG editor anymore

Recently, editing widgets in the WYSIWYG editor does not work anymore. The browser console shows the following error when I click on a widget: Uncaught DOMException: Failed to execute '...
5
votes
3answers
4k views

How To Add Custom Notices to Page Top in Magento 2

I'm just started Magento and recently have some issues. So, this is what I want to do: I want to display Notices at the top of the site as following Image. Eg: I want to show some Discount Coupons on ...
1
vote
1answer
599 views

Error when creating new widget

I have created a new module which provides a Magento 2 widget. The widget was previously working but now when I go Content -> Widgets in Magento admin I get the following error: PHP Fatal error: ...
2
votes
2answers
750 views

Magento 2.1.4 - List of products which have special price with widget conditions

I try to do a list of the products which have a special price defined. So I created a widget like that : But even the products which have their "Date To" that is passed are shown. Is it possible to ...
10
votes
2answers
3k views

JS Widget: two custom Widgets extended same parent Widget Magento 2

Precondition I have 2 custom widgets extending same parent widget. Parent widget: Magento_ConfigurableProduct/js/configurable First Custom Widget: Vendor_AModule/js/configurable Second Custom Widget:...
0
votes
1answer
744 views

Magento 2.1.5: Product Widget for Homepage - Not Working

I am facing the following issue when creating a condition to show products on the homepage using the widgets in the content manager. I am running 2.1.5 and have manually checked the files for which ...
4
votes
1answer
2k views

Magento 2 Open All Accordion

I'm trying to make a accordion faq page on mobile but it should be open by default? It's working when i use this line of code $( "#accordion" ).accordion( "activate" ); is there a counter part for it? ...
0
votes
2answers
668 views

Remove store code from Catalog Product Link Widget

I am adding product links to a CMS page using the "Catalog Product Link" widget feature. The inserted code looks like such: {{widget type="catalog/product_widget_link" title="title" template="catalog/...
0
votes
1answer
190 views

Exceptions after changing to developer mode

After I changed to developer mode, I can't view the main page, and get the following exception (Magento 2.1.2) Invalid XML in file x.com/app/code/Ves/ImageSlider/etc/widget.xml: Element 'description':...
1
vote
0answers
94 views

Magento 2, how to get a widget to update immediately?

So I've created a widget, and I noticed that the products were not updating as frequently as I wanted. So I re-created the widget within the same block. However, even after re-indexing, and re-...
1
vote
2answers
4k views

Magento 2: how to add a block in cart under cart summary?

It's possible to use a widget to insert a block inside the cart summary (at the bottom). However I'd like to add a block under the cart summary. I've already created a custom theme which inherits ...
1
vote
2answers
4k views

How to create Product list widget with owl carousel on Magento 2?

My steps: Copy magento-2-directory/magento/vendor/magento/module-catalog-widget/view/frontend/templates/product/widget/content/**grid.phtml** to magento-2-directory/app/design/frontend/Agestor/...
6
votes
2answers
5k views

How to close modal popup by clicking outside the modal-content in Magento 2

I have created a popup successfully by using Magento 2 modal code as i added below but now i want to close the popup even customer click on outside the pop-up or blur area. Is there any existing ...
2
votes
0answers
454 views

Magento 2 QuickSearch widget

Does anyone have any experience with Magento 2 QuickSearch widget so perhaps they can provide a code sample (how to use it in module)? I have managed to include it to my js file, but i can not figure ...
2
votes
1answer
2k views

Magento : Call widget call from phtml file

I have created Widget and want to call it from header.phtml In this widget i have called Static block but widget not called.This widget have id 2 i have set code below please help me to correct this ...
1
vote
1answer
1k views

How to add widgets to specific pages in magento?

I created a static block. Then made a widget using that static block. And now i want to add that to the layout of some pages. If i choose display on all pages, it works on all pages. But as of now i ...
2
votes
1answer
948 views

Magento 2 getPriceInfo returns the same price for every product in collection

I'm building a widget which displays a given number of products based on the Magento\Sales\Model\ResourceModel\Report\Bestsellers\CollectionFactory collection factory and I try to get the correct ...
3
votes
1answer
2k views

Magento 2 widget with js

Tell me please how to create my own Magento 2 widget with custom JS. I need something like a "scroll to top" button, but with another function. I'm allready have a worked script, but how i can create ...
3
votes
1answer
548 views

Is it possible to disable widget without widget.xml changes?

I have extension with widget.xml file where there are 5 defined widgets. 1 of the widgets is available only to premium customers. I don't want this widget to show up inside Widget type selection in ...
1
vote
0answers
57 views

Meigee Widget code 1.9.1.2 not displaying correctly

I noticed after installing the new security patch my homepage products blocks disappeared. I removed this code which pulled the New products to the home page, however this code blocks all other codes ...
0
votes
4answers
2k views

New Products 3 columns on Home page CMS

I had a nightmare with New Products display on homepage with 1 row to display 5 products (columns) on magento 1.9.3 I have following code: {{widget type="catalog/product_widget_new" display_type="...
2
votes
1answer
934 views

Magento 2 showing the same Widget twice

I need to create 2 widgets on the homepage (CMS Home Page -> Main Content Area). In order to do that, I created 2 modules (one for each widget) and extended from Catalog Product List to use my own ...
0
votes
1answer
49 views

Will removing themes and modules speed up magento

I am using a purchased theme for my website and it contains about 14 different themes. I have picked out bits and pieces of all the different themes to create my own child themes and now the others ...
2
votes
2answers
3k views

Magento 2.1: create a WYSIWYG field in a custom widget

Is there a way to create a custom widget with WYSIWYG fields? I followed this tutorial here but when I enter data, they are not saved.
5
votes
2answers
6k views

What is the difference between block and widget code?

This code gives me a bunch of products: {{block type="catalog/product_list" limit="4" category_id="13" template="catalog/product/list.phtml"}} This code gives me nothing: {{widget type="catalog/...
5
votes
3answers
5k views

Magento 2 Widget With Image Chooser

So am working on a widget which allows the client to choose an image from their library of images and then insert it into the widget's params. Here is the block class code I am using for the image ...
0
votes
1answer
268 views

Mage_Core_Block_Abstract vs Mage_Core_Block_Template

What is the difference between Mage_Core_Block_Abstract and Mage_Core_Block_Template? When would I want to use each?
3
votes
1answer
3k views

Recently viewed widget display nothing - Magento 2.0.8

I installed Magento 2.0.8 without sample data. When I insert the widget in the static block, it does not show any recently viewed product in home page(after sign in). why it is not work in cms ...
2
votes
2answers
2k views

Widget Frontend Display

I managed to develop a custom widget, the problem is that its not displaying in the frontend. The goal is to add the widget to a static block and then display the block in frontend. I created the ...
0
votes
2answers
1k views

Add animation to product tabs (or any jquery widget)

How would you add animation to product tabs in magento2? i tried following the guide here: http://devdocs.magento.com/guides/v2.0/javascript-dev-guide/widgets/widget_tabs.html#fedg_tabs_options-...
0
votes
0answers
413 views

Adding wishlist button on homepage for newest products

I am a newbie .I have added a widget from admin panel to home page for displaying newest product. But it does not show any wishlist button for those product. What should I do for this?
0
votes
1answer
1k views

Can you add the current Currency Symbol to a CMS Block

I would like to add a the currency symbol to a CMS block on a category page or in the category description. It would be something like under €50 or under $50. Is there a simple way to do this with a ...
5
votes
5answers
3k views

Magento 2 Custom Widget set template data not showing at frontend

I am working to create custom widget in custom extension. I followed this to create widget in my custom extension. All working fine but data not showing in the template $this->setTemplate('widget/...
0
votes
1answer
1k views

new products list - with title & short description

I want my New Products (list) widget to display the Title & Short Description of the items. E.g. www.pccasegear.com there "New products" section on there home page. I've had a look at a few ...
1
vote
1answer
464 views

How can I include JS/CSS files only on pages which have my widget?

I'm creating a custom widget of a form element which requires some CSS and Javascript. I plan on injecting the CSS and Javascript files into the <head> section of any pages which uses that ...
2
votes
1answer
547 views

Magento2 Recently viewed widget not working

I am working on a new Magento2 website and need to implement the recently viewed section on a page. I tried using Magento's default widget and double checked all configurations but its output is not ...
3
votes
2answers
6k views

How to render widgets in product and category description in Magento 2?

In Magento 2 we can add widgets to CMS pages and CMS blocks with a directive like this (assuming we created this custom widget with a module before): {{widget type="Vendor\Module\Block\Widget\...
4
votes
2answers
842 views

Magento2, custom widget save data wrong encoding

I create a custom widget for magento2. I have one text parameter: <parameter name="title" xsi:type="text" visible="true" sort_order="1" > <label translate="true">Title</...