# Environment Tagging

## Page / Blocks tagging

If you have blocks / pages that should be visible in some context, for example you only want to show Guest Portal blocks for clients using the Guest Portal, you can use the field "environment".

![This block will only appear if the website has "gms-gp" or "gms-gp-hotel" env](https://3028197268-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LYM6a76uZePOTen0dIw%2F-M6dKaQacse6zzM78H1N%2F-M6dLEkkguT1XSZ40Lbm%2Fblock-environments.png?alt=media\&token=75421c24-1262-40c7-82de-842a5b95338a)

## Variable tagging

With variables environment tagging, you can control the visibility of a CMS variable in the backoffice.

The local website will still receive the variable if there is a value stored

Indeed you could have a variable visible only for a specific role, but not for other roles for example.

![This variable will only appear if the website has "gms-gp" or "gms-gp-hotel" env](https://3028197268-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F-LYM6a76uZePOTen0dIw-887967055%2Fuploads%2FLmKb1fBWIXjnRWrJQIxB%2FCleanShot%202022-07-22%20at%2013.56.27%402x.png?alt=media\&token=9bd24a7e-2a38-40ca-a66b-a4a5ea96d0a9)

## Manually add environments to a website

{% hint style="warning" %}
In an effort to standardize how environments are added, the "Environment" field in Website Parameters is no longer editable *(exept for Admins)*.&#x20;

Environments can now only be added via Automations. Please contact us on Asana for more details.
{% endhint %}

## Extension Environment tag

Sometimes, you want specific sections of the backoffice to be visible automatically when adding the Extension to the website

For example, for IBE project, some sections in the unit should only be visible when in the context of an "IBE website"

For this, add the extension key inside Testeur for the global setting (don't forget to commit the file `theme/data` modified by Testeur)

![](https://3028197268-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LYM6a76uZePOTen0dIw%2F-MlA_SpSjrZilEDdMewm%2F-MlAaLyh9KU7phDfI5Hr%2Fextension-tag.png?alt=media\&token=a317b6f2-561a-4f73-80d4-454cfaca40ba)

When the extension will be added to a website, it will automatically add to it the environment and show the sections.

## Create new environment in the backoffice

{% hint style="warning" %}
This is only available for admin team of the environment. On your dev environment you can add new environments, **on production / preprod you have to do a request to an admin**.
{% endhint %}

Galaxy > System > Environments

![](https://3028197268-files.gitbook.io/~/files/v0/b/gitbook-legacy-files/o/assets%2F-LYM6a76uZePOTen0dIw%2F-MlK_eoDoYVBjNhHU_PA%2F-MlKaNtoZDcLKh0XXXUG%2Fcreate-environment.png?alt=media\&token=60042378-a216-4bf4-9687-6889d0d207a6)

Each environment has:

* a key (the one used inside testeur)
* a name (the one visible in the website settings)

To create a new environment, click on the "ADD" button.

From this list you can see:

* the environments
* where they are used
