No shortcodes are created, go ahead create one in
shortcoder admin page.';
}else{
foreach( $shortcodes as $name => $options ){
$id = $options[ 'id' ];
$content = $options[ 'content' ];
$settings = $options[ 'settings' ];
$params = array();
preg_match_all( '/%%(.*?)%%/', $content, $matches );
$cp_data = $matches[1];
if( !empty( $cp_data ) ){
$cp_data = array_map( 'strtolower', $cp_data );
foreach( $cp_data as $data ){
$colon_pos = strpos( $data, ':' );
if( $colon_pos === false ){
array_push( $params, array( trim( $data ), false ) );
}else{
$cp_name = substr( $data, 0, $colon_pos );
$cp_default = substr( $data, $colon_pos+1 );
array_push( $params, array( trim( $cp_name ), $cp_default ) );
}
}
}
$enclosed_sc = strpos( $content, '$$enclosed_content$$' ) !== false ? 'true' : 'false';
echo '
';
echo '
';
echo '
 . '/images/arrow.svg)
';
echo '
' . esc_html( $settings[ '_sc_title' ] ) . '
';
echo '
' . esc_html( $settings[ '_sc_description' ] ) . '
';
echo '
';
echo '
';
echo '
';
if( !empty( $params ) ){
echo '
' . esc_html__( 'Available parameters', 'shortcoder' ) . ':
';
echo '
';
$temp = array();
foreach( $params as $k => $v ){
$cleaned = str_replace( '%', '', $v[0] );
if( !in_array( $cleaned, $temp ) ){
array_push( $temp, $cleaned );
echo ' ';
}
}
echo '
';
}else{
echo '
' . esc_html__( 'No parameters present in this shortcode', 'shortcoder' ) . '
';
}
echo '';
echo '
';
echo '
';
}
echo '
' . esc_html__( 'No shortcodes match search term !', 'shortcoder' ) . '
';
}
?>