• thbob

    (@matthewokoh)


    Hi
    Is it possible to let user name comments to rooms. We dont see the comment box.
    How can we add a comment box so user can write comments on the rooms?
    Thank you

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author benitolopez

    (@benitolopez)

    Hello,

    Rooms don’t have comments enabled in WP hotelier. It is a custom post type.

    So what you’re asking is possible only modifying the room template and adding the support for comments. Unfortunately I can’t help you with that so this is something you need to integrate yourself.

    To add support for comments you can use this snippet in your theme:
    https://pastebin.com/raw/E5WuQbFS

    Then place this line somewhere in wp-hotelier/templates/single-room/content-single-room.php. Remember that you can override that file in your child theme (https://docs.wphotelier.com/article/66-override-template-files).

    <?php comments_template(); ?>

    You will need to style the form of course.

    Hope this helps.

    Best Regards,
    Benito

    Thread Starter thbob

    (@matthewokoh)

    great thank you and will try it out.

    Thread Starter thbob

    (@matthewokoh)

    Hi
    We add the code to our functions.php in the Hotello child theme and the <?php comments_template(); ?> to the wp-hotelier/templates/single-room/content-single-room.php…. but it did not work and it is not showing the comment field on room page so customer can leave comments.

    Plugin Author benitolopez

    (@benitolopez)

    Hello,

    Probably the theme you’re using is overriding the room template. As I said above, unfortunately I can’t help you with custom code so this is something you need to integrate yourself. Try to contact the author of your theme and check if it works with the default WP theme.

    Best Regards

    Thread Starter thbob

    (@matthewokoh)

    Ok thank you for your help and will try to contact Hellio theme.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Comments on room’ is closed to new replies.