Version Description
Download this release
Release Info
| Developer | Bueltge |
| Plugin | |
| Version | 4.4.16 |
| Comparing to | |
| See all releases | |
Code changes from version 4.4.15 to 4.4.16
- readme.txt +5 -2
- rssimport.php +1438 -1440
readme.txt
CHANGED
|
@@ -6,8 +6,8 @@ Author URI: http://bueltge.de/
|
|
| 6 |
Donate link: http://bueltge.de/wunschliste/
|
| 7 |
Tags: rss, post, content, post, feed
|
| 8 |
Requires at least: 1.5
|
| 9 |
-
Tested up to: 4.
|
| 10 |
-
Stable tag: 4.4.
|
| 11 |
|
| 12 |
Import and display feeds on your blog, using PHP in your templates or Shortcode in your posts and pages.
|
| 13 |
|
|
@@ -142,6 +142,9 @@ or
|
|
| 142 |
1. Widget support
|
| 143 |
|
| 144 |
== Changelog ==
|
|
|
|
|
|
|
|
|
|
| 145 |
= v4.4.15 (08/22/2014) =
|
| 146 |
* Added `%picture_url%` for `before_desc`, `after_desc`, `start_item` and `end_item`
|
| 147 |
|
| 6 |
Donate link: http://bueltge.de/wunschliste/
|
| 7 |
Tags: rss, post, content, post, feed
|
| 8 |
Requires at least: 1.5
|
| 9 |
+
Tested up to: 4.4
|
| 10 |
+
Stable tag: 4.4.16
|
| 11 |
|
| 12 |
Import and display feeds on your blog, using PHP in your templates or Shortcode in your posts and pages.
|
| 13 |
|
| 142 |
1. Widget support
|
| 143 |
|
| 144 |
== Changelog ==
|
| 145 |
+
= v4.4.16 (09/24/2015) =
|
| 146 |
+
* Fix the widget PHP4 style
|
| 147 |
+
|
| 148 |
= v4.4.15 (08/22/2014) =
|
| 149 |
* Added `%picture_url%` for `before_desc`, `after_desc`, `start_item` and `end_item`
|
| 150 |
|
rssimport.php
CHANGED
|
@@ -1,1441 +1,1439 @@
|
|
| 1 |
-
<?php
|
| 2 |
-
/**
|
| 3 |
-
* @package WP-RSSImport
|
| 4 |
-
* @author Frank
|
| 5 |
-
|
| 6 |
-
|
| 7 |
-
|
| 8 |
-
|
| 9 |
-
* Plugin
|
| 10 |
-
*
|
| 11 |
-
*
|
| 12 |
-
*
|
| 13 |
-
*
|
| 14 |
-
*
|
| 15 |
-
*
|
| 16 |
-
*
|
| 17 |
-
|
| 18 |
-
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
-
|
| 27 |
-
|
| 28 |
-
|
| 29 |
-
|
| 30 |
-
|
| 31 |
-
|
| 32 |
-
|
| 33 |
-
|
| 34 |
-
|
| 35 |
-
|
| 36 |
-
|
| 37 |
-
|
| 38 |
-
header('
|
| 39 |
-
|
| 40 |
-
|
| 41 |
-
|
| 42 |
-
|
| 43 |
-
|
| 44 |
-
|
| 45 |
-
|
| 46 |
-
|
| 47 |
-
|
| 48 |
-
|
| 49 |
-
|
| 50 |
-
|
| 51 |
-
|
| 52 |
-
|
| 53 |
-
|
| 54 |
-
|
| 55 |
-
|
| 56 |
-
|
| 57 |
-
|
| 58 |
-
|
| 59 |
-
define( '
|
| 60 |
-
define( '
|
| 61 |
-
define( '
|
| 62 |
-
|
| 63 |
-
|
| 64 |
-
|
| 65 |
-
|
| 66 |
-
|
| 67 |
-
|
| 68 |
-
|
| 69 |
-
|
| 70 |
-
|
| 71 |
-
|
| 72 |
-
|
| 73 |
-
|
| 74 |
-
|
| 75 |
-
|
| 76 |
-
|
| 77 |
-
|
| 78 |
-
|
| 79 |
-
|
| 80 |
-
|
| 81 |
-
|
| 82 |
-
|
| 83 |
-
|
| 84 |
-
//
|
| 85 |
-
|
| 86 |
-
|
| 87 |
-
|
| 88 |
-
//
|
| 89 |
-
|
| 90 |
-
|
| 91 |
-
|
| 92 |
-
$
|
| 93 |
-
$
|
| 94 |
-
$
|
| 95 |
-
$
|
| 96 |
-
$
|
| 97 |
-
$
|
| 98 |
-
$
|
| 99 |
-
$
|
| 100 |
-
$
|
| 101 |
-
$
|
| 102 |
-
$
|
| 103 |
-
$
|
| 104 |
-
$
|
| 105 |
-
$
|
| 106 |
-
$
|
| 107 |
-
$
|
| 108 |
-
$
|
| 109 |
-
$
|
| 110 |
-
$
|
| 111 |
-
$
|
| 112 |
-
$
|
| 113 |
-
$
|
| 114 |
-
$
|
| 115 |
-
$
|
| 116 |
-
$
|
| 117 |
-
$
|
| 118 |
-
$
|
| 119 |
-
$
|
| 120 |
-
$
|
| 121 |
-
$
|
| 122 |
-
$
|
| 123 |
-
$
|
| 124 |
-
$
|
| 125 |
-
$
|
| 126 |
-
$
|
| 127 |
-
$
|
| 128 |
-
$
|
| 129 |
-
$
|
| 130 |
-
|
| 131 |
-
|
| 132 |
-
|
| 133 |
-
|
| 134 |
-
|
| 135 |
-
|
| 136 |
-
$
|
| 137 |
-
$
|
| 138 |
-
$
|
| 139 |
-
$
|
| 140 |
-
$
|
| 141 |
-
$
|
| 142 |
-
|
| 143 |
-
|
| 144 |
-
$
|
| 145 |
-
$
|
| 146 |
-
$
|
| 147 |
-
$
|
| 148 |
-
$
|
| 149 |
-
|
| 150 |
-
|
| 151 |
-
|
| 152 |
-
|
| 153 |
-
|
| 154 |
-
|
| 155 |
-
|
| 156 |
-
|
| 157 |
-
|
| 158 |
-
|
| 159 |
-
|
| 160 |
-
|
| 161 |
-
|
| 162 |
-
|
| 163 |
-
|
| 164 |
-
|
| 165 |
-
|
| 166 |
-
|
| 167 |
-
|
| 168 |
-
|
| 169 |
-
|
| 170 |
-
|
| 171 |
-
|
| 172 |
-
$
|
| 173 |
-
$
|
| 174 |
-
$
|
| 175 |
-
|
| 176 |
-
|
| 177 |
-
$echo = '<!--via SimplePie with RSSImport-->';
|
| 178 |
-
else
|
| 179 |
-
$echo = '<!--via MagpieRSS with RSSImport-->';
|
| 180 |
-
|
| 181 |
-
if ($charsetscan) {
|
| 182 |
-
// read in file for search charset
|
| 183 |
-
if ( function_exists('file_get_contents') ) {
|
| 184 |
-
ini_set('default_socket_timeout', 10);
|
| 185 |
-
$a = file_get_contents($feedurl);
|
| 186 |
-
// for better performance, if the server accepts the method
|
| 187 |
-
// $a = file_get_contents($feedurl, FALSE, NULL, 0, 50);
|
| 188 |
-
}
|
| 189 |
-
}
|
| 190 |
-
|
| 191 |
-
if ($use_simplepie)
|
| 192 |
-
$rss = fetch_feed($feedurl);
|
| 193 |
-
else
|
| 194 |
-
$rss = fetch_rss($feedurl);
|
| 195 |
-
|
| 196 |
-
if ( $rss && ! is_wp_error($rss) ) {
|
| 197 |
-
|
| 198 |
-
// the follow print_r list all items in array, for debug purpose
|
| 199 |
-
if ( $debug ) {
|
| 200 |
-
print('FeedURL: ' . $feedurl);
|
| 201 |
-
print('<pre>');
|
| 202 |
-
print_r($rss);
|
| 203 |
-
print('</pre>');
|
| 204 |
-
if ( ! defined('MAGPIE_CACHE_ON') )
|
| 205 |
-
define('MAGPIE_CACHE_ON', FALSE);
|
| 206 |
-
}
|
| 207 |
-
|
| 208 |
-
if ( isset($target) && $target != '' )
|
| 209 |
-
$target = ' target="_' . $target . '"';
|
| 210 |
-
|
| 211 |
-
if ( isset($rel) && $rel != '' )
|
| 212 |
-
$rel = ' rel="' . $rel . '"';
|
| 213 |
-
|
| 214 |
-
$displayitems = $display;
|
| 215 |
-
$displaylimit = ($page * $display);
|
| 216 |
-
$display = (($page-1) * $display);
|
| 217 |
-
$nextitems = TRUE;
|
| 218 |
-
$previousitems = FALSE;
|
| 219 |
-
if ( $page > 1 )
|
| 220 |
-
$previousitems = TRUE;
|
| 221 |
-
|
| 222 |
-
while($display < $displaylimit) {
|
| 223 |
-
|
| 224 |
-
if ( $use_simplepie && (1 ==$paging) )
|
| 225 |
-
$items = $rss->get_items();
|
| 226 |
-
elseif ($use_simplepie)
|
| 227 |
-
$items = $rss->get_items(0, $displayitems);
|
| 228 |
-
else
|
| 229 |
-
$items = $rss->items;
|
| 230 |
-
|
| 231 |
-
if ( array_key_exists( $display, $items ) ) {
|
| 232 |
-
|
| 233 |
-
if ($use_simplepie)
|
| 234 |
-
$item = $rss->get_item($display);
|
| 235 |
-
else
|
| 236 |
-
$item = $rss->items[$display];
|
| 237 |
-
// import title
|
| 238 |
-
if ($use_simplepie)
|
| 239 |
-
$title = esc_attr( strip_tags( $item->get_title() ) );
|
| 240 |
-
elseif ( isset($item['title']) )
|
| 241 |
-
$title = esc_attr( strip_tags( $item['title'] ) );
|
| 242 |
-
// import link
|
| 243 |
-
if ($use_simplepie)
|
| 244 |
-
$href = wp_filter_kses( $item->get_link() );
|
| 245 |
-
elseif ( isset($item['link']) )
|
| 246 |
-
$href = wp_filter_kses( $item['link'] );
|
| 247 |
-
// import picture_url
|
| 248 |
-
$picture_url = '';
|
| 249 |
-
if ($use_simplepie) {
|
| 250 |
-
if ( $enclosure = $item->get_enclosure() ) {
|
| 251 |
-
$picture_url = wp_filter_kses( $enclosure->get_thumbnail() );
|
| 252 |
-
}
|
| 253 |
-
}
|
| 254 |
-
|
| 255 |
-
$start_item_temp = str_replace('%title%', $title, $start_item);
|
| 256 |
-
$start_item_temp = str_replace('%href%', $href, $start_item_temp);
|
| 257 |
-
$start_item_temp = str_replace('%picture_url%', $picture_url, $start_item_temp);
|
| 258 |
-
$echo .= $start_item_temp;
|
| 259 |
-
|
| 260 |
-
// import date
|
| 261 |
-
if ($use_simplepie && $date)
|
| 262 |
-
$pubDate = date_i18n( $date_format, strtotime( $item->get_date() ) );
|
| 263 |
-
elseif ($date && isset($item['pubdate']) )
|
| 264 |
-
$pubDate = date_i18n( $date_format, strtotime( $item['pubdate'] ) );
|
| 265 |
-
// import creator
|
| 266 |
-
if ($use_simplepie && $creator) {
|
| 267 |
-
$creator = $item->get_author();
|
| 268 |
-
if ( is_object($creator) ) {
|
| 269 |
-
$creator = $creator->get_name();
|
| 270 |
-
$creator = ' <cite>' . esc_html( strip_tags( $creator ) ) . '</cite>';
|
| 271 |
-
}
|
| 272 |
-
} elseif ($creator && isset($item['dc']['creator']) ) {
|
| 273 |
-
$creator = wp_specialchars( $item['dc']['creator'] );
|
| 274 |
-
} elseif ($creator && isset($item['creator']) ) {
|
| 275 |
-
$creator = wp_specialchars( $item['creator'] );
|
| 276 |
-
}
|
| 277 |
-
// import desc
|
| 278 |
-
if ( $use_simplepie && $displaydescriptions && $html )
|
| 279 |
-
$desc = @html_entity_decode( $item->get_content(), ENT_QUOTES, get_option('blog_charset') ); // For import with HTML
|
| 280 |
-
elseif ( $use_simplepie && $displaydescriptions && !$html )
|
| 281 |
-
$desc = str_replace( array("\n", "\r"), ' ', esc_attr( strip_tags( @html_entity_decode( $item->get_description(), ENT_QUOTES, get_option('blog_charset') ) ) ) ); // For import without HTML
|
| 282 |
-
elseif ( $displaydescriptions && $html && isset($item['content']['encoded']) && $item['content']['encoded'] != 'A' )
|
| 283 |
-
$desc = $item['content']['encoded']; // For import with HTML
|
| 284 |
-
elseif ( $displaydescriptions && $html && isset($item['content']['atom_content']) && $item['content']['atom_content'] != 'A' )
|
| 285 |
-
$desc = $item['content']['atom_content']; // For import with HTML
|
| 286 |
-
elseif ( $displaydescriptions && $html && isset($item['content']) && !is_array($item['content']) )
|
| 287 |
-
$desc = $item['content'];
|
| 288 |
-
elseif ( $displaydescriptions && $html && isset($item['description']) )
|
| 289 |
-
$desc = $item['description'];
|
| 290 |
-
elseif ( $displaydescriptions && !$html && isset($item['description']) )
|
| 291 |
-
$desc = wp_specialchars(strip_tags($item['description'])); // For import without HTML
|
| 292 |
-
|
| 293 |
-
if ( isset($a) && eregi('ISO', $a) ) {
|
| 294 |
-
if ($debug)
|
| 295 |
-
$echo .= 'ISO Feed' . "\n";
|
| 296 |
-
if ( isset($title) )
|
| 297 |
-
isodec($title);
|
| 298 |
-
if ( isset($creator) )
|
| 299 |
-
isodec($creator);
|
| 300 |
-
if ( isset($desc) )
|
| 301 |
-
isodec($desc);
|
| 302 |
-
} else {
|
| 303 |
-
if ($debug)
|
| 304 |
-
$echo .= 'NonISO Feed' . "\n";
|
| 305 |
-
if ( isset($title) )
|
| 306 |
-
utf8dec($title);
|
| 307 |
-
if ( isset($creator) )
|
| 308 |
-
utf8dec($creator);
|
| 309 |
-
if ( isset($desc) )
|
| 310 |
-
utf8dec($desc);
|
| 311 |
-
}
|
| 312 |
-
|
| 313 |
-
if ( isset($title) )
|
| 314 |
-
all_convert($title);
|
| 315 |
-
if ( isset($creator) )
|
| 316 |
-
all_convert($creator);
|
| 317 |
-
if ( isset($desc) )
|
| 318 |
-
all_convert($desc);
|
| 319 |
-
|
| 320 |
-
if ( isset($title) && $truncatetitlechar && (strlen($title) > $truncatetitlechar) ) {
|
| 321 |
-
$title = wp_html_excerpt($title, $truncatetitlechar) . $truncatetitlestring;
|
| 322 |
-
}
|
| 323 |
-
|
| 324 |
-
if ( isset($desc) && $truncatedescchar && (strlen($desc) > $truncatedescchar) ) {
|
| 325 |
-
$desc = wp_html_excerpt($desc, $truncatedescchar) . $truncatedescstring;
|
| 326 |
-
}
|
| 327 |
-
|
| 328 |
-
if ( $desc4title ) {
|
| 329 |
-
if ($use_simplepie)
|
| 330 |
-
$desc = str_replace( array("\n", "\r"), ' ', esc_attr( strip_tags( @html_entity_decode( $item->get_description(), ENT_QUOTES, get_option('blog_charset') ) ) ) ); // For import without HTML
|
| 331 |
-
else if (isset($item['description']))
|
| 332 |
-
$desc = wp_specialchars(strip_tags($item['description']));
|
| 333 |
-
else
|
| 334 |
-
$desc ='';
|
| 335 |
-
$atitle = wp_html_excerpt($desc, $truncatedescchar) . $truncatedescstring;
|
| 336 |
-
} else {
|
| 337 |
-
$atitle = $title;
|
| 338 |
-
}
|
| 339 |
-
|
| 340 |
-
$echo .= '<a' . $target . $rel . ' href="' . $href . '" title="'. $atitle . '">' . $title . '</a>';
|
| 341 |
-
if ( isset($pubDate) && $date && $pubDate != '' )
|
| 342 |
-
$echo .= $before_date . $pubDate . $after_date;
|
| 343 |
-
if ( isset($creator) && $creator && $creator != '' )
|
| 344 |
-
$echo .= $before_creator . $creator . $after_creator;
|
| 345 |
-
if ( isset($desc) && $displaydescriptions && $desc != '' ) {
|
| 346 |
-
$after_desc_temp = stripslashes_deep( $after_desc );
|
| 347 |
-
$after_desc_temp = str_replace('%title%', $title, $after_desc_temp);
|
| 348 |
-
$after_desc_temp = str_replace('%href%', $href, $after_desc_temp);
|
| 349 |
-
$after_desc_temp = str_replace('%picture_url%', $picture_url, $after_desc_temp);
|
| 350 |
-
$before_desc_temp = str_replace('%title%', $title, $before_desc);
|
| 351 |
-
$before_desc_temp = str_replace('%href%', $href, $before_desc_temp);
|
| 352 |
-
$before_desc_temp = str_replace('%picture_url%', $picture_url, $before_desc_temp);
|
| 353 |
-
$echo .= $before_desc_temp . $desc . $after_desc_temp;
|
| 354 |
-
}
|
| 355 |
-
$end_item_temp = str_replace('%title%', $title, $end_item);
|
| 356 |
-
$end_item_temp = str_replace('%href%', $href, $end_item_temp);
|
| 357 |
-
$end_item_temp = str_replace('%picture_url%', $picture_url, $end_item_temp);
|
| 358 |
-
$echo .= $end_item_temp;
|
| 359 |
-
} else {
|
| 360 |
-
$nextitems = FALSE;
|
| 361 |
-
}
|
| 362 |
-
|
| 363 |
-
$display++;
|
| 364 |
-
}
|
| 365 |
-
|
| 366 |
-
if (strip_tags($echo)) { // novaclic: needed to filter out false content madeof tags alone (html comments, html tags, ...)
|
| 367 |
-
$echo = wptexturize($start_items . $echo . $end_items);
|
| 368 |
-
} else
|
| 369 |
-
$echo = wptexturize($before_noitems . $noitems . $after_noitems);
|
| 370 |
-
|
| 371 |
-
} else {
|
| 372 |
-
if ( empty($rss->ERROR) )
|
| 373 |
-
$rss->ERROR = NULL;
|
| 374 |
-
$echo = wptexturize($before_error . $error . $rss->ERROR . $after_error);
|
| 375 |
-
}
|
| 376 |
-
|
| 377 |
-
if ($paging) {
|
| 378 |
-
$echo .= '<div class="rsspaging">';
|
| 379 |
-
if ($previousitems)
|
| 380 |
-
$echo .= '<a href="' . add_query_arg( 'rsspage', ($page-1) ) . '" class="rsspaging_prev" title="' . $prev_paging_title . '">' . $prev_paging_link . '</a>';
|
| 381 |
-
if ($nextitems)
|
| 382 |
-
$echo .= '<a href="' . add_query_arg( 'rsspage', ($page+1) ) . '" class="rsspaging_next" title="' . $next_paging_title . '">' . $next_paging_link .'</a>';
|
| 383 |
-
$echo .= '<br style="clear: both" />';
|
| 384 |
-
$echo .= '</div>';
|
| 385 |
-
}
|
| 386 |
-
|
| 387 |
-
if ($view)
|
| 388 |
-
echo $echo;
|
| 389 |
-
else
|
| 390 |
-
return $echo;
|
| 391 |
-
}
|
| 392 |
-
|
| 393 |
-
function utf8dec($s_String) {
|
| 394 |
-
if ( version_compare(phpversion(), '5.0.0', '>=') )
|
| 395 |
-
$s_String = html_entity_decode(htmlentities( $s_String." ", ENT_COMPAT, 'UTF-8') );
|
| 396 |
-
else
|
| 397 |
-
$s_String = RSSImport_html_entity_decode_php4( htmlentities($s_String." ") );
|
| 398 |
-
return substr($s_String, 0, strlen($s_String)-1);
|
| 399 |
-
}
|
| 400 |
-
|
| 401 |
-
function isodec($s_String) {
|
| 402 |
-
if ( version_compare(phpversion(), '5.0.0', '>=') )
|
| 403 |
-
$s_String = html_entity_decode(htmlentities($s_String." ", ENT_COMPAT, 'ISO-8859-1'));
|
| 404 |
-
else
|
| 405 |
-
$s_String = RSSImport_html_entity_decode_php4( htmlentities($s_String." ") );
|
| 406 |
-
return substr($s_String, 0, strlen($s_String)-1);
|
| 407 |
-
}
|
| 408 |
-
|
| 409 |
-
function all_convert($s_String) {
|
| 410 |
-
|
| 411 |
-
// Array for entities
|
| 412 |
-
$umlaute = array('„','“','–',' \"','–','—','‘','’','“','”','„','•','…' ,
|
| 413 |
-
'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,
|
| 414 |
-
'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�','�','�','�','�','�','�','�','�',
|
| 415 |
-
'�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�',
|
| 416 |
-
'�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�',
|
| 417 |
-
'�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�',utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 418 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 419 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 420 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 421 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 422 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 423 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 424 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 425 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 426 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 427 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 428 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 429 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 430 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 431 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 432 |
-
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),chr(128),chr(129),chr(130),
|
| 433 |
-
chr(131),chr(132),chr(133),chr(134),chr(135),chr(136),chr(137),chr(138),chr(139),chr(140),chr(141),chr(142),chr(143),chr(144),chr(145),
|
| 434 |
-
chr(146),chr(147),chr(148),chr(149),chr(150),chr(151),chr(152),chr(153),chr(154),chr(155),chr(156),chr(157),chr(158),chr(159),chr(160),
|
| 435 |
-
chr(161),chr(162),chr(163),chr(164),chr(165),chr(166),chr(167),chr(168),chr(169),chr(170),chr(171),chr(172),chr(173),chr(174),chr(175),
|
| 436 |
-
chr(176),chr(177),chr(178),chr(179),chr(180),chr(181),chr(182),chr(183),chr(184),chr(185),chr(186),chr(187),chr(188),chr(189),chr(190),
|
| 437 |
-
chr(191),chr(192),chr(193),chr(194),chr(195),chr(196),chr(197),chr(198),chr(199),chr(200),chr(201),chr(202),chr(203),chr(204),chr(205),
|
| 438 |
-
chr(206),chr(207),chr(208),chr(209),chr(210),chr(211),chr(212),chr(213),chr(214),chr(215),chr(216),chr(217),chr(218),chr(219),chr(220),
|
| 439 |
-
chr(221),chr(222),chr(223),chr(224),chr(225),chr(226),chr(227),chr(228),chr(229),chr(230),chr(231),chr(232),chr(233),chr(234),chr(235),
|
| 440 |
-
chr(236),chr(237),chr(238),chr(239),chr(240),chr(241),chr(242),chr(243),chr(244),chr(245),chr(246),chr(247),chr(248),chr(249),chr(250),
|
| 441 |
-
chr(251),chr(252),chr(253),chr(254),chr(255),chr(256));
|
| 442 |
-
$htmlcode = array('„','“','–',' "','–','—','‘','’','“','”','„','•' ,
|
| 443 |
-
'…','€','‚','ƒ','„','…','†','‡','ˆ','‰','Š','‹','Œ',
|
| 444 |
-
'Ž','‘','’','“','”','•','–','—','˜','™','š','›','œ',
|
| 445 |
-
'ž','Ÿ','¡','¢','£','¤','¥','¦','§','¨','©','ª','«','¬',
|
| 446 |
-
'®','¯','°','±','²','³','´','µ','¶','·','¸','&supl;','º','»',
|
| 447 |
-
'¼','½','¾','¿','À','Á','Â','Ã','Ä','Å','Æ','Ç','È',
|
| 448 |
-
'É','Ê','Ë','Ì','Í','Î','Ï','Ð','Ñ','Ò','Ó','Ô','Õ',
|
| 449 |
-
'Ö','×','Ø','Ù','Ú','Û','Ü','Ý','Þ','ß','à','á','â',
|
| 450 |
-
'ã','ä','å','æ','ç','è','é','ê','ë','ì','í','î','ï',
|
| 451 |
-
'ð','ñ','ò','ó','ô','õ','ö','÷','ø','ù','ú','û','ü',
|
| 452 |
-
'ý','þ','ÿ','€','‚','ƒ','„','…','†','‡','ˆ','‰','Š',
|
| 453 |
-
'‹','Œ','Ž','‘','’','“','”','•','–','—','˜','™','š',
|
| 454 |
-
'›','œ','ž','Ÿ','¡','¢','£','¤','¥','¦','§','¨','©','ª',
|
| 455 |
-
'«','¬','®','¯','°','±','²','³','´','µ','¶','·','¸','&supl;',
|
| 456 |
-
'º','»','¼','½','¾','¿','À','Á','Â','Ã','Ä','Å','Æ',
|
| 457 |
-
'Ç','È','É','Ê','Ë','Ì','Í','Î','Ï','Ð','Ñ','Ò','Ó',
|
| 458 |
-
'Ô','Õ','Ö','×','Ø','Ù','Ú','Û','Ü','Ý','Þ','ß','à',
|
| 459 |
-
'á','â','ã','ä','å','æ','ç','è','é','ê','ë','ì','í',
|
| 460 |
-
'î','ï','ð','ñ','ò','ó','ô','õ','ö','÷','ø','ù','ú',
|
| 461 |
-
'û','ü','ý','þ','ÿ','€','','‚','ƒ','„','…','†','‡','ˆ',
|
| 462 |
-
'‰','Š','‹','Œ','','Ž','','','‘','’','“','”','•','–','—',
|
| 463 |
-
'˜','™','š','›','œ','','ž','Ÿ',' ','¡','¡','¡','¡','¥',
|
| 464 |
-
'¦','§','¨','©','ª','«','¬','�­','®','¯','°','±','²','³',
|
| 465 |
-
'´','µ','¶','·','¸','&supl;','º','»','¼','½','¾','¿','À',
|
| 466 |
-
'Á','Â','Ã','Ä','Å','Æ','Ç','È','É','Ê','Ë','Ì','Í',
|
| 467 |
-
'Î','Ï','Ð','Ñ','Ò','Ó','Ô','Õ','Ö','×','Ø','Ù','Ú',
|
| 468 |
-
'Û','Ü','Ý','Þ','ß','à','á','â','ã','ä','å','æ','ç',
|
| 469 |
-
'è','é','ê','ë','ì','í','î','ï','ð','ñ','ò','ó','ô',
|
| 470 |
-
'õ','ö','÷','ø','ù','ú','û','ü','ý','þ','ÿ');
|
| 471 |
-
//$s_String = str_replace($umlaute, $htmlcode, $s_String);
|
| 472 |
-
if ( version_compare(phpversion(), '5.0.0', '>=') )
|
| 473 |
-
$s_String = utf8_encode( html_entity_decode( str_replace($umlaute, $htmlcode, $s_String) ) );
|
| 474 |
-
else
|
| 475 |
-
$s_String = utf8_encode( RSSImport_html_entity_decode_php4( str_replace($umlaute, $htmlcode, $s_String) ) );
|
| 476 |
-
|
| 477 |
-
// … , …
|
| 478 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xC2\xA6~', '…', $s_String);
|
| 479 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x82\xC2\xA6~', '…', $s_String);
|
| 480 |
-
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xC2\xA6~', '…', $s_String);
|
| 481 |
-
|
| 482 |
-
// — , —
|
| 483 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xE2\x80\x9D~', '—', $s_String);
|
| 484 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\xA2\xE2\x82\xAC\xC2\x9D~', '—', $s_String);
|
| 485 |
-
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xE2\x80\x9D~', '—', $s_String);
|
| 486 |
-
|
| 487 |
-
// – , –
|
| 488 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xE2\x80\x9C~', '–', $s_String);
|
| 489 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\xA2\xE2\x82\xAC\xC5\x93~', '–', $s_String);
|
| 490 |
-
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xE2\x80\x9C~', '–', $s_String);
|
| 491 |
-
|
| 492 |
-
// ’ , ’
|
| 493 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xE2\x84\xA2~', '’', $s_String);
|
| 494 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\xA2\xE2\x80\x9E\xC2\xA2~', '’', $s_String);
|
| 495 |
-
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xE2\x84\xA2~', '’', $s_String);
|
| 496 |
-
$s_String = preg_replace('~\xD0\xBF\xD1\x97\xD0\x85~', '’', $s_String);
|
| 497 |
-
|
| 498 |
-
// ‘ , ‘
|
| 499 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xCB\x9C~', '‘', $s_String);
|
| 500 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x8B\xC5\x93~', '‘', $s_String);
|
| 501 |
-
|
| 502 |
-
// ” , ”
|
| 503 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xC2\x9D~', '”', $s_String);
|
| 504 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x82\xC2\x9D~', '”', $s_String);
|
| 505 |
-
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xD1\x9C~', '”', $s_String);
|
| 506 |
-
|
| 507 |
-
// “ , “
|
| 508 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xC5\x93~', '“', $s_String);
|
| 509 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x85\xE2\x80\x9C~', '“', $s_String);
|
| 510 |
-
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xD1\x9A~', '“', $s_String);
|
| 511 |
-
|
| 512 |
-
// ™ , ™
|
| 513 |
-
$s_String = preg_replace('~\xC3\xA2\xE2\x80\x9E\xC2\xA2~', '™', $s_String);
|
| 514 |
-
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x82\xAC\xC5\xBE\xC3\x82\xC2\xA2~', '™', $s_String);
|
| 515 |
-
|
| 516 |
-
// th
|
| 517 |
-
$s_String = preg_replace('~t\xC3\x82\xC2\xADh~', 'th', $s_String);
|
| 518 |
-
|
| 519 |
-
// .
|
| 520 |
-
$s_String = preg_replace('~.\xD0\x92+~', '.', $s_String);
|
| 521 |
-
$s_String = preg_replace('~.\xD0\x92~', '.', $s_String);
|
| 522 |
-
|
| 523 |
-
// ,
|
| 524 |
-
$s_String = preg_replace('~\x2C\xD0\x92~', ',', $s_String);
|
| 525 |
-
|
| 526 |
-
return $s_String;
|
| 527 |
-
}
|
| 528 |
-
|
| 529 |
-
/**
|
| 530 |
-
* Entfernt unvollstaendige Worte am Ende eines Strings.
|
| 531 |
-
* @author Thomas Scholz <http://toscho.de>
|
| 532 |
-
* @param $str Zeichenkette
|
| 533 |
-
* @return string
|
| 534 |
-
*/
|
| 535 |
-
function RSSImport_end_on_word($str) {
|
| 536 |
-
|
| 537 |
-
$arr = explode( ' ', trim($str) );
|
| 538 |
-
array_pop($arr);
|
| 539 |
-
|
| 540 |
-
return rtrim( implode(' ', $arr), ',;');
|
| 541 |
-
}
|
| 542 |
-
|
| 543 |
-
function RSSImport_Shortcode($atts) {
|
| 544 |
-
extract(
|
| 545 |
-
shortcode_atts( array(
|
| 546 |
-
'display' => 5,
|
| 547 |
-
'feedurl' => 'http://bueltge.de/feed/',
|
| 548 |
-
'before_desc' => '<br />',
|
| 549 |
-
'displaydescriptions' => 0,
|
| 550 |
-
'after_desc' => '',
|
| 551 |
-
'html' => 0,
|
| 552 |
-
'truncatedescchar' => 200,
|
| 553 |
-
'truncatedescstring' => ' ... ',
|
| 554 |
-
'truncatetitlechar' => '',
|
| 555 |
-
'truncatetitlestring' => ' ... ',
|
| 556 |
-
'before_date' => ' <small>',
|
| 557 |
-
'date' => 0,
|
| 558 |
-
'after_date' => '</small>',
|
| 559 |
-
'date_format' => '',
|
| 560 |
-
'before_creator' => ' <small>',
|
| 561 |
-
'creator' => 0,
|
| 562 |
-
'after_creator' => '</small>',
|
| 563 |
-
'start_items' => '<ul>',
|
| 564 |
-
'end_items' => '</ul>',
|
| 565 |
-
'start_item' => '<li>',
|
| 566 |
-
'end_item' => '</li>',
|
| 567 |
-
'target' => '',
|
| 568 |
-
'rel' => '',
|
| 569 |
-
'desc4title' => 0,
|
| 570 |
-
'charsetscan' => 0,
|
| 571 |
-
'debug' => 0,
|
| 572 |
-
'before_noitems' => '<p>',
|
| 573 |
-
'noitems' => __('No items, feed is empty.', FB_RSSI_TEXTDOMAIN ),
|
| 574 |
-
'after_noitems' => '</p>',
|
| 575 |
-
'before_error' => '<p>',
|
| 576 |
-
'error' => __('Error: Feed has an error or is not valid', FB_RSSI_TEXTDOMAIN ),
|
| 577 |
-
'after_error' => '</p>',
|
| 578 |
-
'paging' => 0,
|
| 579 |
-
'prev_paging_link' => __( '« Previous', FB_RSSI_TEXTDOMAIN ),
|
| 580 |
-
'next_paging_link' => __( 'Next »', FB_RSSI_TEXTDOMAIN ),
|
| 581 |
-
'prev_paging_title' => __( 'more items', FB_RSSI_TEXTDOMAIN ),
|
| 582 |
-
'next_paging_title' => __( 'more items', FB_RSSI_TEXTDOMAIN ),
|
| 583 |
-
'use_simplepie' => 1,
|
| 584 |
-
'view' => 0
|
| 585 |
-
), $atts)
|
| 586 |
-
);
|
| 587 |
-
//var_dump($atts);
|
| 588 |
-
|
| 589 |
-
$display = intval($display);
|
| 590 |
-
if ( strtolower($html) == 'true')
|
| 591 |
-
$html = 1;
|
| 592 |
-
$html = intval($html);
|
| 593 |
-
if ( strtolower($displaydescriptions) == 'true')
|
| 594 |
-
$displaydescriptions = 1;
|
| 595 |
-
$displaydescriptions = intval($displaydescriptions);
|
| 596 |
-
if ( strtolower($truncatedescchar) == 'true')
|
| 597 |
-
$truncatedescchar = 1;
|
| 598 |
-
$truncatedescchar = intval($truncatedescchar);
|
| 599 |
-
if ( strtolower($truncatetitlechar) == 'true')
|
| 600 |
-
$truncatetitlechar = 1;
|
| 601 |
-
$truncatetitlechar = intval($truncatetitlechar);
|
| 602 |
-
if ( strtolower($date) == 'true')
|
| 603 |
-
$date = 1;
|
| 604 |
-
$date = intval($date);
|
| 605 |
-
if ( strtolower($creator) == 'true')
|
| 606 |
-
$creator = 1;
|
| 607 |
-
$creator = intval($creator);
|
| 608 |
-
if ( strtolower($charsetscan) == 'true')
|
| 609 |
-
$charsetscan = 1;
|
| 610 |
-
$charsetscan = intval($charsetscan);
|
| 611 |
-
if ( strtolower($debug) == 'true')
|
| 612 |
-
$debug = 1;
|
| 613 |
-
$debug = intval($debug);
|
| 614 |
-
if ( strtolower($paging) == 'true')
|
| 615 |
-
$paging = 1;
|
| 616 |
-
$paging = intval($paging);
|
| 617 |
-
if ( strtolower($use_simplepie) == 'true')
|
| 618 |
-
$use_simplepie = 1;
|
| 619 |
-
$use_simplepie = intval($use_simplepie);
|
| 620 |
-
$feedurl = html_entity_decode( $feedurl ); // novaclic: undo encoding due to wordpress WYSIWYG editor
|
| 621 |
-
|
| 622 |
-
$return = RSSImport(
|
| 623 |
-
$display, $feedurl,
|
| 624 |
-
$before_desc, $displaydescriptions, $after_desc, $html,
|
| 625 |
-
$truncatedescchar, $truncatedescstring,
|
| 626 |
-
$truncatetitlechar, $truncatetitlestring,
|
| 627 |
-
$before_date, $date, $after_date, $date_format,
|
| 628 |
-
$before_creator, $creator, $after_creator,
|
| 629 |
-
$start_items, $end_items,
|
| 630 |
-
$start_item, $end_item,
|
| 631 |
-
$target,
|
| 632 |
-
$rel,
|
| 633 |
-
$desc4title,
|
| 634 |
-
$charsetscan, $debug,
|
| 635 |
-
$before_noitems, $noitems, $after_noitems,
|
| 636 |
-
$before_error, $error, $after_error,
|
| 637 |
-
$paging, $prev_paging_link, $next_paging_link, $prev_paging_title, $next_paging_title,
|
| 638 |
-
$use_simplepie,
|
| 639 |
-
$view
|
| 640 |
-
);
|
| 641 |
-
|
| 642 |
-
return $return;
|
| 643 |
-
}
|
| 644 |
-
|
| 645 |
-
function RSSImport_shortcode_quot($pee) {
|
| 646 |
-
global $shortcode_tags;
|
| 647 |
-
|
| 648 |
-
if ( !empty($shortcode_tags) && is_array($shortcode_tags) ) {
|
| 649 |
-
$tagnames = array_keys($shortcode_tags);
|
| 650 |
-
$tagregexp = join( '|', array_map('preg_quote', $tagnames) );
|
| 651 |
-
$pee = preg_replace('/\\s*?(\\[(' . $tagregexp . ')\\b.*?\\/?\\](?:.+?\\[\\/\\2\\])?)\\s*/s', '$1', $pee);
|
| 652 |
-
}
|
| 653 |
-
|
| 654 |
-
return $pee;
|
| 655 |
-
}
|
| 656 |
-
|
| 657 |
-
|
| 658 |
-
/**
|
| 659 |
-
* add quicktag-button to editor
|
| 660 |
-
*/
|
| 661 |
-
|
| 662 |
-
function RSSImport_insert_button() {
|
| 663 |
-
global $pagenow;
|
| 664 |
-
|
| 665 |
-
$post_page_pages = array('post-new.php', 'post.php', 'page-new.php', 'page.php');
|
| 666 |
-
if ( ! in_array( $pagenow, $post_page_pages ) )
|
| 667 |
-
return;
|
| 668 |
-
|
| 669 |
-
?>
|
| 670 |
-
<script type="text/javascript" charset="utf-8">
|
| 671 |
-
/* Adding Quicktag buttons to the editor WordPress ver. 3.3 and above
|
| 672 |
-
* - Button HTML ID (required)
|
| 673 |
-
* - Button display, value="" attribute (required)
|
| 674 |
-
* - Opening Tag (required)
|
| 675 |
-
* - Closing Tag (required)
|
| 676 |
-
* - Access key, accesskey="" attribute for the button (optional)
|
| 677 |
-
* - Title, title="" attribute (optional)
|
| 678 |
-
* - Priority/position on bar, 1-9 = first, 11-19 = second, 21-29 = third, etc. (optional)
|
| 679 |
-
*/
|
| 680 |
-
var id = 'rssimport',
|
| 681 |
-
text = '<?php _e( 'RSSImport', FB_RSSI_TEXTDOMAIN ); ?>',
|
| 682 |
-
start = '[RSSImport display="5" feedurl="http://feedurl.com/" before_desc="<br />" displaydescriptions="TRUE" after_desc=" " ' +
|
| 683 |
-
'html="FALSE" truncatedescchar="200" truncatedescstring=" ... " truncatetitlechar="" truncatetitlestring=" ... " ' +
|
| 684 |
-
'before_date=" <small>" date="FALSE" after_date="</small>" date_format="" before_creator=" <small>" creator="FALSE" ' +
|
| 685 |
-
'after_creator="</small>" start_items="<ul>" end_items="</ul>" start_item="<li>" end_item="</li>" target="" rel="" ' +
|
| 686 |
-
'desc4title="" charsetscan="FALSE" debug="FALSE" before_noitems="<p>" noitems="No items, feed is empty." ' +
|
| 687 |
-
'after_noitems="</p>" before_error="<p>" error="Error: Feed has an error or is not valid" after_error="</p>" ' +
|
| 688 |
-
'paging="FALSE" prev_paging_link="« Previous" next_paging_link="Next »" prev_paging_title="more items" ' +
|
| 689 |
-
'next_paging_title="more items" use_simplepie="FALSE"]',
|
| 690 |
-
end = '',
|
| 691 |
-
access = 'r',
|
| 692 |
-
title = '<?php _e( 'Import a feed with RSSImport', FB_RSSI_TEXTDOMAIN ); ?>';
|
| 693 |
-
|
| 694 |
-
QTags.addButton( id, text, start, end, access );
|
| 695 |
-
</script>
|
| 696 |
-
<?php
|
| 697 |
-
}
|
| 698 |
-
|
| 699 |
-
function RSSImport_insert_button_old() {
|
| 700 |
-
global $pagenow;
|
| 701 |
-
|
| 702 |
-
$post_page_pages = array('post-new.php', 'post.php', 'page-new.php', 'page.php');
|
| 703 |
-
if ( ! in_array( $pagenow, $post_page_pages ) )
|
| 704 |
-
return;
|
| 705 |
-
|
| 706 |
-
echo '
|
| 707 |
-
<script type="text/javascript">
|
| 708 |
-
//<![CDATA[
|
| 709 |
-
if ( typeof edButtons != \'undefined\' ) {
|
| 710 |
-
var length = edButtons.length;
|
| 711 |
-
edButtons[length] = new edButton(\'RSSImport\', \'$context\', \'[RSSImport display="5" feedurl="http://feedurl.com/"'.
|
| 712 |
-
' before_desc="<br />" displaydescriptions="TRUE" after_desc=" " html="FALSE" truncatedescchar="200" truncatedescstring=" ... "'.
|
| 713 |
-
' truncatetitlechar=" " truncatetitlestring=" ... " before_date=" <small>" date="FALSE" after_date="</small>"'.
|
| 714 |
-
' date_format="" before_creator=" <small>" creator="FALSE" after_creator="</small>" start_items="<ul>" end_items="</ul>"'.
|
| 715 |
-
' start_item="<li>" end_item="</li>" target="" rel="" desc4title="" charsetscan="FALSE" debug="FALSE" before_noitems="<p>"'.
|
| 716 |
-
' noitems="No items, feed is empty." after_noitems="</p>" before_error="<p>" error="Error: Feed has an error or is not valid"'.
|
| 717 |
-
' after_error="</p>" paging="FALSE" prev_paging_link="« Previous" next_paging_link="Next »"'.
|
| 718 |
-
' prev_paging_title="more items" next_paging_title="more items" use_simplepie="FALSE"]\', \'\', \'\');
|
| 719 |
-
function RSSImport_tag(id) {
|
| 720 |
-
id = id.replace(/RSSImport_/, \'\');
|
| 721 |
-
edInsertTag(edCanvas, id);
|
| 722 |
-
}
|
| 723 |
-
jQuery(document).ready(function() {
|
| 724 |
-
content = \'<input id="RSSImport_\'+length+\'" class="ed_button" type="button" value="' . __( 'RSSImport', FB_RSSI_TEXTDOMAIN ) .
|
| 725 |
-
'" title="' . __( 'Import a feed with RSSImport', FB_RSSI_TEXTDOMAIN ) . '" onclick="RSSImport_tag(this.id);" />\';
|
| 726 |
-
jQuery("#ed_toolbar").append(content);
|
| 727 |
-
});
|
| 728 |
-
}
|
| 729 |
-
//]]>
|
| 730 |
-
</script>';
|
| 731 |
-
}
|
| 732 |
-
|
| 733 |
-
if ( is_admin() && FB_RSSI_QUICKTAG ) {
|
| 734 |
-
if ( version_compare( $GLOBALS['wp_version'], '3.3alpha', '>=' ) )
|
| 735 |
-
add_action( 'admin_print_footer_scripts', 'RSSImport_insert_button' );
|
| 736 |
else
|
| 737 |
-
|
| 738 |
-
|
| 739 |
-
|
| 740 |
-
|
| 741 |
-
|
| 742 |
-
|
| 743 |
-
|
| 744 |
-
|
| 745 |
-
|
| 746 |
-
|
| 747 |
-
|
| 748 |
-
|
| 749 |
-
|
| 750 |
-
|
| 751 |
-
|
| 752 |
-
|
| 753 |
-
|
| 754 |
-
if ($
|
| 755 |
-
|
| 756 |
-
|
| 757 |
-
|
| 758 |
-
|
| 759 |
-
|
| 760 |
-
|
| 761 |
-
|
| 762 |
-
|
| 763 |
-
|
| 764 |
-
|
| 765 |
-
|
| 766 |
-
|
| 767 |
-
|
| 768 |
-
|
| 769 |
-
|
| 770 |
-
|
| 771 |
-
|
| 772 |
-
|
| 773 |
-
|
| 774 |
-
|
| 775 |
-
|
| 776 |
-
|
| 777 |
-
|
| 778 |
-
|
| 779 |
-
|
| 780 |
-
|
| 781 |
-
|
| 782 |
-
|
| 783 |
-
|
| 784 |
-
|
| 785 |
-
|
| 786 |
-
|
| 787 |
-
|
| 788 |
-
|
| 789 |
-
|
| 790 |
-
|
| 791 |
-
|
| 792 |
-
|
| 793 |
-
|
| 794 |
-
|
| 795 |
-
|
| 796 |
-
|
| 797 |
-
|
| 798 |
-
|
| 799 |
-
|
| 800 |
-
|
| 801 |
-
|
| 802 |
-
|
| 803 |
-
|
| 804 |
-
|
| 805 |
-
|
| 806 |
-
|
| 807 |
-
|
| 808 |
-
|
| 809 |
-
|
| 810 |
-
|
| 811 |
-
|
| 812 |
-
|
| 813 |
-
|
| 814 |
-
|
| 815 |
-
|
| 816 |
-
|
| 817 |
-
|
| 818 |
-
|
| 819 |
-
|
| 820 |
-
|
| 821 |
-
|
| 822 |
-
|
| 823 |
-
|
| 824 |
-
|
| 825 |
-
|
| 826 |
-
|
| 827 |
-
|
| 828 |
-
|
| 829 |
-
|
| 830 |
-
|
| 831 |
-
|
| 832 |
-
|
| 833 |
-
|
| 834 |
-
|
| 835 |
-
|
| 836 |
-
|
| 837 |
-
|
| 838 |
-
|
| 839 |
-
|
| 840 |
-
|
| 841 |
-
|
| 842 |
-
|
| 843 |
-
|
| 844 |
-
|
| 845 |
-
|
| 846 |
-
|
| 847 |
-
|
| 848 |
-
|
| 849 |
-
|
| 850 |
-
|
| 851 |
-
|
| 852 |
-
|
| 853 |
-
|
| 854 |
-
|
| 855 |
-
|
| 856 |
-
|
| 857 |
-
|
| 858 |
-
|
| 859 |
-
|
| 860 |
-
|
| 861 |
-
|
| 862 |
-
|
| 863 |
-
|
| 864 |
-
|
| 865 |
-
|
| 866 |
-
|
| 867 |
-
|
| 868 |
-
|
| 869 |
-
|
| 870 |
-
|
| 871 |
-
|
| 872 |
-
|
| 873 |
-
|
| 874 |
-
|
| 875 |
-
|
| 876 |
-
|
| 877 |
-
|
| 878 |
-
|
| 879 |
-
|
| 880 |
-
|
| 881 |
-
|
| 882 |
-
|
| 883 |
-
|
| 884 |
-
|
| 885 |
-
|
| 886 |
-
|
| 887 |
-
|
| 888 |
-
|
| 889 |
-
|
| 890 |
-
|
| 891 |
-
|
| 892 |
-
|
| 893 |
-
|
| 894 |
-
|
| 895 |
-
|
| 896 |
-
|
| 897 |
-
|
| 898 |
-
|
| 899 |
-
|
| 900 |
-
|
| 901 |
-
|
| 902 |
-
|
| 903 |
-
|
| 904 |
-
|
| 905 |
-
|
| 906 |
-
|
| 907 |
-
|
| 908 |
-
|
| 909 |
-
|
| 910 |
-
|
| 911 |
-
|
| 912 |
-
|
| 913 |
-
|
| 914 |
-
|
| 915 |
-
|
| 916 |
-
|
| 917 |
-
|
| 918 |
-
|
| 919 |
-
|
| 920 |
-
|
| 921 |
-
|
| 922 |
-
|
| 923 |
-
|
| 924 |
-
|
| 925 |
-
|
| 926 |
-
|
| 927 |
-
|
| 928 |
-
|
| 929 |
-
|
| 930 |
-
|
| 931 |
-
|
| 932 |
-
|
| 933 |
-
|
| 934 |
-
|
| 935 |
-
|
| 936 |
-
"
|
| 937 |
-
|
| 938 |
-
|
| 939 |
-
|
| 940 |
-
|
| 941 |
-
"
|
| 942 |
-
|
| 943 |
-
|
| 944 |
-
|
| 945 |
-
|
| 946 |
-
|
| 947 |
-
|
| 948 |
-
|
| 949 |
-
|
| 950 |
-
|
| 951 |
-
|
| 952 |
-
|
| 953 |
-
"
|
| 954 |
-
|
| 955 |
-
|
| 956 |
-
|
| 957 |
-
|
| 958 |
-
|
| 959 |
-
|
| 960 |
-
|
| 961 |
-
"
|
| 962 |
-
|
| 963 |
-
|
| 964 |
-
|
| 965 |
-
|
| 966 |
-
|
| 967 |
-
|
| 968 |
-
|
| 969 |
-
|
| 970 |
-
|
| 971 |
-
|
| 972 |
-
|
| 973 |
-
|
| 974 |
-
|
| 975 |
-
|
| 976 |
-
|
| 977 |
-
|
| 978 |
-
|
| 979 |
-
|
| 980 |
-
|
| 981 |
-
|
| 982 |
-
|
| 983 |
-
|
| 984 |
-
|
| 985 |
-
|
| 986 |
-
|
| 987 |
-
|
| 988 |
-
|
| 989 |
-
|
| 990 |
-
|
| 991 |
-
|
| 992 |
-
|
| 993 |
-
|
| 994 |
-
|
| 995 |
-
|
| 996 |
-
|
| 997 |
-
|
| 998 |
-
|
| 999 |
-
|
| 1000 |
-
|
| 1001 |
-
|
| 1002 |
-
|
| 1003 |
-
|
| 1004 |
-
|
| 1005 |
-
|
| 1006 |
-
|
| 1007 |
-
|
| 1008 |
-
|
| 1009 |
-
|
| 1010 |
-
|
| 1011 |
-
|
| 1012 |
-
|
| 1013 |
-
|
| 1014 |
-
|
| 1015 |
-
|
| 1016 |
-
|
| 1017 |
-
|
| 1018 |
-
|
| 1019 |
-
|
| 1020 |
-
|
| 1021 |
-
|
| 1022 |
-
|
| 1023 |
-
|
| 1024 |
-
|
| 1025 |
-
|
| 1026 |
-
|
| 1027 |
-
|
| 1028 |
-
|
| 1029 |
-
|
| 1030 |
-
|
| 1031 |
-
|
| 1032 |
-
|
| 1033 |
-
|
| 1034 |
-
|
| 1035 |
-
|
| 1036 |
-
|
| 1037 |
-
|
| 1038 |
-
|
| 1039 |
-
|
| 1040 |
-
|
| 1041 |
-
|
| 1042 |
-
|
| 1043 |
-
|
| 1044 |
-
|
| 1045 |
-
|
| 1046 |
-
|
| 1047 |
-
|
| 1048 |
-
|
| 1049 |
-
|
| 1050 |
-
|
| 1051 |
-
|
| 1052 |
-
|
| 1053 |
-
|
| 1054 |
-
|
| 1055 |
-
|
| 1056 |
-
|
| 1057 |
-
|
| 1058 |
-
|
| 1059 |
-
|
| 1060 |
-
|
| 1061 |
-
|
| 1062 |
-
|
| 1063 |
-
|
| 1064 |
-
|
| 1065 |
-
|
| 1066 |
-
|
| 1067 |
-
|
| 1068 |
-
|
| 1069 |
-
|
| 1070 |
-
|
| 1071 |
-
|
| 1072 |
-
|
| 1073 |
-
|
| 1074 |
-
|
| 1075 |
-
|
| 1076 |
-
|
| 1077 |
-
|
| 1078 |
-
|
| 1079 |
-
|
| 1080 |
-
|
| 1081 |
-
|
| 1082 |
-
|
| 1083 |
-
|
| 1084 |
-
|
| 1085 |
-
|
| 1086 |
-
|
| 1087 |
-
|
| 1088 |
-
|
| 1089 |
-
|
| 1090 |
-
|
| 1091 |
-
|
| 1092 |
-
|
| 1093 |
-
|
| 1094 |
-
|
| 1095 |
-
|
| 1096 |
-
|
| 1097 |
-
|
| 1098 |
-
|
| 1099 |
-
|
| 1100 |
-
|
| 1101 |
-
|
| 1102 |
-
|
| 1103 |
-
|
| 1104 |
-
|
| 1105 |
-
|
| 1106 |
-
|
| 1107 |
-
|
| 1108 |
-
|
| 1109 |
-
|
| 1110 |
-
|
| 1111 |
-
|
| 1112 |
-
|
| 1113 |
-
|
| 1114 |
-
|
| 1115 |
-
|
| 1116 |
-
|
| 1117 |
-
|
| 1118 |
-
|
| 1119 |
-
|
| 1120 |
-
|
| 1121 |
-
|
| 1122 |
-
|
| 1123 |
-
|
| 1124 |
-
|
| 1125 |
-
|
| 1126 |
-
|
| 1127 |
-
|
| 1128 |
-
|
| 1129 |
-
|
| 1130 |
-
|
| 1131 |
-
|
| 1132 |
-
|
| 1133 |
-
|
| 1134 |
-
|
| 1135 |
-
|
| 1136 |
-
|
| 1137 |
-
|
| 1138 |
-
|
| 1139 |
-
|
| 1140 |
-
|
| 1141 |
-
|
| 1142 |
-
|
| 1143 |
-
|
| 1144 |
-
|
| 1145 |
-
|
| 1146 |
-
|
| 1147 |
-
|
| 1148 |
-
|
| 1149 |
-
|
| 1150 |
-
|
| 1151 |
-
|
| 1152 |
-
|
| 1153 |
-
|
| 1154 |
-
|
| 1155 |
-
|
| 1156 |
-
|
| 1157 |
-
|
| 1158 |
-
|
| 1159 |
-
|
| 1160 |
-
|
| 1161 |
-
|
| 1162 |
-
|
| 1163 |
-
|
| 1164 |
-
|
| 1165 |
-
|
| 1166 |
-
|
| 1167 |
-
|
| 1168 |
-
|
| 1169 |
-
|
| 1170 |
-
|
| 1171 |
-
|
| 1172 |
-
|
| 1173 |
-
|
| 1174 |
-
|
| 1175 |
-
|
| 1176 |
-
|
| 1177 |
-
|
| 1178 |
-
|
| 1179 |
-
|
| 1180 |
-
|
| 1181 |
-
|
| 1182 |
-
|
| 1183 |
-
|
| 1184 |
-
|
| 1185 |
-
|
| 1186 |
-
|
| 1187 |
-
|
| 1188 |
-
|
| 1189 |
-
|
| 1190 |
-
|
| 1191 |
-
|
| 1192 |
-
|
| 1193 |
-
|
| 1194 |
-
|
| 1195 |
-
|
| 1196 |
-
|
| 1197 |
-
|
| 1198 |
-
|
| 1199 |
-
|
| 1200 |
-
|
| 1201 |
-
|
| 1202 |
-
|
| 1203 |
-
|
| 1204 |
-
|
| 1205 |
-
|
| 1206 |
-
|
| 1207 |
-
|
| 1208 |
-
|
| 1209 |
-
|
| 1210 |
-
|
| 1211 |
-
|
| 1212 |
-
|
| 1213 |
-
|
| 1214 |
-
|
| 1215 |
-
|
| 1216 |
-
|
| 1217 |
-
|
| 1218 |
-
|
| 1219 |
-
|
| 1220 |
-
|
| 1221 |
-
|
| 1222 |
-
|
| 1223 |
-
|
| 1224 |
-
|
| 1225 |
-
|
| 1226 |
-
|
| 1227 |
-
|
| 1228 |
-
|
| 1229 |
-
|
| 1230 |
-
|
| 1231 |
-
|
| 1232 |
-
|
| 1233 |
-
|
| 1234 |
-
|
| 1235 |
-
|
| 1236 |
-
|
| 1237 |
-
|
| 1238 |
-
|
| 1239 |
-
|
| 1240 |
-
|
| 1241 |
-
|
| 1242 |
-
|
| 1243 |
-
|
| 1244 |
-
|
| 1245 |
-
|
| 1246 |
-
|
| 1247 |
-
|
| 1248 |
-
|
| 1249 |
-
|
| 1250 |
-
|
| 1251 |
-
|
| 1252 |
-
|
| 1253 |
-
|
| 1254 |
-
|
| 1255 |
-
|
| 1256 |
-
|
| 1257 |
-
|
| 1258 |
-
|
| 1259 |
-
|
| 1260 |
-
|
| 1261 |
-
|
| 1262 |
-
|
| 1263 |
-
|
| 1264 |
-
|
| 1265 |
-
|
| 1266 |
-
|
| 1267 |
-
|
| 1268 |
-
|
| 1269 |
-
|
| 1270 |
-
|
| 1271 |
-
|
| 1272 |
-
|
| 1273 |
-
|
| 1274 |
-
|
| 1275 |
-
|
| 1276 |
-
|
| 1277 |
-
|
| 1278 |
-
|
| 1279 |
-
|
| 1280 |
-
|
| 1281 |
-
|
| 1282 |
-
|
| 1283 |
-
|
| 1284 |
-
|
| 1285 |
-
|
| 1286 |
-
|
| 1287 |
-
|
| 1288 |
-
|
| 1289 |
-
|
| 1290 |
-
|
| 1291 |
-
|
| 1292 |
-
|
| 1293 |
-
|
| 1294 |
-
|
| 1295 |
-
|
| 1296 |
-
|
| 1297 |
-
|
| 1298 |
-
|
| 1299 |
-
|
| 1300 |
-
|
| 1301 |
-
|
| 1302 |
-
|
| 1303 |
-
|
| 1304 |
-
|
| 1305 |
-
|
| 1306 |
-
|
| 1307 |
-
|
| 1308 |
-
|
| 1309 |
-
|
| 1310 |
-
|
| 1311 |
-
|
| 1312 |
-
|
| 1313 |
-
|
| 1314 |
-
|
| 1315 |
-
|
| 1316 |
-
|
| 1317 |
-
|
| 1318 |
-
|
| 1319 |
-
|
| 1320 |
-
|
| 1321 |
-
|
| 1322 |
-
|
| 1323 |
-
|
| 1324 |
-
|
| 1325 |
-
|
| 1326 |
-
|
| 1327 |
-
|
| 1328 |
-
|
| 1329 |
-
|
| 1330 |
-
|
| 1331 |
-
|
| 1332 |
-
|
| 1333 |
-
|
| 1334 |
-
|
| 1335 |
-
|
| 1336 |
-
|
| 1337 |
-
|
| 1338 |
-
|
| 1339 |
-
|
| 1340 |
-
|
| 1341 |
-
|
| 1342 |
-
|
| 1343 |
-
|
| 1344 |
-
|
| 1345 |
-
|
| 1346 |
-
|
| 1347 |
-
|
| 1348 |
-
|
| 1349 |
-
|
| 1350 |
-
|
| 1351 |
-
|
| 1352 |
-
|
| 1353 |
-
|
| 1354 |
-
|
| 1355 |
-
|
| 1356 |
-
|
| 1357 |
-
|
| 1358 |
-
|
| 1359 |
-
|
| 1360 |
-
|
| 1361 |
-
|
| 1362 |
-
|
| 1363 |
-
|
| 1364 |
-
|
| 1365 |
-
|
| 1366 |
-
|
| 1367 |
-
|
| 1368 |
-
|
| 1369 |
-
|
| 1370 |
-
|
| 1371 |
-
|
| 1372 |
-
|
| 1373 |
-
|
| 1374 |
-
|
| 1375 |
-
|
| 1376 |
-
|
| 1377 |
-
|
| 1378 |
-
|
| 1379 |
-
|
| 1380 |
-
|
| 1381 |
-
|
| 1382 |
-
|
| 1383 |
-
|
| 1384 |
-
|
| 1385 |
-
|
| 1386 |
-
|
| 1387 |
-
|
| 1388 |
-
|
| 1389 |
-
|
| 1390 |
-
|
| 1391 |
-
|
| 1392 |
-
|
| 1393 |
-
|
| 1394 |
-
|
| 1395 |
-
|
| 1396 |
-
|
| 1397 |
-
|
| 1398 |
-
|
| 1399 |
-
|
| 1400 |
-
|
| 1401 |
-
|
| 1402 |
-
|
| 1403 |
-
|
| 1404 |
-
|
| 1405 |
-
|
| 1406 |
-
|
| 1407 |
-
|
| 1408 |
-
|
| 1409 |
-
|
| 1410 |
-
|
| 1411 |
-
|
| 1412 |
-
|
| 1413 |
-
|
| 1414 |
-
|
| 1415 |
-
|
| 1416 |
-
|
| 1417 |
-
|
| 1418 |
-
|
| 1419 |
-
|
| 1420 |
-
|
| 1421 |
-
|
| 1422 |
-
|
| 1423 |
-
|
| 1424 |
-
|
| 1425 |
-
|
| 1426 |
-
|
| 1427 |
-
|
| 1428 |
-
|
| 1429 |
-
|
| 1430 |
-
|
| 1431 |
-
|
| 1432 |
-
|
| 1433 |
-
|
| 1434 |
-
|
| 1435 |
-
|
| 1436 |
-
|
| 1437 |
-
|
| 1438 |
-
|
| 1439 |
-
|
| 1440 |
-
|
| 1441 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
<?php
|
| 2 |
+
/**
|
| 3 |
+
* @package WP-RSSImport
|
| 4 |
+
* @author Frank Bültge
|
| 5 |
+
*/
|
| 6 |
+
|
| 7 |
+
/**
|
| 8 |
+
* Plugin Name: WP-RSSImport
|
| 9 |
+
* Plugin URI: http://bueltge.de/wp-rss-import-plugin/55/
|
| 10 |
+
* Text Domain: rssimport
|
| 11 |
+
* Domain Path: /languages
|
| 12 |
+
* Description: Import and display Feeds in your blog, use the function RSSImport(), a Widget or Shortcode [RSSImport].
|
| 13 |
+
* Author: Frank Bültge, took77
|
| 14 |
+
* Version: 4.4.16
|
| 15 |
+
* License: GPLv2+
|
| 16 |
+
* Last change: 09/24/2015
|
| 17 |
+
*/
|
| 18 |
+
|
| 19 |
+
/*
|
| 20 |
+
------------------------------------------------------------
|
| 21 |
+
ACKNOWLEDGEMENTS
|
| 22 |
+
------------------------------------------------------------
|
| 23 |
+
Original and Idea: Dave Wolf, http://www.davewolf.net
|
| 24 |
+
Thx to Thomas Fischer, http://www.securityfocus.de and
|
| 25 |
+
Gunnar Tillmann http://www.gunnart.de for a better code
|
| 26 |
+
|
| 27 |
+
Paging: Ilya Shindyapin, http://skookum.com
|
| 28 |
+
|
| 29 |
+
------------------------------------------------------------
|
| 30 |
+
USAGE: Use following code with a PHP-Plugin for WordPress:
|
| 31 |
+
Example: <?php RSSImport(10, "http://bueltge.de/feed/"); ?>
|
| 32 |
+
------------------------------------------------------------
|
| 33 |
+
*/
|
| 34 |
+
|
| 35 |
+
//avoid direct calls to this file, because now WP core and framework has been used
|
| 36 |
+
if ( ! function_exists('add_action') ) {
|
| 37 |
+
header('Status: 403 Forbidden');
|
| 38 |
+
header('HTTP/1.1 403 Forbidden');
|
| 39 |
+
exit();
|
| 40 |
+
}
|
| 41 |
+
|
| 42 |
+
if ( function_exists('add_action') ) {
|
| 43 |
+
//WordPress definitions
|
| 44 |
+
if ( !defined('WP_CONTENT_URL') )
|
| 45 |
+
define('WP_CONTENT_URL', get_option('siteurl') . '/wp-content');
|
| 46 |
+
if ( !defined('WP_CONTENT_DIR') )
|
| 47 |
+
define('WP_CONTENT_DIR', ABSPATH . 'wp-content');
|
| 48 |
+
if ( !defined('WP_PLUGIN_URL') )
|
| 49 |
+
define('WP_PLUGIN_URL', WP_CONTENT_URL.'/plugins');
|
| 50 |
+
if ( !defined('WP_PLUGIN_DIR') )
|
| 51 |
+
define('WP_PLUGIN_DIR', WP_CONTENT_DIR.'/plugins');
|
| 52 |
+
if ( !defined('PLUGINDIR') )
|
| 53 |
+
define( 'PLUGINDIR', 'wp-content/plugins' ); // Relative to ABSPATH. For back compat.
|
| 54 |
+
if ( !defined('WP_LANG_DIR') )
|
| 55 |
+
define('WP_LANG_DIR', WP_CONTENT_DIR . '/languages');
|
| 56 |
+
|
| 57 |
+
// plugin definitions
|
| 58 |
+
define( 'FB_RSSI_BASENAME', plugin_basename(__FILE__) );
|
| 59 |
+
define( 'FB_RSSI_BASEFOLDER', plugin_basename( dirname( __FILE__ ) ) );
|
| 60 |
+
define( 'FB_RSSI_TEXTDOMAIN', 'rssimport' );
|
| 61 |
+
define( 'FB_RSSI_QUICKTAG', TRUE );
|
| 62 |
+
}
|
| 63 |
+
|
| 64 |
+
function RSSImport_textdomain() {
|
| 65 |
+
|
| 66 |
+
if ( function_exists('load_plugin_textdomain') )
|
| 67 |
+
load_plugin_textdomain( FB_RSSI_TEXTDOMAIN, FALSE, dirname( FB_RSSI_BASENAME ) . '/languages');
|
| 68 |
+
}
|
| 69 |
+
|
| 70 |
+
if ( ! function_exists('esc_attr') ) {
|
| 71 |
+
function esc_attr( $text ) {
|
| 72 |
+
return attribute_escape( $text );
|
| 73 |
+
}
|
| 74 |
+
}
|
| 75 |
+
|
| 76 |
+
if ( ! function_exists('esc_url') ) {
|
| 77 |
+
function esc_url($text ) {
|
| 78 |
+
return clean_url($text);
|
| 79 |
+
}
|
| 80 |
+
}
|
| 81 |
+
|
| 82 |
+
|
| 83 |
+
// cache and error report
|
| 84 |
+
//define('MAGPIE_CACHE_ON', FALSE); // Cache off
|
| 85 |
+
if ( ! defined('MAGPIE_CACHE_AGE') )
|
| 86 |
+
define('MAGPIE_CACHE_AGE', '60*60'); // in sec, one hour
|
| 87 |
+
// error reporting
|
| 88 |
+
//error_reporting(E_ALL);
|
| 89 |
+
|
| 90 |
+
function RSSImport(
|
| 91 |
+
$display = 5,
|
| 92 |
+
$feedurl = 'http://bueltge.de/feed/',
|
| 93 |
+
$before_desc = '',
|
| 94 |
+
$displaydescriptions = 0,
|
| 95 |
+
$after_desc = '',
|
| 96 |
+
$html = 0,
|
| 97 |
+
$truncatedescchar = 200,
|
| 98 |
+
$truncatedescstring = ' ... ',
|
| 99 |
+
$truncatetitlechar = '',
|
| 100 |
+
$truncatetitlestring = ' ... ',
|
| 101 |
+
$before_date = ' <small>',
|
| 102 |
+
$date = 0,
|
| 103 |
+
$after_date = '</small>',
|
| 104 |
+
$date_format = '',
|
| 105 |
+
$before_creator = ' <small>',
|
| 106 |
+
$creator = 0,
|
| 107 |
+
$after_creator = '</small>',
|
| 108 |
+
$start_items = '<ul>',
|
| 109 |
+
$end_items = '</ul>',
|
| 110 |
+
$start_item = '<li>',
|
| 111 |
+
$end_item = '</li>',
|
| 112 |
+
$target = '',
|
| 113 |
+
$rel = '',
|
| 114 |
+
$desc4title = 0,
|
| 115 |
+
$charsetscan = 0,
|
| 116 |
+
$debug = 0,
|
| 117 |
+
$before_noitems = '<p>',
|
| 118 |
+
$noitems = 'No items, feed is empty.',
|
| 119 |
+
$after_noitems = '</p>',
|
| 120 |
+
$before_error = '<p>',
|
| 121 |
+
$error = 'Error: Feed has an error or is not valid',
|
| 122 |
+
$after_error = '</p>',
|
| 123 |
+
$paging = 0,
|
| 124 |
+
$prev_paging_link = '« Previous',
|
| 125 |
+
$next_paging_link = 'Next »',
|
| 126 |
+
$prev_paging_title = 'more items',
|
| 127 |
+
$next_paging_title = 'more items',
|
| 128 |
+
$use_simplepie = 1,
|
| 129 |
+
$view = 1
|
| 130 |
+
) {
|
| 131 |
+
|
| 132 |
+
// replace for yahoo pipes urls
|
| 133 |
+
$feedurl = str_replace('&', '&', $feedurl);
|
| 134 |
+
|
| 135 |
+
$display = (int) $display;
|
| 136 |
+
$displaydescriptions = (int) $displaydescriptions;
|
| 137 |
+
$html = (int) $html;
|
| 138 |
+
$truncatedescchar = (int) $truncatedescchar;
|
| 139 |
+
$truncatetitlechar = (int) $truncatetitlechar;
|
| 140 |
+
$date = (int) $date;
|
| 141 |
+
if ( $date_format == '' )
|
| 142 |
+
$date_format = get_option('date_format');
|
| 143 |
+
$creator = (int) $creator;
|
| 144 |
+
$charsetscan = (int) $charsetscan;
|
| 145 |
+
$debug = (int) $debug;
|
| 146 |
+
$paging = (int) $paging;
|
| 147 |
+
$use_simplepie = (int) $use_simplepie;
|
| 148 |
+
$view = (int) $view;
|
| 149 |
+
|
| 150 |
+
if ($use_simplepie) {
|
| 151 |
+
if ( ! class_exists('SimplePie') ) {
|
| 152 |
+
if ( file_exists(ABSPATH . WPINC . '/class-simplepie.php') ) {
|
| 153 |
+
@require_once (ABSPATH . WPINC . '/class-simplepie.php');
|
| 154 |
+
} else {
|
| 155 |
+
die (__('Error in file: ' . __FILE__ . ' on line: ' . __LINE__ . '.<br />The WordPress file "class-simplepie.php" with class SimplePie could not be included.'));
|
| 156 |
+
}
|
| 157 |
+
}
|
| 158 |
+
} else {
|
| 159 |
+
// For function fetch_rss from wp-core
|
| 160 |
+
if ( file_exists(ABSPATH . WPINC . '/rss.php') ) {
|
| 161 |
+
@require_once (ABSPATH . WPINC . '/rss.php');
|
| 162 |
+
// It's Wordpress 2.x. since it has been loaded successfully
|
| 163 |
+
} elseif (file_exists(ABSPATH . WPINC . '/rss-functions.php')) {
|
| 164 |
+
@require_once (ABSPATH . WPINC . '/rss-functions.php');
|
| 165 |
+
// In Wordpress < 2.1
|
| 166 |
+
} else {
|
| 167 |
+
die (__('Error in file: ' . __FILE__ . ' on line: ' . __LINE__ . '.<br />The Wordpress file "rss-functions.php" or "rss.php" could not be included.'));
|
| 168 |
+
}
|
| 169 |
+
}
|
| 170 |
+
|
| 171 |
+
$display = intval($display);
|
| 172 |
+
$page = ( ( !empty( $_GET['rsspage'] ) && intval($_GET['rsspage']) > 0 ) ? intval($_GET['rsspage']) : 1 );
|
| 173 |
+
$truncatedescchar = intval($truncatedescchar);
|
| 174 |
+
$truncatetitlechar = intval($truncatetitlechar);
|
| 175 |
+
if ($use_simplepie)
|
| 176 |
+
$echo = '<!--via SimplePie with RSSImport-->';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 177 |
else
|
| 178 |
+
$echo = '<!--via MagpieRSS with RSSImport-->';
|
| 179 |
+
|
| 180 |
+
if ($charsetscan) {
|
| 181 |
+
// read in file for search charset
|
| 182 |
+
if ( function_exists('file_get_contents') ) {
|
| 183 |
+
ini_set('default_socket_timeout', 10);
|
| 184 |
+
$a = file_get_contents($feedurl);
|
| 185 |
+
// for better performance, if the server accepts the method
|
| 186 |
+
// $a = file_get_contents($feedurl, FALSE, NULL, 0, 50);
|
| 187 |
+
}
|
| 188 |
+
}
|
| 189 |
+
|
| 190 |
+
if ($use_simplepie)
|
| 191 |
+
$rss = fetch_feed($feedurl);
|
| 192 |
+
else
|
| 193 |
+
$rss = fetch_rss($feedurl);
|
| 194 |
+
|
| 195 |
+
if ( $rss && ! is_wp_error($rss) ) {
|
| 196 |
+
|
| 197 |
+
// the follow print_r list all items in array, for debug purpose
|
| 198 |
+
if ( $debug ) {
|
| 199 |
+
print('FeedURL: ' . $feedurl);
|
| 200 |
+
print('<pre>');
|
| 201 |
+
print_r($rss);
|
| 202 |
+
print('</pre>');
|
| 203 |
+
if ( ! defined('MAGPIE_CACHE_ON') )
|
| 204 |
+
define('MAGPIE_CACHE_ON', FALSE);
|
| 205 |
+
}
|
| 206 |
+
|
| 207 |
+
if ( isset($target) && $target != '' )
|
| 208 |
+
$target = ' target="_' . $target . '"';
|
| 209 |
+
|
| 210 |
+
if ( isset($rel) && $rel != '' )
|
| 211 |
+
$rel = ' rel="' . $rel . '"';
|
| 212 |
+
|
| 213 |
+
$displayitems = $display;
|
| 214 |
+
$displaylimit = ($page * $display);
|
| 215 |
+
$display = (($page-1) * $display);
|
| 216 |
+
$nextitems = TRUE;
|
| 217 |
+
$previousitems = FALSE;
|
| 218 |
+
if ( $page > 1 )
|
| 219 |
+
$previousitems = TRUE;
|
| 220 |
+
|
| 221 |
+
while($display < $displaylimit) {
|
| 222 |
+
|
| 223 |
+
if ( $use_simplepie && (1 ==$paging) )
|
| 224 |
+
$items = $rss->get_items();
|
| 225 |
+
elseif ($use_simplepie)
|
| 226 |
+
$items = $rss->get_items(0, $displayitems);
|
| 227 |
+
else
|
| 228 |
+
$items = $rss->items;
|
| 229 |
+
|
| 230 |
+
if ( array_key_exists( $display, $items ) ) {
|
| 231 |
+
|
| 232 |
+
if ($use_simplepie)
|
| 233 |
+
$item = $rss->get_item($display);
|
| 234 |
+
else
|
| 235 |
+
$item = $rss->items[$display];
|
| 236 |
+
// import title
|
| 237 |
+
if ($use_simplepie)
|
| 238 |
+
$title = esc_attr( strip_tags( $item->get_title() ) );
|
| 239 |
+
elseif ( isset($item['title']) )
|
| 240 |
+
$title = esc_attr( strip_tags( $item['title'] ) );
|
| 241 |
+
// import link
|
| 242 |
+
if ($use_simplepie)
|
| 243 |
+
$href = wp_filter_kses( $item->get_link() );
|
| 244 |
+
elseif ( isset($item['link']) )
|
| 245 |
+
$href = wp_filter_kses( $item['link'] );
|
| 246 |
+
// import picture_url
|
| 247 |
+
$picture_url = '';
|
| 248 |
+
if ($use_simplepie) {
|
| 249 |
+
if ( $enclosure = $item->get_enclosure() ) {
|
| 250 |
+
$picture_url = wp_filter_kses( $enclosure->get_thumbnail() );
|
| 251 |
+
}
|
| 252 |
+
}
|
| 253 |
+
|
| 254 |
+
$start_item_temp = str_replace('%title%', $title, $start_item);
|
| 255 |
+
$start_item_temp = str_replace('%href%', $href, $start_item_temp);
|
| 256 |
+
$start_item_temp = str_replace('%picture_url%', $picture_url, $start_item_temp);
|
| 257 |
+
$echo .= $start_item_temp;
|
| 258 |
+
|
| 259 |
+
// import date
|
| 260 |
+
if ($use_simplepie && $date)
|
| 261 |
+
$pubDate = date_i18n( $date_format, strtotime( $item->get_date() ) );
|
| 262 |
+
elseif ($date && isset($item['pubdate']) )
|
| 263 |
+
$pubDate = date_i18n( $date_format, strtotime( $item['pubdate'] ) );
|
| 264 |
+
// import creator
|
| 265 |
+
if ($use_simplepie && $creator) {
|
| 266 |
+
$creator = $item->get_author();
|
| 267 |
+
if ( is_object($creator) ) {
|
| 268 |
+
$creator = $creator->get_name();
|
| 269 |
+
$creator = ' <cite>' . esc_html( strip_tags( $creator ) ) . '</cite>';
|
| 270 |
+
}
|
| 271 |
+
} elseif ($creator && isset($item['dc']['creator']) ) {
|
| 272 |
+
$creator = wp_specialchars( $item['dc']['creator'] );
|
| 273 |
+
} elseif ($creator && isset($item['creator']) ) {
|
| 274 |
+
$creator = wp_specialchars( $item['creator'] );
|
| 275 |
+
}
|
| 276 |
+
// import desc
|
| 277 |
+
if ( $use_simplepie && $displaydescriptions && $html )
|
| 278 |
+
$desc = @html_entity_decode( $item->get_content(), ENT_QUOTES, get_option('blog_charset') ); // For import with HTML
|
| 279 |
+
elseif ( $use_simplepie && $displaydescriptions && !$html )
|
| 280 |
+
$desc = str_replace( array("\n", "\r"), ' ', esc_attr( strip_tags( @html_entity_decode( $item->get_description(), ENT_QUOTES, get_option('blog_charset') ) ) ) ); // For import without HTML
|
| 281 |
+
elseif ( $displaydescriptions && $html && isset($item['content']['encoded']) && $item['content']['encoded'] != 'A' )
|
| 282 |
+
$desc = $item['content']['encoded']; // For import with HTML
|
| 283 |
+
elseif ( $displaydescriptions && $html && isset($item['content']['atom_content']) && $item['content']['atom_content'] != 'A' )
|
| 284 |
+
$desc = $item['content']['atom_content']; // For import with HTML
|
| 285 |
+
elseif ( $displaydescriptions && $html && isset($item['content']) && !is_array($item['content']) )
|
| 286 |
+
$desc = $item['content'];
|
| 287 |
+
elseif ( $displaydescriptions && $html && isset($item['description']) )
|
| 288 |
+
$desc = $item['description'];
|
| 289 |
+
elseif ( $displaydescriptions && !$html && isset($item['description']) )
|
| 290 |
+
$desc = wp_specialchars(strip_tags($item['description'])); // For import without HTML
|
| 291 |
+
|
| 292 |
+
if ( isset($a) && eregi('ISO', $a) ) {
|
| 293 |
+
if ($debug)
|
| 294 |
+
$echo .= 'ISO Feed' . "\n";
|
| 295 |
+
if ( isset($title) )
|
| 296 |
+
isodec($title);
|
| 297 |
+
if ( isset($creator) )
|
| 298 |
+
isodec($creator);
|
| 299 |
+
if ( isset($desc) )
|
| 300 |
+
isodec($desc);
|
| 301 |
+
} else {
|
| 302 |
+
if ($debug)
|
| 303 |
+
$echo .= 'NonISO Feed' . "\n";
|
| 304 |
+
if ( isset($title) )
|
| 305 |
+
utf8dec($title);
|
| 306 |
+
if ( isset($creator) )
|
| 307 |
+
utf8dec($creator);
|
| 308 |
+
if ( isset($desc) )
|
| 309 |
+
utf8dec($desc);
|
| 310 |
+
}
|
| 311 |
+
|
| 312 |
+
if ( isset($title) )
|
| 313 |
+
all_convert($title);
|
| 314 |
+
if ( isset($creator) )
|
| 315 |
+
all_convert($creator);
|
| 316 |
+
if ( isset($desc) )
|
| 317 |
+
all_convert($desc);
|
| 318 |
+
|
| 319 |
+
if ( isset($title) && $truncatetitlechar && (strlen($title) > $truncatetitlechar) ) {
|
| 320 |
+
$title = wp_html_excerpt($title, $truncatetitlechar) . $truncatetitlestring;
|
| 321 |
+
}
|
| 322 |
+
|
| 323 |
+
if ( isset($desc) && $truncatedescchar && (strlen($desc) > $truncatedescchar) ) {
|
| 324 |
+
$desc = wp_html_excerpt($desc, $truncatedescchar) . $truncatedescstring;
|
| 325 |
+
}
|
| 326 |
+
|
| 327 |
+
if ( $desc4title ) {
|
| 328 |
+
if ($use_simplepie)
|
| 329 |
+
$desc = str_replace( array("\n", "\r"), ' ', esc_attr( strip_tags( @html_entity_decode( $item->get_description(), ENT_QUOTES, get_option('blog_charset') ) ) ) ); // For import without HTML
|
| 330 |
+
else if (isset($item['description']))
|
| 331 |
+
$desc = wp_specialchars(strip_tags($item['description']));
|
| 332 |
+
else
|
| 333 |
+
$desc ='';
|
| 334 |
+
$atitle = wp_html_excerpt($desc, $truncatedescchar) . $truncatedescstring;
|
| 335 |
+
} else {
|
| 336 |
+
$atitle = $title;
|
| 337 |
+
}
|
| 338 |
+
|
| 339 |
+
$echo .= '<a' . $target . $rel . ' href="' . $href . '" title="'. $atitle . '">' . $title . '</a>';
|
| 340 |
+
if ( isset($pubDate) && $date && $pubDate != '' )
|
| 341 |
+
$echo .= $before_date . $pubDate . $after_date;
|
| 342 |
+
if ( isset($creator) && $creator && $creator != '' )
|
| 343 |
+
$echo .= $before_creator . $creator . $after_creator;
|
| 344 |
+
if ( isset($desc) && $displaydescriptions && $desc != '' ) {
|
| 345 |
+
$after_desc_temp = stripslashes_deep( $after_desc );
|
| 346 |
+
$after_desc_temp = str_replace('%title%', $title, $after_desc_temp);
|
| 347 |
+
$after_desc_temp = str_replace('%href%', $href, $after_desc_temp);
|
| 348 |
+
$after_desc_temp = str_replace('%picture_url%', $picture_url, $after_desc_temp);
|
| 349 |
+
$before_desc_temp = str_replace('%title%', $title, $before_desc);
|
| 350 |
+
$before_desc_temp = str_replace('%href%', $href, $before_desc_temp);
|
| 351 |
+
$before_desc_temp = str_replace('%picture_url%', $picture_url, $before_desc_temp);
|
| 352 |
+
$echo .= $before_desc_temp . $desc . $after_desc_temp;
|
| 353 |
+
}
|
| 354 |
+
$end_item_temp = str_replace('%title%', $title, $end_item);
|
| 355 |
+
$end_item_temp = str_replace('%href%', $href, $end_item_temp);
|
| 356 |
+
$end_item_temp = str_replace('%picture_url%', $picture_url, $end_item_temp);
|
| 357 |
+
$echo .= $end_item_temp;
|
| 358 |
+
} else {
|
| 359 |
+
$nextitems = FALSE;
|
| 360 |
+
}
|
| 361 |
+
|
| 362 |
+
$display++;
|
| 363 |
+
}
|
| 364 |
+
|
| 365 |
+
if (strip_tags($echo)) { // novaclic: needed to filter out false content madeof tags alone (html comments, html tags, ...)
|
| 366 |
+
$echo = wptexturize($start_items . $echo . $end_items);
|
| 367 |
+
} else
|
| 368 |
+
$echo = wptexturize($before_noitems . $noitems . $after_noitems);
|
| 369 |
+
|
| 370 |
+
} else {
|
| 371 |
+
if ( empty($rss->ERROR) )
|
| 372 |
+
$rss->ERROR = NULL;
|
| 373 |
+
$echo = wptexturize($before_error . $error . $rss->ERROR . $after_error);
|
| 374 |
+
}
|
| 375 |
+
|
| 376 |
+
if ($paging) {
|
| 377 |
+
$echo .= '<div class="rsspaging">';
|
| 378 |
+
if ($previousitems)
|
| 379 |
+
$echo .= '<a href="' . add_query_arg( 'rsspage', ($page-1) ) . '" class="rsspaging_prev" title="' . $prev_paging_title . '">' . $prev_paging_link . '</a>';
|
| 380 |
+
if ($nextitems)
|
| 381 |
+
$echo .= '<a href="' . add_query_arg( 'rsspage', ($page+1) ) . '" class="rsspaging_next" title="' . $next_paging_title . '">' . $next_paging_link .'</a>';
|
| 382 |
+
$echo .= '<br style="clear: both" />';
|
| 383 |
+
$echo .= '</div>';
|
| 384 |
+
}
|
| 385 |
+
|
| 386 |
+
if ($view)
|
| 387 |
+
echo $echo;
|
| 388 |
+
else
|
| 389 |
+
return $echo;
|
| 390 |
+
}
|
| 391 |
+
|
| 392 |
+
function utf8dec($s_String) {
|
| 393 |
+
if ( version_compare(phpversion(), '5.0.0', '>=') )
|
| 394 |
+
$s_String = html_entity_decode(htmlentities( $s_String." ", ENT_COMPAT, 'UTF-8') );
|
| 395 |
+
else
|
| 396 |
+
$s_String = RSSImport_html_entity_decode_php4( htmlentities($s_String." ") );
|
| 397 |
+
return substr($s_String, 0, strlen($s_String)-1);
|
| 398 |
+
}
|
| 399 |
+
|
| 400 |
+
function isodec($s_String) {
|
| 401 |
+
if ( version_compare(phpversion(), '5.0.0', '>=') )
|
| 402 |
+
$s_String = html_entity_decode(htmlentities($s_String." ", ENT_COMPAT, 'ISO-8859-1'));
|
| 403 |
+
else
|
| 404 |
+
$s_String = RSSImport_html_entity_decode_php4( htmlentities($s_String." ") );
|
| 405 |
+
return substr($s_String, 0, strlen($s_String)-1);
|
| 406 |
+
}
|
| 407 |
+
|
| 408 |
+
function all_convert($s_String) {
|
| 409 |
+
|
| 410 |
+
// Array for entities
|
| 411 |
+
$umlaute = array('„','“','–',' \"','–','—','‘','’','“','”','„','•','…' ,
|
| 412 |
+
'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,
|
| 413 |
+
'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�' ,'�','�','�','�','�','�','�','�','�',
|
| 414 |
+
'�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�',
|
| 415 |
+
'�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�',
|
| 416 |
+
'�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�','�',utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 417 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 418 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 419 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 420 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 421 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 422 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 423 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 424 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 425 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 426 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 427 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 428 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 429 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 430 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),
|
| 431 |
+
utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),utf8_encode('�'),chr(128),chr(129),chr(130),
|
| 432 |
+
chr(131),chr(132),chr(133),chr(134),chr(135),chr(136),chr(137),chr(138),chr(139),chr(140),chr(141),chr(142),chr(143),chr(144),chr(145),
|
| 433 |
+
chr(146),chr(147),chr(148),chr(149),chr(150),chr(151),chr(152),chr(153),chr(154),chr(155),chr(156),chr(157),chr(158),chr(159),chr(160),
|
| 434 |
+
chr(161),chr(162),chr(163),chr(164),chr(165),chr(166),chr(167),chr(168),chr(169),chr(170),chr(171),chr(172),chr(173),chr(174),chr(175),
|
| 435 |
+
chr(176),chr(177),chr(178),chr(179),chr(180),chr(181),chr(182),chr(183),chr(184),chr(185),chr(186),chr(187),chr(188),chr(189),chr(190),
|
| 436 |
+
chr(191),chr(192),chr(193),chr(194),chr(195),chr(196),chr(197),chr(198),chr(199),chr(200),chr(201),chr(202),chr(203),chr(204),chr(205),
|
| 437 |
+
chr(206),chr(207),chr(208),chr(209),chr(210),chr(211),chr(212),chr(213),chr(214),chr(215),chr(216),chr(217),chr(218),chr(219),chr(220),
|
| 438 |
+
chr(221),chr(222),chr(223),chr(224),chr(225),chr(226),chr(227),chr(228),chr(229),chr(230),chr(231),chr(232),chr(233),chr(234),chr(235),
|
| 439 |
+
chr(236),chr(237),chr(238),chr(239),chr(240),chr(241),chr(242),chr(243),chr(244),chr(245),chr(246),chr(247),chr(248),chr(249),chr(250),
|
| 440 |
+
chr(251),chr(252),chr(253),chr(254),chr(255),chr(256));
|
| 441 |
+
$htmlcode = array('„','“','–',' "','–','—','‘','’','“','”','„','•' ,
|
| 442 |
+
'…','€','‚','ƒ','„','…','†','‡','ˆ','‰','Š','‹','Œ',
|
| 443 |
+
'Ž','‘','’','“','”','•','–','—','˜','™','š','›','œ',
|
| 444 |
+
'ž','Ÿ','¡','¢','£','¤','¥','¦','§','¨','©','ª','«','¬',
|
| 445 |
+
'®','¯','°','±','²','³','´','µ','¶','·','¸','&supl;','º','»',
|
| 446 |
+
'¼','½','¾','¿','À','Á','Â','Ã','Ä','Å','Æ','Ç','È',
|
| 447 |
+
'É','Ê','Ë','Ì','Í','Î','Ï','Ð','Ñ','Ò','Ó','Ô','Õ',
|
| 448 |
+
'Ö','×','Ø','Ù','Ú','Û','Ü','Ý','Þ','ß','à','á','â',
|
| 449 |
+
'ã','ä','å','æ','ç','è','é','ê','ë','ì','í','î','ï',
|
| 450 |
+
'ð','ñ','ò','ó','ô','õ','ö','÷','ø','ù','ú','û','ü',
|
| 451 |
+
'ý','þ','ÿ','€','‚','ƒ','„','…','†','‡','ˆ','‰','Š',
|
| 452 |
+
'‹','Œ','Ž','‘','’','“','”','•','–','—','˜','™','š',
|
| 453 |
+
'›','œ','ž','Ÿ','¡','¢','£','¤','¥','¦','§','¨','©','ª',
|
| 454 |
+
'«','¬','®','¯','°','±','²','³','´','µ','¶','·','¸','&supl;',
|
| 455 |
+
'º','»','¼','½','¾','¿','À','Á','Â','Ã','Ä','Å','Æ',
|
| 456 |
+
'Ç','È','É','Ê','Ë','Ì','Í','Î','Ï','Ð','Ñ','Ò','Ó',
|
| 457 |
+
'Ô','Õ','Ö','×','Ø','Ù','Ú','Û','Ü','Ý','Þ','ß','à',
|
| 458 |
+
'á','â','ã','ä','å','æ','ç','è','é','ê','ë','ì','í',
|
| 459 |
+
'î','ï','ð','ñ','ò','ó','ô','õ','ö','÷','ø','ù','ú',
|
| 460 |
+
'û','ü','ý','þ','ÿ','€','','‚','ƒ','„','…','†','‡','ˆ',
|
| 461 |
+
'‰','Š','‹','Œ','','Ž','','','‘','’','“','”','•','–','—',
|
| 462 |
+
'˜','™','š','›','œ','','ž','Ÿ',' ','¡','¡','¡','¡','¥',
|
| 463 |
+
'¦','§','¨','©','ª','«','¬','�­','®','¯','°','±','²','³',
|
| 464 |
+
'´','µ','¶','·','¸','&supl;','º','»','¼','½','¾','¿','À',
|
| 465 |
+
'Á','Â','Ã','Ä','Å','Æ','Ç','È','É','Ê','Ë','Ì','Í',
|
| 466 |
+
'Î','Ï','Ð','Ñ','Ò','Ó','Ô','Õ','Ö','×','Ø','Ù','Ú',
|
| 467 |
+
'Û','Ü','Ý','Þ','ß','à','á','â','ã','ä','å','æ','ç',
|
| 468 |
+
'è','é','ê','ë','ì','í','î','ï','ð','ñ','ò','ó','ô',
|
| 469 |
+
'õ','ö','÷','ø','ù','ú','û','ü','ý','þ','ÿ');
|
| 470 |
+
//$s_String = str_replace($umlaute, $htmlcode, $s_String);
|
| 471 |
+
if ( version_compare(phpversion(), '5.0.0', '>=') )
|
| 472 |
+
$s_String = utf8_encode( html_entity_decode( str_replace($umlaute, $htmlcode, $s_String) ) );
|
| 473 |
+
else
|
| 474 |
+
$s_String = utf8_encode( RSSImport_html_entity_decode_php4( str_replace($umlaute, $htmlcode, $s_String) ) );
|
| 475 |
+
|
| 476 |
+
// … , …
|
| 477 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xC2\xA6~', '…', $s_String);
|
| 478 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x82\xC2\xA6~', '…', $s_String);
|
| 479 |
+
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xC2\xA6~', '…', $s_String);
|
| 480 |
+
|
| 481 |
+
// — , —
|
| 482 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xE2\x80\x9D~', '—', $s_String);
|
| 483 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\xA2\xE2\x82\xAC\xC2\x9D~', '—', $s_String);
|
| 484 |
+
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xE2\x80\x9D~', '—', $s_String);
|
| 485 |
+
|
| 486 |
+
// – , –
|
| 487 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xE2\x80\x9C~', '–', $s_String);
|
| 488 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\xA2\xE2\x82\xAC\xC5\x93~', '–', $s_String);
|
| 489 |
+
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xE2\x80\x9C~', '–', $s_String);
|
| 490 |
+
|
| 491 |
+
// ’ , ’
|
| 492 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xE2\x84\xA2~', '’', $s_String);
|
| 493 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\xA2\xE2\x80\x9E\xC2\xA2~', '’', $s_String);
|
| 494 |
+
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xE2\x84\xA2~', '’', $s_String);
|
| 495 |
+
$s_String = preg_replace('~\xD0\xBF\xD1\x97\xD0\x85~', '’', $s_String);
|
| 496 |
+
|
| 497 |
+
// ‘ , ‘
|
| 498 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xCB\x9C~', '‘', $s_String);
|
| 499 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x8B\xC5\x93~', '‘', $s_String);
|
| 500 |
+
|
| 501 |
+
// ” , ”
|
| 502 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xC2\x9D~', '”', $s_String);
|
| 503 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x82\xC2\x9D~', '”', $s_String);
|
| 504 |
+
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xD1\x9C~', '”', $s_String);
|
| 505 |
+
|
| 506 |
+
// “ , “
|
| 507 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x82\xAC\xC5\x93~', '“', $s_String);
|
| 508 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x80\x9A\xC2\xAC\xC3\x85\xE2\x80\x9C~', '“', $s_String);
|
| 509 |
+
$s_String = preg_replace('~\xD0\xB2\xD0\x82\xD1\x9A~', '“', $s_String);
|
| 510 |
+
|
| 511 |
+
// ™ , ™
|
| 512 |
+
$s_String = preg_replace('~\xC3\xA2\xE2\x80\x9E\xC2\xA2~', '™', $s_String);
|
| 513 |
+
$s_String = preg_replace('~\xC3\x83\xC2\xA2\xC3\xA2\xE2\x82\xAC\xC5\xBE\xC3\x82\xC2\xA2~', '™', $s_String);
|
| 514 |
+
|
| 515 |
+
// th
|
| 516 |
+
$s_String = preg_replace('~t\xC3\x82\xC2\xADh~', 'th', $s_String);
|
| 517 |
+
|
| 518 |
+
// .
|
| 519 |
+
$s_String = preg_replace('~.\xD0\x92+~', '.', $s_String);
|
| 520 |
+
$s_String = preg_replace('~.\xD0\x92~', '.', $s_String);
|
| 521 |
+
|
| 522 |
+
// ,
|
| 523 |
+
$s_String = preg_replace('~\x2C\xD0\x92~', ',', $s_String);
|
| 524 |
+
|
| 525 |
+
return $s_String;
|
| 526 |
+
}
|
| 527 |
+
|
| 528 |
+
/**
|
| 529 |
+
* Entfernt unvollstaendige Worte am Ende eines Strings.
|
| 530 |
+
* @author Thomas Scholz <http://toscho.de>
|
| 531 |
+
* @param $str Zeichenkette
|
| 532 |
+
* @return string
|
| 533 |
+
*/
|
| 534 |
+
function RSSImport_end_on_word($str) {
|
| 535 |
+
|
| 536 |
+
$arr = explode( ' ', trim($str) );
|
| 537 |
+
array_pop($arr);
|
| 538 |
+
|
| 539 |
+
return rtrim( implode(' ', $arr), ',;');
|
| 540 |
+
}
|
| 541 |
+
|
| 542 |
+
function RSSImport_Shortcode($atts) {
|
| 543 |
+
extract(
|
| 544 |
+
shortcode_atts( array(
|
| 545 |
+
'display' => 5,
|
| 546 |
+
'feedurl' => 'http://bueltge.de/feed/',
|
| 547 |
+
'before_desc' => '<br />',
|
| 548 |
+
'displaydescriptions' => 0,
|
| 549 |
+
'after_desc' => '',
|
| 550 |
+
'html' => 0,
|
| 551 |
+
'truncatedescchar' => 200,
|
| 552 |
+
'truncatedescstring' => ' ... ',
|
| 553 |
+
'truncatetitlechar' => '',
|
| 554 |
+
'truncatetitlestring' => ' ... ',
|
| 555 |
+
'before_date' => ' <small>',
|
| 556 |
+
'date' => 0,
|
| 557 |
+
'after_date' => '</small>',
|
| 558 |
+
'date_format' => '',
|
| 559 |
+
'before_creator' => ' <small>',
|
| 560 |
+
'creator' => 0,
|
| 561 |
+
'after_creator' => '</small>',
|
| 562 |
+
'start_items' => '<ul>',
|
| 563 |
+
'end_items' => '</ul>',
|
| 564 |
+
'start_item' => '<li>',
|
| 565 |
+
'end_item' => '</li>',
|
| 566 |
+
'target' => '',
|
| 567 |
+
'rel' => '',
|
| 568 |
+
'desc4title' => 0,
|
| 569 |
+
'charsetscan' => 0,
|
| 570 |
+
'debug' => 0,
|
| 571 |
+
'before_noitems' => '<p>',
|
| 572 |
+
'noitems' => __('No items, feed is empty.', FB_RSSI_TEXTDOMAIN ),
|
| 573 |
+
'after_noitems' => '</p>',
|
| 574 |
+
'before_error' => '<p>',
|
| 575 |
+
'error' => __('Error: Feed has an error or is not valid', FB_RSSI_TEXTDOMAIN ),
|
| 576 |
+
'after_error' => '</p>',
|
| 577 |
+
'paging' => 0,
|
| 578 |
+
'prev_paging_link' => __( '« Previous', FB_RSSI_TEXTDOMAIN ),
|
| 579 |
+
'next_paging_link' => __( 'Next »', FB_RSSI_TEXTDOMAIN ),
|
| 580 |
+
'prev_paging_title' => __( 'more items', FB_RSSI_TEXTDOMAIN ),
|
| 581 |
+
'next_paging_title' => __( 'more items', FB_RSSI_TEXTDOMAIN ),
|
| 582 |
+
'use_simplepie' => 1,
|
| 583 |
+
'view' => 0
|
| 584 |
+
), $atts)
|
| 585 |
+
);
|
| 586 |
+
//var_dump($atts);
|
| 587 |
+
|
| 588 |
+
$display = intval($display);
|
| 589 |
+
if ( strtolower($html) == 'true')
|
| 590 |
+
$html = 1;
|
| 591 |
+
$html = intval($html);
|
| 592 |
+
if ( strtolower($displaydescriptions) == 'true')
|
| 593 |
+
$displaydescriptions = 1;
|
| 594 |
+
$displaydescriptions = intval($displaydescriptions);
|
| 595 |
+
if ( strtolower($truncatedescchar) == 'true')
|
| 596 |
+
$truncatedescchar = 1;
|
| 597 |
+
$truncatedescchar = intval($truncatedescchar);
|
| 598 |
+
if ( strtolower($truncatetitlechar) == 'true')
|
| 599 |
+
$truncatetitlechar = 1;
|
| 600 |
+
$truncatetitlechar = intval($truncatetitlechar);
|
| 601 |
+
if ( strtolower($date) == 'true')
|
| 602 |
+
$date = 1;
|
| 603 |
+
$date = intval($date);
|
| 604 |
+
if ( strtolower($creator) == 'true')
|
| 605 |
+
$creator = 1;
|
| 606 |
+
$creator = intval($creator);
|
| 607 |
+
if ( strtolower($charsetscan) == 'true')
|
| 608 |
+
$charsetscan = 1;
|
| 609 |
+
$charsetscan = intval($charsetscan);
|
| 610 |
+
if ( strtolower($debug) == 'true')
|
| 611 |
+
$debug = 1;
|
| 612 |
+
$debug = intval($debug);
|
| 613 |
+
if ( strtolower($paging) == 'true')
|
| 614 |
+
$paging = 1;
|
| 615 |
+
$paging = intval($paging);
|
| 616 |
+
if ( strtolower($use_simplepie) == 'true')
|
| 617 |
+
$use_simplepie = 1;
|
| 618 |
+
$use_simplepie = intval($use_simplepie);
|
| 619 |
+
$feedurl = html_entity_decode( $feedurl ); // novaclic: undo encoding due to wordpress WYSIWYG editor
|
| 620 |
+
|
| 621 |
+
$return = RSSImport(
|
| 622 |
+
$display, $feedurl,
|
| 623 |
+
$before_desc, $displaydescriptions, $after_desc, $html,
|
| 624 |
+
$truncatedescchar, $truncatedescstring,
|
| 625 |
+
$truncatetitlechar, $truncatetitlestring,
|
| 626 |
+
$before_date, $date, $after_date, $date_format,
|
| 627 |
+
$before_creator, $creator, $after_creator,
|
| 628 |
+
$start_items, $end_items,
|
| 629 |
+
$start_item, $end_item,
|
| 630 |
+
$target,
|
| 631 |
+
$rel,
|
| 632 |
+
$desc4title,
|
| 633 |
+
$charsetscan, $debug,
|
| 634 |
+
$before_noitems, $noitems, $after_noitems,
|
| 635 |
+
$before_error, $error, $after_error,
|
| 636 |
+
$paging, $prev_paging_link, $next_paging_link, $prev_paging_title, $next_paging_title,
|
| 637 |
+
$use_simplepie,
|
| 638 |
+
$view
|
| 639 |
+
);
|
| 640 |
+
|
| 641 |
+
return $return;
|
| 642 |
+
}
|
| 643 |
+
|
| 644 |
+
function RSSImport_shortcode_quot($pee) {
|
| 645 |
+
global $shortcode_tags;
|
| 646 |
+
|
| 647 |
+
if ( !empty($shortcode_tags) && is_array($shortcode_tags) ) {
|
| 648 |
+
$tagnames = array_keys($shortcode_tags);
|
| 649 |
+
$tagregexp = join( '|', array_map('preg_quote', $tagnames) );
|
| 650 |
+
$pee = preg_replace('/\\s*?(\\[(' . $tagregexp . ')\\b.*?\\/?\\](?:.+?\\[\\/\\2\\])?)\\s*/s', '$1', $pee);
|
| 651 |
+
}
|
| 652 |
+
|
| 653 |
+
return $pee;
|
| 654 |
+
}
|
| 655 |
+
|
| 656 |
+
|
| 657 |
+
/**
|
| 658 |
+
* add quicktag-button to editor
|
| 659 |
+
*/
|
| 660 |
+
|
| 661 |
+
function RSSImport_insert_button() {
|
| 662 |
+
global $pagenow;
|
| 663 |
+
|
| 664 |
+
$post_page_pages = array('post-new.php', 'post.php', 'page-new.php', 'page.php');
|
| 665 |
+
if ( ! in_array( $pagenow, $post_page_pages ) )
|
| 666 |
+
return;
|
| 667 |
+
|
| 668 |
+
?>
|
| 669 |
+
<script type="text/javascript" charset="utf-8">
|
| 670 |
+
/* Adding Quicktag buttons to the editor WordPress ver. 3.3 and above
|
| 671 |
+
* - Button HTML ID (required)
|
| 672 |
+
* - Button display, value="" attribute (required)
|
| 673 |
+
* - Opening Tag (required)
|
| 674 |
+
* - Closing Tag (required)
|
| 675 |
+
* - Access key, accesskey="" attribute for the button (optional)
|
| 676 |
+
* - Title, title="" attribute (optional)
|
| 677 |
+
* - Priority/position on bar, 1-9 = first, 11-19 = second, 21-29 = third, etc. (optional)
|
| 678 |
+
*/
|
| 679 |
+
var id = 'rssimport',
|
| 680 |
+
text = '<?php _e( 'RSSImport', FB_RSSI_TEXTDOMAIN ); ?>',
|
| 681 |
+
start = '[RSSImport display="5" feedurl="http://feedurl.com/" before_desc="<br />" displaydescriptions="TRUE" after_desc=" " ' +
|
| 682 |
+
'html="FALSE" truncatedescchar="200" truncatedescstring=" ... " truncatetitlechar="" truncatetitlestring=" ... " ' +
|
| 683 |
+
'before_date=" <small>" date="FALSE" after_date="</small>" date_format="" before_creator=" <small>" creator="FALSE" ' +
|
| 684 |
+
'after_creator="</small>" start_items="<ul>" end_items="</ul>" start_item="<li>" end_item="</li>" target="" rel="" ' +
|
| 685 |
+
'desc4title="" charsetscan="FALSE" debug="FALSE" before_noitems="<p>" noitems="No items, feed is empty." ' +
|
| 686 |
+
'after_noitems="</p>" before_error="<p>" error="Error: Feed has an error or is not valid" after_error="</p>" ' +
|
| 687 |
+
'paging="FALSE" prev_paging_link="« Previous" next_paging_link="Next »" prev_paging_title="more items" ' +
|
| 688 |
+
'next_paging_title="more items" use_simplepie="FALSE"]',
|
| 689 |
+
end = '',
|
| 690 |
+
access = 'r',
|
| 691 |
+
title = '<?php _e( 'Import a feed with RSSImport', FB_RSSI_TEXTDOMAIN ); ?>';
|
| 692 |
+
|
| 693 |
+
QTags.addButton( id, text, start, end, access );
|
| 694 |
+
</script>
|
| 695 |
+
<?php
|
| 696 |
+
}
|
| 697 |
+
|
| 698 |
+
function RSSImport_insert_button_old() {
|
| 699 |
+
global $pagenow;
|
| 700 |
+
|
| 701 |
+
$post_page_pages = array('post-new.php', 'post.php', 'page-new.php', 'page.php');
|
| 702 |
+
if ( ! in_array( $pagenow, $post_page_pages ) )
|
| 703 |
+
return;
|
| 704 |
+
|
| 705 |
+
echo '
|
| 706 |
+
<script type="text/javascript">
|
| 707 |
+
//<![CDATA[
|
| 708 |
+
if ( typeof edButtons != \'undefined\' ) {
|
| 709 |
+
var length = edButtons.length;
|
| 710 |
+
edButtons[length] = new edButton(\'RSSImport\', \'$context\', \'[RSSImport display="5" feedurl="http://feedurl.com/"'.
|
| 711 |
+
' before_desc="<br />" displaydescriptions="TRUE" after_desc=" " html="FALSE" truncatedescchar="200" truncatedescstring=" ... "'.
|
| 712 |
+
' truncatetitlechar=" " truncatetitlestring=" ... " before_date=" <small>" date="FALSE" after_date="</small>"'.
|
| 713 |
+
' date_format="" before_creator=" <small>" creator="FALSE" after_creator="</small>" start_items="<ul>" end_items="</ul>"'.
|
| 714 |
+
' start_item="<li>" end_item="</li>" target="" rel="" desc4title="" charsetscan="FALSE" debug="FALSE" before_noitems="<p>"'.
|
| 715 |
+
' noitems="No items, feed is empty." after_noitems="</p>" before_error="<p>" error="Error: Feed has an error or is not valid"'.
|
| 716 |
+
' after_error="</p>" paging="FALSE" prev_paging_link="« Previous" next_paging_link="Next »"'.
|
| 717 |
+
' prev_paging_title="more items" next_paging_title="more items" use_simplepie="FALSE"]\', \'\', \'\');
|
| 718 |
+
function RSSImport_tag(id) {
|
| 719 |
+
id = id.replace(/RSSImport_/, \'\');
|
| 720 |
+
edInsertTag(edCanvas, id);
|
| 721 |
+
}
|
| 722 |
+
jQuery(document).ready(function() {
|
| 723 |
+
content = \'<input id="RSSImport_\'+length+\'" class="ed_button" type="button" value="' . __( 'RSSImport', FB_RSSI_TEXTDOMAIN ) .
|
| 724 |
+
'" title="' . __( 'Import a feed with RSSImport', FB_RSSI_TEXTDOMAIN ) . '" onclick="RSSImport_tag(this.id);" />\';
|
| 725 |
+
jQuery("#ed_toolbar").append(content);
|
| 726 |
+
});
|
| 727 |
+
}
|
| 728 |
+
//]]>
|
| 729 |
+
</script>';
|
| 730 |
+
}
|
| 731 |
+
|
| 732 |
+
if ( is_admin() && FB_RSSI_QUICKTAG ) {
|
| 733 |
+
if ( version_compare( $GLOBALS['wp_version'], '3.3alpha', '>=' ) )
|
| 734 |
+
add_action( 'admin_print_footer_scripts', 'RSSImport_insert_button' );
|
| 735 |
+
else
|
| 736 |
+
add_action( 'admin_footer', 'RSSImport_insert_button_old' );
|
| 737 |
+
}
|
| 738 |
+
|
| 739 |
+
if ( function_exists('add_shortcode') )
|
| 740 |
+
add_shortcode('RSSImport', 'RSSImport_Shortcode');
|
| 741 |
+
|
| 742 |
+
add_action( 'init', 'RSSImport_textdomain' );
|
| 743 |
+
|
| 744 |
+
|
| 745 |
+
|
| 746 |
+
/**
|
| 747 |
+
* code to utf-8 in PHP 4
|
| 748 |
+
*
|
| 749 |
+
* @package WP-RSSImport
|
| 750 |
+
*/
|
| 751 |
+
function RSSImport_code_to_utf8($num) {
|
| 752 |
+
|
| 753 |
+
if ($num <= 0x7F) {
|
| 754 |
+
return chr($num);
|
| 755 |
+
} elseif ($num <= 0x7FF) {
|
| 756 |
+
return chr(($num >> 0x06) + 0xC0) . chr(($num & 0x3F) + 128);
|
| 757 |
+
} elseif ($num <= 0xFFFF) {
|
| 758 |
+
return chr(($num >> 0x0C) + 0xE0) . chr((($num >> 0x06) & 0x3F) + 0x80) . chr(($num & 0x3F) + 0x80);
|
| 759 |
+
} elseif ($num <= 0x1FFFFF) {
|
| 760 |
+
return chr(($num >> 0x12) + 0xF0) . chr((($num >> 0x0C) & 0x3F) + 0x80) . chr((($num >> 0x06) & 0x3F) + 0x80) . chr(($num & 0x3F) + 0x80);
|
| 761 |
+
}
|
| 762 |
+
|
| 763 |
+
return '';
|
| 764 |
+
}
|
| 765 |
+
|
| 766 |
+
|
| 767 |
+
/**
|
| 768 |
+
* html_entity_decode for PHP 4
|
| 769 |
+
*
|
| 770 |
+
* @package WP-RSSImport
|
| 771 |
+
*/
|
| 772 |
+
function RSSImport_html_entity_decode_php4($str) {
|
| 773 |
+
$htmlentities = array (
|
| 774 |
+
"Á" => chr(195).chr(129),
|
| 775 |
+
"á" => chr(195).chr(161),
|
| 776 |
+
"Â" => chr(195).chr(130),
|
| 777 |
+
"â" => chr(195).chr(162),
|
| 778 |
+
"´" => chr(194).chr(180),
|
| 779 |
+
"Æ" => chr(195).chr(134),
|
| 780 |
+
"æ" => chr(195).chr(166),
|
| 781 |
+
"À" => chr(195).chr(128),
|
| 782 |
+
"à" => chr(195).chr(160),
|
| 783 |
+
"ℵ" => chr(226).chr(132).chr(181),
|
| 784 |
+
"Α" => chr(206).chr(145),
|
| 785 |
+
"α" => chr(206).chr(177),
|
| 786 |
+
"&" => chr(38),
|
| 787 |
+
"∧" => chr(226).chr(136).chr(167),
|
| 788 |
+
"∠" => chr(226).chr(136).chr(160),
|
| 789 |
+
"Å" => chr(195).chr(133),
|
| 790 |
+
"å" => chr(195).chr(165),
|
| 791 |
+
"≈" => chr(226).chr(137).chr(136),
|
| 792 |
+
"Ã" => chr(195).chr(131),
|
| 793 |
+
"ã" => chr(195).chr(163),
|
| 794 |
+
"Ä" => chr(195).chr(132),
|
| 795 |
+
"ä" => chr(195).chr(164),
|
| 796 |
+
"„" => chr(226).chr(128).chr(158),
|
| 797 |
+
"Β" => chr(206).chr(146),
|
| 798 |
+
"β" => chr(206).chr(178),
|
| 799 |
+
"¦" => chr(194).chr(166),
|
| 800 |
+
"•" => chr(226).chr(128).chr(162),
|
| 801 |
+
"∩" => chr(226).chr(136).chr(169),
|
| 802 |
+
"Ç" => chr(195).chr(135),
|
| 803 |
+
"ç" => chr(195).chr(167),
|
| 804 |
+
"¸" => chr(194).chr(184),
|
| 805 |
+
"¢" => chr(194).chr(162),
|
| 806 |
+
"Χ" => chr(206).chr(167),
|
| 807 |
+
"χ" => chr(207).chr(135),
|
| 808 |
+
"ˆ" => chr(203).chr(134),
|
| 809 |
+
"♣" => chr(226).chr(153).chr(163),
|
| 810 |
+
"≅" => chr(226).chr(137).chr(133),
|
| 811 |
+
"©" => chr(194).chr(169),
|
| 812 |
+
"↵" => chr(226).chr(134).chr(181),
|
| 813 |
+
"∪" => chr(226).chr(136).chr(170),
|
| 814 |
+
"¤" => chr(194).chr(164),
|
| 815 |
+
"†" => chr(226).chr(128).chr(160),
|
| 816 |
+
"‡" => chr(226).chr(128).chr(161),
|
| 817 |
+
"↓" => chr(226).chr(134).chr(147),
|
| 818 |
+
"⇓" => chr(226).chr(135).chr(147),
|
| 819 |
+
"°" => chr(194).chr(176),
|
| 820 |
+
"Δ" => chr(206).chr(148),
|
| 821 |
+
"δ" => chr(206).chr(180),
|
| 822 |
+
"♦" => chr(226).chr(153).chr(166),
|
| 823 |
+
"÷" => chr(195).chr(183),
|
| 824 |
+
"É" => chr(195).chr(137),
|
| 825 |
+
"é" => chr(195).chr(169),
|
| 826 |
+
"Ê" => chr(195).chr(138),
|
| 827 |
+
"ê" => chr(195).chr(170),
|
| 828 |
+
"È" => chr(195).chr(136),
|
| 829 |
+
"è" => chr(195).chr(168),
|
| 830 |
+
"∅" => chr(226).chr(136).chr(133),
|
| 831 |
+
" " => chr(226).chr(128).chr(131),
|
| 832 |
+
" " => chr(226).chr(128).chr(130),
|
| 833 |
+
"Ε" => chr(206).chr(149),
|
| 834 |
+
"ε" => chr(206).chr(181),
|
| 835 |
+
"≡" => chr(226).chr(137).chr(161),
|
| 836 |
+
"Η" => chr(206).chr(151),
|
| 837 |
+
"η" => chr(206).chr(183),
|
| 838 |
+
"Ð" => chr(195).chr(144),
|
| 839 |
+
"ð" => chr(195).chr(176),
|
| 840 |
+
"Ë" => chr(195).chr(139),
|
| 841 |
+
"ë" => chr(195).chr(171),
|
| 842 |
+
"€" => chr(226).chr(130).chr(172),
|
| 843 |
+
"∃" => chr(226).chr(136).chr(131),
|
| 844 |
+
"ƒ" => chr(198).chr(146),
|
| 845 |
+
"∀" => chr(226).chr(136).chr(128),
|
| 846 |
+
"½" => chr(194).chr(189),
|
| 847 |
+
"¼" => chr(194).chr(188),
|
| 848 |
+
"¾" => chr(194).chr(190),
|
| 849 |
+
"⁄" => chr(226).chr(129).chr(132),
|
| 850 |
+
"Γ" => chr(206).chr(147),
|
| 851 |
+
"γ" => chr(206).chr(179),
|
| 852 |
+
"≥" => chr(226).chr(137).chr(165),
|
| 853 |
+
"↔" => chr(226).chr(134).chr(148),
|
| 854 |
+
"⇔" => chr(226).chr(135).chr(148),
|
| 855 |
+
"♥" => chr(226).chr(153).chr(165),
|
| 856 |
+
"…" => chr(226).chr(128).chr(166),
|
| 857 |
+
"Í" => chr(195).chr(141),
|
| 858 |
+
"í" => chr(195).chr(173),
|
| 859 |
+
"Î" => chr(195).chr(142),
|
| 860 |
+
"î" => chr(195).chr(174),
|
| 861 |
+
"¡" => chr(194).chr(161),
|
| 862 |
+
"Ì" => chr(195).chr(140),
|
| 863 |
+
"ì" => chr(195).chr(172),
|
| 864 |
+
"ℑ" => chr(226).chr(132).chr(145),
|
| 865 |
+
"∞" => chr(226).chr(136).chr(158),
|
| 866 |
+
"∫" => chr(226).chr(136).chr(171),
|
| 867 |
+
"Ι" => chr(206).chr(153),
|
| 868 |
+
"ι" => chr(206).chr(185),
|
| 869 |
+
"¿" => chr(194).chr(191),
|
| 870 |
+
"∈" => chr(226).chr(136).chr(136),
|
| 871 |
+
"Ï" => chr(195).chr(143),
|
| 872 |
+
"ï" => chr(195).chr(175),
|
| 873 |
+
"Κ" => chr(206).chr(154),
|
| 874 |
+
"κ" => chr(206).chr(186),
|
| 875 |
+
"Λ" => chr(206).chr(155),
|
| 876 |
+
"λ" => chr(206).chr(187),
|
| 877 |
+
"⟨" => chr(226).chr(140).chr(169),
|
| 878 |
+
"«" => chr(194).chr(171),
|
| 879 |
+
"←" => chr(226).chr(134).chr(144),
|
| 880 |
+
"⇐" => chr(226).chr(135).chr(144),
|
| 881 |
+
"⌈" => chr(226).chr(140).chr(136),
|
| 882 |
+
"“" => chr(226).chr(128).chr(156),
|
| 883 |
+
"≤" => chr(226).chr(137).chr(164),
|
| 884 |
+
"⌊" => chr(226).chr(140).chr(138),
|
| 885 |
+
"∗" => chr(226).chr(136).chr(151),
|
| 886 |
+
"◊" => chr(226).chr(151).chr(138),
|
| 887 |
+
"‎" => chr(226).chr(128).chr(142),
|
| 888 |
+
"‹" => chr(226).chr(128).chr(185),
|
| 889 |
+
"‘" => chr(226).chr(128).chr(152),
|
| 890 |
+
"¯" => chr(194).chr(175),
|
| 891 |
+
"—" => chr(226).chr(128).chr(148),
|
| 892 |
+
"µ" => chr(194).chr(181),
|
| 893 |
+
"·" => chr(194).chr(183),
|
| 894 |
+
"−" => chr(226).chr(136).chr(146),
|
| 895 |
+
"Μ" => chr(206).chr(156),
|
| 896 |
+
"μ" => chr(206).chr(188),
|
| 897 |
+
"∇" => chr(226).chr(136).chr(135),
|
| 898 |
+
" " => chr(194).chr(160),
|
| 899 |
+
"–" => chr(226).chr(128).chr(147),
|
| 900 |
+
"≠" => chr(226).chr(137).chr(160),
|
| 901 |
+
"∋" => chr(226).chr(136).chr(139),
|
| 902 |
+
"¬" => chr(194).chr(172),
|
| 903 |
+
"∉" => chr(226).chr(136).chr(137),
|
| 904 |
+
"⊄" => chr(226).chr(138).chr(132),
|
| 905 |
+
"Ñ" => chr(195).chr(145),
|
| 906 |
+
"ñ" => chr(195).chr(177),
|
| 907 |
+
"Ν" => chr(206).chr(157),
|
| 908 |
+
"ν" => chr(206).chr(189),
|
| 909 |
+
"Ó" => chr(195).chr(147),
|
| 910 |
+
"ó" => chr(195).chr(179),
|
| 911 |
+
"Ô" => chr(195).chr(148),
|
| 912 |
+
"ô" => chr(195).chr(180),
|
| 913 |
+
"Œ" => chr(197).chr(146),
|
| 914 |
+
"œ" => chr(197).chr(147),
|
| 915 |
+
"Ò" => chr(195).chr(146),
|
| 916 |
+
"ò" => chr(195).chr(178),
|
| 917 |
+
"‾" => chr(226).chr(128).chr(190),
|
| 918 |
+
"Ω" => chr(206).chr(169),
|
| 919 |
+
"ω" => chr(207).chr(137),
|
| 920 |
+
"Ο" => chr(206).chr(159),
|
| 921 |
+
"ο" => chr(206).chr(191),
|
| 922 |
+
"⊕" => chr(226).chr(138).chr(149),
|
| 923 |
+
"∨" => chr(226).chr(136).chr(168),
|
| 924 |
+
"ª" => chr(194).chr(170),
|
| 925 |
+
"º" => chr(194).chr(186),
|
| 926 |
+
"Ø" => chr(195).chr(152),
|
| 927 |
+
"ø" => chr(195).chr(184),
|
| 928 |
+
"Õ" => chr(195).chr(149),
|
| 929 |
+
"õ" => chr(195).chr(181),
|
| 930 |
+
"⊗" => chr(226).chr(138).chr(151),
|
| 931 |
+
"Ö" => chr(195).chr(150),
|
| 932 |
+
"ö" => chr(195).chr(182),
|
| 933 |
+
"¶" => chr(194).chr(182),
|
| 934 |
+
"∂" => chr(226).chr(136).chr(130),
|
| 935 |
+
"‰" => chr(226).chr(128).chr(176),
|
| 936 |
+
"⊥" => chr(226).chr(138).chr(165),
|
| 937 |
+
"Φ" => chr(206).chr(166),
|
| 938 |
+
"φ" => chr(207).chr(134),
|
| 939 |
+
"Π" => chr(206).chr(160),
|
| 940 |
+
"π" => chr(207).chr(128),
|
| 941 |
+
"ϖ" => chr(207).chr(150),
|
| 942 |
+
"±" => chr(194).chr(177),
|
| 943 |
+
"£" => chr(194).chr(163),
|
| 944 |
+
"′" => chr(226).chr(128).chr(178),
|
| 945 |
+
"″" => chr(226).chr(128).chr(179),
|
| 946 |
+
"∏" => chr(226).chr(136).chr(143),
|
| 947 |
+
"∝" => chr(226).chr(136).chr(157),
|
| 948 |
+
"Ψ" => chr(206).chr(168),
|
| 949 |
+
"ψ" => chr(207).chr(136),
|
| 950 |
+
"√" => chr(226).chr(136).chr(154),
|
| 951 |
+
"⟩" => chr(226).chr(140).chr(170),
|
| 952 |
+
"»" => chr(194).chr(187),
|
| 953 |
+
"→" => chr(226).chr(134).chr(146),
|
| 954 |
+
"⇒" => chr(226).chr(135).chr(146),
|
| 955 |
+
"⌉" => chr(226).chr(140).chr(137),
|
| 956 |
+
"”" => chr(226).chr(128).chr(157),
|
| 957 |
+
"ℜ" => chr(226).chr(132).chr(156),
|
| 958 |
+
"®" => chr(194).chr(174),
|
| 959 |
+
"⌋" => chr(226).chr(140).chr(139),
|
| 960 |
+
"Ρ" => chr(206).chr(161),
|
| 961 |
+
"ρ" => chr(207).chr(129),
|
| 962 |
+
"‏" => chr(226).chr(128).chr(143),
|
| 963 |
+
"›" => chr(226).chr(128).chr(186),
|
| 964 |
+
"’" => chr(226).chr(128).chr(153),
|
| 965 |
+
"‚" => chr(226).chr(128).chr(154),
|
| 966 |
+
"Š" => chr(197).chr(160),
|
| 967 |
+
"š" => chr(197).chr(161),
|
| 968 |
+
"⋅" => chr(226).chr(139).chr(133),
|
| 969 |
+
"§" => chr(194).chr(167),
|
| 970 |
+
"­" => chr(194).chr(173),
|
| 971 |
+
"Σ" => chr(206).chr(163),
|
| 972 |
+
"σ" => chr(207).chr(131),
|
| 973 |
+
"ς" => chr(207).chr(130),
|
| 974 |
+
"∼" => chr(226).chr(136).chr(188),
|
| 975 |
+
"♠" => chr(226).chr(153).chr(160),
|
| 976 |
+
"⊂" => chr(226).chr(138).chr(130),
|
| 977 |
+
"⊆" => chr(226).chr(138).chr(134),
|
| 978 |
+
"∑" => chr(226).chr(136).chr(145),
|
| 979 |
+
"¹" => chr(194).chr(185),
|
| 980 |
+
"²" => chr(194).chr(178),
|
| 981 |
+
"³" => chr(194).chr(179),
|
| 982 |
+
"⊃" => chr(226).chr(138).chr(131),
|
| 983 |
+
"⊇" => chr(226).chr(138).chr(135),
|
| 984 |
+
"ß" => chr(195).chr(159),
|
| 985 |
+
"Τ" => chr(206).chr(164),
|
| 986 |
+
"τ" => chr(207).chr(132),
|
| 987 |
+
"∴" => chr(226).chr(136).chr(180),
|
| 988 |
+
"Θ" => chr(206).chr(152),
|
| 989 |
+
"θ" => chr(206).chr(184),
|
| 990 |
+
"ϑ" => chr(207).chr(145),
|
| 991 |
+
" " => chr(226).chr(128).chr(137),
|
| 992 |
+
"Þ" => chr(195).chr(158),
|
| 993 |
+
"þ" => chr(195).chr(190),
|
| 994 |
+
"˜" => chr(203).chr(156),
|
| 995 |
+
"×" => chr(195).chr(151),
|
| 996 |
+
"™" => chr(226).chr(132).chr(162),
|
| 997 |
+
"Ú" => chr(195).chr(154),
|
| 998 |
+
"ú" => chr(195).chr(186),
|
| 999 |
+
"↑" => chr(226).chr(134).chr(145),
|
| 1000 |
+
"⇑" => chr(226).chr(135).chr(145),
|
| 1001 |
+
"Û" => chr(195).chr(155),
|
| 1002 |
+
"û" => chr(195).chr(187),
|
| 1003 |
+
"Ù" => chr(195).chr(153),
|
| 1004 |
+
"ù" => chr(195).chr(185),
|
| 1005 |
+
"¨" => chr(194).chr(168),
|
| 1006 |
+
"ϒ" => chr(207).chr(146),
|
| 1007 |
+
"Υ" => chr(206).chr(165),
|
| 1008 |
+
"υ" => chr(207).chr(133),
|
| 1009 |
+
"Ü" => chr(195).chr(156),
|
| 1010 |
+
"ü" => chr(195).chr(188),
|
| 1011 |
+
"℘" => chr(226).chr(132).chr(152),
|
| 1012 |
+
"Ξ" => chr(206).chr(158),
|
| 1013 |
+
"ξ" => chr(206).chr(190),
|
| 1014 |
+
"Ý" => chr(195).chr(157),
|
| 1015 |
+
"ý" => chr(195).chr(189),
|
| 1016 |
+
"¥" => chr(194).chr(165),
|
| 1017 |
+
"ÿ" => chr(195).chr(191),
|
| 1018 |
+
"Ÿ" => chr(197).chr(184),
|
| 1019 |
+
"Ζ" => chr(206).chr(150),
|
| 1020 |
+
"ζ" => chr(206).chr(182),
|
| 1021 |
+
"‍" => chr(226).chr(128).chr(141),
|
| 1022 |
+
"‌" => chr(226).chr(128).chr(140),
|
| 1023 |
+
">" => ">",
|
| 1024 |
+
"<" => "<"
|
| 1025 |
+
);
|
| 1026 |
+
|
| 1027 |
+
$return = strtr($str, $htmlentities);
|
| 1028 |
+
$return = preg_replace('~&#x([0-9a-f]+);~ei', 'RSSImport_code_to_utf8(hexdec("\\1"))', $return);
|
| 1029 |
+
$return = preg_replace('~&#([0-9]+);~e', 'RSSImport_code_to_utf8(\\1)', $return);
|
| 1030 |
+
|
| 1031 |
+
return $return;
|
| 1032 |
+
}
|
| 1033 |
+
|
| 1034 |
+
|
| 1035 |
+
// check class wp_widget exists
|
| 1036 |
+
if ( class_exists('WP_Widget') ) {
|
| 1037 |
+
|
| 1038 |
+
class RSSImport_Widget extends WP_Widget {
|
| 1039 |
+
|
| 1040 |
+
function __construct() {
|
| 1041 |
+
$widget_ops = array('classname' => 'rssimport', 'description' => __( 'Entries from any RSS or Atom feed', FB_RSSI_TEXTDOMAIN ) );
|
| 1042 |
+
parent::__construct('rssimport', __( 'RSSImport' ), $widget_ops);
|
| 1043 |
+
}
|
| 1044 |
+
|
| 1045 |
+
function widget($args, $instance) {
|
| 1046 |
+
extract($args, EXTR_SKIP);
|
| 1047 |
+
|
| 1048 |
+
$title = empty($instance['title']) ? ' ' : apply_filters('widget_title', $instance['title']);
|
| 1049 |
+
$titlelink = empty($instance['titlelink']) ? '' : $instance['titlelink'];
|
| 1050 |
+
$display = empty($instance['display']) ? '5' : $instance['display'];
|
| 1051 |
+
$feedurl = empty($instance['feedurl']) ? 'http://bueltge.de/feed/' : $instance['feedurl'];
|
| 1052 |
+
$before_desc = empty($instance['before_desc']) ? '' : $instance['before_desc'];
|
| 1053 |
+
$displaydescriptions = empty($instance['displaydescriptions']) ? '0' : $instance['displaydescriptions'];
|
| 1054 |
+
$after_desc = empty($instance['after_desc']) ? '' : $instance['after_desc'];
|
| 1055 |
+
$html = empty($instance['html']) ? '0' : $instance['html'];
|
| 1056 |
+
$truncatedescchar = empty($instance['truncatedescchar']) ? '200' : $instance['truncatedescchar'];
|
| 1057 |
+
$truncatedescstring = empty($instance['truncatedescstring']) ? '' : $instance['truncatedescstring'];
|
| 1058 |
+
$truncatetitlechar = empty($instance['truncatetitlechar']) ? '' : $instance['truncatetitlechar'];
|
| 1059 |
+
$truncatetitlestring = empty($instance['truncatetitlestring']) ? ' ... ' : $instance['truncatetitlestring'];
|
| 1060 |
+
$before_date = empty($instance['before_date']) ? ' <small>' : $instance['before_date'];
|
| 1061 |
+
$date = empty($instance['date']) ? '0' : $instance['date'];
|
| 1062 |
+
$after_date = empty($instance['after_date']) ? '</small>' : $instance['after_date'];
|
| 1063 |
+
$date_format = empty($instance['date_format']) ? '' : $instance['date_format'];
|
| 1064 |
+
$before_creator = empty($instance['before_creator']) ? ' <small>' : $instance['before_creator'];
|
| 1065 |
+
$creator = empty($instance['creator']) ? '0' : $instance['creator'];
|
| 1066 |
+
$after_creator = empty($instance['after_creator']) ? '</small>' : $instance['after_creator'];
|
| 1067 |
+
$start_items = empty($instance['start_items']) ? '<ul>' : $instance['start_items'];
|
| 1068 |
+
$end_items = empty($instance['end_items']) ? '</ul>' : $instance['end_items'];
|
| 1069 |
+
$start_item = empty($instance['start_item']) ? '<li>' : $instance['start_item'];
|
| 1070 |
+
$end_item = empty($instance['end_item']) ? '</li>' : $instance['end_item'];
|
| 1071 |
+
$target = empty($instance['target']) ? '' : $instance['target'];
|
| 1072 |
+
$rel = empty($instance['rel']) ? '' : $instance['rel'];
|
| 1073 |
+
$desc4title = empty($instance['desc4title']) ? '0' : $instance['desc4title'];
|
| 1074 |
+
$charsetscan = empty($instance['charsetscan']) ? '0' : $instance['charsetscan'];
|
| 1075 |
+
$debug = empty($instance['debug']) ? '0' : $instance['debug'];
|
| 1076 |
+
$before_noitems = empty($instance['before_noitems']) ? '<p>' : $instance['before_noitems'];
|
| 1077 |
+
$noitems = empty($instance['noitems']) ? __('No items, feed is empty.', FB_RSSI_TEXTDOMAIN) : $instance['noitems'];
|
| 1078 |
+
$after_noitems = empty($instance['after_noitems']) ? '</p>' : $instance['after_noitems'];
|
| 1079 |
+
$before_error = empty($instance['before_error']) ? '<p>' : $instance['before_error'];
|
| 1080 |
+
$error = empty($instance['error']) ? __('Error: Feed has an error or is not valid', FB_RSSI_TEXTDOMAIN) : $instance['error'];
|
| 1081 |
+
$after_error = empty($instance['after_error']) ? '</p>' : $instance['after_error'];
|
| 1082 |
+
$paging = empty($instance['paging']) ? '0' : $instance['paging'];
|
| 1083 |
+
$prev_paging_link = empty($instance['prev_paging_link']) ? __('« Previous', FB_RSSI_TEXTDOMAIN) : $instance['prev_paging_link'];
|
| 1084 |
+
$next_paging_link = empty($instance['next_paging_link']) ? __('Next »', FB_RSSI_TEXTDOMAIN) : $instance['next_paging_link'];
|
| 1085 |
+
$prev_paging_title = empty($instance['prev_paging_title']) ? __('more items', FB_RSSI_TEXTDOMAIN) : $instance['prev_paging_title'];
|
| 1086 |
+
$next_paging_title = empty($instance['next_paging_title']) ? __('more items', FB_RSSI_TEXTDOMAIN) : $instance['next_paging_title'];
|
| 1087 |
+
$use_simplepie = empty($instance['use_simplepie']) ? '1' : $instance['use_simplepie'];
|
| 1088 |
+
$view = empty($instance['view']) ? '1' : $instance['view'];
|
| 1089 |
+
|
| 1090 |
+
echo $before_widget;
|
| 1091 |
+
if ( $titlelink != '' )
|
| 1092 |
+
$title = '<a href="' . $titlelink . '">' . $title . '</a>';
|
| 1093 |
+
echo $before_title . $title . $after_title;
|
| 1094 |
+
RSSImport(
|
| 1095 |
+
$display, $feedurl,
|
| 1096 |
+
$before_desc, $displaydescriptions, $after_desc, $html, $truncatedescchar, $truncatedescstring,
|
| 1097 |
+
$truncatetitlechar, $truncatetitlestring,
|
| 1098 |
+
$before_date, $date, $after_date, $date_format,
|
| 1099 |
+
$before_creator, $creator, $after_creator,
|
| 1100 |
+
$start_items, $end_items,
|
| 1101 |
+
$start_item, $end_item,
|
| 1102 |
+
$target,
|
| 1103 |
+
$rel,
|
| 1104 |
+
$desc4title,
|
| 1105 |
+
$charsetscan, $debug,
|
| 1106 |
+
$before_noitems, $noitems, $after_noitems,
|
| 1107 |
+
$before_error, $error, $after_error,
|
| 1108 |
+
$paging, $prev_paging_link, $next_paging_link, $prev_paging_title, $next_paging_title,
|
| 1109 |
+
$use_simplepie,
|
| 1110 |
+
$view
|
| 1111 |
+
);
|
| 1112 |
+
echo $after_widget;
|
| 1113 |
+
}
|
| 1114 |
+
|
| 1115 |
+
function update($new_instance, $old_instance) {
|
| 1116 |
+
$instance['instance'] = $old_instance;
|
| 1117 |
+
$instance['title'] = strip_tags( $new_instance['title'] );
|
| 1118 |
+
$instance['titlelink'] = esc_url($new_instance['titlelink']);
|
| 1119 |
+
$instance['display'] = (int) $new_instance['display'];
|
| 1120 |
+
$instance['feedurl'] = $new_instance['feedurl'];
|
| 1121 |
+
$instance['before_desc'] = $new_instance['before_desc'];
|
| 1122 |
+
$instance['displaydescriptions'] = (int) $new_instance['displaydescriptions'];
|
| 1123 |
+
$instance['after_desc'] = stripslashes_deep( $new_instance['after_desc'] );
|
| 1124 |
+
$instance['html'] = (int) $new_instance['html'];
|
| 1125 |
+
$instance['truncatedescchar'] = (int) $new_instance['truncatedescchar'];
|
| 1126 |
+
$instance['truncatedescstring'] = $new_instance['truncatedescstring'];
|
| 1127 |
+
$instance['truncatetitlechar'] = (int) $new_instance['truncatetitlechar'];
|
| 1128 |
+
$instance['truncatetitlestring'] = $new_instance['truncatetitlestring'];
|
| 1129 |
+
$instance['before_date'] = $new_instance['before_date'];
|
| 1130 |
+
$instance['date'] = (int) $new_instance['date'];
|
| 1131 |
+
$instance['after_date'] = $new_instance['after_date'];
|
| 1132 |
+
$instance['date_format'] = $new_instance['date_format'];
|
| 1133 |
+
$instance['before_creator'] = $new_instance['before_creator'];
|
| 1134 |
+
$instance['creator'] = (int) $new_instance['creator'];
|
| 1135 |
+
$instance['after_creator'] = $new_instance['after_creator'];
|
| 1136 |
+
$instance['start_items'] = $new_instance['start_items'];
|
| 1137 |
+
$instance['end_items'] = $new_instance['end_items'];
|
| 1138 |
+
$instance['start_item'] = $new_instance['start_item'];
|
| 1139 |
+
$instance['end_item'] = $new_instance['end_item'];
|
| 1140 |
+
$instance['target'] = $new_instance['target'];
|
| 1141 |
+
$instance['rel'] = $new_instance['rel'];
|
| 1142 |
+
$instance['desc4title'] = (int) $new_instance['desc4title'];
|
| 1143 |
+
$instance['charsetscan'] = (int) $new_instance['charsetscan'];
|
| 1144 |
+
$instance['debug'] = (int) $new_instance['debug'];
|
| 1145 |
+
$instance['view'] = (int) $new_instance['view'];
|
| 1146 |
+
$instance['before_noitems'] = $new_instance['before_noitems'];
|
| 1147 |
+
$instance['noitems'] = $new_instance['noitems'];
|
| 1148 |
+
$instance['after_noitems'] = $new_instance['after_noitems'];
|
| 1149 |
+
$instance['before_error'] = $new_instance['before_error'];
|
| 1150 |
+
$instance['error'] = $new_instance['error'];
|
| 1151 |
+
$instance['after_error'] = $new_instance['after_error'];
|
| 1152 |
+
$instance['paging'] = (int) $new_instance['paging'];
|
| 1153 |
+
$instance['prev_paging_link'] = $new_instance['prev_paging_link'];
|
| 1154 |
+
$instance['next_paging_link'] = $new_instance['next_paging_link'];
|
| 1155 |
+
$instance['prev_paging_title'] = $new_instance['prev_paging_title'];
|
| 1156 |
+
$instance['next_paging_title'] = $new_instance['next_paging_title'];
|
| 1157 |
+
$instance['use_simplepie'] = (int) $new_instance['use_simplepie'];
|
| 1158 |
+
|
| 1159 |
+
if ( current_user_can('unfiltered_html') )
|
| 1160 |
+
return $instance;
|
| 1161 |
+
else
|
| 1162 |
+
return stripslashes( strip_tags ( $instance ) );
|
| 1163 |
+
}
|
| 1164 |
+
|
| 1165 |
+
function form($instance) {
|
| 1166 |
+
$instance = wp_parse_args(
|
| 1167 |
+
(array) $instance, array(
|
| 1168 |
+
'title' => '',
|
| 1169 |
+
'titlelink' => '',
|
| 1170 |
+
'display' => 5,
|
| 1171 |
+
'feedurl' => 'http://bueltge.de/feed/',
|
| 1172 |
+
'before_desc' => '',
|
| 1173 |
+
'displaydescriptions' => 0,
|
| 1174 |
+
'after_desc' => '',
|
| 1175 |
+
'html' => 0,
|
| 1176 |
+
'truncatedescchar' => 200,
|
| 1177 |
+
'truncatedescstring' => ' ... ',
|
| 1178 |
+
'truncatetitlechar' => '',
|
| 1179 |
+
'truncatetitlestring' => ' ... ',
|
| 1180 |
+
'before_date' => ' <small>',
|
| 1181 |
+
'date' => 0,
|
| 1182 |
+
'after_date' => '</small>',
|
| 1183 |
+
'date_format' => '',
|
| 1184 |
+
'before_creator' => ' <small>',
|
| 1185 |
+
'creator' => 0,
|
| 1186 |
+
'after_creator' => '</small>',
|
| 1187 |
+
'start_items' => '<ul>',
|
| 1188 |
+
'end_items' => '</ul>',
|
| 1189 |
+
'start_item' => '<li>',
|
| 1190 |
+
'end_item' => '</li>',
|
| 1191 |
+
'target' => '',
|
| 1192 |
+
'rel' => '',
|
| 1193 |
+
'desc4title' => 0,
|
| 1194 |
+
'charsetscan' => 0,
|
| 1195 |
+
'debug' => 0,
|
| 1196 |
+
'view' => 1,
|
| 1197 |
+
'before_noitems' => '<p>',
|
| 1198 |
+
'noitems' => __('No items, feed is empty.', FB_RSSI_TEXTDOMAIN),
|
| 1199 |
+
'after_noitems' => '</p>',
|
| 1200 |
+
'before_error' => '<p>',
|
| 1201 |
+
'error' => __('Error: Feed has an error or is not valid', FB_RSSI_TEXTDOMAIN),
|
| 1202 |
+
'after_error' => '</p>',
|
| 1203 |
+
'paging' => 0,
|
| 1204 |
+
'prev_paging_link' => __('« Previous', FB_RSSI_TEXTDOMAIN),
|
| 1205 |
+
'next_paging_link' => __('Next »', FB_RSSI_TEXTDOMAIN),
|
| 1206 |
+
'prev_paging_title' => __('more items', FB_RSSI_TEXTDOMAIN),
|
| 1207 |
+
'next_paging_title' => __('more items', FB_RSSI_TEXTDOMAIN),
|
| 1208 |
+
'use_simplepie' => 1
|
| 1209 |
+
)
|
| 1210 |
+
);
|
| 1211 |
+
|
| 1212 |
+
$title = strip_tags($instance['title']);
|
| 1213 |
+
$titlelink = esc_url($instance['titlelink']);
|
| 1214 |
+
$display = (int) $instance['display'];
|
| 1215 |
+
$feedurl = $instance['feedurl'];
|
| 1216 |
+
$before_desc = $instance['before_desc'];
|
| 1217 |
+
$displaydescriptions = (int) $instance['displaydescriptions'];
|
| 1218 |
+
$after_desc = format_to_edit( $instance['after_desc'] );
|
| 1219 |
+
$html = (int) $instance['html'];
|
| 1220 |
+
$truncatedescchar = (int) $instance['truncatedescchar'];
|
| 1221 |
+
$truncatedescstring = (int) $instance['truncatedescstring'];
|
| 1222 |
+
$truncatetitlechar = $instance['truncatetitlechar'];
|
| 1223 |
+
$truncatetitlestring = $instance['truncatetitlestring'];
|
| 1224 |
+
$before_date = $instance['before_date'];
|
| 1225 |
+
$date = (int) $instance['date'];
|
| 1226 |
+
$after_date = $instance['after_date'];
|
| 1227 |
+
$date_format = $instance['date_format'];
|
| 1228 |
+
$before_creator = $instance['before_creator'];
|
| 1229 |
+
$creator = (int) $instance['creator'];
|
| 1230 |
+
$after_creator = $instance['after_creator'];
|
| 1231 |
+
$start_items = $instance['start_items'];
|
| 1232 |
+
$end_items = $instance['end_items'];
|
| 1233 |
+
$start_item = $instance['start_item'];
|
| 1234 |
+
$end_item = $instance['end_item'];
|
| 1235 |
+
$target = $instance['target'];
|
| 1236 |
+
$rel = $instance['rel'];
|
| 1237 |
+
$desc4title = (int) $instance['desc4title'];
|
| 1238 |
+
$charsetscan = (int) $instance['charsetscan'];
|
| 1239 |
+
$debug = (int) $instance['debug'];
|
| 1240 |
+
$before_noitems = $instance['before_noitems'];
|
| 1241 |
+
$noitems = $instance['noitems'];
|
| 1242 |
+
$after_noitems = $instance['after_noitems'];
|
| 1243 |
+
$before_error = $instance['before_error'];
|
| 1244 |
+
$error = $instance['error'];
|
| 1245 |
+
$after_error = $instance['after_error'];
|
| 1246 |
+
$paging = (int) $instance['paging'];
|
| 1247 |
+
$prev_paging_link = $instance['prev_paging_link'];
|
| 1248 |
+
$next_paging_link = $instance['next_paging_link'];
|
| 1249 |
+
$prev_paging_title = $instance['prev_paging_title'];
|
| 1250 |
+
$next_paging_title = $instance['next_paging_title'];
|
| 1251 |
+
$use_simplepie = (int) $instance['use_simplepie'];
|
| 1252 |
+
$view = (int) $instance['view'];
|
| 1253 |
+
?>
|
| 1254 |
+
<p>
|
| 1255 |
+
<label for="<?php echo $this->get_field_id('title'); ?>"><?php _e( 'Title:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('title'); ?>" name="<?php echo $this->get_field_name('title'); ?>" type="text" value="<?php echo esc_attr($title); ?>" /></label>
|
| 1256 |
+
</p>
|
| 1257 |
+
<p>
|
| 1258 |
+
<label for="<?php echo $this->get_field_id('titlelink'); ?>"><?php _e( 'URL for Title (incl. http://):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('titlelink'); ?>" name="<?php echo $this->get_field_name('titlelink'); ?>" type="text" value="<?php echo esc_url($titlelink); ?>" /></label>
|
| 1259 |
+
</p>
|
| 1260 |
+
<p>
|
| 1261 |
+
<label for="<?php echo $this->get_field_id('display'); ?>"><?php _e( 'Display:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('display'); ?>" name="<?php echo $this->get_field_name('display'); ?>" type="text" value="<?php echo esc_attr($display); ?>" /></label>
|
| 1262 |
+
</p>
|
| 1263 |
+
<p>
|
| 1264 |
+
<label for="<?php echo $this->get_field_id('feedurl'); ?>"><?php _e( 'FeedURL:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('feedurl'); ?>" name="<?php echo $this->get_field_name('feedurl'); ?>" type="text" value="<?php echo $feedurl; ?>" /></label>
|
| 1265 |
+
</p>
|
| 1266 |
+
<p>
|
| 1267 |
+
<label for="<?php echo $this->get_field_id('before_desc'); ?>"><?php _e( 'Before Description:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('before_desc'); ?>" name="<?php echo $this->get_field_name('before_desc'); ?>" type="text" value="<?php echo $before_desc; ?>" /></label>
|
| 1268 |
+
</p>
|
| 1269 |
+
<p>
|
| 1270 |
+
<label for="<?php echo $this->get_field_id('displaydescriptions'); ?>"><?php _e( 'Display Description:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1271 |
+
<select id="<?php echo $this->get_field_id('displaydescriptions'); ?>" name="<?php echo $this->get_field_name('displaydescriptions'); ?>">
|
| 1272 |
+
<option value="0"<?php if ($displaydescriptions == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1273 |
+
<option value="1"<?php if ($displaydescriptions == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1274 |
+
</select>
|
| 1275 |
+
</label>
|
| 1276 |
+
</p>
|
| 1277 |
+
<p>
|
| 1278 |
+
<label for="<?php echo $this->get_field_id('after_desc'); ?>"><?php _e( 'After Description:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('after_desc'); ?>" name="<?php echo $this->get_field_name('after_desc'); ?>" type="text" value="<?php echo $after_desc; ?>" /></label>
|
| 1279 |
+
<br /><small><?php _e( 'You can use the following strings to create custom links:', FB_RSSI_TEXTDOMAIN ); ?> <code>%title%</code>, <code>%href%</code>
|
| 1280 |
+
<br /><?php _e( 'Example:', FB_RSSI_TEXTDOMAIN ); ?> <code><a href="%href%" target="self" rel="follow">%title%</a></code></small>
|
| 1281 |
+
</p>
|
| 1282 |
+
<p>
|
| 1283 |
+
<label for="<?php echo $this->get_field_id('html'); ?>"><?php _e( 'HTML:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1284 |
+
<select id="<?php echo $this->get_field_id('html'); ?>" name="<?php echo $this->get_field_name('html'); ?>">
|
| 1285 |
+
<option value="0"<?php if ($html == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1286 |
+
<option value="1"<?php if ($html == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1287 |
+
</select>
|
| 1288 |
+
</label>
|
| 1289 |
+
</p>
|
| 1290 |
+
<p>
|
| 1291 |
+
<label for="<?php echo $this->get_field_id('truncatedescchar'); ?>"><?php _e( 'Truncate Description Char:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('truncatedescchar'); ?>" name="<?php echo $this->get_field_name('truncatedescchar'); ?>" type="text" value="<?php echo esc_attr($truncatedescchar); ?>" /></label>
|
| 1292 |
+
</p>
|
| 1293 |
+
<p>
|
| 1294 |
+
<label for="<?php echo $this->get_field_id('truncatedescstring'); ?>"><?php _e( 'Truncate Description String (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('truncatedescstring'); ?>" name="<?php echo $this->get_field_name('truncatedescstring'); ?>" type="text" value="<?php echo $truncatedescstring; ?>" /></label>
|
| 1295 |
+
</p>
|
| 1296 |
+
<p>
|
| 1297 |
+
<label for="<?php echo $this->get_field_id('truncatetitlechar'); ?>"><?php _e( 'Truncate Title Char:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('truncatetitlechar'); ?>" name="<?php echo $this->get_field_name('truncatetitlechar'); ?>" type="text" value="<?php echo esc_attr($truncatetitlechar); ?>" /></label>
|
| 1298 |
+
</p>
|
| 1299 |
+
<p>
|
| 1300 |
+
<label for="<?php echo $this->get_field_id('truncatetitlestring'); ?>"><?php _e( 'Truncate Title String (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('truncatetitlestring'); ?>" name="<?php echo $this->get_field_name('truncatetitlestring'); ?>" type="text" value="<?php echo $truncatetitlestring; ?>" /></label>
|
| 1301 |
+
</p>
|
| 1302 |
+
<p>
|
| 1303 |
+
<label for="<?php echo $this->get_field_id('before_date'); ?>"><?php _e( 'Before Date (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('before_date'); ?>" name="<?php echo $this->get_field_name('before_date'); ?>" type="text" value="<?php echo $before_date; ?>" /></label>
|
| 1304 |
+
</p>
|
| 1305 |
+
<p>
|
| 1306 |
+
<label for="<?php echo $this->get_field_id('date'); ?>"><?php _e( 'Date:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1307 |
+
<select id="<?php echo $this->get_field_id('date'); ?>" name="<?php echo $this->get_field_name('date'); ?>">
|
| 1308 |
+
<option value="0"<?php if ($date == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1309 |
+
<option value="1"<?php if ($date == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1310 |
+
</select>
|
| 1311 |
+
</label>
|
| 1312 |
+
</p>
|
| 1313 |
+
<p>
|
| 1314 |
+
<label for="<?php echo $this->get_field_id('after_date'); ?>"><?php _e( 'After Date (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('after_date'); ?>" name="<?php echo $this->get_field_name('after_date'); ?>" type="text" value="<?php echo $after_date; ?>" /></label>
|
| 1315 |
+
</p>
|
| 1316 |
+
<p>
|
| 1317 |
+
<label for="<?php echo $this->get_field_id('date_format'); ?>"><?php _e( 'Date Formatting:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('date_format'); ?>" name="<?php echo $this->get_field_name('date_format'); ?>" type="text" value="<?php echo $date_format; ?>" /></label>
|
| 1318 |
+
<br /><small><?php _e( 'Leave empty for use the date format of your WordPress settings.', FB_RSSI_TEXTDOMAIN ); ?> <a href="http://codex.wordpress.org/Formatting_Date_and_Time"><?php _e( 'Documentation on date formatting', FB_RSSI_TEXTDOMAIN ); ?></a></small>
|
| 1319 |
+
</p>
|
| 1320 |
+
<p>
|
| 1321 |
+
<label for="<?php echo $this->get_field_id('before_creator'); ?>"><?php _e( 'Before Creator (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('before_creator'); ?>" name="<?php echo $this->get_field_name('before_creator'); ?>" type="text" value="<?php echo $before_creator; ?>" /></label>
|
| 1322 |
+
</p>
|
| 1323 |
+
<p>
|
| 1324 |
+
<label for="<?php echo $this->get_field_id('creator'); ?>"><?php _e( 'Creator:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1325 |
+
<select id="<?php echo $this->get_field_id('creator'); ?>" name="<?php echo $this->get_field_name('creator'); ?>">
|
| 1326 |
+
<option value="0"<?php if ($creator == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1327 |
+
<option value="1"<?php if ($creator == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1328 |
+
</select>
|
| 1329 |
+
</label>
|
| 1330 |
+
</p>
|
| 1331 |
+
<p>
|
| 1332 |
+
<label for="<?php echo $this->get_field_id('after_creator'); ?>"><?php _e( 'After Creator (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('after_creator'); ?>" name="<?php echo $this->get_field_name('after_creator'); ?>" type="text" value="<?php echo $after_creator; ?>" /></label>
|
| 1333 |
+
</p>
|
| 1334 |
+
<p>
|
| 1335 |
+
<label for="<?php echo $this->get_field_id('start_items'); ?>"><?php _e( 'Before Items (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('start_items'); ?>" name="<?php echo $this->get_field_name('start_items'); ?>" type="text" value="<?php echo $start_items; ?>" /></label>
|
| 1336 |
+
</p>
|
| 1337 |
+
<p>
|
| 1338 |
+
<label for="<?php echo $this->get_field_id('end_items'); ?>"><?php _e( 'After Items (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('end_items'); ?>" name="<?php echo $this->get_field_name('end_items'); ?>" type="text" value="<?php echo $end_items; ?>" /></label>
|
| 1339 |
+
</p>
|
| 1340 |
+
<p>
|
| 1341 |
+
<label for="<?php echo $this->get_field_id('start_item'); ?>"><?php _e( 'Before Item (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('start_item'); ?>" name="<?php echo $this->get_field_name('start_item'); ?>" type="text" value="<?php echo $start_item; ?>" /></label>
|
| 1342 |
+
</p>
|
| 1343 |
+
<p>
|
| 1344 |
+
<label for="<?php echo $this->get_field_id('end_item'); ?>"><?php _e( 'After Item (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('end_item'); ?>" name="<?php echo $this->get_field_name('end_item'); ?>" type="text" value="<?php echo $end_item; ?>" /></label>
|
| 1345 |
+
</p>
|
| 1346 |
+
<p>
|
| 1347 |
+
<label for="<?php echo $this->get_field_id('target'); ?>"><?php _e( 'Target Attribut:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('target'); ?>" name="<?php echo $this->get_field_name('target'); ?>" type="text" value="<?php echo esc_attr($target); ?>" /></label>
|
| 1348 |
+
</p>
|
| 1349 |
+
<p>
|
| 1350 |
+
<label for="<?php echo $this->get_field_id('rel'); ?>"><?php _e( 'Rel Attribut:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('rel'); ?>" name="<?php echo $this->get_field_name('rel'); ?>" type="text" value="<?php echo esc_attr($rel); ?>" /></label>
|
| 1351 |
+
</p>
|
| 1352 |
+
<p>
|
| 1353 |
+
<label for="<?php echo $this->get_field_id('desc4title'); ?>"><?php _e( 'Desc4Title:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1354 |
+
<select id="<?php echo $this->get_field_id('desc4title'); ?>" name="<?php echo $this->get_field_name('desc4title'); ?>">
|
| 1355 |
+
<option value="0"<?php if ($desc4title == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1356 |
+
<option value="1"<?php if ($desc4title == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1357 |
+
</select>
|
| 1358 |
+
</label>
|
| 1359 |
+
<br />
|
| 1360 |
+
<small><?php _e( 'Description for title-Attribut on Title-Link', FB_RSSI_TEXTDOMAIN ); ?></small>
|
| 1361 |
+
</p>
|
| 1362 |
+
<p>
|
| 1363 |
+
<label for="<?php echo $this->get_field_id('charsetscan'); ?>"><?php _e( 'Charsetscan:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1364 |
+
<select id="<?php echo $this->get_field_id('charsetscan'); ?>" name="<?php echo $this->get_field_name('charsetscan'); ?>">
|
| 1365 |
+
<option value="0"<?php if ($charsetscan == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1366 |
+
<option value="1"<?php if ($charsetscan == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1367 |
+
</select>
|
| 1368 |
+
</label>
|
| 1369 |
+
</p>
|
| 1370 |
+
<p>
|
| 1371 |
+
<label for="<?php echo $this->get_field_id('debug'); ?>"><?php _e( 'Debug mode:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1372 |
+
<select id="<?php echo $this->get_field_id('debug'); ?>" name="<?php echo $this->get_field_name('debug'); ?>">
|
| 1373 |
+
<option value="0"<?php if ($debug == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1374 |
+
<option value="1"<?php if ($debug == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1375 |
+
</select>
|
| 1376 |
+
</label>
|
| 1377 |
+
</p>
|
| 1378 |
+
<p>
|
| 1379 |
+
<label for="<?php echo $this->get_field_id('before_noitems'); ?>"><?php _e( 'Before <em>No</em> Items Message (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('before_noitems'); ?>" name="<?php echo $this->get_field_name('before_noitems'); ?>" type="text" value="<?php echo $before_noitems; ?>" /></label>
|
| 1380 |
+
</p>
|
| 1381 |
+
<p>
|
| 1382 |
+
<label for="<?php echo $this->get_field_id('noitems'); ?>"><?php _e( '<em>No</em> Items Message:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('noitems'); ?>" name="<?php echo $this->get_field_name('noitems'); ?>" type="text" value="<?php echo esc_attr($noitems); ?>" /></label>
|
| 1383 |
+
</p>
|
| 1384 |
+
<p>
|
| 1385 |
+
<label for="<?php echo $this->get_field_id('after_noitems'); ?>"><?php _e( 'After <em>No</em> Items Message (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('after_noitems'); ?>" name="<?php echo $this->get_field_name('after_noitems'); ?>" type="text" value="<?php echo $after_noitems; ?>" /></label>
|
| 1386 |
+
</p>
|
| 1387 |
+
<p>
|
| 1388 |
+
<label for="<?php echo $this->get_field_id('before_error'); ?>"><?php _e( 'Before Error Message (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('before_error'); ?>" name="<?php echo $this->get_field_name('before_error'); ?>" type="text" value="<?php echo $before_error; ?>" /></label>
|
| 1389 |
+
</p>
|
| 1390 |
+
<p>
|
| 1391 |
+
<label for="<?php echo $this->get_field_id('error'); ?>"><?php _e( 'Error Message:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('error'); ?>" name="<?php echo $this->get_field_name('error'); ?>" type="text" value="<?php echo esc_attr($error); ?>" /></label>
|
| 1392 |
+
</p>
|
| 1393 |
+
<p>
|
| 1394 |
+
<label for="<?php echo $this->get_field_id('after_error'); ?>"><?php _e( 'After Error Message (HTML):', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat code" id="<?php echo $this->get_field_id('after_error'); ?>" name="<?php echo $this->get_field_name('after_error'); ?>" type="text" value="<?php echo $after_error; ?>" /></label>
|
| 1395 |
+
</p>
|
| 1396 |
+
<p>
|
| 1397 |
+
<label for="<?php echo $this->get_field_id('paging'); ?>"><?php _e( 'Pagination:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1398 |
+
<select id="<?php echo $this->get_field_id('paging'); ?>" name="<?php echo $this->get_field_name('paging'); ?>">
|
| 1399 |
+
<option value="0"<?php if ($paging == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1400 |
+
<option value="1"<?php if ($paging == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1401 |
+
</select>
|
| 1402 |
+
</label>
|
| 1403 |
+
</p>
|
| 1404 |
+
<p>
|
| 1405 |
+
<label for="<?php echo $this->get_field_id('prev_paging_link'); ?>"><?php _e( 'Previous Pagination Link String:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('prev_paging_link'); ?>" name="<?php echo $this->get_field_name('prev_paging_link'); ?>" type="text" value="<?php echo esc_attr($prev_paging_link); ?>" /></label>
|
| 1406 |
+
</p>
|
| 1407 |
+
<p>
|
| 1408 |
+
<label for="<?php echo $this->get_field_id('next_paging_link'); ?>"><?php _e( 'Next Pagination Link String:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('next_paging_link'); ?>" name="<?php echo $this->get_field_name('next_paging_link'); ?>" type="text" value="<?php echo esc_attr($next_paging_link); ?>" /></label>
|
| 1409 |
+
</p>
|
| 1410 |
+
<p>
|
| 1411 |
+
<label for="<?php echo $this->get_field_id('prev_paging_title'); ?>"><?php _e( 'Previous Pagination Title String:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('prev_paging_title'); ?>" name="<?php echo $this->get_field_name('prev_paging_title'); ?>" type="text" value="<?php echo esc_attr($prev_paging_title); ?>" /></label>
|
| 1412 |
+
</p>
|
| 1413 |
+
<p>
|
| 1414 |
+
<label for="<?php echo $this->get_field_id('next_paging_title'); ?>"><?php _e( 'Next Pagination Title String:', FB_RSSI_TEXTDOMAIN ) ?> <input class="widefat" id="<?php echo $this->get_field_id('next_paging_title'); ?>" name="<?php echo $this->get_field_name('next_paging_title'); ?>" type="text" value="<?php echo esc_attr($next_paging_title); ?>" /></label>
|
| 1415 |
+
</p>
|
| 1416 |
+
<p>
|
| 1417 |
+
<label for="<?php echo $this->get_field_id('use_simplepie'); ?>"><?php _e( 'Use SimplePie class:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1418 |
+
<select id="<?php echo $this->get_field_id('use_simplepie'); ?>" name="<?php echo $this->get_field_name('use_simplepie'); ?>">
|
| 1419 |
+
<option value="0"<?php if ($use_simplepie == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1420 |
+
<option value="1"<?php if ($use_simplepie == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1421 |
+
</select>
|
| 1422 |
+
</label>
|
| 1423 |
+
</p>
|
| 1424 |
+
<p>
|
| 1425 |
+
<label for="<?php echo $this->get_field_id('view'); ?>"><?php _e( 'Echo/Return:', FB_RSSI_TEXTDOMAIN ) ?>
|
| 1426 |
+
<select id="<?php echo $this->get_field_id('view'); ?>" name="<?php echo $this->get_field_name('view'); ?>">
|
| 1427 |
+
<option value="0"<?php if ($view == '0') { echo ' selected="selected"'; } ?>><?php _e('False', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1428 |
+
<option value="1"<?php if ($view == '1') { echo ' selected="selected"'; } ?>><?php _e('True', FB_RSSI_TEXTDOMAIN ); ?></option>
|
| 1429 |
+
</select>
|
| 1430 |
+
</label>
|
| 1431 |
+
</p>
|
| 1432 |
+
<?php
|
| 1433 |
+
|
| 1434 |
+
}
|
| 1435 |
+
}
|
| 1436 |
+
|
| 1437 |
+
add_action( 'widgets_init', create_function('', 'return register_widget("RSSImport_Widget");') );
|
| 1438 |
+
|
| 1439 |
+
} // end if class wp_widget exists
|
