Elxis CMS Forum

Extensions => Components => Topic started by: Davide on February 08, 2011, 12:28:56

Title: More/Less Specific Dates
Post by: Davide on February 08, 2011, 12:28:56
Code: [Select]
echo ' <a href="javascript:void(null);" onclick="resdiscountdetails(1, '.$hotel->hid.', \''.$ajaxLive.'\');" title="'._MORE.'" class="reservlink">'._MORE.'</a>';
Code: [Select]
echo ' <a href="javascript:void(null);" onclick="resdiscountdetails(2, '.$hotel->hid.', \''.$ajaxLive.'\');" title="'._MORE.'" class="reservlink">'._MORE.'</a>';
Code: [Select]
echo ' <a href="javascript:void(null);" onclick="resdiscountdetails(3, '.$hotel->hid.', \''.$ajaxLive.'\');" title="'._MORE.'" class="reservlink">'._MORE.'</a>';
That's for get More information about the discount. How to get less information? that's means close the previous opened div?

Thank you
Title: Re: More/Less Specific Dates
Post by: datahell on February 08, 2011, 12:37:05
You have to put a link inside the opened data with something that will clear the text.
Related javascript methods:

//reset the contents
document.getElementById('id_of_the_element_here').innerHTML = '';

//hide an element
document.getElementById('id_of_the_element_here').style.display= 'none';