Skip to content

Commit

Permalink
Standardized headers to use .title; this is actually an old convent…
Browse files Browse the repository at this point in the history
…ion we're re-enforcing. It should be much easier to create these headers now.
  • Loading branch information
morrisonlevi committed Dec 27, 2013
1 parent 897eae1 commit 4f3a842
Show file tree
Hide file tree
Showing 7 changed files with 64 additions and 76 deletions.
2 changes: 1 addition & 1 deletion conferences/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
$id = parse_url($entry["id"], PHP_URL_FRAGMENT);
$date = date_format(date_create($entry["updated"]), 'Y-m-d');
$content .= '<div class="newsentry">';
$content .= '<h3 class="newstitle"><a href="'. $MYSITE.$link .'" name="' . $id . '">' . $entry["title"] . '</a></h3>';
$content .= '<h3 class="newstitle title"><a href="'. $MYSITE.$link .'" name="' . $id . '">' . $entry["title"] . '</a></h3>';
$content .= '<div class="newsimage">';
$content .= sprintf('<a href="%s"><img src="/images/news/%s"></a>', $entry["newsImage"]["link"], $entry["newsImage"]["content"]);
$content .= '</div>';
Expand Down
2 changes: 1 addition & 1 deletion downloads.php
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
<?php $mver = substr($v, 0, strrpos($v, '.')); ?>
<?php $stable = $i++ === 0 ? "Current Stable" : "Old Stable"; ?>

<h3 id="v<?php echo $v; ?>" class="content-header">
<h3 id="v<?php echo $v; ?>" class="title">
<span class="release-state"><?php echo $stable; ?></span>
PHP <?php echo $v; ?>
(<a href="/ChangeLog-<?php echo $MAJOR; ?>.php#<?php echo urlencode($v); ?>" class="changelog">Changelog</a>)
Expand Down
2 changes: 1 addition & 1 deletion index.php
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@
$content .= <<<NEWSENTRY
<div class="newsentry">
<div class="newstime">$date</div>
<h3 class="newstitle"><a href="{$MYSITE}{$link}" id="{$id}">{$entry["title"]}</a></h3>
<h3 class="newstitle title"><a href="{$MYSITE}{$link}" id="{$id}">{$entry["title"]}</a></h3>
<div class="newscontent">
{$entry["content"]}
</div>
Expand Down
40 changes: 6 additions & 34 deletions styles/home.css
Original file line number Diff line number Diff line change
Expand Up @@ -66,41 +66,13 @@ complimentary greens: 9FB553 7B8851 61761B C6DA82 CCDA99
content: "\21AF \2003";
}



.newsentry {
margin: 0 0 2.25em;
position: relative;
}
.newsentry h3 {
font-weight:normal;
margin-left: -25px;
padding-left: 25px;
padding-right: 25px;
margin-right: -25px
.home .newsentry .newstitle a:after {
content:"\20 \00bb";
color:#666;
}
.newsentry h3 .release-state {
float: right;
opacity: 0.8;
}
.newsentry h3 a {
color: #000;
border:0;
}
.newsentry .newstitle a::after {
content:"\20 \00bb";
color:#666;
}
.newsentry .newstime {
float:right;
margin-top:.5em;
margin-right:.444444444em;
}

.newsentry .newsimage a {
float: right;
border: 0;
padding: 10px;
.home .newsentry .newstime {
margin-top:8px;
margin-right:12px;
}

p.archive {
Expand Down
63 changes: 48 additions & 15 deletions styles/theme-base.css
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,9 @@ html {
-webkit-text-size-adjust: 100%;
-ms-text-size-adjust: 100%;
}
a {
border-bottom:1px solid;
}
a:focus {
outline: thin dotted #333;
outline-offset: -2px;
Expand Down Expand Up @@ -485,25 +488,18 @@ hr {
position: relative;
margin-top:1.5em;
}

#usernotes h3.title {
border-bottom: 0.166666667em solid;
margin-bottom: -0.166666667em;
line-height:2.666666667;
}

#usernotes .count {
display:inline-block;
vertical-align: text-top;
padding: 0.333333333em .5em;
font-size: 0.666666667em;
line-height:2;
vertical-align: middle;
}

/* Add a note buttons. */
#usernotes .action {
display: block;
top: 1em;
right: 0;
top: 8px;
right: 12px;
position: absolute;
text-align: right;
}
Expand Down Expand Up @@ -1198,13 +1194,14 @@ fieldset {
}
}

