gif', 'B+B Gold Award'=>'etcgold.gif', 'Selfcater Silver Award'=>'eesilversc.gif', 'Selfcater Gold Award'=>'eegoldsc.gif', 'Walkers Welcome'=>'walkers.gif', 'Cyclists Welcome'=>'cyclists.gif', 'Families Welcome'=>'families.gif','Pets Welcome'=>'petswelcome.gif','PD Cuisine'=>'pdcuisine.gif', 'PD Environmental Quality'=>'pdenvqual2.gif'); } function getMaxImageWidth() { return '100%'; } function html_ents($s) { // get rid of irritating UTF characters $s = utf8_encode($s); $s = preg_replace("/£/",'£', $s); $s = preg_replace("/½/", '½',$s); if (!$this->testHTML($s)) return stripslashes($s); //htmlentities(stripslashes($s), 0 , "UTF-8"); else return html_entity_decode(stripslashes($s)); //htmlentities($s, 0, "UTF-8"), 'ENT_SUBSTITUTE'); } function nltobr($string, $nobreak=0) { // replace line breaks with
// looks like this is now redundant //$string = nl2br($string); //$string = preg_replace("/ /ism", "  ", $string); //$string = preg_replace("/\,/ism", ", ", $string); if (!$nobreak) { $string = preg_replace("/\r\n/ism","
",$string); $string = preg_replace("/\n/ism","
",$string); $string = preg_replace("//ism","
",$string); } return $string; } function oddChars($s) { // remove characters with ASCII code > 127 and < 32 // now appears to be redundant $len = strlen($s); $res = ''; for($i = 0; $i < $len; $i++) { $in = ord($s[$i]); if (($in<0x7E && $in >0x1F) || $in == 0xAB || $in == 0xAC) { $res .= substr($s, $i, 1); } else if ($in == 0xC2) $res .= '£'; else $res .= ''; } return $res; } function testHTML($s) { // check to see if a string is HTML or not - may need more tests $s = trim($s); if (preg_match("/^<.*>$/is", $s)) return 1; if (preg_match("/<\/p>/is", $s)) return 1; if (preg_match("/<\/b>/is", $s)) return 1; if (preg_match("/<\/h[1..6]>/is", $s)) return 1; else return 0; } function html_ent($s) { // get rid of irritating UTF characters $s = utf8_encode($s); $s = preg_replace("/£/",'£', $s); $s = preg_replace("/½/", '½',$s); if (!$this->testHTML($s)) return stripslashes($s); //htmlentities(stripslashes($s), 0 , "UTF-8"); else return html_entity_decode(stripslashes($s)); //htmlentities($s, 0, "UTF-8"), 'ENT_SUBSTITUTE'); } function putout($f, $obj=null, $class=null , $alt=null, $w=0) { // retrieve a DB field from one of the objects specifiec in the construction // parameters are fieldname and theobject (ie DB table name - not required if using $obj->putout()) //for displaying in image: width, alt, class (ie style) are all optional - (for images only) // parameters are fieldname and the (for displaying omawidth, alt, class (all optional - for images only) // parameters are fieldname and the (for displaying omawidth, alt, class (all optional - for images only) // output a field of the object - $obj can be passed as a parameter if required // $param is an additional parameter - eg. subject in e-mail // - otherwise it is the object set when this is constructed /*if (empty($obj)) { $obj = $this->obj; }*/ $t = $this->getFieldType($f); $val = $this->getField($f); if ($t == 'v') { // print the 'v' type - varchar text and blobs return $this->html_ents($val); } else if ($t == 'b') { // blob (text) type // if not HTML, remove slashes, convert line breaks to
and convert to html $string = $this->nltobr(stripslashes(stripslashes($val))); return $this->html_ents($string); } else if ($t == 'm') { // email address $mstring = ''.htmlspecialchars($val).''; return $mstring; } else if ($t == 'w') { // URL field if (preg_match('/^http:\/\//i',$val)) { $val = preg_replace('/^http:\/\//i','',$val); } if (!empty($param)) $val = $val.'?'.$param; return ''.htmlspecialchars($val).''; } else if ($t == 'd') { // $val is assumed to be an SQL format date $months = array('', 'Jan', 'Feb', 'Mar', 'Apr', 'May', 'June', 'July', 'Aug', 'Sep', 'Oct', 'Nov', 'Dec'); $parts = explode('-', $val); $parts[1] = preg_replace('/^0/','', $parts[1]); $dow = date("D", mktime(0,0,0,$parts[1],$parts[2],$parts[0])); return $dow.' '.$parts[2].' '.$months[$parts[1]].' '.$parts[0]; } else if ($t == 't') { // time variable return $val; } else if ($t == 'o') { // owner variable return htmlspecialchars(stripslashes($val)); } else if ($t == 'n') { // numeric type return $val; } else if ($t == 'l') { // list select type $s = $this->getSelects($f); foreach ($s as $k=>$v) { if($v == $val) return htmlspecialchars(stripslashes($k)); } } else if ($t == 'p') { // picture type // get the max image width for this field $max = $this->getMaxImgWidth(); if (is_array($max)) { if (isset($max[$f])) $max = $max[$f]; else $max = null; } $imagedir = $this->getImageDir(); if ($w != 0) { if (strstr($w, '%')) { $percent = substr($w, 0, strlen($w)-1); } else $max = $w; } if (empty($val)) { $def = $this->getDefaultImage(); if (empty($def)) return; $val = $def; } $r = ''.$alt.' 0) $r .= 'width="'.$max.'px"'; $r.= ' border="0" '; } return $r. '>'; } else if ($t == 'i') { // icon type if (empty($val) || $val == 0) return ''; $icondir = $obj->getIconDir(); $val = $obj->getIcon($f); $alt = $obj->getIconAlt($f); if (!empty($class)) return ''.$alt.''; else return ''.$alt.''; } else if ($t == 'j') { // numeric icon type $icondir = $obj->getIconDir(); $v = $obj->getIcon($f); $alt = $obj->getIconAlt($f); $p = $obj->getParams($f); $s = $p[0]; if (isset($p[1])) $m = $p[1]; else $m = null; if ($val != $s){ if (!empty($class)) return ''.$alt.''.$val.''; else return ''.$alt.''.$val.''; } else return ''; } else if ($t == 'c') { // currency type return sprintf("£%0.2f",$this->html_ent($val)); } return ''; } } ?>
peak district B&B bed and breakfast
Peak District Bed and Breakfast

We have a wide range of bed and breakfast establishments ranging from Glossop to the edge of Derby.
Click here or on the image to continue.

peak park map
peak district hotels, pubs and inns
Peak District Hotels, Inns and Pubs

We have a wide range of Hotels, Inns, Pubs and restaurants which offer rooms, in locations across the Peak District.
Click here or on the image to continue.

peak district self catering holiday cottages
Peak District Holiday Cottages

We have a range of top quality self catering holiday cottages in both the towns and the deepest countryside.
Click here or on the image to continue.

peak district caravan and camp sites
Peak District Caravan and Camp Sites

We have a long list of caravan and camp sites in and around the Peak District National Park.
Click here or on the image to continue.


More Accommodation Options


google plus

facebook