| CARVIEW |
Select Language
HTTP/2 301
date: Mon, 29 Dec 2025 17:14:46 GMT
content-type: text/html; charset=UTF-8
location: https://docs.gravityforms.com/gform_preview_header/
server: cloudflare
strict-transport-security: max-age=604800
strict-transport-security: max-age=31536000; includeSubDomains
x-content-type-options: nosniff
x-content-type-options: nosniff
x-xss-protection: 1; mode=block
x-xss-protection: 1; mode=block
x-frame-options: SAMEORIGIN
x-frame-options: SAMEORIGIN
content-security-policy: frame-ancestors 'self';
referrer-policy: no-referrer
referrer-policy: strict-origin-when-cross-origin
x-redirect-by: WordPress
fastcgi-cache: MISS
cf-cache-status: DYNAMIC
nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
report-to: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=IgcpmN6CKVc1nOnHJ16zwO8QeBB53tEm0y8s96BX8vC9MurVxhTBpz6PihqKf%2FJRlpD95DnhUbaS5HAY2dONk8xRxElF%2BWTzqB3W7W74LJW4BuU7"}]}
cf-ray: 9b5aef840a24e8e0-BLR
HTTP/2 200
date: Mon, 29 Dec 2025 17:14:47 GMT
content-type: text/html; charset=UTF-8
server: cloudflare
vary: Accept-Encoding
strict-transport-security: max-age=604800
strict-transport-security: max-age=31536000; includeSubDomains
x-content-type-options: nosniff
x-content-type-options: nosniff
x-xss-protection: 1; mode=block
x-xss-protection: 1; mode=block
x-frame-options: SAMEORIGIN
x-frame-options: SAMEORIGIN
content-security-policy: frame-ancestors 'self';
referrer-policy: no-referrer
referrer-policy: strict-origin-when-cross-origin
link: ; rel="https://api.w.org/"
link: ; rel="alternate"; title="JSON"; type="application/json"
link: ; rel=shortlink
fastcgi-cache: MISS
report-to: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=z3eIbOjmwXF3pv9H06iOpCh%2FPqxNStxrvH7ElAJa8%2FvCBm728Z5vmcKSun8ePb0jhe3qZn1lU2Oomzp2hRgieusyqu5pGE9lUPi70mxFvwpFc%2FhP"}]}
cf-cache-status: DYNAMIC
nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800}
content-encoding: gzip
cf-ray: 9b5aef8b1e4ce8e0-BLR
gform_preview_header - Gravity Forms Documentation
gform_preview_header
Description
The “gform_preview_header” action is triggered when the header of the form preview page loads, allowing further actions to be done.
Usage
add_action( 'gform_preview_header', 'my_function', 10, 1 );
Parameters
- $form_id int
The ID of the current form being previewed.
Examples
function my_function() {
//Do something here
}
add_action( 'gform_preview_header', 'my_function', 10, 1 );
Since
This action hook was added in Gravity Forms 2.4.19
Source Code
This action hook is located in preview.php.