Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author Joe Dolson

    (@joedolson)

    Use {date format=”M, d”} (or your choice of date formatting) to customize the date. All date template tags can take custom formatting.

    Thread Starter aasrithg

    (@aasrithg)

    Thank for that. But when I use the code like

    <span> {date format=”F”} </span> for month
    <span> {date format=”d”} </span> for day

    the month appears correctly but my date gets messed up and {date format =”d”} is printed on the screen

    Plugin Author Joe Dolson

    (@joedolson)

    How are you using the code? Can you provide an exact sample from your template?

    Thread Starter aasrithg

    (@aasrithg)

    My code in the widget is as foolows:

    <div id="events">
    <div class="item">
    
    <span class="month">{date format="F"}</span>
    
    <div class="event-date">
    <span class ="day">{date}</span></div>
    <h4>{link_title}</h4>
    <p class="time">From {time} until:{endusertime},{category}</p>
    </div>
    </div>

    [Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum’s parser.]

    Thread Starter aasrithg

    (@aasrithg)

    In the second {date} in the above code the display gets messed up and does not get parsed. I want to display the month in one line and the day in the other.

    Thread Starter aasrithg

    (@aasrithg)

    <div id="events">
    <div class="item">
    
    <span class="month">{date format="F"}</span>
    
    <div class="event-date">
    <span class ="day">{date}</span></div>
    <h4>{link_title}</h4>
    <p class="time">From {time} until:{endusertime},{category}</p>
    </div>
    </div>

    this was my code for implementation

    Plugin Author Joe Dolson

    (@joedolson)

    Interesting. Each template item is only parsed once. However, there are multiple date template options – I recommend using {dtstart format=”F”} and {date}, respectively.

    For the record, {date} only includes the base date information; {dtstart} contains a full timestamp including the date and time information.

    Thread Starter aasrithg

    (@aasrithg)

    It worked thank you my widget looks the way I wanted it to.

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘Widget {date} option’ is closed to new replies.