-
AuthorPosts
-
November 30, 2013 at 9:29 am #192653
Dear Team,
I have noticed that events page in the template shows the Event by the day of publication. But I want to show the day of the Event and no the day when I publish the article. It has no sense if I publish the Event the same day that starts.
How can I solve this?
phong nam Friendphong nam
- Join date:
- May 2015
- Posts:
- 3779
- Downloads:
- 1
- Uploads:
- 587
- Thanks:
- 499
- Thanked:
- 974 times in 888 posts
December 3, 2013 at 9:03 am #514187Hi mrvallejo,
On the Events layout of JA Muzic template, we just use the Joomla articles to display the event info with the created/published date of that articles. In addition, Joomla does not support to display the articles that its created date is in the coming time. So the solution in this case is publishing the Event at the same day that starts.
Another choice is using an Event Management extension that allow you to control fully the starting date time of Events.
woluweb Friendwoluweb
- Join date:
- October 2012
- Posts:
- 196
- Downloads:
- 18
- Uploads:
- 69
- Thanks:
- 68
- Thanked:
- 31 times in 3 posts
December 4, 2013 at 11:31 am #514312Hi Leo,
I face the same problem as my fellow Mrvallejo.
I have just made a simple test : changing the “creation” date to some date in the future *does* work in Joomla, in the sense that the article will show.
See screenshot here :
of course, in normal circumstances, it is non-sense to cheat with that creation date, but here it would make perfect sense.
Moreover, when I inspect the code, I see that the nice block showing the date is named after “creation date”, while it shows publication date…
So, to rephrase the question of Mrvallejo : “given the fact we *can* indeed choose a theoretical creation date in the future, how to make this creation date be shown on the blog layout, instead of the published date” ?
I guess there the template directory contains some override of some php files of Joomla, where we can make this change, but where ?Txs for helping us 🙂
Marc
PS : I was trying to figure out which was the file to edit, but then I realized that the Demo Builder would NOT give access to the code. Never mind, I downloaded the template and I found the following file
templatesja_muzichtmlcom_contentcategoryevent_item.php
with the following code.But I am no PHP expert, so Leo could you please indicated what “hack” should be made ?
Txs !<?php if ($params->get('show_publish_date')) : ?>
<?php if($event_category == $this->item->catid){ ?>
<div class="created-date">
<span class="day"><?php echo JHtml::_('date', $this->item->publish_up, JText::_('TPL_DATE_FORMAT_DAY'));?></span>
<span class="month"><?php echo JHtml::_('date', $this->item->publish_up, JText::_('TPL_DATE_FORMAT_MONTH'));?></span>
</div>
<?php }else{ ?>
<dd class="published">
<?php echo JText::sprintf('COM_CONTENT_PUBLISHED_DATE_ON', '<span>'.JHtml::_('date', $this->item->publish_up, JText::_('DATE_FORMAT_LC3')).'</span>'); ?>
</dd>
<?php }?>
<?php endif; ?><?php if ($params->get('show_create_date')) : ?>
<?phpif($event_category == $this->item->catid){ ?>
<div class="created-date">
<span class="day"><?php echo JHtml::_('date', $this->item->publish_up, JText::_('TPL_DATE_FORMAT_DAY'));?></span>
<span class="month"><?php echo JHtml::_('date', $this->item->publish_up, JText::_('TPL_DATE_FORMAT_MONTH'));?></span>
</div>
<?php }else{ ?>
<dd class="create">
<?php echo JText::sprintf('COM_CONTENT_CREATED_DATE_ON', '<span>'.JHtml::_('date', $this->item->created, JText::_('DATE_FORMAT_LC3')).'</span>'); ?>
</dd>
<?php }?>
<?php endif; ?>-
phong nam Friend
phong nam
- Join date:
- May 2015
- Posts:
- 3779
- Downloads:
- 1
- Uploads:
- 587
- Thanks:
- 499
- Thanked:
- 974 times in 888 posts
December 5, 2013 at 5:29 am #514394Hi mrvallejo, Marc,
It seems that this is an error of our JA Muzic template when the Event date time is showing the published date, instead of created date as we defined. You guys can open that event _item.php file and find lines:
<div class="created-date">
<span class="day"><?php echo JHtml::_('date', $this->item->publish_up, JText::_('TPL_DATE_FORMAT_DAY'));?></span>
<span class="month"><?php echo JHtml::_('date', $this->item->publish_up, JText::_('TPL_DATE_FORMAT_MONTH'));?></span>
</div>Change publish_up to created . The Event Blog layout will display the creation date as you set in article backend.
2 users say Thank You to phong nam for this useful post
woluweb Friendwoluweb
- Join date:
- October 2012
- Posts:
- 196
- Downloads:
- 18
- Uploads:
- 69
- Thanks:
- 68
- Thanked:
- 31 times in 3 posts
December 5, 2013 at 11:18 am #514436Txs Leo !!
I was intending to use that template for a festival next month, but playing with the demo builder I had discovered the events were only possible in the past, which was a serious drawback for using the template 🙂Would you please Leo pass the fix to the dev team ? Txs !
mrvallejo, would you please test this & confirm if everything is then OK ?
(don’t forget to “cheat” with the creation date : by default it is… the creation date, but just edit it & choose some date in the future, typically the date of the event)
phong nam Friendphong nam
- Join date:
- May 2015
- Posts:
- 3779
- Downloads:
- 1
- Uploads:
- 587
- Thanks:
- 499
- Thanked:
- 974 times in 888 posts
-
AuthorPosts
Viewing 6 posts - 1 through 6 (of 6 total)This topic contains 6 replies, has 3 voices, and was last updated by phong nam 10 years, 11 months ago.
We moved to new unified forum. Please post all new support queries in our New Forum
Jump to forum