Skip to content
This repository was archived by the owner on May 2, 2018. It is now read-only.

Commit c88d05b

Browse files
committed
working on #29
2 parents 299b34a + 9a7d3c5 commit c88d05b

2 files changed

Lines changed: 5 additions & 6 deletions

File tree

admin/includes/cmb2-extra.php

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ function ds_cmb_render_multicheck_posttype( $field, $escaped_value, $object_id,
1212
$options = '';
1313
$i = 1;
1414
$values = ( array ) $escaped_value;
15-
1615
if ( $cpts ) {
1716
foreach ( $cpts as $cpt ) {
1817
$args = array(
@@ -29,6 +28,7 @@ function ds_cmb_render_multicheck_posttype( $field, $escaped_value, $object_id,
2928
} else {
3029
$options .= $field_type_object->list_input( $args, $i );
3130
}
31+
$options .= $field_type_object->list_input( $args, $i );
3232
$i++;
3333
}
3434
}
@@ -47,6 +47,5 @@ function sm_cmb_render_text_number( $field, $escaped_value, $object_id, $object_
4747

4848
function sm_cmb2_sanitize_text_number( $null, $new ) {
4949
$new = preg_replace( "/[^0-9]/", "", $new );
50-
5150
return $new;
5251
}

public/class-glossary.php

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -255,18 +255,18 @@ public function glossary_auto_link( $text ) {
255255
$words[] = $this->search_string( get_the_title() );
256256
if ( isset( $this->settings[ 'tooltip' ] ) ) {
257257
global $post;
258-
$links[] = $this->tooltip_html( $link, get_the_title(), $post, $target, $nofollow, $internal );
258+
$links[] = $this->tooltip_html( $link, '$0', $post, $target, $nofollow, $internal );
259259
} else {
260-
$links[] = '<a href="' . $link . '"' . $target . $nofollow . '>' . get_the_title() . '</a>';
260+
$links[] = '<a href="' . $link . '"' . $target . $nofollow . '>$0</a>';
261261
}
262262
$related = $this->related_post_meta( get_post_meta( get_the_ID(), $this->get_plugin_slug() . '_tag', true ) );
263263
if ( is_array( $related ) ) {
264264
foreach ( $related as $value ) {
265265
$words[] = $this->search_string( $value );
266266
if ( isset( $this->settings[ 'tooltip' ] ) ) {
267-
$links[] = $this->tooltip_html( $link, $value, $post, $target, $nofollow, $internal );
267+
$links[] = $this->tooltip_html( $link, '$0', $post, $target, $nofollow, $internal );
268268
} else {
269-
$links[] = '<a href="' . $link . '"' . $target . $nofollow . '>' . $value . '</a>';
269+
$links[] = '<a href="' . $link . '"' . $target . $nofollow . '>$0</a>';
270270
}
271271
}
272272
}

0 commit comments

Comments
 (0)