Problem while i am trying to display the events in the calendar?
<p>Hell all,</p>

<p>I am creating a event module. In that as usual after creating the event we need to display the event title in the popup when clicking the date in the calendar. its working. but if i have multiple events in the same day its just showing the first event.</p>

<p>Template Engine i used here is SMARTY. And i used {literal} to differentiate smarty and JS.</p>

<p>Here is the code:</p>

<pre><code>function getDateInfo(date, wantsClassName) 
{ 

{/literal}{foreach from=$view_event item=event}{literal} // USED {literal} to differentiate SMARTY and Java Script. 

        var as_number = Calendar.dateToInt(date); 

if (as_number &gt;=  {/literal}{$view_event.sdate}{literal} &amp;&amp; as_number &lt;=  {/literal}{$view_event.edate}{literal})

            return {

                klass   : "highlight2",
                tooltip: "&lt;div style='text-align: center'&gt;From:{/literal}{$view_event.started_on|date_format:'%d-%m-%Y'}{literal} -- To:{/literal}{$view_event.end_on|date_format:'%d-%m-%Y'}{literal}&lt;br&gt;Event:{/literal}{$view_event.event_name}{literal}&lt;/div&gt;" 

            };

    {/literal}{/foreach}{literal}

    return DATE_INFO[as_number];
};
</code></pre>

<p>How can i accomplish this critical ISSUE.</p>

<p>Thanks in advance...</p>
