I need the user to enter opening hours for their helpline in the CMS along with two sets of text, one that will be displayed if the user views it during their opening hours & another which is displayed outside of their opening hours.
The way I have been trying to approach the problem (taken from a suggestion else where on Stack Exchange) was to use the Office Hours & Colorbox Node modules together. Unfortunately unless I've misunderstood what Colorbox Node does or how it works I cannot get it to open a modal at all, I can't actually get it to do anything.
Below are the steps I've taken to install the Office Hours & the Colorbox Node modules so hopefully someone can spot what I've done wrong. I am more than open to other suggestions to solve this problem though.
Using the two modules mentioned my plan was to create a custom template which would read the current date & time, compare it to what has been entered into the Office Hours module then display the appropriate text from one of two text area fields in the CMS.
- Created fresh Drupal 7 install
Installed Office Hours 7.x-1.4 module (https://www.drupal.org/project/office_hours)
2a. Installed required module Date api 7.x-2.9 (https://www.drupal.org/project/date)
Installed Colorbox node 7.x-3.5 module (https://www.drupal.org/project/colorbox_node)
3a. Installed required module colorbox 7.x-2.10 (https://www.drupal.org/project/colorbox)
3b. Installed required module Libaries 7.x-2.2 (https://www.drupal.org/project/libraries)
- Created new content type with the Office Hours field
- Created new node setting the new office hours
- Created test page with link to office hours page, link has class of "colorbox-node" which should show a modal?
This is what the link tag currently looks like:
<a class="colorbox-node" href="/node/1?width=600&height=600">Test link</a>