wp-content/plugins/contact-form-7-multi-step-module/cf7msm.php
/**
 * Go through a wpcf7 form's formstring and find the multistep url.
 * If $steps is true, return the steps part as "<curr>-<total>", otherwise return the url.
 */
Go through a wpcf7 form's formstring and find the multistep url.
If $steps is true, return the steps part as "-", otherwise return the url.
Go through a wpcf7 form ' s formstring and find the multistep url . If $steps is true return the steps part as " - " otherwise return the url .
function parse_form_for_multistep( $wpcf7, $steps = false )
{
    $formstring = $wpcf7->prop( 'form' );
    if ( preg_match( '/\\[multistep "(\\d+)-(\\d+)-(.+)"\\]/', $formstring, $matches ) ) {
        if ( $steps ) {
            if ( !empty($matches[1]) && !empty($matches[2]) ) {
                return $matches[1] . '-' . $matches[2];
            }
        } else {
            if ( !empty($matches[3]) ) {
                return $matches[3];
            }
        }
    }
    return '';
}
function parse_form_for_multistep ( $ wpcf7 , $ steps = false ) { $ formstring = $ wpcf7 -> prop ( 'form' ) ; if ( preg_match ( '/\\[multistep "(\\d+)-(\\d+)-(.+)"\\]/' , $ formstring , $ matches ) ) { if ( $ steps ) { if ( ! empty ( $ matches [ 1 ] ) && ! empty ( $ matches [ 2 ] ) ) { return $ matches [ 1 ] . '-' . $ matches [ 2 ] ; } } else { if ( ! empty ( $ matches [ 3 ] ) ) { return $ matches [ 3 ] ; } } } return '' ; }
Go through a wpcf7 form's formstring and find the multistep url.
Go through a wpcf7 form ' s formstring and find the multistep url .