Skip to content

Commit e824961

Browse files
committed
README: Whitespace.
1 parent d145840 commit e824961

File tree

1 file changed

+50
-51
lines changed

1 file changed

+50
-51
lines changed

README.md

Lines changed: 50 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
This is a set of plugins, themes, and configuration files for jQuery's website infrastructure, which is powered by WordPress. It is designed as a custom content directory. So think of `jquery-wp-content` as your `wp-content` directory.
44

5-
## Prerequisites
5+
## Prerequisites
66

77
This install guide assumes you already have certain prerequisites already configured within your environment.
88

@@ -14,72 +14,71 @@ This install guide assumes you already have certain prerequisites already config
1414

1515
1. Configure your local webserver with a virtual host that covers the relevant jQuery domains, such as `*.jquery.com` and `*.jqueryui.com`, all pointing to the same root. For example, in Apache:
1616

17-
```
18-
<VirtualHost *:80>
19-
ServerName local.jquery.com
20-
ServerAlias *.jquery.com *.jqueryui.com *.jquery.org *.qunitjs.com *.sizzlejs.com *.jquerymobile.com
21-
DocumentRoot "/srv/www/jquery"
22-
<Directory /srv/www/jquery>
23-
Options All
24-
AllowOverride All
25-
Order allow,deny
26-
Allow from all
27-
</Directory>
28-
</VirtualHost>
29-
```
30-
31-
You do not need to configure your `/etc/hosts` file for `local.*` because `jquery.com`'s DNS handles this for you.
17+
```
18+
<VirtualHost *:80>
19+
ServerName local.jquery.com
20+
ServerAlias *.jquery.com *.jqueryui.com *.jquery.org *.qunitjs.com *.sizzlejs.com *.jquerymobile.com
21+
DocumentRoot "/srv/www/jquery"
22+
<Directory /srv/www/jquery>
23+
Options All
24+
AllowOverride All
25+
Order allow,deny
26+
Allow from all
27+
</Directory>
28+
</VirtualHost>
29+
```
30+
31+
You do not need to configure your `/etc/hosts` file for `local.*` because `jquery.com`'s DNS handles this for you.
3232

3333
1. Place the WordPress core files in the document root you chose. (Don't install it.) You can do this any number of ways:
34-
35-
<ul>
36-
<li>Download the latest version from http://wordpress.org/latest.zip</li>
37-
<li>Check out the latest tag from http://core.svn.wordpress.org/tags/</li>
38-
<li>Clone the official WordPress Github mirror at http://github.com/wordpress/wordpress/</li>
39-
</ul>
34+
* Download the latest version from http://wordpress.org/latest.zip
35+
* Check out the latest tag from http://core.svn.wordpress.org/tags/
36+
* Clone the official WordPress Github mirror at http://github.com/wordpress/wordpress/
4037

4138
1. Clone `jquery-wp-content` into place, so you have a file tree that looks like this:
4239

43-
```
44-
index.php
45-
jquery-wp-content/
46-
license.txt
47-
readme.html
48-
wp-activate.php
49-
...
50-
```
40+
```
41+
index.php
42+
jquery-wp-content/
43+
license.txt
44+
readme.html
45+
wp-activate.php
46+
...
47+
```
5148

5249
1. Copy `jquery-wp-content/wp-config-sample.php` and move it up one directory, to `wp-config.php`. Fill in your database credentials.
5350

5451
1. Create an .htaccess file with the following content into that same document root:
5552

56-
```
57-
RewriteEngine On
58-
RewriteBase /
59-
RewriteRule ^index\.php$ - [L]
53+
```
54+
RewriteEngine On
55+
RewriteBase /
56+
RewriteRule ^index\.php$ - [L]
57+
58+
RewriteRule ^resources/?$ index.php [L]
59+
RewriteRule ^resources/(.+) gw-resources/%{HTTP_HOST}/$1 [L]
6060

61-
RewriteRule ^resources/?$ index.php [L]
62-
RewriteRule ^resources/(.+) gw-resources/%{HTTP_HOST}/$1 [L]
61+
# Add a trailing slash to the wp-admin of a subsite.
62+
RewriteRule ^([_0-9a-zA-Z\.-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
6363

64-
# Add a trailing slash to the wp-admin of a subsite.
65-
RewriteRule ^([_0-9a-zA-Z\.-]+/)?wp-admin$ $1wp-admin/ [R=301,L]
64+
RewriteCond %{REQUEST_FILENAME} -f [OR]
65+
RewriteCond %{REQUEST_FILENAME} -d
66+
RewriteRule ^ - [L]
6667

67-
RewriteCond %{REQUEST_FILENAME} -f [OR]
68-
RewriteCond %{REQUEST_FILENAME} -d
69-
RewriteRule ^ - [L]
68+
# Handle wp-admin, wp-includes, and root PHP files for subsites.
69+
RewriteRule ^[_0-9a-zA-Z\.-]+/((wp-admin|wp-includes).*) $1 [L]
70+
RewriteRule ^[_0-9a-zA-Z\.-]+/(.*\.php)$ $1 [L]
7071

71-
# Handle wp-admin, wp-includes, and root PHP files for subsites.
72-
RewriteRule ^[_0-9a-zA-Z\.-]+/((wp-admin|wp-includes).*) $1 [L]
73-
RewriteRule ^[_0-9a-zA-Z\.-]+/(.*\.php)$ $1 [L]
72+
RewriteRule . index.php [L]
73+
```
7474

75-
RewriteRule . index.php [L]
76-
```
77-
1. Make sure that you have assigned your WordPress files and directories the correct permissions.
75+
1. Make sure that you have assigned your WordPress files and directories the correct permissions.
7876
For example, if your WordPress files are in the directory ```wordpress```, and you are running Apache under Mac OS X with the ```_www``` user:
79-
```
80-
sudo chown -R _www wordpress
81-
sudo chmod -R g+w wordpress
82-
```
77+
78+
```
79+
sudo chown -R _www wordpress
80+
sudo chmod -R g+w wordpress
81+
```
8382

8483
1. Go to `http://local.jquery.com` and walk through the standard WordPress installation. `jquery-wp-content` includes a special install script that will initialize the entire network.
8584

0 commit comments

Comments
 (0)