By clicking “Accept All”, you agree to the storing of cookies on your device to enhance site navigation, analyse site usage, and assist in our marketing efforts
These cookies enable our website and App to remember things such as your region or country, language, accessibility options and your preferences and settings.
Analytic cookies help website owners to understand how visitors interact with websites by collecting and reporting information anonymously.
Marketing cookies are used to track visitors across websites. The intention is to display ads that are relevant and engaging for the individual user and thereby more valuable for publishers and third party advertisers.
Hi,
You could do it with jQuery - count the buttons, get the width of the div/parent element, calculate the spacing needed, then set it. Should work on any browser that has JavaScript enabled.
Cheers,
i've done it with php now thanks. same principal of counting buttons and calculate space and inject variable into margin-right.
He's right though, to slightly change what I said you should use Javascript to do this. PHP doesn't really have any place deciding how your page should be laid out, I know you consider PHP to be a hack which it is, so is the JS really, but it's less of a hack![]()
well if JS is turned off then I would probably use php just in case anyway as it already uses php.
It all depends on how your navbar and links are coded - using floats or inline!
If you has an URL, i could help!![]()