nuSetIframeProperty()
and nuGetIframeProperty()
—that let you effortlessly set or retrieve a hash cookie inside an iframe.nuSetIframeProperty()
Syntax:
Code: Select all
nuSetIframeProperty(frameId, property, value, refresh = true)
- frameId: ID of the <iframe> element
- property: Name of the property to set via nuSetProperty
- value: Value to assign to that property
- refresh: (optional) Whether to call nuGetBreadcrumb() afterwards (default: true)
Code: Select all
true – if win.nuSetProperty was called (and breadcrumb refreshed if requested)
false – otherwise
Sets a Hash Cookie inside the target iframe (of a Run Type object, Method iframe) by invoking its nuSetProperty method (if present), then optionally refreshes it.
Quick example:
Code: Select all
nuSetIframeProperty('customer_iframe', 'date_filter', '2025-12-31');
Code: Select all
var iframe = $("#customer_iframe")[0].contentWindow;
iframe.nuSetProperty("date_filter", '2025-12-31');
iframe.nuGetBreadcrumb();
nuGetIframeProperty()
Syntax:
Code: Select all
nuGetIframeProperty(frameId, property)
- frameId: ID of the <iframe> element
- property: Name of the property to retrieve via nuGetProperty
Code: Select all
Value returned by win.nuGetProperty(property), or null if the iframe or method isn’t found
Fetches a Hash Cookie from inside the target iframe by calling its nuGetProperty method.
Quick example:
Code: Select all
let dateFilter = nuGetIframeProperty('customer_iframe', 'date_filter');
console.log(dateFilter); // e.g. "2025-12-31"
Code: Select all
var iframe = document.getElementById('customer_iframe').contentWindow;
var dateFilter = iframe.nuGetProperty('date_filter');
console.log(dateFilter); // e.g. "2025-12-31"