Category:Developers: Difference between revisions

Jump to navigation Jump to search
No edit summary
Line 50: Line 50:
For example: this would cause property 1234 to open in the parent window (frame busting) when it's book button is clicked on the multiple property page
For example: this would cause property 1234 to open in the parent window (frame busting) when it's book button is clicked on the multiple property page


<script>
<script>
$(document).ready(function(){
$(document).ready(function(){
$('#propid1234 a').attr('target', '_parent');
$('#propid1234 a').attr('target', '_parent');
});
});
</script>
</script>


<span style="color: #f3e504; font-size: 250%;" >{{#fas:lightbulb}} </span> Check the settings under  {{#fas:cog}} (SETTINGS) >BOOKING ENGINE  >  PROPERTY BOOKING PAGE > BEHAVIOUR before you add such a script.
<span style="color: #f3e504; font-size: 250%;" >{{#fas:lightbulb}} </span> Check the settings under  {{#fas:cog}} (SETTINGS) >BOOKING ENGINE  >  PROPERTY BOOKING PAGE > BEHAVIOUR before you add such a script.


=== Change the title text ===
=== Change the title text ===
javascript to change the titletext
Javascript to change the titletext.


<code> <script>document.title='your title';</script></code>
<code> <script>document.title='your title';</script></code>
=== Change date format to American ===
Javascript to change the date format.
<script>
$(document).ready(function(){
$('#inputcheckin').data('date-format','MMMM DD, YYYY');
$('#inputcheckout').data('date-format','MMMM DD, YYYY');
})
</script>
<script>
window.onload = function() {
$("[id^='ptdate']").text(function(i, t) {
  return t.split(' ').reverse().join(' ');
})
};
window.onunload = function(){};
</script>


== Booking Page Parameters ==
== Booking Page Parameters ==