var roomDetails =
[ 
    {'nodeID':'room11497002', 'description':'<p style="padding-bottom: 8px;"><b>Description: </b>Cottage has a family room, double room, bathroom and shower room. There is a comfortable lounge with three piece suite, an electric fire and a separate dining room with further seating.</p>', 'amenities':'<p style="padding-bottom: 8px;"><b>Room amenities: </b>Tea/Coffee Maker, TV, Telephone, Radio, Refrigerator, Ironing Facilities, Seating Area, DVD Player, Microwave, Bathroom, Heating, Kitchen, Bath or Shower.</p>', 'clickTest':false},
    {'nodeID':'room11497001', 'description':'<p style="padding-bottom: 8px;"><b>Description: </b>The cottage consists of a double and twin room, Fitted kitchen with dishwasher, microwave, fridge/freezer and electric cooker and all cooking utensils.</p>', 'amenities':'<p style="padding-bottom: 8px;"><b>Room amenities: </b>Tea/Coffee Maker, TV, Telephone, Radio, Refrigerator, Ironing Facilities, Seating Area, DVD Player, Microwave, Bathroom, Heating, Kitchen, Bath or Shower.</p>', 'clickTest':false},
    {'nodeID':'room156', 'description':'<p style="padding-bottom: 8px;"><b>Description: </b>With a TV and facilities for making tea and coffee.</p>', 'amenities':'<p style="padding-bottom: 8px;"><b>Room amenities: </b>Tea/Coffee Maker, TV, Telephone, Hairdryer, Wake Up Service/Alarm Clock, Bathrobe, Radio, Ironing Facilities, DVD Player, Heating, Bath or Shower.</p>', 'clickTest':false},
    {'nodeID':'room155', 'description':'<p style="padding-bottom: 8px;"><b>Description: </b>Our twin rooms have either 2 single beds or a double and single bed. All are en suite and have views over either the gardens or fields.</p>', 'amenities':'<p style="padding-bottom: 8px;"><b>Room amenities: </b>Tea/Coffee Maker, TV, Hairdryer, Wake Up Service/Alarm Clock, Bathrobe, Radio, Ironing Facilities, DVD Player, Toilet, Heating, Bath or Shower.</p>', 'clickTest':false},
    {'nodeID':'room154', 'description':'<p style="padding-bottom: 8px;"><b>Description: </b>All are en suite and have views of the lawns, gardens or surrounding fields. There are 2 king-size rooms available (subject to availability).</p>', 'amenities':'<p style="padding-bottom: 8px;"><b>Room amenities: </b>Tea/Coffee Maker, TV, Telephone, Hairdryer, Wake Up Service/Alarm Clock, Trouser Press, Bathrobe, Radio, Ironing Facilities, DVD Player, Heating, Bath or Shower.</p>', 'clickTest':false},
    {'nodeID':'room153', 'description':'<p style="padding-bottom: 8px;"><b>Description: </b>Features a 4-foot small double bed, a TV/DVD player, telephone, bottled water, bathrobe, tea/coffee facilities, free Wi-Fi, shower en suite and views over the lawns.</p>', 'amenities':'<p style="padding-bottom: 8px;"><b>Room amenities: </b>Tea/Coffee Maker, Shower, TV, Hairdryer, Wake Up Service/Alarm Clock, Bathrobe, Radio, Ironing Facilities, DVD Player, Toilet, Heating, View (sea, garden, landmark, etc.).</p>', 'clickTest':false}
];

// Example of roomDetails contents:
//
// var roomDetails =
// [ 
//     {'nodeID':'room0', 'description':'room0 description', 'amenities':'room 0 amenities', 'clickTest':false},
//     {'nodeID':'room1', 'description':'room1 description', 'amenities':'room 1 amenities', 'clickTest':false},
// ];

function secondClicktest(roomID) {
    var theroom = roomDetails[roomID];

    if (theroom["clickTest"] == false)
    {
        document.getElementById(theroom["nodeID"]).innerHTML=theroom["description"]+" "+theroom["amenities"];
        return theroom["clickTest"] = true;
    } else
    {
        document.getElementById(theroom["nodeID"]).innerHTML="";
        return theroom["clickTest"] = false;
    }
} 