.newsentry h3,
.downloads .content-header,
.refsect1 h3.title {
padding:0.333333333em 0.444444444em;
.title {
padding:6px 12px;
border-top:2px solid #669;
border-bottom:1px solid;
}
.title a {
border:0;
}
.refsect1 > *:last-child {
margin-bottom:0;
}
Expand All @@ -1216,6 +1213,19 @@ fieldset {
margin-top:0;
}

.country {
position: relative;
padding:0 12px;
}
.country .countrytitle {
margin-left:-12px;
margin-right:-12px;
}
.country .title img {
position: absolute;
right: 12px;
}

/* {{{ General styles (p, parameters, initializers, ...) */

.refsect1 .parameter {
Expand Down Expand Up @@ -1884,5 +1894,28 @@ aside.tips div.inner {
}
/* }}} */

/* {{{ News */
.newsentry {
margin: 0 0 1.5em;
position: relative;
}
.newsentry h3 {
font-weight:normal;
}
.newsentry h3 .release-state {
float: right;
opacity: 0.8;
}
.newsentry .newstime {
float:right;
}

.newsentry .newsimage a {
float: right;
border: 0;
padding: 10px;
}
/* }}} */


// vim: set ts=2 sw=2 et:
24 changes: 4 additions & 20 deletions styles/theme-medium.css
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ h1, h2, h3, h4, h5, h6 {
a:link,
a:visited {
color: #369;
border-bottom: 1px solid;
}

a:hover,
Expand Down Expand Up @@ -106,13 +105,7 @@ h1.refname {
color:#f80;
}

.newsentry h3 a {
color: #446;
border-color:#C6C6E2;
}
.newsentry h3,
.downloads .content-header,
.refsect1 h3.title {
.title {
color: #446;
background: #E3E3F1;
border-radius:0 0 2px 2px;
Expand All @@ -122,6 +115,9 @@ h1.refname {
inset 1px 0 1px -1px #C6C6E2,
inset -1px 0 1px -1px #C6C6E2
}
.title a {
color: #446;
}

.methodname b,
.methodname strong,
Expand All @@ -140,7 +136,6 @@ h1.refname {
color:#737373;
}


/* {{{ Warnings, Tips and Notes */
#flash-message .success {
background:#E6F2D9;
Expand Down Expand Up @@ -210,10 +205,6 @@ div.warning:before {


/* {{{ User notes */
#usernotes h3.title {
border-color:#669;
color:#262626;
}
#usernotes .count {
background-color: #669;
color: #fff;
Expand Down Expand Up @@ -489,12 +480,5 @@ div.elephpants img:focus {
text-align: center;
color: #fff;
}
.country {
position: relative;
}
.country .title img {
position: absolute;
right: 0px;
}

// vim: set ts=2 sw=2 et:
7 changes: 3 additions & 4 deletions ug.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
site_header("Hypertext Preprocessor",
array(
'current' => 'community',
'css' => array('home.css'),
//'intro' => $intro
)
);
Expand Down Expand Up @@ -60,11 +59,11 @@ function format_event_date($starts, $ends, $usually) {
$entry = "";

$entry .= '<div class="country" id="' . $country. '">';
$entry .= '<h2 class="title">' . $countrycode;
$entry .= '<h2 class="title countrytitle">' . $countrycode;
$entry .= '<img alt="' . $countrycode . '" height="25" width="45" src="' . $_SERVER['STATIC_ROOT'] . '/images/flags/beta/' . strtolower($country) . '.png">';
$entry .= '</h2>';
if ($events["ug"]) {
$entry .= "<h2>User Groups in $countrycode</h2>";
$entry .= "<h2 class='title'>User Groups in $countrycode</h2>";
}

foreach($events["ug"] as $event) {
Expand All @@ -80,7 +79,7 @@ function format_event_date($starts, $ends, $usually) {
$entry .= '</div>';
}
if ($events["conf"]) {
$entry .= "<h2>Conferences in $countrycode</h2>";
$entry .= "<h2 class='title'>Conferences in $countrycode</h2>";
}
foreach($events["conf"] as $event) {
$link = $event["url"];
Expand Down

0 comments on commit 4f3a842

Please sign in to comment.