Changeset 1451430
- Timestamp:
- 07/08/2016 03:15:17 PM (10 years ago)
- Location:
- wp-realtime-sitemap/trunk
- Files:
-
- 2 edited
-
readme.txt (modified) (3 diffs)
-
wp-realtime-sitemap.php (modified) (17 diffs)
Legend:
- Unmodified
- Added
- Removed
-
wp-realtime-sitemap/trunk/readme.txt
r1451359 r1451430 2 2 Contributors: Rincewind 3 3 Donate link: http://goo.gl/mmUuGj 4 Tags: seo, navigation, site, map, sitemap, sitemaps, posts, pages, custom, post, types, wpmu, w ordpress, multisite, multiuser, bilingual, i18n, l10n, language, multilanguage, multilingual, translation, qtranslate4 Tags: seo, navigation, site, map, sitemap, sitemaps, posts, pages, custom, post, types, wpmu, wpml, wordpress, multisite, multiuser, bilingual, i18n, l10n, language, multilanguage, multilingual, translation, qtranslate 5 5 Requires at least: 3.0 6 6 Tested up to: 4.5.3 7 Stable tag: 1.5. 57 Stable tag: 1.5.6 8 8 9 9 A sitemap plugin to make it easier for your site to show all your pages, posts, archives, categories and tags in an easy to read format. … … 27 27 1. Supports use of the wordpress shortcode for including the sitemap in pages and posts. 28 28 1. Supports menus created with the inbuilt WordPress Menu Editor. 29 1. Works on WordPress Multisite (WPMU ) blogs.29 1. Works on WordPress Multisite (WPMU, WMPML) blogs. 30 30 1. Comes with an uninstaller, if you dont want it anymore just deactivate the plugin and delete it from within wordpress and it will delete all of its settings itself. 31 31 … … 151 151 152 152 == Changelog == 153 154 = 1.5.6 = 155 * Escaped some strings to address security issues. 156 * Added "suppress_filters => false" to make the plugin WPML compatible. 157 * Fixed uninstall hook as was incorrectly used. 153 158 154 159 = 1.5.5 = -
wp-realtime-sitemap/trunk/wp-realtime-sitemap.php
r1451366 r1451430 5 5 Plugin URI: http://goo.gl/ri9xU 6 6 Description: Adds a sitemap to your Wordpress blog that is always up-to-date. Add `[wp-realtime-sitemap]` to any page or post and the site map will be added there. Use Settings->WP Realtime Sitemap to set options. 7 Version: 1.5. 57 Version: 1.5.6 8 8 Author: Daniel Tweedy 9 9 Author URI: http://goo.gl/jdOfL … … 27 27 */ 28 28 29 define('WPRealtimeSitemap_Version', '1.5. 5');29 define('WPRealtimeSitemap_Version', '1.5.6'); 30 30 31 31 if (!class_exists('WPRealtimeSitemap')) { … … 69 69 register_activation_hook(__FILE__, array(&$this, 'installSettings')); 70 70 71 // Uninstall Settings 72 register_uninstall_hook(__FILE__, array(&$this, 'uninstallSettings')); 71 // Uninstall Settings - Doesn't fire on Uninstall!! 72 //register_deactivation_hook(__FILE__, array(&$this, 'UninstallSettings')); 73 74 // Uninstall Settings - Doesn't fire on Deactivations!! 75 register_uninstall_hook(__FILE__, 'WPRealtimeSitemapUninstallSettings'); 73 76 } 74 77 … … 857 860 $optionFormat = '<option value="%s"%s>%s</option>'; 858 861 859 $output = '<select name="plugin_wp_realtime_sitemap_settings[' . $args['dbfield']. ']">';862 $output = '<select name="plugin_wp_realtime_sitemap_settings[' . esc_attr( $args['dbfield'] ) . ']">'; 860 863 861 864 foreach ($values as $key => $label) { … … 876 879 877 880 if (array_key_exists('dbfield', $args) && isset($infotext)) { 878 echo '<input name="plugin_wp_realtime_sitemap_settings[' . $args['dbfield'] . ']" size="30" type="text" value="' . $$args['dbfield']. '" /><br />' . $infotext;881 echo '<input name="plugin_wp_realtime_sitemap_settings[' . esc_attr( $args['dbfield'] ) . ']" size="30" type="text" value="' . esc_attr( $$args['dbfield'] ) . '" /><br />' . $infotext; 879 882 } 880 883 } … … 1565 1568 $menu_header = (empty($menu_header)) ? __('Menu', 'wp-realtime-sitemap') : $menu_header; 1566 1569 1567 $menu = '<div id="wp-realtime-sitemap-menu"><h3>' . $menu_header. '</h3>';1570 $menu = '<div id="wp-realtime-sitemap-menu"><h3>' . esc_html( $menu_header ) . '</h3>'; 1568 1571 $menu .= '<ul>' . wp_nav_menu(array('menu' => $menu_id, 'container' => false, 'items_wrap' => '%3$s', 'echo' => '0')) . '</ul>'; 1569 1572 $menu .= '</div>'; … … 1574 1577 $pages_header = (empty($pages_header)) ? __('Pages', 'wp-realtime-sitemap') : $pages_header; 1575 1578 1576 $pages = '<div id="wp-realtime-sitemap-pages"><h3>' . $pages_header. '</h3>';1579 $pages = '<div id="wp-realtime-sitemap-pages"><h3>' . esc_html( $pages_header ) . '</h3>'; 1577 1580 $pages .= '<ul>' . wp_list_pages(array('sort_column' => $page_sort_column, 'sort_order' => $page_sort_order, 'exclude' => $page_exclude, 'depth' => $page_depth, 'show_date' => $page_show_date, 'title_li' => '', 'echo' => '0')) . '</ul></div>'; 1578 1581 } … … 1589 1592 foreach($thecategories as $category) { 1590 1593 1591 $posts .= '<li><a href="' . get_category_link($category->term_id) . '" title="' . $category->category_description . '">' . $category->name. '</a><ul>';1594 $posts .= '<li><a href="' . get_category_link($category->term_id) . '" title="' . esc_attr( $category->category_description ) . '">' . esc_html( $category->name ) . '</a><ul>'; 1592 1595 1593 1596 // Set options for post query 1594 1597 $theposts = get_posts(array( 1595 'numberposts' => $post_numberposts, 1596 'category' => $category->cat_ID, 1597 'orderby' => $post_orderby, 1598 'order' => $post_order, 1599 'exclude' => $post_exclude, 1600 'post_type' => 'post', 1598 'numberposts' => $post_numberposts, 1599 'category' => $category->cat_ID, 1600 'orderby' => $post_orderby, 1601 'order' => $post_order, 1602 'exclude' => $post_exclude, 1603 'post_type' => 'post', 1604 'suppress_filters' => false 1601 1605 )); 1602 1606 … … 1621 1625 $posts_header = (empty($posts_header)) ? __('Posts', 'wp-realtime-sitemap') : $posts_header; 1622 1626 1623 $posts = '<div id="wp-realtime-sitemap-posts"><h3>' . $posts_header. '</h3><ul>' . $posts . '</ul></div>';1627 $posts = '<div id="wp-realtime-sitemap-posts"><h3>' . esc_html( $posts_header ) . '</h3><ul>' . $posts . '</ul></div>'; 1624 1628 } 1625 1629 … … 1627 1631 // Set options for post query 1628 1632 $theposts = get_posts(array( 1629 'numberposts' => $post_numberposts, 1630 'orderby' => $post_orderby, 1631 'order' => $post_order, 1632 'exclude' => $post_exclude, 1633 'post_type' => 'post', 1633 'numberposts' => $post_numberposts, 1634 'orderby' => $post_orderby, 1635 'order' => $post_order, 1636 'exclude' => $post_exclude, 1637 'post_type' => 'post', 1638 'suppress_filters' => false 1634 1639 )); 1635 1640 … … 1650 1655 $posts_header = (empty($posts_header)) ? __('Posts', 'wp-realtime-sitemap') : $posts_header; 1651 1656 1652 $posts = '<div id="wp-realtime-sitemap-posts"><h3>' . $posts_header. '</h3><ul>' . $posts . '</ul></div>';1657 $posts = '<div id="wp-realtime-sitemap-posts"><h3>' . esc_html( $posts_header ) . '</h3><ul>' . $posts . '</ul></div>'; 1653 1658 } 1654 1659 } … … 1664 1669 // Set options for post query 1665 1670 $theposts = get_posts(array( 1666 'numberposts' => $post_numberposts, 1667 'orderby' => $post_orderby, 1668 'order' => $post_order, 1669 'exclude' => $post_exclude, 1670 'post_type' => $post_type->name, 1671 'numberposts' => $post_numberposts, 1672 'orderby' => $post_orderby, 1673 'order' => $post_order, 1674 'exclude' => $post_exclude, 1675 'post_type' => $post_type->name, 1676 'suppress_filters' => false 1671 1677 )); 1672 1678 … … 1695 1701 $archives_header = (empty($archives_header)) ? __('Archives', 'wp-realtime-sitemap') : $archives_header; 1696 1702 1697 $archives = '<div id="wp-realtime-sitemap-archives"><h3>' . $archives_header. '</h3>';1703 $archives = '<div id="wp-realtime-sitemap-archives"><h3>' . esc_html( $archives_header ) . '</h3>'; 1698 1704 $archives .= '<ul>' . wp_get_archives(array('type' => $archive_type, 'limit' => $archive_limit, 'show_post_count' => $archive_show_post_count, 'echo' => 0)) . '</ul></div>'; 1699 1705 } … … 1703 1709 $categories_header = (empty($categories_header)) ? __('Categories', 'wp-realtime-sitemap') : $categories_header; 1704 1710 1705 $categories = '<div id="wp-realtime-sitemap-categories"><h3>' . $categories_header. '</h3>';1711 $categories = '<div id="wp-realtime-sitemap-categories"><h3>' . esc_html( $categories_header ) . '</h3>'; 1706 1712 1707 1713 // Tag Cloud: Yes/No? … … 1719 1725 $tags_header = (empty($tags_header)) ? __('Tags', 'wp-realtime-sitemap') : $tags_header; 1720 1726 1721 $tags = '<div id="wp-realtime-sitemap-tags"><h3>' . $tags_header. '</h3>';1727 $tags = '<div id="wp-realtime-sitemap-tags"><h3>' . esc_html( $tags_header ) . '</h3>'; 1722 1728 1723 1729 // Tag Cloud: Yes/No? … … 1864 1870 } 1865 1871 1866 function uninstallSettings() {1872 function WPRealtimeSitemapUninstallSettings() { 1867 1873 global $wpdb, $wp_roles, $wp_version; 1868 1874 … … 1899 1905 if( class_exists('WPRealtimeSitemap') ) 1900 1906 $wpRealtimeSitemap = new WPRealtimeSitemap(); 1901 1902 ?>
Note: See TracChangeset
for help on using the changeset viewer.