Learn how to generate and place Drupal shortcodes and how to extend the shortcode using arguments, which are values passed in the code to customize the experience.
Are you new to Drupal? Please read the first article in this series for an introduction to our Drupal integration.
Which plans include this feature?
Legacy: Soho, Pro, Plus, Enterprise, Flex
New: Growth (Subscription), Growth (Online Booking Fee), Managed
→ Learn more about our new plans or how to change your plan.
Where can I find this feature using the top menu?
Manage > Integrations > Website Integration > Drupal
What more do I need to use this feature?
- Admin permissions to manage integrations.
- A hosted website with free Drupal software.
- Ability to copy and paste into your website code or have some helpful person do this for you!
Which Checkfront version supports this feature - classic, new or both?
- This feature is available in both our classic version using items (Inventory > Items) and our newest version using products (Inventory > Products). → Learn more about products
Generating the shortcode
Back to topYou should have by now selected all the previous options that make the most sense in terms of your requirements. It's now time to generate the shortcode for your website!
Click the Generate Code button and copy the resulting shortcode to your clipboard. The basic shortcode generated looks like this:[checkfront]
.
Placing the shortcode
Back to topWith the shortcode pasted to your clipboard, head back to Drupal and locate/create the page/post where you wish to embed the booking portal.
- Place the shortcode wherever you want the portal to appear. This may be before, after, or somewhere within your page content.
- Make sure you select Full HTML from the Text Format field.
Using arguments with the shortcode
Back to topAdding arguments (from the list below) controls how the booking portal appears and the information it contains. Above is an example of what this shortcode might look like.
Extending the shortcode
Back to topFollowing is a list of arguments that can be added to the basic [checkfront]
shortcode to change the look and behaviour of your booking portal.
Type | Variable | Description |
Inventory |
|
Show specific items or products |
|
|
Show specific categories |
|
|
Limit upcoming events to a specific category |
Options |
|
Tabs as categories |
|
[checkfront options=category_select |
Dropdowns as categories |
|
|
Hide search and calendar |
|
|
Hide date picker |
|
|
Together they would look like this |
Discount Code |
|
Include an automatic discount code |
Language |
|
Set default booking portal language |
|
|
Set default customer language. Customers can change this from the menu bar. Supercedes lang_id |
Style |
|
Font colour |
|
|
Font-family |
|
|
Background colour |
|
|
Font styles combined |
Date |
|
Fast forward to a specific date |
|
[checkfront end_date="20140131"] |
Add an end date |
Tracking ID |
|
Tracking ID |
-
Is it possible to have multiple shortcodes on the same webpage?
No. You can only have one shortcode per webpage. If you want multiple integrations on the same webpage, you need to add generated Booking Widget code as HTML.
Be sure to allow browser cookies in the current browser session. Not accepting cookies may prevent the plugin from loading properly. |
< Configuring advanced options for the Drupal plugin