Changeset 2405752
- Timestamp:
- 10/24/2020 06:34:54 AM (5 years ago)
- Location:
- sitetree
- Files:
-
- 10 deleted
- 5 edited
- 32 copied
-
tags/4.5.1 (copied) (copied from sitetree/trunk)
-
tags/4.5.1/admin/admin-controller.class.php (copied) (copied from sitetree/trunk/admin/admin-controller.class.php)
-
tags/4.5.1/admin/meta-box-controller.class.php (copied) (copied from sitetree/trunk/admin/meta-box-controller.class.php)
-
tags/4.5.1/admin/page-controller-classes.php (copied) (copied from sitetree/trunk/admin/page-controller-classes.php) (3 diffs)
-
tags/4.5.1/admin/page-view-delegate-protocols.php (copied) (copied from sitetree/trunk/admin/page-view-delegate-protocols.php)
-
tags/4.5.1/admin/sitetree-field-view.class.php (copied) (copied from sitetree/trunk/admin/sitetree-field-view.class.php)
-
tags/4.5.1/admin/sitetree-page-view.class.php (copied) (copied from sitetree/trunk/admin/sitetree-page-view.class.php)
-
tags/4.5.1/core/builder-core.class.php (deleted)
-
tags/4.5.1/core/builders (copied) (copied from sitetree/trunk/core/builders)
-
tags/4.5.1/core/builders-interfaces.php (deleted)
-
tags/4.5.1/core/builders/builder-core.class.php (copied) (copied from sitetree/trunk/core/builders/builder-core.class.php)
-
tags/4.5.1/core/builders/builders-interfaces.php (copied) (copied from sitetree/trunk/core/builders/builders-interfaces.php)
-
tags/4.5.1/core/builders/site-tree-builder.class.php (copied) (copied from sitetree/trunk/core/builders/site-tree-builder.class.php)
-
tags/4.5.1/core/builders/stylesheet-builder.class.php (copied) (copied from sitetree/trunk/core/builders/stylesheet-builder.class.php)
-
tags/4.5.1/core/db-classes.php (deleted)
-
tags/4.5.1/core/db.class.php (copied) (copied from sitetree/trunk/core/db.class.php)
-
tags/4.5.1/core/filter.class.php (deleted)
-
tags/4.5.1/core/image-element.class.php (deleted)
-
tags/4.5.1/core/ping-controller.class.php (copied) (copied from sitetree/trunk/core/ping-controller.class.php) (1 diff)
-
tags/4.5.1/core/ping-state.class.php (copied) (copied from sitetree/trunk/core/ping-state.class.php)
-
tags/4.5.1/core/shortcode-controller.class.php (copied) (copied from sitetree/trunk/core/shortcode-controller.class.php)
-
tags/4.5.1/core/site-tree-builder.class.php (deleted)
-
tags/4.5.1/core/sitemap-builder.class.php (deleted)
-
tags/4.5.1/core/sitetree-controller.class.php (deleted)
-
tags/4.5.1/core/sitetree-delegate.class.php (copied) (copied from sitetree/trunk/core/sitetree-delegate.class.php)
-
tags/4.5.1/core/sitetree.class.php (copied) (copied from sitetree/trunk/core/sitetree.class.php) (1 diff)
-
tags/4.5.1/core/upgrader.class.php (copied) (copied from sitetree/trunk/core/upgrader.class.php)
-
tags/4.5.1/data-model/dashboard-page-data.php (copied) (copied from sitetree/trunk/data-model/dashboard-page-data.php)
-
tags/4.5.1/data-model/data-model-classes.php (copied) (copied from sitetree/trunk/data-model/data-model-classes.php)
-
tags/4.5.1/data-model/site_tree-page-data.php (copied) (copied from sitetree/trunk/data-model/site_tree-page-data.php)
-
tags/4.5.1/data-model/sitemap-page-data.php (copied) (copied from sitetree/trunk/data-model/sitemap-page-data.php)
-
tags/4.5.1/includes (copied) (copied from sitetree/trunk/includes)
-
tags/4.5.1/library/plugin.class.php (copied) (copied from sitetree/trunk/library/plugin.class.php)
-
tags/4.5.1/readme.txt (copied) (copied from sitetree/trunk/readme.txt) (3 diffs)
-
tags/4.5.1/resources/.htaccess (deleted)
-
tags/4.5.1/resources/sitetree-min.css (copied) (copied from sitetree/trunk/resources/sitetree-min.css)
-
tags/4.5.1/resources/sitetree-min.js (copied) (copied from sitetree/trunk/resources/sitetree-min.js)
-
tags/4.5.1/resources/sitetree.css (copied) (copied from sitetree/trunk/resources/sitetree.css)
-
tags/4.5.1/resources/sitetree.js (copied) (copied from sitetree/trunk/resources/sitetree.js)
-
tags/4.5.1/resources/template.xsl (deleted)
-
tags/4.5.1/sitetree.php (copied) (copied from sitetree/trunk/sitetree.php) (2 diffs)
-
tags/4.5.1/uninstall.php (copied) (copied from sitetree/trunk/uninstall.php)
-
trunk/admin/page-controller-classes.php (modified) (3 diffs)
-
trunk/core/ping-controller.class.php (modified) (1 diff)
-
trunk/core/sitetree.class.php (modified) (1 diff)
-
trunk/readme.txt (modified) (3 diffs)
-
trunk/sitetree.php (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
sitetree/tags/4.5.1/admin/page-controller-classes.php
r2402399 r2405752 231 231 } 232 232 233 if ( $this->plugin->is ServerLocal() ) {233 if ( $this->plugin->isWebsiteLocal() ) { 234 234 return false; 235 235 } … … 474 474 private function makePingNode( $form_id ) { 475 475 $can_ping = false; 476 $server_is_local = $this->plugin->is ServerLocal();476 $server_is_local = $this->plugin->isWebsiteLocal(); 477 477 $automatic_pinging_on = ( $this->db->getOption( 'automatic_pinging_on' ) || ( $form_id == 'newsmap' ) ); 478 478 … … 535 535 536 536 if ( $server_is_local ) { 537 $node .= __( 'I cannot send pings from a local server, I am sorry.', 'sitetree' );537 $node .= __( 'I cannot send pings from your website, because its address appears to be a known local development environment URL.', 'sitetree' ); 538 538 $node .= '</p>'; 539 539 } -
sitetree/tags/4.5.1/core/ping-controller.class.php
r2324214 r2405752 98 98 if ( 99 99 !( $is_automatic_ping || $this->canPingOnRequest( $sitemap_id ) ) || 100 $this->plugin->is ServerLocal()100 $this->plugin->isWebsiteLocal() 101 101 ) { 102 102 return false; -
sitetree/tags/4.5.1/core/sitetree.class.php
r2402399 r2405752 311 311 312 312 /** 313 * @since 3.2313 * @since 4.5.1 314 314 * @return bool 315 315 */ 316 public function is ServerLocal() {316 public function isWebsiteLocal() { 317 317 if ( WP_DEBUG ) { 318 318 return false; 319 319 } 320 321 return ( 322 ( $_SERVER['SERVER_ADDR'] == '127.0.0.1' ) || 323 ( $_SERVER['SERVER_ADDR'] == '::1' ) 320 321 $site_url = site_url(); 322 323 if ( strpos( $site_url, '.' ) === false ) { 324 return true; 325 } 326 327 $host = parse_url( $site_url, PHP_URL_HOST ); 328 329 if ( $host == '127.0.0.1' ) { 330 return true; 331 } 332 333 $known_local_patterns = array( 334 '#\.local$#i', 335 '#\.localhost$#i', 336 '#\.test$#i', 337 '#\.staging$#i', 338 '#\.stage$#i', 339 '#^dev\.#i', 340 '#^stage\.#i', 341 '#^staging\.#i', 324 342 ); 343 344 foreach( $known_local_patterns as $pattern ) { 345 if ( preg_match( $pattern, $host ) ) { 346 return true; 347 } 348 } 349 350 return false; 325 351 } 326 352 -
sitetree/tags/4.5.1/readme.txt
r2402399 r2405752 7 7 Tested up to: 5.5.1 8 8 Requires PHP: 5.6.20 9 Stable tag: 4.5 9 Stable tag: 4.5.1 10 10 License: GPLv3 11 11 License URI: https://opensource.org/licenses/GPL-3.0 … … 131 131 == Upgrade Notice == 132 132 133 = 4.5 =133 = 4.5.1 = 134 134 135 135 If you are upgrading from SiteTree 1.5.3 your preferences about whether or not to exclude a post or page from the sitemaps will be automatically upgraded, but your general settings will be reset instead. The Change Frequency and Priority metadata are not used any more, nonetheless they will be deleted from the database with a future update. … … 137 137 138 138 == Changelog == 139 140 = 4.5.1 (24 October 2020) = 141 142 Implemented a more reliable way of checking whether SiteTree is installed on a local development environment. 143 139 144 140 145 = 4.5 (19 October 2020) = -
sitetree/tags/4.5.1/sitetree.php
r2402399 r2405752 4 4 * Plugin URI: https://luigicavalieri.com/sitetree/ 5 5 * Description: A sitemap maker for WordPress. 6 * Version: 4.5 6 * Version: 4.5.1 7 7 * Requires: 5.2 8 8 * Author: Luigi Cavalieri … … 13 13 * 14 14 * @package SiteTree 15 * @version 4.5 15 * @version 4.5.1 16 16 * @copyright Copyright 2020 Luigi Cavalieri. 17 17 * @license https://opensource.org/licenses/GPL-3.0 GPL v3.0 -
sitetree/trunk/admin/page-controller-classes.php
r2402399 r2405752 231 231 } 232 232 233 if ( $this->plugin->is ServerLocal() ) {233 if ( $this->plugin->isWebsiteLocal() ) { 234 234 return false; 235 235 } … … 474 474 private function makePingNode( $form_id ) { 475 475 $can_ping = false; 476 $server_is_local = $this->plugin->is ServerLocal();476 $server_is_local = $this->plugin->isWebsiteLocal(); 477 477 $automatic_pinging_on = ( $this->db->getOption( 'automatic_pinging_on' ) || ( $form_id == 'newsmap' ) ); 478 478 … … 535 535 536 536 if ( $server_is_local ) { 537 $node .= __( 'I cannot send pings from a local server, I am sorry.', 'sitetree' );537 $node .= __( 'I cannot send pings from your website, because its address appears to be a known local development environment URL.', 'sitetree' ); 538 538 $node .= '</p>'; 539 539 } -
sitetree/trunk/core/ping-controller.class.php
r2324214 r2405752 98 98 if ( 99 99 !( $is_automatic_ping || $this->canPingOnRequest( $sitemap_id ) ) || 100 $this->plugin->is ServerLocal()100 $this->plugin->isWebsiteLocal() 101 101 ) { 102 102 return false; -
sitetree/trunk/core/sitetree.class.php
r2402399 r2405752 311 311 312 312 /** 313 * @since 3.2313 * @since 4.5.1 314 314 * @return bool 315 315 */ 316 public function is ServerLocal() {316 public function isWebsiteLocal() { 317 317 if ( WP_DEBUG ) { 318 318 return false; 319 319 } 320 321 return ( 322 ( $_SERVER['SERVER_ADDR'] == '127.0.0.1' ) || 323 ( $_SERVER['SERVER_ADDR'] == '::1' ) 320 321 $site_url = site_url(); 322 323 if ( strpos( $site_url, '.' ) === false ) { 324 return true; 325 } 326 327 $host = parse_url( $site_url, PHP_URL_HOST ); 328 329 if ( $host == '127.0.0.1' ) { 330 return true; 331 } 332 333 $known_local_patterns = array( 334 '#\.local$#i', 335 '#\.localhost$#i', 336 '#\.test$#i', 337 '#\.staging$#i', 338 '#\.stage$#i', 339 '#^dev\.#i', 340 '#^stage\.#i', 341 '#^staging\.#i', 324 342 ); 343 344 foreach( $known_local_patterns as $pattern ) { 345 if ( preg_match( $pattern, $host ) ) { 346 return true; 347 } 348 } 349 350 return false; 325 351 } 326 352 -
sitetree/trunk/readme.txt
r2402399 r2405752 7 7 Tested up to: 5.5.1 8 8 Requires PHP: 5.6.20 9 Stable tag: 4.5 9 Stable tag: 4.5.1 10 10 License: GPLv3 11 11 License URI: https://opensource.org/licenses/GPL-3.0 … … 131 131 == Upgrade Notice == 132 132 133 = 4.5 =133 = 4.5.1 = 134 134 135 135 If you are upgrading from SiteTree 1.5.3 your preferences about whether or not to exclude a post or page from the sitemaps will be automatically upgraded, but your general settings will be reset instead. The Change Frequency and Priority metadata are not used any more, nonetheless they will be deleted from the database with a future update. … … 137 137 138 138 == Changelog == 139 140 = 4.5.1 (24 October 2020) = 141 142 Implemented a more reliable way of checking whether SiteTree is installed on a local development environment. 143 139 144 140 145 = 4.5 (19 October 2020) = -
sitetree/trunk/sitetree.php
r2402399 r2405752 4 4 * Plugin URI: https://luigicavalieri.com/sitetree/ 5 5 * Description: A sitemap maker for WordPress. 6 * Version: 4.5 6 * Version: 4.5.1 7 7 * Requires: 5.2 8 8 * Author: Luigi Cavalieri … … 13 13 * 14 14 * @package SiteTree 15 * @version 4.5 15 * @version 4.5.1 16 16 * @copyright Copyright 2020 Luigi Cavalieri. 17 17 * @license https://opensource.org/licenses/GPL-3.0 GPL v3.0
Note: See TracChangeset
for help on using the changeset viewer.