public static function getValue($key) { if ($v = CmsOption::where('name', '=', $key)->firstOrFail()) { return $v->value; } else { return ''; } }