Page 3 of 4
Re: manipulation between main form and iframe
Posted: Thu Feb 20, 2020 10:30 am
by joecocs
I have nested iframes in its iframes with 5 levels of nesting.
like this :
Capture d’écran 2020-02-20 à 10.26.39.png
now i'm looking to color the tabs and the header of forms with the background color of each iframe, if you have an idea

Re: manipulation between main form and iframe
Posted: Thu Feb 20, 2020 11:38 pm
by admin
joecocs,
Try this in the Javascript section of each iFrame's Form Properties.
Code: Select all
var c = '#6395ed;
parent.$('#iframe1').css('border-color', c');
$('.nuTab').css('color', c);
$('#nuBreadcrumbHolder').css('background-color', c);
Capture.PNG
Steven
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 7:21 am
by kev1n
joecocs wrote:
now i'm looking to color the tabs and the header of forms with the background color of each iframe, if you have an idea

How are you seting the background color of each frame?
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 8:54 am
by joecocs
Thank's for the code,
currently I put this code in the Custom Script of each form in the iFrame
Code: Select all
$('#nubody').css("background-color", "#20b2aa");
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 8:58 am
by joecocs
Is it possible to color the header of each forms like the background ?
I have a question about the function: How do I use it in for when I save a new record, the form refreshes and displays this record without having to go back to the browse form?
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 8:59 am
by kev1n
Try adding this:
Code: Select all
$('#nuBreadcrumbHolder').css('background-color', "#20b2aa");
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 9:13 am
by joecocs
Sorry but don't work :
Code: Select all
var c = '#ffa07a;
parent.$('#Form_Gestion_Projets').css('border-color', c');
$('.nuTab').css('color', c);
$('#nuBreadcrumbHolder').css('background-color', c);
$('#nubody').css("background-color", "#c");
$('#nuBreadcrumbHolder').css('background-color', c);
Instead of # iframe1 # should I put the name of the iframe I want to colorize?
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 9:21 am
by kev1n
Just put this code in each iframe:
Code: Select all
$('#nubody').css("background-color", "#20b2aa");
$('#nuBreadcrumbHolder').css('background-color', "#20b2aa");
if it doesn't work, try this:
Code: Select all
$(document).find("#nubody").css("background-color", "#20b2aa");
$(document).find("#nuBreadcrumbHolder").css("background-color", "#20b2aa");
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 9:35 am
by joecocs
I just checked the code:
Code: Select all
var c = '#6395ed;
parent.$('#iframe1').css('border-color', c');
$('.nuTab').css('color', c);
$('#nuBreadcrumbHolder').css('background-color', c);
and I replaced with:
Code: Select all
var c = '#6395ed';
parent.$('#iframe1').css('border-color', c);
and it works
on the other hand the area of the button is not colored?
and I try to nitpick by wanting each word on the tab to take the background color of the iframe, is it possible?
Re: manipulation between main form and iframe
Posted: Fri Feb 21, 2020 9:52 am
by kev1n
joecocs wrote:
on the other hand the area of the button is not colored?
What button are you referring to? (maybe upload a screenshot)
joecocs wrote:
and I try to nitpick by wanting each word on the tab to take the background color of the iframe, is it possible?
Something like this?
Code: Select all
$(document).find(".nuBreadcrumb").css("color", "#20b2aa");