Log in

View Full Version : Text in posts with more margin


tijmen_4real
05-11-2009, 01:29 PM
Hi !

How can i increase the margin around the text in a post. I only want to increase this margin, and none other. How can this be done?

http://www.soldaatmuis.com/diversen/textmargin.JPG

As you can see, the text in this post is too close to the left and right borders.
How can i increase only this margin?
Greetz,

tijmen_4real

Cryo
05-11-2009, 02:15 PM
Two ways to do this...

1. Open your postbit template.
2. Find the following...

<!-- message -->
<div id="post_message_$post[postid]">$post[message]</div>
<!-- / message -->

3. Replace it with...

<!-- message -->
<div style="margin-left: 5px;" id="post_message_$post[postid]">$post[message]</div>
<!-- / message -->


You can adjust the "5px" to whatever you want it to be.

The second method is pretty much the same, but instead of setting the style of the individual element you would set a class, and then define the style for that class in your template.

tijmen_4real
05-11-2009, 03:11 PM
Thanks for the quick reply!
I can't find the script to edit, only this:
<!-- message -->
<div id="post_message_$post[postid]">
$ad_location[ad_showthread_firstpost_start]
$post[message]
</div>
<!-- / message -->

Is the edit method for this code the same? Or is this the wrong piece of code??

Lynne
05-11-2009, 03:35 PM
Just add the style to the div that is there.

Cryo
05-11-2009, 04:18 PM
Yeah, the first div can be changed. Sorry, I forgot that I didn't have the advertisement hook in my template. They're the same otherwise. :)

tijmen_4real
05-18-2009, 08:05 AM
So i made it like this:

<!-- message -->
<div style="margin: 10px;" id="post_message_$post[postid]">
$ad_location[ad_showthread_firstpost_start]
$post[message]
</div>
<!-- / message -->

But nothing in the message, the text margin, changed... :(
Is something wrong or....?

1Unreal
05-18-2009, 09:03 AM
Post the URL to your site and we should be able to help you more.

tijmen_4real
05-18-2009, 09:11 AM
The board is located here (http://www.deorvanheemskerk.nl), but only workers from our company are allowed. If you want i can give you a temp-account to help me out?

1Unreal
05-18-2009, 09:24 AM
Yeah that would be much easier.

Lynne
05-18-2009, 02:57 PM
Make sure you modify the correct template - postbit or postbit_legacy.

tijmen_4real
05-30-2009, 04:40 PM
Or --or--- if, should i change it in both templates? What's the difference between them??

Lynne
05-30-2009, 05:33 PM
You may change it in both templates. postbit display the user information on top of the post. postbit_legacy displays the user information on the left side of the post.

tijmen_4real
05-30-2009, 09:43 PM
Sorry, but changes to both templates don't change a thing in the text margin/padding... :( What else can be done to get this fixed??

Lynne
05-30-2009, 09:59 PM
How about a link to a thread so we can see the problem? If we need to be logged in, please post a test account username/password.

(And, did you try using padding:10px instead of margin:10px ?)

tijmen_4real
05-31-2009, 06:27 PM
<a href="http://www.deorvanheemskerk.nl" target="_blank">link</a> to the board (login with test / testen). See any message as an example....

Lynne
05-31-2009, 06:54 PM
When I added padding="10px" to the div tag, it did what you wanted. Right now, you have no style added to the div tag - I thought you said you had added it?

tijmen_4real
05-31-2009, 07:11 PM
I added this code, looked if something changed, but it didn't, so i changed the code back to original. I think i did something wrong. Where did you added the code? And which code exactly??

--------------- Added 1243801023 at 1243801023 ---------------

You may change it in both templates. postbit display the user information on top of the post. postbit_legacy displays the user information on the left side of the post. Maybe you got me wrong. I want to change the padding/margin of the text in the post itself.....

Seven Skins
05-31-2009, 07:31 PM
Find in postbit_legacy template:

<!-- message -->
<div id="post_message_$post[postid]">
$ad_location[ad_showthread_firstpost_start]
$post[message]
</div>
<!-- / message -->

Replace it with:
<!-- message -->
<div style="padding-left: 15px;" id="post_message_$post[postid]">
$ad_location[ad_showthread_firstpost_start]
$post[message]
</div>
<!-- / message -->


.

--------------- Added 1243801983 at 1243801983 ---------------

PS. Padding is usually 6px so you will have to use more 6px to see any changes. I have used 15px but you can adjust it if needed.

tijmen_4real
05-31-2009, 07:36 PM
Yes, that did the magic! Thanks from a noob (also you, Lynne!!:D)