NetTalk Central

Author Topic: Trying to Format the Menu in Page Header  (Read 4404 times)

Jim A

  • Full Member
  • ***
  • Posts: 203
    • View Profile
    • Email
Trying to Format the Menu in Page Header
« on: January 09, 2014, 04:45:43 PM »
Hi All: I'm using a Double-Drop menu that lives on the bottom of the page header.  I am trying to set its properties to the following:

    margin-left: auto;
    margin-right: auto;
    width: 90%;
    display: block;
    border: 0;
    min-height: 37px;

What I want is to have the row of buttons centered at the bottom of the pageheader.

I can find the section of CSS using Firebug and can make the changes in Firebug.  That works fine.  But, if I try editing the theme.css to reflect these changes, and then refresh the page, nothing changes.  (I know -- don't make changes to the theme.css cuz they will be overwritten by the next update -- but I was just testing). When I look at the saved theme.css in Firebug, those changes that I made with an editor don't stick.  I am using the theme.css that Firebug points to.

I've tried to follow the trail to the place where these changes can be made but am having a hard time making sense of it.  How can I apply the changes to the 'nt-menu-div ui-corner-br' so that it will actually work?  There are six buttons in the menu.  What do I need to change to move the group of buttons to the center?

Many thanks,

Jim

Nick

  • Full Member
  • ***
  • Posts: 118
    • View Profile
    • Email
Re: Trying to Format the Menu in Page Header
« Reply #1 on: January 10, 2014, 12:21:18 AM »
I made some changes to the double-drop menu in jquery-nt-menu.css and that worked.
Sometimes you have to delete your complete browser cache to see changes but I guess you know that.

HTH,
Nick

Jim A

  • Full Member
  • ***
  • Posts: 203
    • View Profile
    • Email
Re: Trying to Format the Menu in Page Header
« Reply #2 on: January 10, 2014, 03:57:03 AM »
Thanks Nick.  I will give that a try.

Jim A

  • Full Member
  • ***
  • Posts: 203
    • View Profile
    • Email
Re: Trying to Format the Menu in Page Header
« Reply #3 on: January 10, 2014, 05:35:04 AM »
Tried that.  No joy.

I can't seem to follow the hierarchy of css properties.  Firebug shows that the properties are coming from the /themes/metroblue/theme.css.  Since they don't change, it has to be coming from somewhere else.

I'll keep experimenting.

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: Trying to Format the Menu in Page Header
« Reply #4 on: January 10, 2014, 06:21:56 AM »
>> What I want is to have the row of buttons centered at the bottom of the pageheader.

you can't use
width: 90%;
well, I suppose you can, but that won't center it. It'll just create a 5% margin on the left. to centre it you would need to calculate the width exactly in pixels, and then set
width:295px;
where 295 is however many pixels wide it is.

Note also that this technique is not supported by all browsers, but most modern ones you should be ok.

>> I can't seem to follow the hierarchy of css properties

see http://www.capesoft.com/docs/NetTalk7/NetWebThemes.htm#CssOrder

>> But, if I try editing the theme.css to reflect these changes, and then refresh the page, nothing changes. 

correct.

>> (I know -- don't make changes to the theme.css cuz they will be overwritten by the next update -- but I was just testing)

no, they don't get overwritten by the next update, they get overwritten by the next build that runs gzipall.bat. You're trying to do "quick and dirty testing" which is not only harder than doing it correctly, it serves no purpose because the results will change when you _do_ do it correctly.

The correct way is to add the style to your own css file, using an existing css class name if you like. If you just do it right then it's much easier, and may actually work.

cheers
Bruce





Jim A

  • Full Member
  • ***
  • Posts: 203
    • View Profile
    • Email
Re: Trying to Format the Menu in Page Header
« Reply #5 on: January 10, 2014, 06:55:00 AM »
Thanks Bruce.  That makes sense.

Incidentally, I'm using % in setting up columns in the page and also in the image tag.  It adjusts both proportionately and works in Chrome and Firefox. Not sure about IE.  I wasn't counting on the % to do the centering.   

Jim A

  • Full Member
  • ***
  • Posts: 203
    • View Profile
    • Email
Re: Trying to Format the Menu in Page Header
« Reply #6 on: January 10, 2014, 07:47:37 AM »
Hmm. My apologies for not consulting the latest documentation.  Things are quite clear in there.