function patterns_load_yaml in Patterns 6
Same name and namespace in other branches
- 6.2 patterns.module \patterns_load_yaml()
1 call to patterns_load_yaml()
File
- ./
patterns.module, line 1119 - Enables extremely simple adding/removing features to your site with minimal to no configuration
Code
function patterns_load_yaml($path, $local = TRUE) {
if ($local && !file_exists($path)) {
return FALSE;
}
include_once 'spyc/spyc.php';
$pattern = Spyc::YAMLLoad($path);
if (!patterns_validate_pattern($pattern)) {
return FALSE;
}
return $pattern;
}