Function Reference: geodir_in_plugin_update_message

Summary

This function has not been documented yet.

Source File

geodir_in_plugin_update_message() is located in geodirectory-admin/admin_functions.php [Line: 6194]

Source Code

function geodir_in_plugin_update_message($content) {
    // Output Upgrade Notice
    $matches        = null;
    $regexp         = '~==\s*Upgrade Notice\s*==\s*=\s*(.*)\s*=(.*)(=\s*' . preg_quote( GEODIRECTORY_VERSION ) . '\s*=|$)~Uis';
    $upgrade_notice = '';
    if ( preg_match( $regexp, $content, $matches ) ) {
        if(empty($matches)){return;}

        $version = trim( $matches[1] );
        if($version && $version>GEODIRECTORY_VERSION){


        $notices = (array) preg_split('~[\r\n]+~', trim( $matches[2] ) );
        if ( version_compare( GEODIRECTORY_VERSION, $version, '<' ) ) {
            $upgrade_notice .= '
'; foreach ( $notices as $index => $line ) { $upgrade_notice .= wp_kses_post( preg_replace( '~\[([^\]]*)\]\(([^\)]*)\)~', '${1}', $line ) ); } $upgrade_notice .= '
'; } } } echo $upgrade_notice; }