Questions tagged [cms-block]

Denotes questions related to CMS blocks.

Filter by
Sorted by
Tagged with
0 votes
1 answer
21 views

Display product attributes in cms block or page builder

I need to be able to reference product attributes inside a cms block or page builder, I am not wanting to create any template files I am wanting to call it like you can call a variable. So here is one ...
user avatar
  • 1
0 votes
0 answers
13 views

How can I add static block with arguments in cms page?

I would like to add that static block {{block class="MSP\ReCaptcha\Block\Frontend\ReCaptcha" name="msp-recaptcha-newsletter" template="MSP_ReCaptcha::msp_recaptcha_newsletter....
user avatar
0 votes
0 answers
21 views

problem with image

Image is not displaying from cms block: while inspecting the image (%5Ccache%C) on the PHP page. media/catalog/product%5Ccache%5Cb61ea1bed30c1f9d9fe7f48eaf8288bc%5C//m/e/meal.jpg instead of (media/...
user avatar
0 votes
0 answers
14 views

Magento2 Pass CMS Block data to API in Json format by extracting data from Html tags

Magento2 I have created a CMS Block with HTML data inside, with tags like Ul Li etc.. In this li tags I have added new tags like <li type="XYZ" title="ABC" />, Now I need to ...
user avatar
  • 3,426
0 votes
1 answer
31 views

i want to add accordion inside the cms block, but it is not taking

i want to add accordion inside the cms block, but it is not taking this is the code i want to add <div id="accordion" data-mage-init='{ "accordion":{ "activate": 2, &...
user avatar
0 votes
2 answers
209 views

Magento 2 Passing parameters to Content Blocks

I'm new to Magento I want to create a block in the admin panel (Content > Elements > Blocks) which contains HTML code, CSS style, and some dynamic parameters under its content box. Example: <...
user avatar
0 votes
0 answers
19 views

How to add a row within another row?

I want to add a row within another row through admin panel blocks. I'm trying to but it doesn't work so, is it even possible ?
user avatar
0 votes
0 answers
10 views

Magento widget not pulling through

I have a Magefan blog widget that is pulling through the widget code on the frontend on the dev site but it works on my local! The module is up to date on both sites but I'm not sure why it's working ...
user avatar
0 votes
0 answers
90 views

How to add image with link in CMS Block using Page builder in Magento 2?

In Magento 2.4.2, I am trying to add the CMS Block with image and link Image should be based on Device - Responsive ie., for web page view one image, for mobile view different image. How to add this? ...
user avatar
  • 1,094
1 vote
2 answers
116 views

magento 2 how to get cms blocks toOptionArray

<?php namespace [Vendor\Module]\Model\System\Config; use Magento\Cms\Model\ResourceModel\Block\CollectionFactory; use Magento\Framework\Data\OptionSourceInterface; class CmsBlocks implements ...
user avatar
  • 45
0 votes
1 answer
55 views

Call CMS Block in Non-Checkout KO Template

I am using the WeltPixel theme and want to add add a CMS block to the ajaxlogin-popup.html file below the "Forgot Password" link. I am getting this error in console: Uncaught TypeError: ...
user avatar
0 votes
2 answers
114 views

How do you create or modify a CMS Block without Deprecated Methods?

How can I create or modify a CMS Block from a list according to that CMS Block if there is or not, in the same programming code without depracted methods? load() & save() -> is the deprecated ...
user avatar
  • 2,757
0 votes
1 answer
59 views

Display a static block in Homepage listing all categories

I'd like to display a static block in my CMS Homepage which lists all 1 level categories. How should I do?
user avatar
  • 115
0 votes
1 answer
32 views

Product -> Content -> Edit with Page Builder -> Apply Template -> CMS Block application problem

When inserting the previously created CMS block into product description, i can apply template in pagebuilder in Super Admin, but i cannot apply template if i am not Super Admin. Is there any way ...
user avatar
0 votes
1 answer
288 views

How to display CMS static blocks based on store in Magento 2

I have created two stores english and german and created static blocks with different contents based on the store in admin.Block Id(test) for both stores are the same but both blocks assigned to ...
user avatar
4 votes
1 answer
223 views

How "cms_block_store" and "cms_page_store" tables are working with Primary keys in Magento?

I have a general doubt in MySql foreign key constraints and Magento. As per MySql, a table should have only one primary key for a table and a Primary key should contain unique values. I checked in &...
user avatar
0 votes
1 answer
149 views

Can't get module to show in static block

Using Magento 2 I created a cms static block that points to {{block class="Inchoo\ModalOverlay\Block\etc" template="modal_overlay.phtml"}} I followed this guide on how to create ...
user avatar
  • 47
0 votes
3 answers
338 views

Header and Footer in Luma theme

I want some customization theme luma in my magento 2 website, so I need add in header for all pages banner - custom blocki created - (banner-section) below menu and in footer I need add custom block (...
user avatar
  • 57
0 votes
2 answers
342 views

magento2 how to implement graphql with alpine.js get cms static block data

I have create a static block in magento2 admin panel. I like use graphql with alpine.js to get data of the static block.
user avatar
  • 1
0 votes
1 answer
29 views

Other Method for call a custom customer attribute

I am doing an internship in a company, and my internship supervisor wants me to display customer data. More precisely, on the back office in the customer information there is a custom attribute that I ...
user avatar
0 votes
0 answers
160 views

How to add cms static block to category description programmatically

Instead of directly add cms block to category description, how to add programmatically?
user avatar
  • 103
0 votes
1 answer
70 views

How to add CMS Static block above product Description Section

I want to add cms block above description, how to do in custom theme?
user avatar
  • 103
0 votes
1 answer
81 views

How to set cms block design full width?

For my design i am using cms block as my hero banner, how to set full width?
user avatar
  • 103
1 vote
1 answer
129 views

M2 - Best practice for adding custom less file in Custom Theme for CMS Static Block

I just created custom theme, i have followed a number of guides to properly setting up .less files in a custom theme and nothing seems to be working. Where should i place less file for cms custom ...
user avatar
  • 103
1 vote
1 answer
54 views

M2 - How to include custom theme directory less file path into my CMS block?

I have created custom theme which is inherit from blank theme, I have created more than one CMS block and include into CMS page for home page design. One of my CMS block named service banner In the ...
user avatar
  • 103
0 votes
0 answers
45 views

Pull in Terms and Conditions from Static Block

On Terms and Conditions we try to pull in a static block {{block class="Magento\Cms\Block\Block" block_id="terms_and_conditions"}} {{block id='terms_and_conditions'}} Both ...
user avatar
  • 14.6k
0 votes
3 answers
157 views

Magento 2 how to work with CMS blocks and CMS pages on repository?

I have created many blocks but as far as I know only by exporting them from database is the only way to have their code. Is there another way to have the files? because pushing and commiting .sql to ...
user avatar
1 vote
0 answers
98 views

cms blocks removing content after save in magento 2?

cms block break html tags after saving data. it is removing url of image and display like this <div class="col-sm-12 col-xs-12"> <a href="#"> <img class="...
user avatar
0 votes
1 answer
59 views

show all products in one page on magento 2

I want to show all products in one page from a custom cms block. This is the code I tried: {{block class="\Magento\Catalog\Block\Product\ListProduct" template="Magento_Catalog::list....
user avatar
  • 455
0 votes
1 answer
85 views

Display CMS Static Block At Shipping Step Outside Order Summary

I want to display a cms-static block outside summary at shipping & payment step in side bar please check below attachment of output Shipping Step Payment Page Find checkout_index_index.xml code ...
user avatar
1 vote
0 answers
50 views

Show wishlist counter on header when it doesnt have items

I need to display cart and wishlist counters on my own header block. For the first one i've just modified the CSS to display block. But I can't find how the wish list counter works, so it will show 0 ...
user avatar
1 vote
1 answer
106 views

Magento 2 - WYSIWYG uploaded images resized to 500px wide. How can I prevent this?

When uploading large images to be used within a block or page, Magento 2 resizes them to 500px width. I don't want that instead I want them left at their original size. I have no extensions installed ...
user avatar
1 vote
0 answers
132 views

Cannot insert widgets in CMS page or static block, somebody know what could be wrong?

using Magento version 2.3.5-p1. Have the follwing problem and do not know why this is not working anymore. Editing a block, disable editor and clicking on "insert widget" I get a 404 page ...
user avatar
0 votes
2 answers
72 views

How to add Slick Slider

I want to add slick slider on my home page in magento using static block and phtml with rotating images. if anyone have idea about that then please answer my question as soon as possible. Thank you ...
user avatar
  • 473
0 votes
1 answer
85 views

Override xml files

Is it possible to override etc/import/block.xml with child theme ? I have modified block.xml itself and works fine for now but if I update 3rd party extension my modifications will be lost . I am ...
user avatar
2 votes
1 answer
2k views

Magento 2.3.5 - Inline Translate within a CMS Block

I'm running a multi website and store setup. I'm trying to use inline translation within a CMS block so I don't have to create multiple blocks for different stores. For example I'm using this within ...
user avatar
0 votes
1 answer
66 views

Magento 2.3.4 - Call phtml file within CMS block

I'm trying to call the following phtml file into a CMS block. Phtml file location app/design/frontend/{Package}/{theme}/Magento_Newsletter/templates/subscribe_footer.phtml I tried using {{block ...
user avatar
0 votes
0 answers
76 views

Magento 1.9.4.0 CMS Block Widget Issue

I'm trying to add widget to cms block or page but when i add it only display short code on page and not render, i tried different magento default widgets results is same also tried using code on ...
user avatar
0 votes
1 answer
1k views

How to update existing CMS block content using data patches?

I have updated content for the existing cms page by using data patches in Magento 2.3.3, but the same approach not working for CMS block. <?php namespace Test\CmsExport\Setup\Patch\Data; use ...
user avatar
2 votes
2 answers
1k views

Magento 2 graphql get the cms block based on store

I am trying to get the cms block based on store, but it is alway returning the default store block content. The query I used : { cmsBlocks(identifiers: "login-data") { items { identifier ...
user avatar
0 votes
2 answers
53 views

Show parent categories on a page

I am a beginner in Magento. This may be a simple question. I have a header menu 'shop'. This link should redirect to a page that shows all parent categories. How can I do this? any help is really ...
user avatar
0 votes
1 answer
49 views

magento 2.2.3 how to add a new cms block or new phtml to product page

I want to add a new cms block or PHTML to the product page. I have the following files composer.json, etc/module.xml, and registration.php I have view/frontend/layout/catalog_product_view.xml &...
user avatar
1 vote
2 answers
2k views

How to make the Video Autoplay in cms block? Magento 2.2

In Cms Block, I'm trying to add an embed Youtube video that would autoplay upon the page is loaded. However, the part that defines autoplay "?autoplay=1&loop=999999999999&playlist=_bkTXNozzzQ" ...
user avatar
1 vote
2 answers
362 views

Adding a block inside a block already in a container

I have a third-party module and I'm trying to inject a block of my own (a CMS block) between two of their blocks. I'm doing something wrong because I can get my block to appear at the very end or the ...
user avatar
  • 669
1 vote
1 answer
68 views

Set different static cms block to each different product

I have a created different CMS static blocks. I need to call the respective static block for each product. I thought of getting the URL key and then assign it to the respective Products. How could I ...
user avatar
  • 661
1 vote
0 answers
92 views

Magento 2 How to create Hero image module to CMS page [duplicate]

I have created the hero image module for the CMS page. But the image is not uploaded and there is issue to save the image too. Is there any solution for that? please suggest.
user avatar
0 votes
1 answer
956 views

Magento 2.3: Using HTML in a Static Block

Can I use HTML content in a Static Box? If so, please provide the code that I can use in the Block Content to identify the code as HTML. I am trying to use a Widget to insert HTML content into the ...
user avatar
0 votes
1 answer
25 views

Using a Page vs. a Static Block

I'm trying to get a very basic understanding of when I should use a Page vs. Static Block to create content for the site. Can someone provide examples of where they might be used? Or scenarios where ...
user avatar
0 votes
0 answers
584 views

Magento 2 - Custom Variable | How to get the Plain Value as well as HTML value using directive {{CustomVar code="CUSTOM_VAR_CODE"}} in CMS Blocks?

I have added the Custom Variable from Admin > System > Other settings > Custom Variables > Add New Variable, it is possible to add both the Variable HTML Value as well as Variable Plain Value as in ...
user avatar
0 votes
1 answer
635 views

Magento2 : How to call CMS page link in PWA

I have Created one CMS page and Added in Static block like below code : <ul> <li><a href="about">About</a></li> </ul> Called static block in venia-concept/src/...
user avatar

1
2 3 4 5 6