Advertisement:

Author Topic: code to add "Posted on" and "Updated on" labels on item page.  (Read 1696 times)

marki

  • Newbie
  • *
  • Posts: 16
Hello,

   The changes below will add  "Posted on:" and "Updated on:" information to the item description page. This will help explain why there are 2 dates listed by the item category on the item list page.

open themes\modern\item.php

Find this code:

<div id="type_dates">
<strong><?php echo osc_item_category() ; ?></strong>
 <em class="publish"><?php if ( osc_item_pub_date() != '' ) echo osc_format_date( osc_item_pub_date() ) ; ?></em>
 <em class="update"><?php if ( osc_item_mod_date() != '' ) echo osc_format_date( osc_item_mod_date() ) ; ?></em>
</div>

Replace with this code:

<div id="type_dates">
      <strong><?php echo osc_item_category() ; ?></strong>
       <em class="publish"><?php if ( osc_item_pub_date() != '' ) echo "Posted on: "; echo osc_format_date( osc_item_pub_date() ) ; ?></em>
        <em class="update"><?php if ( osc_item_mod_date() != '' ) echo "Updated on: "; echo osc_format_date( osc_item_mod_date() ) ; ?></em>
 </div>

Any questions please let me know.

Mark