Trying to make strikethrough but need help

Get help with installation and running phpBB 3.0.x here. Please do not post bug reports, feature requests, or MOD-related questions here.
Suggested Hosts
Forum rules
END OF SUPPORT: 1 January 2017 (announcement)
Locked
pororo
Registered User
Posts: 25
Joined: Tue Apr 20, 2010 3:04 pm

Trying to make strikethrough but need help

Post by pororo »

I'm trying to make my topic titles have strikethroughs if the topic is 'Locked'.

I'm using ProSilver and changed the code in the viewforum_body.html to below.

Code: Select all

<a <!-- IF topicrow.S_TOPIC_LOCKED and not (topicrow.S_POST_ANNOUNCE or topicrow.S_POST_GLOBAL or topicrow.S_POST_STICKY) -->style="text-decoration: line-through;"<!-- ENDIF --> href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
But it's not working. Any ideas?

User avatar
Mick
Support Team Member
Support Team Member
Posts: 22040
Joined: Fri Aug 29, 2008 9:49 am
Location: Watching cricket.

Re: Trying to make strikethrough but need help

Post by Mick »

Have a look at this.
Last edited by Mick on Fri May 28, 2010 5:18 am, edited 1 time in total.
"The more connected we get the more alone we become" - Kyle Broflovski

Please read: “Am I In The Right Place?” before posting.

pororo
Registered User
Posts: 25
Joined: Tue Apr 20, 2010 3:04 pm

Re: Trying to make strikethrough but need help

Post by pororo »

I'm not sure what I did wrong. Do I need to put { } between the lines?

Would you be kind enough to alter my initial posted code so it gets corrected? I could learn from that.

User avatar
Mick
Support Team Member
Support Team Member
Posts: 22040
Joined: Fri Aug 29, 2008 9:49 am
Location: Watching cricket.

Re: Trying to make strikethrough but need help

Post by Mick »

I can't edit your post, sorry.

I'm only guessing but try surrounding the style section with <> like:

Code: Select all

<style="text-decoration: line-through;">
This is a standard method for doing it:

Code: Select all

<p style="text-decoration:line-through;">This text has line through</p>
Note: I edited my previous post as it was unnecessary.
"The more connected we get the more alone we become" - Kyle Broflovski

Please read: “Am I In The Right Place?” before posting.

pororo
Registered User
Posts: 25
Joined: Tue Apr 20, 2010 3:04 pm

Re: Trying to make strikethrough but need help

Post by pororo »

Tried it like this

Code: Select all

<a <!-- IF topicrow.S_TOPIC_LOCKED and not (topicrow.S_POST_ANNOUNCE or topicrow.S_POST_GLOBAL or topicrow.S_POST_STICKY) --><style="text-decoration:line-through;"><!-- ENDIF --> href="{topicrow.U_VIEW_TOPIC}" class="topictitle">{topicrow.TOPIC_TITLE}</a>
But still, no strikethrough. Since the text-decoration thingy is alread wrapped by <a , I don't think I need to add the < > for the style attibute.

Hmm... :roll:

User avatar
Christian 2.0
Former Team Member
Posts: 4550
Joined: Wed Nov 04, 2009 11:16 pm
Location: UK
Name: Christian
Contact:

Re: Trying to make strikethrough but need help

Post by Christian 2.0 »

Try this:

Code: Select all

<a href="{topicrow.U_VIEW_TOPIC}" class="topictitle"><!-- IF topicrow.S_TOPIC_LOCKED --><span style="text-decoration: line-through;">{topicrow.TOPIC_TITLE}</span><!-- ELSE -->{topicrow.TOPIC_TITLE}<!-- ENDIF --></a>

User avatar
Mick
Support Team Member
Support Team Member
Posts: 22040
Joined: Fri Aug 29, 2008 9:49 am
Location: Watching cricket.

Re: Trying to make strikethrough but need help

Post by Mick »

Nice one Chris! ;)
"The more connected we get the more alone we become" - Kyle Broflovski

Please read: “Am I In The Right Place?” before posting.

pororo
Registered User
Posts: 25
Joined: Tue Apr 20, 2010 3:04 pm

Re: Trying to make strikethrough but need help

Post by pororo »

Christian 2.0 wrote:Try this:

Code: Select all

<a href="{topicrow.U_VIEW_TOPIC}" class="topictitle"><!-- IF topicrow.S_TOPIC_LOCKED --><span style="text-decoration: line-through;">{topicrow.TOPIC_TITLE}</span><!-- ELSE -->{topicrow.TOPIC_TITLE}<!-- ENDIF --></a>
Thx a million. Works perfectly! :)
Mixstar wrote:Nice one Chris! ;)
Mixstar, thx to u 2 for helping out. Cheers! ;)

Locked

Return to “[3.0.x] Support Forum”