I added an html component to my website. I hope that the content in this component can be directly adapted to the size of the component for full-screen display. What should I do?
Wix does not currently support programatic sizing and positioning of an HtmlComponent. For more information, see Adjusting the Sizing of the Displayed Content .
Fullscreen with HTML Component
This example demonstrates the requestFullscreen method of the HTML fullscreen API as used to change a specified element to full screen.
Hi, the example link no longer works - is there an updated example for this? Thank you
This is what you are searching for.
$w("#myHtmlComponent").allowFullScreen();
In future make sure to open your own posts, instead of bumping up very old ones!!!
Old posts can lead to wrong answers!!!
Wix-Eco-System changes monthly. The code provided years ago → today maybe no longer working!!!
1 Like