Manage content display
By default, a CDN resource returns a response from the content source. You can temporarily hide the content so that the CDN resource content is unavailable to users.
If you hid content display, you can restore it at any time.
Hide content display
You can hide CDN resource content display in one of the following ways:
- set a status code — the user will receive a response with the set status code;
- or configure a redirect — the user will be redirected via another link.
Set a status code
-
In the Control panel, in the top menu, click Products and select CDN.
-
In the CDN resources section, open the CDN resource page → the General tab.
-
In the Return http status code block, select the Enabled checkbox.
-
In the Response status code field, enter a response code in the range from
100to599, except redirect codes:301,302,303,307,308. The entered status code will be displayed in the CDN resource response. -
Optional: in the Response body field, enter the text that will be displayed in the response.
-
Click Apply. While the settings are being applied, the CDN resource will be in the
PROCESSINGstatus. During this time, applying other settings is unavailable. The settings will be applied when the CDN resource switches to theACTIVEstatus.
Configure a redirect
-
In the Control panel, in the top menu, click Products and select CDN.
-
In the CDN resources section, open the CDN resource page → the General tab.
-
In the Return http status code block, select the Enabled checkbox.
-
In the Response status code field, enter one of the redirect codes:
301,302,303,307,308. -
In the Redirect URL field, enter the link to which the user will be redirected.
-
Click Apply. While the settings are being applied, the CDN resource will be in the
PROCESSINGstatus. During this time, applying other settings is unavailable. The settings will be applied when the CDN resource switches to theACTIVEstatus. -
Optional: for the CDN server to cache content from the redirect link, enable redirect following. By default, the CDN server caches only the response with the redirect code.
Restore CDN resource content display
-
In the Control panel, in the top menu, click Products and select CDN.
-
In the CDN resources section, open the CDN resource page → the General tab.
-
In the Return http status code block, clear the Enabled checkbox.
-
Click Apply. While the settings are being applied, the CDN resource will be in the
PROCESSINGstatus. During this time, applying other settings is unavailable. The settings will be applied when the CDN resource switches to theACTIVEstatus.