Hide the post reply title via css?

General discussion of development ideas and the approaches taken in the 3.x branch of phpBB. The current feature release of phpBB 3 is 3.3/Proteus.
Forum rules
Please do not post support questions regarding installing, updating, or upgrading phpBB 3.3.x. If you need support for phpBB 3.3.x please visit the 3.3.x Support Forum on phpbb.com.

If you have questions regarding writing extensions please post in Extension Writers Discussion to receive proper guidance from our staff and community.
Post Reply
User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Hide the post reply title via css?

Post by Dragosvr92 »

In viewtopic_body.html we have the code bellow.
I want to remove it via css, display;none, and replace it with another line added via an extension, but there is no way of doing so.

Code: Select all

<h3 <!-- IF postrow.S_FIRST_ROW -->class="first"<!-- ENDIF -->>

<!-- IF postrow.POST_ICON_IMG --><img src="{T_ICONS_PATH}{postrow.POST_ICON_IMG}" width="{postrow.POST_ICON_IMG_WIDTH}" height="{postrow.POST_ICON_IMG_HEIGHT}" alt="" /> <!-- ENDIF -->

<a href="#p{postrow.POST_ID}">{postrow.POST_SUBJECT}</a></h3>
We can hide the first post title via .first {display: none;} But there is no class we can use to hide rest of the post reply titles.
Can we add a class for any other post title besides the first?

I tried doing it like this, but i realised it wont work as it hides everything in those tags, and i need them added back anyway.

Code: Select all

h3 a {display: none;}
a[href*="#p"] {display: none;}
Previous user: TheKiller
Avatar on Memberlist 1.0.3
User avatar
DavidIQ
Customisations Team Leader
Customisations Team Leader
Posts: 1864
Joined: Thu Mar 02, 2006 4:29 pm
Location: Earth
Contact:

Re: Hide the post reply title via css?

Post by DavidIQ »

You could just do:

Code: Select all

.postbody div > h3.first > a {
     display: block;
}

.postbody div > h3 > a {
     display: none;
}
EDIT: corrected the first
Image
User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Hide the post reply title via css?

Post by Dragosvr92 »

Thanks David. :)
Previous user: TheKiller
Avatar on Memberlist 1.0.3
User avatar
Dragosvr92
Registered User
Posts: 624
Joined: Tue May 31, 2011 12:08 pm
Location: Romania
Contact:

Re: Hide the post reply title via css?

Post by Dragosvr92 »

I already did that on my style months ago.
I wanted to make an extension as it was requested in this topic viewtopic.php?f=81&t=48706&p=286271#p286206

But i noticed the guy made a tiny ext himself. Not sure what to do with it now. lol. I guess ill attach it here for storage?
Attachments
removere.zip
(2.6 KiB) Downloaded 159 times
Previous user: TheKiller
Avatar on Memberlist 1.0.3
Post Reply