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.

Show description of event first

10 years 3 months ago
  • Trude's Avatar
    Topic Author
  • Trude
  • Offline
  • Fresh Boarder
  • Posts: 25
  • Thank you received: 3
Licenses:
JomSocial Active Socialize Expired

I want to change the event view so it shows the description first.

Earlier I found some code for this in this forum, but cannot find it (the changes I did got overwritten after update).

How do I swap the two views, and how do I prevent this from being overwritten again?

I also implemented other tweaks I found in this forum, which are all overwritten now, and I had to change them again.

10 years 3 months ago
Licenses:

Trude wrote: I want to change the event view so it shows the description first.
Earlier I found some code for this in this forum, but cannot find it (the changes I did got overwritten after update).


Use search feature: www.jomsocial.com/component/kunena/search
Or please, tell me more about what you want to achieve... a print screens will be helpful. Do you want to replace "Recent Activities" with "Event Details" that details will be visible first?

Trude wrote: How do I swap the two views, and how do I prevent this from being overwritten again?
I also implemented other tweaks I found in this forum, which are all overwritten now, and I had to change them again.


That's always could happen when you hack the core files. Where is it possible you always should use Joomla! override feature to override views. Please read this docs:

docs.joomla.org/How_to_override_the_outp...rom_the_Joomla!_core


- 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
10 years 3 months ago
  • Trude's Avatar
    Topic Author
  • Trude
  • Offline
  • Fresh Boarder
  • Posts: 25
  • Thank you received: 3
Licenses:
JomSocial Active Socialize Expired

Do you want to replace "Recent Activities" with "Event Details" that details will be visible first?


Yes please! :)

10 years 3 months ago
Licenses:

Hi, Trude.

Make a safe copy first.

You will need to edit template file components/com_community/templates/default/events.viewevent.php, line 216 to 244
change from:

