Elxis CMS Forum

Extensions => Modules => Topic started by: openita on February 03, 2014, 11:08:45

Title: Calendar hotel search
Post by: openita on February 03, 2014, 11:08:45
Good morning!
After doing the latest updates i realized that the hotel search form no longer appears on the calendar. Can you help me?
THANK YOU!  ;)
Title: Re: Calendar hotel search
Post by: datahell on February 03, 2014, 14:28:18
Can you show us a link or a screenshot?
Title: Re: Calendar hotel search
Post by: openita on February 03, 2014, 17:16:16
http://i.imgur.com/mweUCIf.png
Title: Re: Calendar hotel search
Post by: datahell on February 03, 2014, 19:35:55
Hit control+F5 to make sure you don't see a cached version.
If this isn't the problem make sure this image exist:
modules/mod_iosr_hsearch/css/calendar.png

IOSR Hotel Search v1.1
This module updated today to version 1.1 which supports an alternative location selection method: select location from a drop-down list.
Go to IOS Reservations > Updates and download IOSR Hotel Search v1.1. Then install this module via the Elxis installer to automatically update from v1.0 to v1.1.
Title: Re: Calendar hotel search
Post by: openita on February 03, 2014, 20:20:33
I tried to install the update but I have not solved.
Doing several tests I realized that the problem that creates a potential conflict with the search form hotels and the new form that I created with the following code:
   
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js">  </script>

<script>
$(document).ready(function(){
  $("#mat_ricerca").click(function(){
    $("#fmmodsearch").toggle();
  });
});
</script>
<div> <img alt="" id="mat_ricerca" src="http://www. _______________ /engine.png" style="width: 16px; height: 16px;" />  </div>


My objective is to create a form that allows me to click the search icon (as you can see in the image http://i.imgur.com/Hjxyx2K.png ) make me look the search form (http://i.imgur.com/AJa5W6v.png)

thank you very much  :D

Title: Re: Calendar hotel search
Post by: datahell on February 03, 2014, 20:48:13
This is because you load 2 different versions of jquery.

To load jquery in Elxis ALWAYS use this:
$eDoc = eFactory::getDocument();
$eDoc->addJQuery();

So don't use this:
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
But the code I wrote you and you wont have conflicts.

If you want to load a newer jQuery version that the one Elxis uses use this:
$eDoc = eFactory::getDocument();
$eDoc->addLibrary('jquery', 'http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js', '1.10.2');
Elxis is very smart, it will detect different library versions loads and finally load the newer one. But you should be aware that your loaded jquery file has all the required by Elxis and its extensions jquery libraries. Else you will have errors. To avoid this always use $eDoc->addJQuery();
Title: Re: Calendar hotel search
Post by: openita on February 04, 2014, 10:52:35
I modified the code and it works perfectly.
Thank you very much
Title: Re: Calendar hotel search
Post by: openita on February 04, 2014, 18:42:03
I created the module and it works fine without conflict, the only thing that bothers me is that the icon of the magnifying glass to search I get the mobile version. You can lock the module in the mobile version?

Thanks