1. Upload file on the server |
Before the installation, please upload files .htaccess and rwdgate.php located in the installation package. Other files from the package are additional and are only the demonstration of the installation. Server configuration file (.htacess) has to be installed on the main folder of the project (the index.php file will be located there as well)), rwdgate.php file may be uploaded in any location but make sure to set the correct path during implementation of the library (see point 2).
2. Library implementation (in the constructor, provide affilliate identificator which can be found on the administration bar in the VacationsCMS panel):
$rwdgate = new rwdGate('3987123456');
3. Widget implementation (using id):
<?php $widgets = array(lista_id); ?>
$widgets = array(2120310, 2120315, 2120320, 2120330, 2138306);
Widget Id can be found in the VacationsCMS administration panel after selecting preview ID option (top menu of the panel, black bar - Configuration).
5. Header implementation in the head section:
<?php echo $rwdgate->getSection('HEAD'); ?>
6. Implementation of parts:
Any iteration method can be used, either by elements or element id (sample):
7. Footer implementation (after implementation of every other element/widget)
$list = $rwdgate->getSectionsList();
if (in_array('2120310', $list ))
Notice: it is necessary to implement BODY element, which is responsible for further steps of search process (results, details, booking and confirmation).
<?php $rwdgate->getSection('BODY'); ?>
If you want to show some elements on the main site but not on the other subpages, use the
if (in_array('BODY', $list ))
echo 'elementy strony głównej';
<?php $rwdgate->getSection('FOOTER'); ?>
8. Offer cart
Display of the amount of offers added to the cart (information displayed in any place on the website):
<a href="#" class="btn-cart text text-color-16 text-hover-18">
<span class="yourCart">Schowek ofert:
if (document.readyState == 'complete' || document.readyState =='interactive' || document.readyState == 'loaded')
if (document.readyState == 'complete' || document.readyState == 'interactive' || document.readyState == 'loaded')
Display of the open cart with offers as a new layer. Needs to be implemented just before the BODY element.
<?php echo '<main></main>'; ?>
Add autosearch to a list of received elements:
$widgets = array(2120310, 2120315, 2120320, 2120330, 2138306,'quicksearch');
Display search field in the chosen location:
<?php echo $rwdgate->getSection('quicksearch'); ?>