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.

How to make the event location as not mandatory

11 years 2 months ago
Licenses:
JomSocial Expired

ISSUE SUMMARY:
While we enter a new event system force me to select he location while some events that might be over the Web or skype so once i select either web or skype for example system show this location on the google map !!

so i was wondering whether we can leave the location as optional on the event creation

STEPS TO REPLICATE:
1 create new event
2 enter event location as skype
3 skype show as location on the google map
4
5
RESULT
EXPECTED RESULT
BROWSER

11 years 2 months ago
Licenses:

Hi,

here the steps:
copy events.forms.php from /components/com_community/templates/jomsocial/layouts/ to /templates/[your front end template]/html/com_community/layouts/ ( create the folder if not exist yet)
edit it, at line 109 change the code
from

<div class="joms-form__group">
    <span><?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION'); ?> <span class="joms-required">*</span></span>
    <input type="text" class="joms-input" name="location" required=""
        title="<?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION_TIPS'); ?>"
        value="<?php echo $this->escape($event->location); ?>"
        placeholder="<?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION_DESCRIPTION'); ?>">
</div>
to
<div class="joms-form__group">
    <span><?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION'); ?></span>
    <input type="text" class="joms-input" name="location"
        title="<?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION_TIPS'); ?>"
        value="<?php echo $this->escape($event->location); ?>"
        placeholder="<?php echo JText::_('COM_COMMUNITY_EVENTS_LOCATION_DESCRIPTION'); ?>">
</div>

and edit /components/com_community/controllers/events.php, and comment out (put // at every code)
line 2117
if (empty($event->location)) {
    $validated = false;
    $mainframe->enqueueMessage(JText::_('COM_COMMUNITY_EVENTS_LOCATION_ERR0R'), 'error');
}

and 2124
$event->location,

Regards

The following user(s) said Thank You: Ahmad Ensour
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