Notice

The forum is in read only mode.

Support Forum

Welcome! Support Forums have been reactivated
Welcome the Technical Support section. Help us in assisting you by providing us with a concise and descriptive elaboration of your issues. Be specific and if possible, provide us with a step-by-step instruction in replicating your problem.

Event cover (list and detail) date layout

8 years 11 months ago
  • Adriano's Avatar
    Topic Author
  • Adriano
  • Offline
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 0
Licenses:
JomSocial Active

ISSUE SUMMARY: Hi, the event cover in the event list or in the detail event shows only the start date. Is it possible to show also the end date very useful for the ongoing events (the one started in the past but that are still up till a date in the future).

The best should be to show only the secon date for the events with duration of more than 1 days in the future or currently.
Cheers


STEPS TO REPLICATE:
1
2
3
4
5
RESULT
EXPECTED RESULT
BROWSER

8 years 11 months ago
Licenses:

Hi, Adriano.

Yes, this is possible, this code will display event end date:

$event->getEndDate()

You may even break it into parts:
<?php
                    $datestr = strtotime($event->getEndDate());
                    $day = date('d', $datestr);
                    $month = date('M', $datestr);
                    $year = date('y', $datestr);
                ?>

Then use it in:

ROOT/components/com_community/templates/jomsocial/layouts/events/single.php

I presume that you know how to do overrides ;)


- Instead of saying: 'it's not working', explain the problem in detail.
- Screenshots with the URL visible in them and the problem marked are more than welcome.
- Tell us how to replicate the problem, we can't fix it if we can't find it.
- Make sure that your site/server meets JomSocial System Requirements
- Make sure to setup JomSocial Cron Job
- Always provide us with access details to the backend and ftp. We need it to debug problems.
- If you have a similar problem, but a solution you found isn't working, open a new thread instead of 'merging' with an existing one.

- Use the "Thank You" feature on any post that helped you
8 years 11 months ago
  • Adriano's Avatar
    Topic Author
  • Adriano
  • Offline
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 0
Licenses:
JomSocial Active

Hi Michal

thanks for the tips.

Just to be sure we are talking about same topic, i added a screenshot of what i want to duplicate for the enddate.

I was quicly inspecting the file you suggested to me, i was wondering to find in some place a sort of $event->getStartDate()...

Just to speed up my process.

Thanks

Attachment date.jpg not found

Attachments:
8 years 11 months ago
  • Adriano's Avatar
    Topic Author
  • Adriano
  • Offline
  • Fresh Boarder
  • Posts: 3
  • Thank you received: 0
Licenses:
JomSocial Active

I solved.

I strongly suggest to Jomsocial to add this simple feature that shows both event dates that help a generic user to understand if an event is already ongoing or at leat how long it will be.

Cheers
Max

Hereafter how looks like

Attachment pic1.png not found



Attachment pic2.png not found

Attachments:
Moderators: Piotr Garasiński
Powered by Kunena Forum

Join 180,000 websites creating Amazing communities

JomSocial is the most complete, easy-to-use addon that turns Joomla CMS into a
full -fledged, social networking site

TRY NOW BUY NOW