Changeset 483672
- Timestamp:
- 01/02/2012 11:12:30 PM (14 years ago)
- Location:
- wp-mvc
- Files:
-
- 9 edited
- 4 copied
-
tags/1.1.2 (copied) (copied from wp-mvc/trunk)
-
tags/1.1.2/core/controllers/mvc_controller.php (copied) (copied from wp-mvc/trunk/core/controllers/mvc_controller.php)
-
tags/1.1.2/core/mvc_configuration.php (modified) (3 diffs)
-
tags/1.1.2/core/mvc_dispatcher.php (modified) (2 diffs)
-
tags/1.1.2/core/mvc_inflector.php (copied) (copied from wp-mvc/trunk/core/mvc_inflector.php)
-
tags/1.1.2/core/mvc_router.php (modified) (1 diff)
-
tags/1.1.2/readme.txt (modified) (1 diff)
-
tags/1.1.2/wp_mvc.php (copied) (copied from wp-mvc/trunk/wp_mvc.php) (1 diff)
-
trunk/core/mvc_configuration.php (modified) (3 diffs)
-
trunk/core/mvc_dispatcher.php (modified) (2 diffs)
-
trunk/core/mvc_router.php (modified) (1 diff)
-
trunk/readme.txt (modified) (1 diff)
-
trunk/wp_mvc.php (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
wp-mvc/tags/1.1.2/core/mvc_configuration.php
r371344 r483672 3 3 class MvcConfiguration { 4 4 5 function &get Instance($boot = true) {5 function &get_instance($boot = true) { 6 6 static $instance = array(); 7 7 … … 14 14 15 15 function set($config, $value = null) { 16 $_this =& MvcConfiguration::get Instance();16 $_this =& MvcConfiguration::get_instance(); 17 17 18 18 if (!is_array($config)) { … … 35 35 36 36 function get($config) { 37 $_this =& MvcConfiguration::get Instance();37 $_this =& MvcConfiguration::get_instance(); 38 38 39 39 if (strpos($config, '.') !== false) { -
wp-mvc/tags/1.1.2/core/mvc_dispatcher.php
r451789 r483672 7 7 $controller_name = $options['controller']; 8 8 $action = $options['action']; 9 $ object_id = empty($options['id']) ? null : $options['id'];9 $params = $options; 10 10 11 11 $controller_class = MvcInflector::camelize($controller_name).'Controller'; … … 21 21 } 22 22 23 $params = $_REQUEST; 24 $params = self::escape_params($params); 23 $request_params = $_REQUEST; 24 $request_params = self::escape_params($request_params); 25 26 $params = array_merge($request_params, $params); 25 27 26 28 if (is_admin()) { 27 29 unset($params['page']); 28 } else {29 if (empty($params['id']) && !empty($object_id)) {30 $params['id'] = $object_id;31 }32 30 } 33 31 -
wp-mvc/tags/1.1.2/core/mvc_router.php
r451789 r483672 42 42 $value = $options[$option_key]; 43 43 $path = preg_replace('/'.preg_quote($pattern).'/', $value, $path, 1); 44 } else if (isset($options['object']) && is_object($options['object'])) { 45 if (isset($options['object']->{$option_key})) { 46 $value = $options['object']->{$option_key}; 47 $path = preg_replace('/'.preg_quote($pattern).'/', $value, $path, 1); 48 $path = rtrim($path, '.*?'); 49 } 44 50 } 45 51 } -
wp-mvc/tags/1.1.2/readme.txt
r452703 r483672 3 3 Tags: mvc, framework, model, view, controller, development, plugin 4 4 Requires at least: 3.0 5 Tested up to: 3. 2.16 Stable tag: 1.1. 15 Tested up to: 3.3 6 Stable tag: 1.1.2 7 7 8 8 WP MVC is a full-fledged MVC framework, similar to CakePHP and Rails, that developers can use to create WordPress plugins. -
wp-mvc/tags/1.1.2/wp_mvc.php
r472892 r483672 5 5 Description: Sets up an MVC framework inside of WordPress. 6 6 Author: Tom Benner 7 Version: 1.1. 17 Version: 1.1.2 8 8 Author URI: 9 9 */ -
wp-mvc/trunk/core/mvc_configuration.php
r371344 r483672 3 3 class MvcConfiguration { 4 4 5 function &get Instance($boot = true) {5 function &get_instance($boot = true) { 6 6 static $instance = array(); 7 7 … … 14 14 15 15 function set($config, $value = null) { 16 $_this =& MvcConfiguration::get Instance();16 $_this =& MvcConfiguration::get_instance(); 17 17 18 18 if (!is_array($config)) { … … 35 35 36 36 function get($config) { 37 $_this =& MvcConfiguration::get Instance();37 $_this =& MvcConfiguration::get_instance(); 38 38 39 39 if (strpos($config, '.') !== false) { -
wp-mvc/trunk/core/mvc_dispatcher.php
r451789 r483672 7 7 $controller_name = $options['controller']; 8 8 $action = $options['action']; 9 $ object_id = empty($options['id']) ? null : $options['id'];9 $params = $options; 10 10 11 11 $controller_class = MvcInflector::camelize($controller_name).'Controller'; … … 21 21 } 22 22 23 $params = $_REQUEST; 24 $params = self::escape_params($params); 23 $request_params = $_REQUEST; 24 $request_params = self::escape_params($request_params); 25 26 $params = array_merge($request_params, $params); 25 27 26 28 if (is_admin()) { 27 29 unset($params['page']); 28 } else {29 if (empty($params['id']) && !empty($object_id)) {30 $params['id'] = $object_id;31 }32 30 } 33 31 -
wp-mvc/trunk/core/mvc_router.php
r451789 r483672 42 42 $value = $options[$option_key]; 43 43 $path = preg_replace('/'.preg_quote($pattern).'/', $value, $path, 1); 44 } else if (isset($options['object']) && is_object($options['object'])) { 45 if (isset($options['object']->{$option_key})) { 46 $value = $options['object']->{$option_key}; 47 $path = preg_replace('/'.preg_quote($pattern).'/', $value, $path, 1); 48 $path = rtrim($path, '.*?'); 49 } 44 50 } 45 51 } -
wp-mvc/trunk/readme.txt
r452703 r483672 3 3 Tags: mvc, framework, model, view, controller, development, plugin 4 4 Requires at least: 3.0 5 Tested up to: 3. 2.16 Stable tag: 1.1. 15 Tested up to: 3.3 6 Stable tag: 1.1.2 7 7 8 8 WP MVC is a full-fledged MVC framework, similar to CakePHP and Rails, that developers can use to create WordPress plugins. -
wp-mvc/trunk/wp_mvc.php
r472892 r483672 5 5 Description: Sets up an MVC framework inside of WordPress. 6 6 Author: Tom Benner 7 Version: 1.1. 17 Version: 1.1.2 8 8 Author URI: 9 9 */
Note: See TracChangeset
for help on using the changeset viewer.