Sergey Biryukov
47ed56f38f
Code Modernization: Replace `dirname( __FILE__ )` calls with `__DIR__` magic constant.
...
This avoids the performance overhead of the function call every time `dirname( __FILE__ )` was used instead of `__DIR__`.
This commit also includes:
* Removing unnecessary parentheses from `include`/`require` statements. These are language constructs, not function calls.
* Replacing `include` statements for several files with `require_once`, for consistency:
* `wp-admin/admin-header.php`
* `wp-admin/admin-footer.php`
* `wp-includes/version.php`
Props ayeshrajans, desrosj, valentinbora, jrf, joostdevalk, netweb.
Fixes #48082 .
Built from https://develop.svn.wordpress.org/trunk@47198
git-svn-id: http://core.svn.wordpress.org/trunk@46998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-06 06:33:11 +00:00
Gary Pendergast
aaf99e6913
Code is Poetry.
...
WordPress' code just... wasn't.
This is now dealt with.
Props jrf, pento, netweb, GaryJ, jdgrimes, westonruter, Greg Sherwood from PHPCS, and everyone who's ever contributed to WPCS and PHPCS.
Fixes #41057 .
Built from https://develop.svn.wordpress.org/trunk@42343
git-svn-id: http://core.svn.wordpress.org/trunk@42172 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-11-30 23:11:00 +00:00
Andrew Nacin
fd57b239d2
Don't rely on include_path to include files.
...
Always use dirname() or, once available, ABSPATH.
props ketwaroo, hakre.
fixes #17092 .
Built from https://develop.svn.wordpress.org/trunk@25616
git-svn-id: http://core.svn.wordpress.org/trunk@25533 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-09-25 00:18:11 +00:00
ryan
e3b46b25d3
Lose EOF ?>. Clean up EOF newlines. fixes #12307
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@19712 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2012-01-08 17:01:11 +00:00
nacin
9cb6e158fc
Switch from Panel/SubPanel to Screen in inline documentation and Codex links. props michaelh, fixes #17265 .
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@17748 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2011-04-28 15:24:49 +00:00
nacin
a717edca97
Always exit after wp_redirect. props filosofo, fixes #15518 .
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@16847 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-12-09 18:02:54 +00:00
dd32
4f3b9f7b7f
Use Absolute URL's & API's in header redirects in more locations. See #14062
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@16008 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-10-27 10:43:43 +00:00
westi
7f894ae416
phpdoc for wp-admin. See #7496 props santosj.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@8645 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2008-08-14 06:30:38 +00:00
ryan
5b8113578d
Allow wp-config.php to exist one level up from WordPress root directory. Props sambauers. fixes #6933
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@7971 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2008-05-21 05:59:27 +00:00
ryan
2229af8cb6
Resurrect moderation.php as a redirect to edit-comments.php.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@7027 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2008-02-25 19:29:30 +00:00
ryan
fd18739a7a
Remove moderation.php. edit-comments.php now handles moderation
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@7019 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2008-02-25 08:24:44 +00:00
ryan
90ef210610
Validation fixes from nbachiyski. fixes #5962
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@6980 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2008-02-22 17:30:43 +00:00
ryan
ad42d0148a
Remove raquo from buttons. Props filosofo. fixes #5938
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@6943 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2008-02-20 19:30:55 +00:00
ryan
7f722d1f90
Use __ngettext() for plurals. Props darkdragon. see #4865
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@6430 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-12-20 17:05:06 +00:00
ryan
24f0b83cae
Fix comment delete links and ajax moderation. Props mdawaffe. fixes #5288
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@6298 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-10-31 01:37:58 +00:00
ryan
321c310717
Remove trailing whitespace
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@6026 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-09-03 23:32:58 +00:00
markjaquith
aec08dedad
Use doublequotes so line break works. Props Lloyd. fixes #4557
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5773 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-06-28 23:08:23 +00:00
ryan
2f09416258
Trim empty lines. Nothing but newline.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5700 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-06-14 02:25:30 +00:00
rob1n
02959eb9d4
Move a stray <p> from a recent change.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5663 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-06-07 22:52:09 +00:00
matt
ff1e0f32fc
No good reason to align the mark all in the center or move the metadata around.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5661 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-06-07 14:01:02 +00:00
rob1n
380d9c3487
Show me more!
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5578 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-05-28 19:32:24 +00:00
rob1n
a5e4caba87
Moderation cleaned up, add paging and various bug fixes. fixes #4317
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5574 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-05-28 17:21:25 +00:00
matt
b0d60f0351
Show post name and bring organization in line with the edit comments page.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5472 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-05-14 03:41:03 +00:00
rob1n
7db9d9f6b2
Use fancy quotes instead of raw quotes (which should have been " anyways).
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@5378 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-05-03 01:23:14 +00:00
ryan
bec5b4f188
gettext date formats. Props rob1n and yskin. fixes #3863
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4974 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-03-07 01:25:17 +00:00
ryan
0dfaeadb12
JS quoting fixes from nbachiyski. fixes #3539
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4702 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2007-01-08 21:22:10 +00:00
markjaquith
8a678f3841
i18n fixes, logic cleanup, wording clarifications, and more from nbachiyski. fixes #3474
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4658 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-12-21 23:06:18 +00:00
markjaquith
deb53f7027
No need to backslash escape single quotes and line breaks when using js_escape()
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4655 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-12-21 06:04:39 +00:00
ryan
cc44db510d
Use js_escape. Props nbachiyski. fixes #3399
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4535 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-11-28 21:51:13 +00:00
ryan
9f534ebae6
Remove trailing spaces and convert spaces to tabs. Props Nazgul. fixes #986
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4495 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-11-19 07:56:05 +00:00
ryan
eda9021317
Hold off on menu cleanup until next release. There be dragons.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4480 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-11-18 07:31:29 +00:00
matt
07126127e6
Admin functions cleanup, and change how we do titles and parents in the backend
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4478 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-11-18 06:09:48 +00:00
matt
448bd4fb7b
Create a new comments top-level menu and move things under it
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4474 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-11-17 16:22:46 +00:00
markjaquith
2b1f1fd240
More [4432] cleanup. fixes #3309
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4437 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-10-31 06:50:38 +00:00
ryan
43f36aab78
RTL enhancements from Sewar. #3136
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4258 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-09-27 00:51:17 +00:00
ryan
849a0d29d7
Use get_option instead of get_settings. Just 'cause.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4144 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-08-30 21:46:31 +00:00
matt
b2d5509491
Fix for radio labels on moderation page
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@4005 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-07-07 18:35:49 +00:00
ryan
42557940a1
Use wp_die(). Props filosofo. fixes #2914
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3985 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-07-05 22:00:03 +00:00
ryan
f02a7931d8
Validation fixes from leftjustified. fixes #2907
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3983 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-07-05 20:28:02 +00:00
ryan
55af15d623
wp_reset_vars() from Sewar. fixes #2888
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3946 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-07-03 19:03:37 +00:00
ryan
ff19f4b5a5
Use wp_redirect().
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3928 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-06-27 05:38:56 +00:00
ryan
73b4b6055e
List manipulation improvements from mdawaffe. fixes #2786
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3847 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-06-06 04:14:04 +00:00
ryan
4d49e98fe4
Script loader from mdawaffe. #2701
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3788 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-05-22 17:16:05 +00:00
ryan
293b3b4dee
Better escaping of strings used in JS.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3763 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-05-05 07:49:05 +00:00
ryan
3f57a94f4c
Nonce from above. #2678
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3759 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-05-02 22:36:06 +00:00
matt
7fea857c9f
Unification of how we display comments in various parts of the admin section
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3722 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-04-19 08:30:56 +00:00
ryan
805df2b129
Ref checks from mdawaffe.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3665 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-03-30 23:12:54 +00:00
ryan
b3214d6cc8
Fix edit comment link.
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3599 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-03-02 12:26:13 +00:00
ryan
dd202ce1f9
Death to trailing tabs. Props Mark J. fixes #2405
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3517 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-02-12 07:53:23 +00:00
matt
759faa6b9a
HTML and JS cleanup
...
git-svn-id: http://svn.automattic.com/wordpress/trunk@3422 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2006-01-10 05:16:17 +00:00