function cdn_touch_file_form_submit in CDN 7.2
Same name and namespace in other branches
- 6.2 cdn.stats.inc \cdn_touch_file_form_submit()
File
- ./
cdn.stats.inc, line 46 - Per-page CDN integration statistics functionality.
Code
function cdn_touch_file_form_submit($form, &$form_state) {
$filepath = $form_state['filepath'];
if (touch(_cdn_get_absolute_path($filepath))) {
drupal_set_message(t('Successfully touched %filepath.', array(
'%filepath' => $filepath,
)));
}
else {
drupal_set_message(t('Failed to touch %filepath. Likely you do not have sufficient permissions.', array(
'%filepath' => $filepath,
)));
}
drupal_goto($form_state['storage']['redirect']);
}