Page 1 of 1

CSS not Being Applied to the Back Button?

Posted: Mon Nov 22, 2021 4:38 pm
by pmjd
Hello,

I've added the following custom code to move just the nuActionHolder to a left vertical position for only the edit form, and change the nuActionButton format to be bigger.

Code: Select all

if (nuFormType() == 'edit') {
    nuResize()}
    


function nuResize() {
   
     var h = window.innerHeight;

     $('#nuActionHolder').css({
         'width': '100px',
         'float': 'left',
         'height': h,
         'border-right': 'solid',
         'border-right-width': 'thin'
     });
    $('.nuActionButton').css({
         'width': '90px',
         'height': '45px',
         'margin':'5px'
     });
    $('.nuBackBtnButton.nuActionButton').css({
         'width': '90px',
         'height': '45px',
         'margin':'5px'
     });
   
}
However the Back button always retains it's original css code and looks different to the rest.
nuActionHolder.png
I've tried to target the Back button using #nuBackBtnButton and #nuBackBtnButton.nuActionButton but neither have any effect. Does anyone know if there is another class I should be targetting to change the Back button?

Thanks,
Paul

Re: CSS not Being Applied to the Back Button?

Posted: Mon Nov 22, 2021 4:59 pm
by kev1n
Add this in the function nuResize():

Code: Select all

$(function() {
    $('#nuBackBtnButton').css({
         'width': '90px',
         'height': '45px',
         'margin':'5px'
     });
});   

Re: CSS not Being Applied to the Back Button?

Posted: Mon Nov 22, 2021 5:02 pm
by pmjd
Great, thank you kev1n that worked :D

Can I ask how it works? How does the function within the function force the css to be applied?

Re: CSS not Being Applied to the Back Button?

Posted: Mon Nov 22, 2021 5:06 pm
by kev1n
This is a jQuery construct, see here: https://api.jquery.com/ready/ The event occurs when the HTML document has been fully loaded.

Re: CSS not Being Applied to the Back Button?

Posted: Mon Nov 22, 2021 5:08 pm
by pmjd
Thank you

Re: CSS not Being Applied to the Back Button?

Posted: Thu Jan 27, 2022 3:59 pm
by baracca
Hello! I'm absolutly a newbie.
In my nuActionHolder there isn't the back button, why? Probably I have to add it but I don't understand how...

Re: CSS not Being Applied to the Back Button?

Posted: Thu Jan 27, 2022 4:04 pm
by kev1n
Hi,

Edit nuconfig.php and set this option to true.

Code: Select all

nuUXOptions['nuShowBackButton']= true;
You must restart your browser after modifying nuconfig.php in order for changes to be reflected

Re: CSS not Being Applied to the Back Button?

Posted: Thu Jan 27, 2022 4:31 pm
by baracca
kev1n wrote: Thu Jan 27, 2022 4:04 pm Hi,

Edit nuconfig.php and set this option to true.

Code: Select all

nuUXOptions['nuShowBackButton']= true;
You must restart your browser after modifying nuconfig.php in order for changes to be reflected
Thank you very much! 8-)