• Plans & Pricing
  • Log in
  • Get started
  • WordPress Hosting
  • WordPress for Agencies
  • Become an Affiliate
  • Domain Names
  • AI Website Builder
  • Website Builder
  • Create a Blog
  • Newsletter
  • Professional Email
  • Website Design Services
  • Commerce
  • WordPress Studio
  • Enterprise WordPress 
  • Overview
  • WordPress Themes
  • WordPress Plugins
  • WordPress Patterns
  • Google Apps
  • Support Center
  • WordPress News
  • Business Name Generator
  • Logo Maker
  • Discover New Posts
  • Popular Tags
  • Blog Search
Get started
  • Sign up
  • Log in
About
  • Plans & Pricing
Products
  • WordPress Hosting
  • WordPress for Agencies
  • Become an Affiliate
  • Domain Names
  • AI Website Builder
  • Website Builder
  • Create a Blog
  • Newsletter
  • Professional Email
  • Website Design Services
  • Commerce
  • WordPress Studio
  • Enterprise WordPress  
Features
  • Overview
  • WordPress Themes
  • WordPress Plugins
  • WordPress Patterns
  • Google Apps
Resources
  • Support Center
  • WordPress News
  • Business Name Generator
  • Logo Maker
  • Discover New Posts
  • Popular Tags
  • Blog Search
Jetpack App
  • Learn more
  • Support Center
  • Guides
  • Courses
  • Forums
  • Contact
Search
  • Support Center
  • Guides
  • Courses
  • Forums
  • Contact
Forums / Changing date format with CSS

Changing date format with CSS

  • Unknown's avatar
    windwhistle · Member · Apr 6, 2012 at 9:06 pm
    • Copy link Copy link
    • Add topic to favorites Add topic to favorites

    For a number of years, with different themes, I’ve tried unsuccessfully to add the time to my posts’ datelines. Yes, under Settings > General I can set a custom dateline — F j, Y, g:i a T — and get what I want: April 6, 2012, 2:57 pm MDT. But doing so inevitably causes the dateline in the accompanying comments to repeat the time: April 6, 2012, 2:57 pm MDT 2:57 pm MDT, since comment datelines already include the time by default. I have the CSS upgrade. Is there a way to use CSS to add the time to the post datelines only? I’m using The Morning After theme.

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar
    michaelfields · Member · Apr 13, 2012 at 12:13 am
    • Copy link Copy link

    This process is not exactly “correct” as far as the options are concerned.

    The Date Format should represent items such as the day – month – year while the Time Format should contain the time section.

    Please correct me if I am wrong but it sounds like you are using both values in the Date Format. In The Morning After both the date and time format values are “glued” together to create the datetime that prints with each comment. Unfortunately there is no way to hide one independent of the other.

  • Unknown's avatar
    windwhistle · Member · Apr 13, 2012 at 12:29 am
    • Copy link Copy link

    Yes, I was adding the time values to the Date Format. It was a work around to get the time into datelines for my posts. Except that it fails because it causes the time to be duplicated in the comments.

    I’m wondering if there is a way with CSS to add the time to the default dateline for posts. I don’t know enough CSS to figure it out for myself.

  • Unknown's avatar
    michaelfields · Member · Apr 13, 2012 at 2:59 am
    • Copy link Copy link

    Unfortunately CSS was not really designed to do something like this.

  • Unknown's avatar
    windwhistle · Member · Apr 13, 2012 at 5:14 am
    • Copy link Copy link

    Okay, thanks. I guess I can cross that off my wish list.

  • The topic ‘Changing date format with CSS’ is closed to new replies.

Tags

  • date format
  • dateline
  • The Morning After

About this topic

  • In: CSS Customization
  • 2 participants
  • 4 replies
  • Last activity 14 years
  • Latest reply from windwhistle

Couldn't find what you needed?

Contact us

Contact us

Get answers from our AI assistant, with access to 24/7 expert human support on paid plans.

Browse our guides

Browse our guides

Find step-by-step solutions to common questions in our comprehensive guides.

WordPress.com

Products
  • WordPress Hosting
  • WordPress for Agencies
  • Become an Affiliate
  • Domain Names
  • AI Website Builder
  • Website Builder
  • Create a Blog
  • Professional Email
  • Website Design Services
  • WordPress Studio
  • Enterprise WordPress
Features
  • Overview
  • WordPress Themes
  • WordPress Plugins
  • WordPress Patterns
  • Google Apps
Resources
  • WordPress.com Blog
  • Business Name Generator
  • Logo Maker
  • WordPress.com Reader
  • Accessibility
  • Remove Subscriptions
Help
  • Support Center
  • Guides
  • Courses
  • Forums
  • Contact
  • Developer Resources
Company
  • About
  • Press
  • Terms of Service
  • Privacy Policy
  • Do Not Sell or Share My Personal Information
  • Privacy Notice for California Users
DeutschEspañolFrançaisBahasa IndonesiaItalianoNederlandsPortuguês do BrasilSvenskaTürkçeРусскийالعربيةעִבְרִית日本語한국어简体中文繁體中文English

Mobile Apps

  • Download on the App Store
  • Get it on Google Play

Social Media

  • WordPress.com on Facebook
  • WordPress.com on X (Twitter)
  • WordPress.com on Instagram
  • WordPress.com on YouTube

Automattic

Automattic
Work With Us
    • WordPress.com Forums
    • Sign up
    • Log in
    • Copy shortlink
    • Report this content
    • Manage subscriptions