Skip to content

Commit 8150ac0

Browse files
committed
Merge branch 'master' into prod
2 parents 8ecdb5c + a287e41 commit 8150ac0

File tree

9 files changed

+44
-39
lines changed

9 files changed

+44
-39
lines changed

.htaccess

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<IfModule mod_rewrite.c>
22
RewriteEngine On
3-
RewriteBase /
3+
#RewriteBase /~ramsey/phpcon-web/
44
RewriteRule ^(resources|templates).*$ http://phpcon.org/ [R=302,L]
55
RewriteCond %{REQUEST_FILENAME} !-d
66
RewriteCond %{REQUEST_FILENAME} !-f

index.php

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,26 +4,28 @@
44
ini_set('display_errors', 0);
55

66
$uri = $_SERVER['REQUEST_URI'];
7-
if (substr($uri, -1) == '/') {
8-
$uri = substr($uri, 0, -1);
9-
}
7+
$base = dirname($_SERVER['SCRIPT_NAME']);
8+
$path = substr($uri, strlen($base));
9+
$parsedUrl = parse_url(basename($path));
10+
$requestedPage = $parsedUrl['path'];
1011

11-
$requestedPage = substr($uri, strrpos($uri, '/') + 1);
1212
if (strtolower(substr($requestedPage, -5)) == '.html') {
13-
header('Location: ' . substr($uri, 0, strrpos($uri, '/')) . '/' . substr($requestedPage, 0, -5), true, 301);
13+
header('Location: ' . $base . (substr($base, -1) == '/' ? '' : '/') . substr($requestedPage, 0, -5), true, 301);
1414
exit;
1515
}
16-
if (strtolower($requestedPage) == 'index' || strtolower($requestedPage) == 'index.php') {
17-
header('Location: /', true, 301);
16+
if (strtolower($requestedPage) == 'home' || strtolower($requestedPage) == 'index' || strtolower($requestedPage) == 'index.php') {
17+
header('Location: ' . $base . (substr($base, -1) == '/' ? '' : '/'), true, 301);
1818
exit;
1919
}
20-
if (strlen($requestedPage) == 0) {
20+
if (!$requestedPage) {
2121
$requestedPage = 'home';
2222
}
2323
if (!ctype_alnum($requestedPage)) {
2424
$requestedPage = '404';
2525
}
2626

27+
$baseHref = '//' . $_SERVER['SERVER_NAME'] . $base . (substr($base, -1) == '/' ? '' : '/');
28+
2729
if (!(include 'resources/' . $requestedPage . '.html')) {
2830
header('HTTP/1.0 404 Not Found');
2931
include 'resources/404.html';

resources/404.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ <h1>PHP Community
99
<span>Conference</span></h1>
1010
<div id="nav">
1111
<ul>
12-
<li><a href="/">Home</a></li>
13-
<li><a href="/about">About Us</a></li>
14-
<li><a href="/sponsorships">Sponsor Us</a></li>
15-
<li><a href="/cfp">CFP</a></li>
16-
<li><a href="/subscribe">Keep in Touch</a></li>
12+
<li><a href="home">Home</a></li>
13+
<li><a href="http://phpcon.eventbrite.com/">Register</a></li>
14+
<li><a href="about">About Us</a></li>
15+
<li><a href="sponsorships">Sponsor Us</a></li>
16+
<li><a href="subscribe">Keep in Touch</a></li>
1717
</ul>
1818
</div>
1919
<div id="social">

resources/about.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ <h1>PHP Community
99
<span>Conference</span></h1>
1010
<div id="nav">
1111
<ul>
12-
<li><a href="/">Home</a></li>
12+
<li><a href="home">Home</a></li>
13+
<li><a href="http://phpcon.eventbrite.com/">Register</a></li>
1314
<li>About Us</li>
14-
<li><a href="/sponsorships">Sponsor Us</a></li>
15-
<li><a href="/cfp">CFP</a></li>
16-
<li><a href="/subscribe">Keep in Touch</a></li>
15+
<li><a href="sponsorships">Sponsor Us</a></li>
16+
<li><a href="subscribe">Keep in Touch</a></li>
1717
</ul>
1818
</div>
1919
<div id="social">

resources/cfp.html

Lines changed: 6 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ <h1>PHP Community
99
<span>Conference</span></h1>
1010
<div id="nav">
1111
<ul>
12-
<li><a href="/">Home</a></li>
13-
<li><a href="/about">About Us</a></li>
14-
<li><a href="/sponsorships">Sponsor Us</a></li>
15-
<li>CFP</li>
16-
<li><a href="/subscribe">Keep in Touch</a></li>
12+
<li><a href="home">Home</a></li>
13+
<li><a href="http://phpcon.eventbrite.com/">Register</a></li>
14+
<li><a href="about">About Us</a></li>
15+
<li><a href="sponsorships">Sponsor Us</a></li>
16+
<li><a href="subscribe">Keep in Touch</a></li>
1717
</ul>
1818
</div>
1919
<div id="social">
@@ -25,8 +25,7 @@ <h1>PHP Community
2525
<p>Tell us about an inspiring project you&rsquo;re working on and why it&rsquo;s important.</p>
2626
</div>
2727
<div class="section">
28-
29-
<h2>Call for Proposals</h2>
28+
<h2>The Call for Proposals is <strong>closed</strong>. Thank you for your interest.</h2>
3029
<p>We're calling for presentations on the topic of <strong>real world PHP</strong>. Tell us about an inspiring project you're working on and why it's important. We don't want to focus on the details of the code itself, but rather on <strong>how your project solves a problem or fills a need</strong>.</p>
3130
<p>If selected as a speaker, we will cover your air fare and hotel costs for the dates of the event. To submit a talk, please email your proposed title and abstract to <a href="mailto:[email protected]">[email protected]</a> by <strong>January 31, 2011</strong>.</p>
3231

resources/home.html

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,20 @@ <h3>Nashville,<span>&nbsp;</span>TN</h3>
1515
<div id="nav">
1616
<ul>
1717
<li>Home</li>
18-
<li><a href="/about">About Us</a></li>
19-
<li><a href="/sponsorships">Sponsor Us</a></li>
20-
<li><a href="/cfp">CFP</a></li>
21-
<li><a href="/subscribe">Keep in Touch</a></li>
18+
<li><a href="http://phpcon.eventbrite.com/">Register</a></li>
19+
<li><a href="about">About Us</a></li>
20+
<li><a href="sponsorships">Sponsor Us</a></li>
21+
<li><a href="subscribe">Keep in Touch</a></li>
2222
</ul>
2323
</div>
2424
</div>
2525
<div class="aside">
2626
<p>A conference for people who care about PHP and what they make with it.</p>
2727
</div>
2828
<div class="section">
29-
<p>The PHP Community Conference is all about you! Come on out to Nashville for a different kind of conference this spring. We're going to hear from community members about projects they're working on and how they were inspired. It's going to be a fun, laid-back event where you and the people you'll meet can collaborate to build some awesome applications of your own with PHP. Tickets go on sale February 3, 2011. <a href="/subscribe">Subscribe to our mailing list</a>, and we'll keep you updated on all the latest PHP Community Conference news and information.</p>
30-
<p>Of course we'll need some help from all of you to pull this off. We're calling for presentations on the topic of real world PHP. Tell us about an inspiring project you're working on and why it's important. We don't want to focus on the details of the code itself, but rather on how your project solves a problem or fills a need. If selected as a speaker, we will cover your air fare and hotel costs for the dates of the event. To submit a talk, please email your proposed title and abstract to <a href="mailto:[email protected]">[email protected]</a> by January 31, 2011.</p>
29+
<p>We know you were sold at <em>Community</em> <strong>so <a href="http://phpcon.eventbrite.com/">register</a> now!</strong> Spaces will go quickly. If you need a bit of a sales pitch, keep reading. Read quickly though, we could be sold out before you finish.</p>
30+
<p>The PHP Community Conference is all about you! Come on out to Nashville for a different kind of conference this spring. We're going to hear from community members about projects they're working on and how they were inspired. It's going to be a fun, laid-back event where you and the people you'll meet can collaborate to build some awesome applications of your own with PHP.</p>
31+
<p><a href="subscribe">Subscribe to our mailing list</a>, and we'll keep you updated on all the latest PHP Community Conference news and information.</p>
3132
</div>
3233

3334
<div id="sponsors">

resources/sponsorships.html

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@ <h1>PHP Community
99
<span>Conference</span></h1>
1010
<div id="nav">
1111
<ul>
12-
<li><a href="/">Home</a></li>
13-
<li><a href="/about">About Us</a></li>
12+
<li><a href="home">Home</a></li>
13+
<li><a href="http://phpcon.eventbrite.com/">Register</a></li>
14+
<li><a href="about">About Us</a></li>
1415
<li>Sponsor Us</li>
15-
<li><a href="/cfp">CFP</a></li>
16-
<li><a href="/subscribe">Keep in Touch</a></li>
16+
<li><a href="subscribe">Keep in Touch</a></li>
1717
</ul>
1818
</div>
1919
<div id="social">
@@ -59,6 +59,7 @@ <h3><a name="silver">Silver Sponsorship: $2,500.00</a></h3>
5959

6060

6161
<h3>Community Sponsorship: $500.00</h3>
62+
<p>Become a <a href="http://phpconsponsors.eventbrite.com/">Community Sponsor</a> now.</p>
6263
<ul>
6364
<li>1 ticket to the main conference day while supplies last<br>
6465
<em>Tickets are limited to the first 50 Community Sponsors</em></li>

resources/subscribe.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ <h1>PHP Community
99
<span>Conference</span></h1>
1010
<div id="nav">
1111
<ul>
12-
<li><a href="/">Home</a></li>
13-
<li><a href="/about">About Us</a></li>
14-
<li><a href="/sponsorships">Sponsor Us</a></li>
15-
<li><a href="/cfp">CFP</a></li>
12+
<li><a href="home">Home</a></li>
13+
<li><a href="http://phpcon.eventbrite.com/">Register</a></li>
14+
<li><a href="about">About Us</a></li>
15+
<li><a href="sponsorships">Sponsor Us</a></li>
1616
<li>Keep in Touch</li>
1717
</ul>
1818
</div>

templates/page.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@
1212
<meta property="fb:admins" content="623959689,796025211,756315701,12105030" />
1313
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
1414

15+
<base href="<?php echo $baseHref; ?>" />
16+
1517
<link href="webfontkit/stylesheet.css" rel="stylesheet" type="text/css">
1618
<link href="css/style.css?r=20110125-2" rel="stylesheet" type="text/css">
1719
<!-- Grab latest version of jQuery -->

0 commit comments

Comments
 (0)