MyBB Community Forums

Full Version: Fix visible width to minimize scrolling
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hello,

Could you please let me know which template I need to modify the TD tag too so that I can set the value of the post's width on the screen?  I am setting my forum in a fixed sized window on my website and I do not want to have horizontal scrolling required to read a thread.  (I want to fix the horizontal width so that horizontal scrolling is minimised)

Regards,
Pete
To stop the horizontal scrolling the basic CSS is

overflow-x: hidden;

You may need additional declarations based on where you are applying and what is your layout.
you need change showthread template , if you are using custom theme , you can add css with class name or id element specific element or relative selector and add css to showthread.css from stylesheets page. if not have this stylesheet you can add to global.css or any stylesheet that attached to showthread page (if not have any , you can create a new one)
Thanks, so if I understand - I am modifying the main showthread template with the argument: "overflow-x: hidden;" somewhere in it ?  Or is this meant to be applied to a stylesheet instead?  (As you can tell, I have little knowledge of these aspects)
you have two way :
1. If you have CSS knowledge you can add
overflow-x: hidden;
or any style in showthread.css with your element selctor.
2. if you not have CSS knowledge go to showthread template and find your element that you talking about and add this css attribute in element style

for example  if your element is TD something like tihs :
<td style="overflow-x:hidden;">
and if element already have style attribute you can add this end of attributes
for example :
<td style="OTHERSTYLES;overflow-x:hidden;">
That's very helpful, thank you for your time.  I think I will go down the 2nd route, but I cannot test all of this until my website is finished it's domain move that it's going through at the moment.

It does sound like this is the resolution though so as I say - thanks   Smile
I think You would need to modify the template files associated with the display of forum posts. Look for templates related to the post layout or structure, such as "post" or "thread" templates. Then, find the <td> tag within those templates and adjust its attributes, such as width, to control the post's width on the screen.