Presale Questions
-
I am looking at this plugin as the feature set looks amazing. I am looking through documentation though and I don’t see anything about shortcodes or templates. Does the plugin have shortcodes and the ability to edit templates?
-
Hi,
Thanks for your message. Shortcodes are indeed available in Vik Booking, and that’s how you publish the “Views” (pages) generated by the plugin in the front-end section of your website.
From the back-end page Dashboard, you will see a dedicated “Shortcode” button that will take you to the management functions for the various types of Shortcode available. Once you have created one, Vik Booking will display a button to create a new WordPress page with that Shortcode string inside it, so that the page will be ready to be visited, and even to be modified through your preferred editor/content-builder.
We always recommend to create at least 3 types of Shortcodes: Search Form, Rooms List and Booking Details. Such types of Shortcodes should be properly configured and linked to a corresponding WordPress page/post so that the URL routing functions for the front-end will work correctly by applying the permalinks of your pages and the WordPress general URL rewriting settings.
If you are looking to customize the default layout of some pages generated by Vik Booking, then you should understand first if some CSS adjustments are sufficient, or if you would like to apply changes to the default HTML/JS structure. In case CSS adjustments are sufficient for your edit, then you can either add the necessary CSS styles to the apposite CSS file for the front-end (modifiable from the page Configuration of Vik Booking), or you can add such CSS customization to your Theme’s custom CSS file/setting.
For any complex modification of the HTML structure, JS and even PHP code, you are supposed to create an override for the page you wish to modify. This is because Vik Booking is written according to the MVC pattern of PHP, and so every “page” is actually a “View”, and this means that you can override its own template file by cloning the original file and by moving it to the apposite directory for the overrides. This way, you will be able to work on a copy of that template file to implement your customization, and no future updates will ever touch your changes.
You can find more information in the Knowledge Base section on our website, under the section Vik Booking – Customization Tips.
Best regards,
The VikWP TeamYour knowledge base has absolutely zero info about templates on it. Can you please just tell me where/which files I can edit in order to change the layout of the room pages?
Hi,
There are no files you should edit if you don’t want to lose your changes by installing a future update. As I said, our Knowledge Base section explains how to create a “Page Override” in the dedicated article under “Vik Booking – Customization Tips – Page Overrides”.
When you want to change the layout of a specific page, say the “Rooms List”, you need to create an override for the layout file of that View. By following the Model-View-Controller (MVC) pattern of PHP, Vik Booking will render that View (page) by either using the override file (if available in the apposite directory) or the default file.
In order to edit the HTML, JS or PHP code of a specific page to implement any kind of modification, you need to override the layout file of that page (View). In order to do that, you should identify the name and type of the View to locate the PHP file you want to clone and move onto the apposite override directory. At that point, you will be able to edit the file to perform any kind of customization.
I know how to edit templates. The problem I see now is that your knowledge base and documentation are two different things apparently. It is confusing and they don’t have the same info. The “documentation” page is completely missing the template stuff.
https://vikwp.com/support/knowledge-base/vik-booking/customization-tips
https://vikwp.com/support/documentation/vik-booking/customization-tips
-
This reply was modified 2 years ago by
Anonymous User 13711045.
Hi,
Well, the documentation page is only linking to the KB article for the CSS adjustments. If you visit the parent section “Customization Tips” in the KB, you will also find the article I mentioned above. If you visit the Knowledge Base sections, you will find the article you are looking for. Thank you!
Yeah, I see that now. As I said, it’s confusing. I would expect the documentation to contain that info or at least have the same info as the knowledgebase or link to it or something.
Thanks for your feedback. We are definitely going to inform our colleagues!
-
This reply was modified 2 years ago by
- The topic ‘Presale Questions’ is closed to new replies.