function menu_position_read_rule in Menu Position 7
Same name and namespace in other branches
- 7.2 menu_position.admin.inc \menu_position_read_rule()
Retrieves a menu position rule from the database.
Parameters
int $rid: The ID of the requested rule.
Return value
array An associative array for the requested rule.
1 call to menu_position_read_rule()
- menu_position_edit_rule_form in ./
menu_position.admin.inc - Menu callback; Edits rules.
File
- ./
menu_position.admin.inc, line 576 - Provides infrequently used functions and hooks for menu_position.
Code
function menu_position_read_rule($rid) {
$rule = db_query('SELECT * FROM {menu_position_rules} WHERE rid = :rid', array(
':rid' => $rid,
))
->fetchAssoc();
$rule['conditions'] = unserialize($rule['conditions']);
return $rule;
}