Start game stretched? (Browser embed)

Hey,

Whenever I try to embed my game in a webpage using an iframe, if I set it to be a smaller resolution that the game, scrollbars appear.

I know if you press F3 it sets it to stretch, how can I make that happen by default? They somehow did it with the demo on the preorder page.

Thanks!
. . .do you use any framework? if yes, the framework may set the iframe element's overflow attribute to auto which will automatically put up a scroll bar if the content is too large for the parent element or screen to fit in to. . .( check the css files ). . .
Hey,

Whenever I try to embed my game in a webpage using an iframe, if I set it to be a smaller resolution that the game, scrollbars appear.

I know if you press F3 it sets it to stretch, how can I make that happen by default? They somehow did it with the demo on the preorder page.

Thanks!
Unless specified otherwise, iframes are still "frames" and as such they have a required width and height. This means that if you see scroll bars, the iframe itself is larger than it's being set to. You need to do two things:

1) Set the size of the iframe to the correct width and height

<iframe scrolling="no" frameborder="0" width="640" height="480" style="border: 0px; overflow: hidden;"></iframe> and

2) Set the right document size in the iframe. The most direct way of doing this is

Code:
<html><head></head><body style="margin:0;padding:0;"></body></html>
Unless specified otherwise, iframes are still "frames" and as such they have a required width and height. This means that if you see scroll bars, the iframe itself is larger than it's being set to. You need to do two things:

1) Set the size of the iframe to the correct width and height

<iframe scrolling="no" frameborder="0" width="640" height="480" style="border: 0px; overflow: hidden;"></iframe> and

2) Set the right document size in the iframe. The most direct way of doing this is

<html><head></head><body style="margin:0;padding:0;"></body></html>
That solution doesn't work perfectly.

qpdsv7J.png


The scrollbars are gone but you still need to press F3 to make the game stretch to the height and width of the iframe.
Lol Glory "O"

Sorry that is all I see when I look at the title of your game.
Lol Glory "O"

Sorry that is all I see when I look at the title of your game.
???

http://forums.rpgmakerweb.com/index.php?/topic/49756-gloryquest-a-game-made-in-1-hour/

It's my game i'm using to test embed.

Original thread: https://forums.rpgmakerweb.com/threads/start-game-stretched-browser-embed.50204/