<div class="cTabsBar clearfull">
			<ul class="cPageTabs cResetList cFloatedList clearfix">
				<li <?php if( $showStream ) {echo 'class="cTabCurrent"';} else {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_FRONTPAGE_RECENT_ACTIVITIES');?></a></li>
				<li <?php if(!$isEventGuest && !$showStream) {echo 'class="cTabCurrent"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_EVENTS_DETAIL');?></a></li>
				<!--li <?php if(!$isEventGuest) {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)">Event Program</a></li-->
			</ul>
		</div>
		<!-- END: Global Application Tab bar framework -->
 
		<!-- START: Global Application Tab bar contents -->
		<div class="cTabsContentWrap">
			<!-- Tab 1: Activity Stream Container -->
			<?php if( $showStream ) { ?>
			<div class="cTabsContent  <?php if($showStream) {echo 'cTabsContentCurrent';} ?>">
				<!-- Stream -->
				 <?php if( $showStream ) { $status->render(); } ?>
				<div class="cActivity cEvent-Activity" id="activity-stream-container">
					<div class="cActivity-LoadLatest joms-latest-activities-container">
						<a id="activity-update-click" class="btn btn-block" href="javascript:void(0);"></a>
					</div>
					<?php echo $streamHTML; ?>
				</div>
				<!-- end: stream -->
			</div>
			<?php } ?>
			<!-- Tab 1: END -->
 
			<!-- Tab 2: Event Details -->
			<div class="cTabsContent <?php if(!$isEventGuest && !$showStream ) {echo 'cTabsContentCurrent';} ?>">

into this:
<div class="cTabsBar clearfull">
			<ul class="cPageTabs cResetList cFloatedList clearfix">
				<li <?php if( !$showStream ) {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_FRONTPAGE_RECENT_ACTIVITIES');?></a></li>
				<li <?php echo 'class="cTabCurrent"'; ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_EVENTS_DETAIL');?></a></li>
				<!--li <?php if(!$isEventGuest) {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)">Event Program</a></li-->
			</ul>
		</div>
		<!-- END: Global Application Tab bar framework -->
 
		<!-- START: Global Application Tab bar contents -->
		<div class="cTabsContentWrap">
			<!-- Tab 1: Activity Stream Container -->
			<?php if( $showStream ) { ?>
			<div class="cTabsContent">
				<!-- Stream -->
				 <?php if( $showStream ) { $status->render(); } ?>
				<div class="cActivity cEvent-Activity" id="activity-stream-container">
					<div class="cActivity-LoadLatest joms-latest-activities-container">
						<a id="activity-update-click" class="btn btn-block" href="javascript:void(0);"></a>
					</div>
					<?php echo $streamHTML; ?>
				</div>
				<!-- end: stream -->
			</div>
			<?php } ?>
			<!-- Tab 1: END -->
 
			<!-- Tab 2: Event Details -->
			<div class="cTabsContent cTabsContentCurrent">


- 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
The following user(s) said Thank You: Tara Allin
10 years 3 months ago
  • Trude's Avatar
    Topic Author
  • Trude
  • Offline
  • Fresh Boarder
  • Posts: 25
  • Thank you received: 3
Licenses:
JomSocial Active Socialize Expired

Thank you, yes that's the one I was looking for! :)

Only problem now is that the activity stream under events disappeared completely, and the option to view details remains even in detail view.

Attachment no_activity_feed_option.png not found



This also happened the last time I used this code.

BTW: My lines "216-244" was from 220-248, and I haven't altered this sheet before (it's original after upgrade).

Attachments:
10 years 3 months ago
Licenses:

Hi,

Let's try again. Find this text: "<!-- begin: .cMain -->".
Should be around line 216/217. And replace:

<div class="cMain">

		<!-- Global Application Tab bar framework -->
		<div class="cTabsBar clearfull">
			<ul class="cPageTabs cResetList cFloatedList clearfix">
				<li <?php if( $showStream ) {echo 'class="cTabCurrent"';} else {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_FRONTPAGE_RECENT_ACTIVITIES');?></a></li>
				<li <?php if(!$isEventGuest && !$showStream) {echo 'class="cTabCurrent"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_EVENTS_DETAIL');?></a></li>
				<!--li <?php if(!$isEventGuest) {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)">Event Program</a></li-->
			</ul>
		</div>
		<!-- END: Global Application Tab bar framework -->

		<!-- START: Global Application Tab bar contents -->
		<div class="cTabsContentWrap">
			<!-- Tab 1: Activity Stream Container -->
			<?php if( $showStream ) { ?>
			<div class="cTabsContent  <?php if($showStream) {echo 'cTabsContentCurrent';} ?>">
				<!-- Stream -->
				 <?php if( $showStream ) { $status->render(); } ?>
				<div class="cActivity cEvent-Activity" id="activity-stream-container">
					<div class="cActivity-LoadLatest joms-latest-activities-container">
						<a id="activity-update-click" class="btn btn-block" href="javascript:void(0);"></a>
					</div>
					<?php echo $streamHTML; ?>
				</div>
				<!-- end: stream -->
			</div>
			<?php } ?>
			<!-- Tab 1: END -->

			<!-- Tab 2: Event Details -->
			<div class="cTabsContent <?php if(!$isEventGuest && !$showStream ) {echo 'cTabsContentCurrent';} ?>">
				<div class="cEvent-Description">
					<?php
					if( !CStringHelper::isHTML($event->description) ) {
						echo CStringHelper::nl2br($event->description);
					}
					else {
						echo $event->description;
					}
					?>
					<!-- Focus Details expand/collapse -->
				<div class="js-focus-details">
					<div class="row-fluid">
						<div class="span12">

							<div class="important">
								<i class="icon-calendar"></i>
								<?php echo $event->startdateHTML ?>
							</div>
							<dl>
								<!-- Event Category -->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_CATEGORY'); ?></dt>
								<dd><a href="<?php echo CRoute::_('index.php?option=com_community&view=events&categoryid=' . $event->catid);?>"><?php echo JText::_( $event->getCategoryName() ); ?></a></dd>
								<!-- Event Date & Time -->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_TIME')?></dt>
								<dd>
								<?php echo ($allday) ? JText::sprintf('COM_COMMUNITY_EVENTS_ALLDAY_DATE',$event->startdateHTML) : JText::sprintf('COM_COMMUNITY_EVENTS_DURATION',$event->startdateHTML,$event->enddateHTML); ?>
									<?php if( $config->get('eventshowtimezone') ) { ?>
										<span class="small"><?php echo $timezone; ?></span>
									<?php } ?>
								</dd>
								<!-- Event Location -->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION');?></dt>
								<dd id="community-event-data-location">
									<a href="http://maps.google.com/?q=<?php echo urlencode($event->location); ?>" target="_blank"><?php echo $event->location; ?></a>
								</dd>
								<!--Event Occurence -->
								<?php if ($event->isRecurring()) { ?>
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_OCCURENCE');?></dt>
								<dd><?php echo JText::_('COM_COMMUNITY_EVENTS_REPEAT_' . strtoupper($event->repeat)); ?></dd>
								<?php }?>
								<!--Event Admins-->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_ADMINS')?></dt>
								<dd><?php echo $adminsList;?></dd>
							</dl>


						</div>
					</div>
				</div>
				</div>
			</div>
			<!-- Tab 2: END -->
		</div>
		<!-- END: Global Application Tab bar contents -->
		</div>

In short - replace <div class="cMain"> and all it contains with:
<div class="cMain">

		<!-- Global Application Tab bar framework -->
		<div class="cTabsBar clearfull">
			<ul class="cPageTabs cResetList cFloatedList clearfix">
				<li <?php if( $showStream ) {echo 'class="cTabCurrent"';} else {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_EVENTS_DETAIL');?></a></li>
				<li <?php if(!$isEventGuest && !$showStream) {echo 'class="cTabCurrent"';} ?>><a href="javascript:void(0)"><?php echo JText::_('COM_COMMUNITY_FRONTPAGE_RECENT_ACTIVITIES');?></a></li>
				
				<!--li <?php if(!$isEventGuest) {echo 'class="cTabDisabled"';} ?>><a href="javascript:void(0)">Event Program</a></li-->
			</ul>
		</div>
		<!-- END: Global Application Tab bar framework -->

		<!-- START: Global Application Tab bar contents -->
		<div class="cTabsContentWrap">
			

			<!-- Tab 2: Event Details -->
			<div class="cTabsContent <?php if($showStream) {echo 'cTabsContentCurrent';} ?>">
				<div class="cEvent-Description">
					<?php
					if( !CStringHelper::isHTML($event->description) ) {
						echo CStringHelper::nl2br($event->description);
					}
					else {
						echo $event->description;
					}
					?>
					<!-- Focus Details expand/collapse -->
				<div class="js-focus-details">
					<div class="row-fluid">
						<div class="span12">

							<div class="important">
								<i class="icon-calendar"></i>
								<?php echo $event->startdateHTML ?>
							</div>
							<dl>
								<!-- Event Category -->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_CATEGORY'); ?></dt>
								<dd><a href="<?php echo CRoute::_('index.php?option=com_community&view=events&categoryid=' . $event->catid);?>"><?php echo JText::_( $event->getCategoryName() ); ?></a></dd>
								<!-- Event Date & Time -->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_TIME')?></dt>
								<dd>
								<?php echo ($allday) ? JText::sprintf('COM_COMMUNITY_EVENTS_ALLDAY_DATE',$event->startdateHTML) : JText::sprintf('COM_COMMUNITY_EVENTS_DURATION',$event->startdateHTML,$event->enddateHTML); ?>
									<?php if( $config->get('eventshowtimezone') ) { ?>
										<span class="small"><?php echo $timezone; ?></span>
									<?php } ?>
								</dd>
								<!-- Event Location -->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION');?></dt>
								<dd id="community-event-data-location">
									<a href="http://maps.google.com/?q=<?php echo urlencode($event->location); ?>" target="_blank"><?php echo $event->location; ?></a>
								</dd>
								<!--Event Occurence -->
								<?php if ($event->isRecurring()) { ?>
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_OCCURENCE');?></dt>
								<dd><?php echo JText::_('COM_COMMUNITY_EVENTS_REPEAT_' . strtoupper($event->repeat)); ?></dd>
								<?php }?>
								<!--Event Admins-->
								<dt><?php echo JText::_('COM_COMMUNITY_EVENTS_ADMINS')?></dt>
								<dd><?php echo $adminsList;?></dd>
							</dl>


						</div>
					</div>
				</div>
				</div>
			</div>
			<!-- Tab 2: END -->
			
			<!-- Tab 1: Activity Stream Container -->
			<?php if( $showStream ) { ?>
			<div class="cTabsContent  <?php if(!$isEventGuest && !$showStream ) {echo 'cTabsContentCurrent';} ?>">
				<!-- Stream -->
				 <?php if( $showStream ) { $status->render(); } ?>
				<div class="cActivity cEvent-Activity" id="activity-stream-container">
					<div class="cActivity-LoadLatest joms-latest-activities-container">
						<a id="activity-update-click" class="btn btn-block" href="javascript:void(0);"></a>
					</div>
					<?php echo $streamHTML; ?>
				</div>
				<!-- end: stream -->
			</div>
			<?php } ?>
			<!-- Tab 1: END -->
		</div>
		<!-- END: Global Application Tab bar contents -->
		</div>

It works on my installation... does it work for you too?


- 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
The following user(s) said Thank You: Tara Allin
10 years 3 months ago
  • Trude's Avatar
    Topic Author
  • Trude
  • Offline
  • Fresh Boarder
  • Posts: 25
  • Thank you received: 3
Licenses:
JomSocial Active Socialize Expired

Thank you,

but I'm afraid it still removes the option to view the event activity stream in my page, and still leaves a tab option to view the details I am already viewing (nothing happens pressing this).

I did this very carefully twice now, so I am pretty sure I replaced the correct code?

10 years 3 months ago
Licenses:

Hi, Trude.

Then revert changes, make a safe copy and replace your file with mine.

I added to your first post credential to my site where you can see that it works.


- 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

This message has an attachment file.
Please log in or register to see it.

The following user(s) said Thank You: Tara Allin
10 years 3 months ago
  • Trude's Avatar
    Topic Author
  • Trude
  • Offline
  • Fresh Boarder
  • Posts: 25
  • Thank you received: 3
Licenses:
JomSocial Active Socialize Expired

Thank you,

really nice of you, but I'm afraid the problem remains... Also, I can't find your working site anywhere in the posts?

You can login frontend with the admin credentials and have a look at one of the events. As you can see, the activity stream is gone, even with your file. And the option to view details is still there :)

10 years 3 months ago
Licenses:

Hi, Trude.

Ok, I sent you credentials to test site via PM.
Enter here: prolusatia.nazwa.pl/test/
Log with credentials.
Enter to a link I provided you.

As for your site, upgrade to current JomSocial -> 3.1.0.4


- 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
10 years 3 months ago
  • Trude's Avatar
    Topic Author
  • Trude
  • Offline
  • Fresh Boarder
  • Posts: 25
  • Thank you received: 3
Licenses:
JomSocial Active Socialize Expired

Thanks, yes your test site shows events exactly the way I want them to. How weird is that! :)

I will upgrade later today, and try again.

10 years 3 months ago
Licenses:

Hi, Trude.

Yes, so upgrade, switch files and check again.


- 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
10 years 3 weeks ago
Licenses:

Hi, Trude.

We have not received any response back from you in over 7 days, and would like to know if you consider this issue to be resolved. If you have any further questions, simply reply to this post.


- 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
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