modules/widgets/blog-stats.php 1 location
|
@@ 115-121 (lines=7) @@
|
112 |
|
* |
113 |
|
* @return array Updated safe values to be saved. |
114 |
|
*/ |
115 |
|
function update( $new_instance, $old_instance ) { |
116 |
|
$instance = array(); |
117 |
|
$instance['title'] = wp_kses( $new_instance['title'], array() ); |
118 |
|
$instance['hits'] = wp_kses( $new_instance['hits'], array() ); |
119 |
|
|
120 |
|
return $instance; |
121 |
|
} |
122 |
|
|
123 |
|
/** |
124 |
|
* Front-end display of widget. |
modules/widgets/google-translate.php 1 location
|
@@ 124-131 (lines=8) @@
|
121 |
|
* |
122 |
|
* @return array $instance Updated safe values to be saved. |
123 |
|
*/ |
124 |
|
public function update( $new_instance, $old_instance ) { |
125 |
|
$instance = array(); |
126 |
|
$instance['title'] = wp_kses( $new_instance['title'], array() ); |
127 |
|
if ( $instance['title'] === $this->default_title ) { |
128 |
|
$instance['title'] = false; // Store as false in case of language change |
129 |
|
} |
130 |
|
return $instance; |
131 |
|
} |
132 |
|
|
133 |
|
} |
134 |
|
|