wpseek.com
Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren
delete_blog_option › WordPress Function
Seit
Veraltetn/v
› delete_blog_option ( $id, $option )
| Parameter: (2) |
|
| Gibt zurück: |
|
| Definiert in: |
|
| Codex: | |
| Changelog: |
|
Removes an option by name for a given blog ID. Prevents removal of protected WordPress options.
Ähnliche Funktionen: get_blog_option, delete_option, update_blog_option, add_blog_option, delete_site_option
Quellcode
function delete_blog_option( $id, $option ) {
$id = (int) $id;
if ( empty( $id ) ) {
$id = get_current_blog_id();
}
if ( get_current_blog_id() === $id ) {
return delete_option( $option );
}
switch_to_blog( $id );
$return = delete_option( $option );
restore_current_blog();
return $return;
}