W
W
WebDev2017-04-17 13:48:10
In contact with
WebDev, 2017-04-17 13:48:10

How to make an iframe display the mobile version of the site?

I created a VK application (essentially a frame), the site is displayed there. The iframe is narrow, but the site is displayed in the full version and does not want to switch to mobile. The site is designed adaptively, without a separate domain for the mobile version.
Is there any easy way to make the site appear as mobile?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
seniorjava, 2020-04-02
@seniorjava

The width of the iframe depends on the viewport, so try setting your header to something like this:

<meta name="viewport" content="width=device-width; initial-scale=1.0; maximum-scale=1.0; minimum-scale=1.0;" />

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question