Permalink
Browse files

Code cleaning.

  • Loading branch information...
1 parent c54d582 commit 78e6bc0c99249c76a98f32349d0902181798f060 @eddieajau eddieajau committed Jul 29, 2011
Showing with 3,428 additions and 2,745 deletions.
  1. +22 −13 libraries/import.php
  2. +213 −185 libraries/joomla/factory.php
  3. +57 −39 libraries/joomla/html/editor.php
  4. +169 −118 libraries/joomla/html/html.php
  5. +63 −73 libraries/joomla/html/html/access.php
  6. +12 −22 libraries/joomla/html/html/batch.php
  7. +239 −231 libraries/joomla/html/html/behavior.php
  8. +47 −35 libraries/joomla/html/html/category.php
  9. +3 −4 libraries/joomla/html/html/content.php
  10. +12 −9 libraries/joomla/html/html/contentlanguage.php
  11. +79 −69 libraries/joomla/html/html/email.php
  12. +3 −3 libraries/joomla/html/html/form.php
  13. +95 −86 libraries/joomla/html/html/grid.php
  14. +43 −25 libraries/joomla/html/html/image.php
  15. +133 −106 libraries/joomla/html/html/jgrid.php
  16. +100 −115 libraries/joomla/html/html/list.php
  17. +85 −89 libraries/joomla/html/html/menu.php
  18. +9 −7 libraries/joomla/html/html/number.php
  19. +57 −58 libraries/joomla/html/html/rules.php
  20. +192 −226 libraries/joomla/html/html/select.php
  21. +30 −19 libraries/joomla/html/html/sliders.php
  22. +22 −18 libraries/joomla/html/html/string.php
  23. +21 −19 libraries/joomla/html/html/tabs.php
  24. +13 −10 libraries/joomla/html/html/tel.php
  25. +163 −107 libraries/joomla/html/pagination.php
  26. +33 −27 libraries/joomla/html/pane.php
  27. +106 −57 libraries/joomla/html/parameter.php
  28. +26 −22 libraries/joomla/html/parameter/element.php
  29. +34 −21 libraries/joomla/html/toolbar.php
  30. +8 −7 libraries/joomla/html/toolbar/button.php
  31. +18 −15 libraries/joomla/html/toolbar/button/confirm.php
  32. +3 −3 libraries/joomla/html/toolbar/button/custom.php
  33. +5 −5 libraries/joomla/html/toolbar/button/help.php
  34. +9 −9 libraries/joomla/html/toolbar/button/link.php
  35. +12 −10 libraries/joomla/html/toolbar/button/popup.php
  36. +3 −3 libraries/joomla/html/toolbar/button/separator.php
  37. +16 −14 libraries/joomla/html/toolbar/button/standard.php
  38. +150 −82 libraries/joomla/methods.php
  39. +30 −24 libraries/joomla/updater/adapters/collection.php
  40. +45 −26 libraries/joomla/updater/adapters/extension.php
  41. +25 −18 libraries/joomla/updater/update.php
  42. +5 −5 libraries/joomla/updater/updateadapter.php
  43. +47 −32 libraries/joomla/updater/updater.php
  44. +41 −32 libraries/joomla/user/authentication.php
  45. +129 −100 libraries/joomla/user/helper.php
  46. +139 −91 libraries/joomla/user/user.php
  47. +151 −103 libraries/joomla/utilities/arrayhelper.php
  48. +45 −32 libraries/joomla/utilities/buffer.php
  49. +103 −93 libraries/joomla/utilities/date.php
  50. +66 −35 libraries/joomla/utilities/simplecrypt.php
  51. +204 −119 libraries/joomla/utilities/simplexml.php
  52. +24 −24 libraries/joomla/utilities/utility.php
  53. +25 −17 libraries/joomla/utilities/xmlelement.php
  54. +41 −29 libraries/loader.php
  55. +3 −4 libraries/platform.php
View
@@ -9,35 +9,42 @@
defined('_JEXEC') or die;
// Set the platform root path as a constant if necessary.
-if (!defined('JPATH_PLATFORM')) {
+if (!defined('JPATH_PLATFORM'))
+{
define('JPATH_PLATFORM', dirname(__FILE__));
}
// Set the directory separator define if necessary.
-if (!defined('DS')) {
+if (!defined('DS'))
+{
define('DS', DIRECTORY_SEPARATOR);
}
// Detect the native operating system type.
$os = strtoupper(substr(PHP_OS, 0, 3));
-if (!defined('IS_WIN')) {
+if (!defined('IS_WIN'))
+{
define('IS_WIN', ($os === 'WIN') ? true : false);
}
-if (!defined('IS_MAC')) {
+if (!defined('IS_MAC'))
+{
define('IS_MAC', ($os === 'MAC') ? true : false);
}
-if (!defined('IS_UNIX')) {
+if (!defined('IS_UNIX'))
+{
define('IS_UNIX', (($os !== 'MAC') && ($os !== 'WIN')) ? true : false);
}
// Import the platform version library if necessary.
-if (!class_exists('JPlatform')) {
- require_once JPATH_PLATFORM.'/platform.php';
+if (!class_exists('JPlatform'))
+{
+ require_once JPATH_PLATFORM . '/platform.php';
}
// Import the library loader if necessary.
-if (!class_exists('JLoader')) {
- require_once JPATH_PLATFORM.'/loader.php';
+if (!class_exists('JLoader'))
+{
+ require_once JPATH_PLATFORM . '/loader.php';
}
/**
@@ -55,11 +62,13 @@
* If the HTTP_HOST environment variable is set we assume a Web request and
* thus we import the request library and most likely clean the request input.
*/
-if (isset($_SERVER['HTTP_HOST'])) {
+if (isset($_SERVER['HTTP_HOST']))
+{
JLoader::import('joomla.environment.request');
// If an application flags it doesn't want this, adhere to that.
- if (!defined('_JREQUEST_NO_CLEAN')) {
+ if (!defined('_JREQUEST_NO_CLEAN'))
+ {
JRequest::clean();
}
}
@@ -68,5 +77,5 @@
JLoader::import('joomla.base.object');
// Register classes that don't follow one file per class naming conventions.
-JLoader::register('JText', JPATH_PLATFORM.'/joomla/methods.php');
-JLoader::register('JRoute', JPATH_PLATFORM.'/joomla/methods.php');
+JLoader::register('JText', JPATH_PLATFORM . '/joomla/methods.php');
+JLoader::register('JRoute', JPATH_PLATFORM . '/joomla/methods.php');
Oops, something went wrong.

0 comments on commit 78e6bc0

Please sign in to comment.