The forum of the forums
Welcome to the Official Support Forum of Forumotion!

To take full advantage of everything offered by our forum, please log in if you are already a member, or join our community if you've not yet.



Create a free forum like this one.

Template editing

View previous topic View next topic Go down

Template editing

Post by LasTemptation on July 15th 2010, 10:13 pm

Hey, I need some assistance with editing the template viewtopic_body.
<!-- BEGIN postrow -->
<!-- BEGIN displayed -->
<tr class="post">
<td class="{postrow.displayed.ROW_CLASS}"{postrow.displayed.THANK_BGCOLOR} valign="top" width="200" align="center">
<span class="name"><a name="{postrow.displayed.U_POST_ID}"></a><strong>{postrow.displayed.POSTER_NAME}<br>{postrow.displayed.POSTER_RANK}<br></strong></span>
<span class="postdetails poster-profile">

<br>{postrow.displayed.POSTER_AVATAR}<br><br>{postrow.displayed.RANK_IMAGE}<br>
<!-- BEGIN profile_field -->
{postrow.displayed.profile_field.LABEL}{postrow.displayed.profile_field.CONTENT}{postrow.displayed.profile_field.SEPARATOR}
<!-- END profile_field -->
{postrow.displayed.POSTER_RPG}
</span><br />
<img src="http://illiweb.com/fa/empty.gif" alt="" style="width:150px;height:1px" />
</td>

I need this to be modified so that the poster name, rank, avatar, and rank image, stays centered, but the profile fields are all to the left. Can anyone give me the correct code for this, please? kiss

LasTemptation
Forumember

Male Posts : 50
Reputation : 0
Language : English
Location : United States

Back to top Go down

Re: Template editing

Post by techguy1001 on July 16th 2010, 3:22 am

Isn't that just the default template for all themes?

techguy1001
Forumember

Male Posts : 198
Reputation : 0
Language : English, HTML, CSS, Javascript
Location : California, USA

http://gamingchiefforum.forumotion.com/forum.htm

Back to top Go down

Re: Template editing

Post by ankillien on July 16th 2010, 3:57 am

Hello,

Can you tell me what version are you using? phpBB2 or punBB?

ankillien
Energetic

Posts : 5198
Reputation : 129
Language : English, XHTML, CSS, JS, PHP, SQL

http://www.webartzforum.com/

Back to top Go down

Re: Template editing

Post by LasTemptation on July 16th 2010, 5:02 am

Oh, phpBB2. Sorry about that. ))

LasTemptation
Forumember

Male Posts : 50
Reputation : 0
Language : English
Location : United States

Back to top Go down

Re: Template editing

Post by LasTemptation on July 17th 2010, 3:22 am

So.. can anyone help me out? Dx

LasTemptation
Forumember

Male Posts : 50
Reputation : 0
Language : English
Location : United States

Back to top Go down

Re: Template editing

Post by ankillien on July 17th 2010, 6:03 am

Try adding this code to your CSS...

Code:
.post td[width="200"] {
text-align : center !important;
}

ankillien
Energetic

Posts : 5198
Reputation : 129
Language : English, XHTML, CSS, JS, PHP, SQL

http://www.webartzforum.com/

Back to top Go down

Re: Template editing

Post by LasTemptation on July 17th 2010, 7:08 am

Nope.. didn't work.
You notice here,
<td class="{postrow.displayed.ROW_CLASS}"{postrow.displayed.THANK_BGCOLOR} valign="top" width="200" align="center">

That code in the template centers everything in the miniprofile. I tried to add a new "td class" in under what I wanted centered, and make that align=left, but that actually severely messed up the forum so I had to remove it. So I'm stumped on how to do that..

LasTemptation
Forumember

Male Posts : 50
Reputation : 0
Language : English
Location : United States

Back to top Go down

Re: Template editing

Post by ankillien on July 17th 2010, 9:45 am

Centering the <td> will center the whole post profile.
You can add a <div> tag to center align the name, avatar and rank only.
Your template code should look like this...

<tr class="post">
<td class="{postrow.displayed.ROW_CLASS}"{postrow.displayed.THANK_BGCOLOR} valign="top" width="150">
<div align="center"><span class="name"><a name="{postrow.displayed.U_POST_ID}"></a><strong>{postrow.displayed.POSTER_NAME}</strong></span><br />
<span class="postdetails poster-profile">
{postrow.displayed.POSTER_RANK}<br />
{postrow.displayed.RANK_IMAGE}{postrow.displayed.POSTER_AVATAR}<br /><br /></div>
<!-- BEGIN profile_field -->

ankillien
Energetic

Posts : 5198
Reputation : 129
Language : English, XHTML, CSS, JS, PHP, SQL

http://www.webartzforum.com/

Back to top Go down

Re: Template editing

Post by lsprix on July 17th 2010, 10:16 am

Its hard for me to understand can some1 explain how to create a script? PLEASE!!

------------------
Pallet Racking
Fitflop Boots


Last edited by lsprix on July 17th 2010, 10:22 am; edited 1 time in total

lsprix
New Member

Posts : 1
Reputation : 0
Language : english

Back to top Go down

Re: Template editing

Post by ankillien on July 17th 2010, 10:21 am

@lsprix wrote:Its hard for me to understand can some1 explain how to create a script? PLEASE!!

Hello,

To crate a script of your own, you need to learn HTML and CSS coding.
You can learn here : http://w3schools.com

ankillien
Energetic

Posts : 5198
Reputation : 129
Language : English, XHTML, CSS, JS, PHP, SQL

http://www.webartzforum.com/

Back to top Go down

View previous topic View next topic Back to top


 
Permissions in this forum:
You cannot reply to topics in this forum