The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.

Removing Words From Post's Date and Time Section

4 posters

Go down

Solved Removing Words From Post's Date and Time Section

Post by Sienna May 26th 2016, 5:00 pm

Technical Details

Forum version : #phpBB3
Position : Administrator
Concerned browser(s) : Google Chrome
Screenshot of problem : http://image.prntscr.com/image/8746901a29354e81b9a0a57fcde183b3.png
Who the problem concerns : All members
When the problem appeared : When it began.
Forum link : http://www.ardentartforum.com/

Description of problem

Hello! So, I was wondering if there's a way to remove words from the area on a post that says

(Small Post Image) by Kelso on Mon May 23, 2016 11:00 am

What I would like to remove is the image and the words "by Kelso on" and just keep the day, date, and time.

Thanks for any help!


Last edited by Kelso on May 29th 2016, 8:05 pm; edited 1 time in total
Sienna
Sienna
Forumember

Female Posts : 93
Reputation : 6
Language : English

http://liveandnet.forumotion.com/

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Sienna May 27th 2016, 8:29 pm

Bump! Very Happy
Sienna
Sienna
Forumember

Female Posts : 93
Reputation : 6
Language : English

http://liveandnet.forumotion.com/

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Rhino.Freak May 27th 2016, 8:42 pm

You have to do some template editing for this Smile

Go to
Code:
Admin Panel > Display > Templates > General
and edit viewtopic_body
Find
Code:
<p class="author"><img src="{postrow.displayed.MINI_POST_IMG}" alt="{postrow.displayed.L_MINI_POST_ALT}" title="{postrow.displayed.L_MINI_POST_ALT}" />&nbsp;{L_TOPIC_BY}&nbsp;{postrow.displayed.POSTER_NAME} {postrow.displayed.POST_DATE_NEW}</p>
And replace it by
Code:
<p class="author">{postrow.displayed.POST_DATE_NEW}</p>

Hit save and don't forget to publish the template! Very Happy
Rhino.Freak
Rhino.Freak
Helper
Helper

Male Posts : 1248
Reputation : 104
Language : English
Location : Mumbai, India

http://freetest.forumotion.net/

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Sienna May 29th 2016, 6:14 pm

@Rhino.Freak

Thank you!! It worked amazingly. Also, I apologize for the delay on the reply. I've been working a lot this weekend!

I was wondering if there was a way to take out the word "on"? I know I sound very picky, haha. If not, this looks really good either way.
Sienna
Sienna
Forumember

Female Posts : 93
Reputation : 6
Language : English

http://liveandnet.forumotion.com/

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Rhino.Freak May 29th 2016, 7:01 pm

Actually
Code:
{postrow.displayed.POST_DATE_NEW}
is hardcoded.
It automatically gets replaced by:
"on 29.05.2016" or whatever the time was.

Some JavaScript might be able to slice initial 3 characters but I don't know how to do it Razz
Rhino.Freak
Rhino.Freak
Helper
Helper

Male Posts : 1248
Reputation : 104
Language : English
Location : Mumbai, India

http://freetest.forumotion.net/

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Sienna May 29th 2016, 8:04 pm

That's perfectly fine! Thank you for that, I didn't know that at all, haha.

Solved!

Big thanks to Rhino.Freak, always saving my life on here. :-)
Sienna
Sienna
Forumember

Female Posts : 93
Reputation : 6
Language : English

http://liveandnet.forumotion.com/

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Ange Tuteur May 29th 2016, 11:27 pm

Rhino.Freak wrote:Actually
Code:
{postrow.displayed.POST_DATE_NEW}
is hardcoded.
It automatically gets replaced by:
"on 29.05.2016" or whatever the time was.

Some JavaScript might be able to slice initial 3 characters but I don't know how to do it Razz
Liiiiike this ?
Code:
<noscript>{postrow.displayed.POST_DATE_NEW}</noscript>
<script type="text/javascript">document.write('{postrow.displayed.POST_DATE_NEW}'.replace(/^on /, ''));</script>
Razz

Well, I wouldn't recommend that in this case, because you can remove "on " by removing "_NEW" from the variable. Like this :
Code:
{postrow.displayed.POST_DATE}
Ange Tuteur
Ange Tuteur
Forumaster

Male Posts : 13207
Reputation : 3000
Language : English & 日本語
Location : Pennsylvania

https://fmdesign.forumotion.com

Back to top Go down

Solved Re: Removing Words From Post's Date and Time Section

Post by Ape May 30th 2016, 3:04 pm

Problem solved & topic archived.
Please read our forum rules: ESF General Rules


Removing Words From Post's Date and Time Section Left1212Removing Words From Post's Date and Time Section Center11Removing Words From Post's Date and Time Section Right112
Removing Words From Post's Date and Time Section Ape_b110
Removing Words From Post's Date and Time Section Ape1010
Ape
Ape
Administrator
Administrator

Male Posts : 19435
Reputation : 2010
Language : fluent in dork / mumbojumbo & English haha

http://chatworld.forumotion.co.uk/

Back to top Go down

Back to top

- Similar topics

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