This commit is contained in:
Matt Sherman 2023-09-04 16:23:45 -04:00
parent 4f867c6736
commit 7daeb102c5
1 changed files with 1 additions and 1 deletions

View File

@ -63,7 +63,7 @@ Starting with these three broad lifecycle areas, you can begin to break your ext
## Handling activation and deactivation
A common pattern in WooCommerce extensions is to create dedicated functions in your main PHP file to serve as activation and deactivation hooks. You then register these hooks with WordPress using the applicable registration function. This tells WordPess to call the function when the plugin is activated or deactivated. Consider the following examples:
A common pattern in WooCommerce extensions is to create dedicated functions in your main PHP file to serve as activation and deactivation hooks. You then register these hooks with WordPress using the applicable registration function. This tells WordPress to call the function when the plugin is activated or deactivated. Consider the following examples:
```php
function my_extension_activate() {