# Qualsiasi modo per impostare l'orientamento in manifest.webmanifest su ritratto?

**URL:** https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948
**Category:** Support
**Created:** [3 Marzo 2021, 11:21pm UTC](https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948 "2021-03-03T23:21:34Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![MrDavis97](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mrdavis97/32/206391_2.png) [@MrDavis97](https://meta.discourse.org/u/MrDavis97)
#### Post date: [3 Marzo 2021, 11:21pm UTC](https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948/1 "2021-03-03T23:21:34Z")

</div>

Ho provato a modificare il file `metadata_controller.rb`, ma con `./launcher rebuild app` le impostazioni per questo campo vengono reimpostate come vuote (cioè l’utente può scegliere). Quindi, esiste un modo per forzare la modalità verticale con le PWA, o solo il team di Discourse decide a livello di core per tutte le istanze di Discourse?

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [3 Marzo 2021, 11:35pm UTC](https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948/2 "2021-03-03T23:35:58Z")

</div>

Potresti voler leggere la storia di questo argomento _in qualche modo_ controverso:

> [@Manifest orientation property](https://meta.discourse.org/t/manifest-orientation-property/94900/3?u=falco):
>
> At first it was portrait and people asked for any in the link OP provided. Then we got [a PR](https://github.com/discourse/discourse/pull/4703) changing to natural. Then we [got complaints](https://forum.quartertothree.com/t/suggestions-for-future-improvements-to-our-forum-software/129744/469) and changed back to any. man_shrugging We can certainly do this. Let me research a bit and get back to you.

Le persone si lamentano sempre, quindi non impostiamo più nulla. Se vuoi impedire che il tuo telefono ruoti, puoi bloccare la rotazione dal pulsante di accesso rapido di Android nel pannello delle notifiche.

Detto questo, se desideri comunque modificare il file manifest per il tuo sito, dovrai scrivere un plugin.

---

<div class="post-metadata">

### Author: ![MrDavis97](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/mrdavis97/32/206391_2.png) [@MrDavis97](https://meta.discourse.org/u/MrDavis97)
#### Post date: [4 Marzo 2021, 12:02am UTC](https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948/3 "2021-03-04T00:02:27Z")

</div>

Grazie. Forse scriverò un plug-in.

Vorrei anche farti sapere il motivo per cui vorrei solo l’orientamento verticale. Prendiamo ad esempio Meta Discourse. Sto usando un iPhone, quindi vado su [meta.discourse.org](http://meta.discourse.org) con Safari e clicco su ![Share_Icon_Apple_NEW](https://global.discourse-cdn.com/meta/original/3X/d/4/d4d4d1673f2c8c8a8bf09cebca2da62f6475e74b.png), poi su `aggiungi alla schermata Home`. Quindi tutto funziona correttamente, ed ecco come appare:

 ![IMG_6209.PNG](https://global.discourse-cdn.com/meta/original/3X/7/7/77abcc68a44989f51cccdad9fd948ebaa66f9596.jpeg)

Tuttavia, quando ruoto lo schermo in modalità orizzontale e poi torno alla modalità verticale, succede questo (nota che il banner viene tagliato e non torna normale):

 ![IMG_6210.PNG](https://global.discourse-cdn.com/meta/original/3X/a/7/a79b9226ff577ab8c123989b563a733bdbd5446e.jpeg)

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [4 Marzo 2021, 12:21am UTC](https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948/4 "2021-03-04T00:21:08Z")

</div>

> [@MrDavis97](#):
>
> iPhone

Non scommetterei sul fatto che quella proprietà venga rispettata su iOS, considerando che il loro supporto per il Web App Manifest è quasi inesistente.

---

<div class="post-metadata">

### Author: ![system](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/system/32/443519_2.png) [@system](https://meta.discourse.org/u/system)
#### Post date: [3 Aprile 2021, 12:21am UTC](https://meta.discourse.org/t/any-way-to-set-orientation-in-manifest-webmanifest-to-portrait/181948/5 "2021-04-03T00:21:52Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
