Switch language

wpseek.com
Eine auf WordPress spezialiserte Suchmaschine für Entwickler und Theme-Autoren




wp_die [ WordPress Function ]

wp_die ( $message = '', $title = '', $args = array() )
Parameter:
  • (string) $message Error message.
  • (string) $title Error title.
  • (string|array) $args Optional arguments to control behavior.
Definiert in:



Kill WordPress execution and display HTML message with error message.

This function complements the die() PHP function. The difference is that HTML will be displayed to the user. It is recommended to use this function only, when the execution should not continue any further. It is not recommended to call this function very often and try to handle as many errors as possible silently.

Source


<?php
function wp_die$message ''$title ''$args = array() ) {
    if ( 
defined'DOING_AJAX' ) && DOING_AJAX )
        
$function apply_filters'wp_die_ajax_handler''_ajax_wp_die_handler' );
    elseif ( 
defined'XMLRPC_REQUEST' ) && XMLRPC_REQUEST )
        
$function apply_filters'wp_die_xmlrpc_handler''_xmlrpc_wp_die_handler' );
    elseif ( 
defined'APP_REQUEST' ) && APP_REQUEST )
        
$function apply_filters'wp_die_app_handler''_scalar_wp_die_handler' );
    else
        
$function apply_filters'wp_die_handler''_default_wp_die_handler' );

    
call_user_func$function$message$title$args );
}
?>

Beispiele [ wp-snippets.com ]

Top Google Suchergebnisse

Mehr ...

0 Nutzerkommentare

Noch keine. Sei der Erste!

Neu hinzufügen ...



HTML5 Powered with CSS3 / Styling, Performance & Integration, and Semantics