Changeset 2697 for trunk/wp-includes/functions.php
- Timestamp:
- 07/04/2005 09:53:26 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/functions.php
r2671 r2697 1967 1967 } 1968 1968 1969 function register_activation_hook($file, $function) { 1970 $file = plugin_basename($file); 1971 1972 add_action('activate_' . $file, $function); 1973 } 1974 1975 function register_deactivation_hook($file, $function) { 1976 $file = plugin_basename($file); 1977 1978 add_action('deactivate_' . $file, $function); 1979 } 1980 1981 function plugin_basename($file) { 1982 return preg_replace('/^.*wp-content[\\\\\/]plugins[\\\\\/]/', '', $file); 1983 } 1984 1969 1985 ?>
Note: See TracChangeset
for help on using the changeset viewer.