projects/plugins/jetpack/modules/shortcodes/gist.php 1 location
|
@@ 124-130 (lines=7) @@
|
121 |
|
*/ |
122 |
|
function github_gist_shortcode( $atts, $content = '' ) { |
123 |
|
|
124 |
|
if ( empty( $atts[0] ) && empty( $content ) ) { |
125 |
|
if ( current_user_can( 'edit_posts' ) ) { |
126 |
|
return esc_html__( 'Please specify a Gist URL or ID.', 'jetpack' ); |
127 |
|
} else { |
128 |
|
return '<!-- Missing Gist ID -->'; |
129 |
|
} |
130 |
|
} |
131 |
|
|
132 |
|
$id = ( ! empty( $content ) ) ? $content : $atts[0]; |
133 |
|
|
projects/plugins/jetpack/modules/shortcodes/soundcloud.php 1 location
|
@@ 42-48 (lines=7) @@
|
39 |
|
); |
40 |
|
|
41 |
|
// The "url" option is required. |
42 |
|
if ( empty( $shortcode_options['url'] ) ) { |
43 |
|
if ( current_user_can( 'edit_posts' ) ) { |
44 |
|
return esc_html__( 'Please specify a Soundcloud URL.', 'jetpack' ); |
45 |
|
} else { |
46 |
|
return '<!-- Missing Soundcloud URL -->'; |
47 |
|
} |
48 |
|
} |
49 |
|
|
50 |
|
// Turn shortcode option "param" (param=value¶m2=value) into array of params. |
51 |
|
$shortcode_params = array(); |