function feedback_mask_path in Feedback 5.2
Same name and namespace in other branches
- 6.2 feedback.module \feedback_mask_path()
- 7.2 feedback.module \feedback_mask_path()
'Mask' a path, i.e. replace all numeric arguments in a path with '%' placeholders.
Please note that only numeric arguments with a preceding slash will be replaced.
Parameters
$path: An internal Drupal path, f.e. 'user/123/edit'.
Return value
A 'masked' path, for above example 'user/%/edit'.
2 calls to feedback_mask_path()
- feedback_add_entry in ./
feedback.module - Store a new feedback entry in the database.
- feedback_form in ./
feedback.module - Form builder function for a user feedback form.
File
- ./
feedback.module, line 199 - Allows site visitors and users to report issues about this site.
Code
function feedback_mask_path($path) {
return preg_replace('@/\\d+@', '/%', $path);
}