From: Gabriel Dunne Date: Sat, 29 Jun 2013 03:58:18 +0000 (-0700) Subject: Added Archive mode X-Git-Url: https://git.quilime.com/?a=commitdiff_plain;h=fae1e8e361d66534462e62a97f04043cacce6ab6;p=plog.git Added Archive mode --- diff --git a/css/style.css b/css/style.css index 870db98..5cde885 100644 --- a/css/style.css +++ b/css/style.css @@ -78,7 +78,9 @@ blockquote { color:#999; line-height:1.3em; margin:0; - padding:0; + padding:1em; + background:#ddd; + max-width:600px; } pre { padding:10px 20px; diff --git a/lib/config.ini b/lib/config.ini index 8479201..456788b 100644 --- a/lib/config.ini +++ b/lib/config.ini @@ -1,7 +1,7 @@ ; settings -site_title = GABRIEL DUNNE +site_title = GABRIEL L DUNNE clean_urls = 1 -limit = 100 +limit = 1000 ; http://php.net/manual/en/function.date.php ; ie, M d Y, h:i:s A T date_format = M d Y diff --git a/lib/data.php b/lib/data.php index 5e288b6..892e78e 100644 --- a/lib/data.php +++ b/lib/data.php @@ -12,6 +12,7 @@ function get_entries( $path = "", $args = array() ) $order = empty($args['order']) ? SORT_DESC : $args['order']; $tag = empty($args['tag']) ? null : $args['tag']; $show_featured = isset($args['show_featured']) ? $args['show_featured'] : 0; + $archived = isset($args['archived']) ? $args['archived'] : 0; $local_path = rtrim(LOCAL_ROOT . '/' . CONTENT_DIR . '/' . $path, "/"); $data_path = rtrim(LOCAL_ROOT . '/' . DATA_DIR . '/' . CONTENT_DIR . '/' . $path, '/'); @@ -72,6 +73,13 @@ function get_entries( $path = "", $args = array() ) } } } + if ($archived) { + foreach ($data->entries as $i => $entry) { + if (!$entry->archived) { + unset($data->entries[$i]); + } + } + } if (isset($tag)) { foreach ($data->entries as $i => $entry) { if ( @@ -290,6 +298,7 @@ function parse_entry($fileInfo, $page = false) $file['timestamp'] = $file['config']['date'] ? date('U', strtotime( $file['config']['date'])) : $fileInfo->getCTime(); $file['tags'] = isset($file['config']['tags']) ? explode(" ", $file['config']['tags']) : null; $file['featured'] = isset($file['config']['featured']) ? $file['config']['featured'] : null; + $file['archived'] = isset($file['config']['archived']) ? $file['config']['archived'] : null; $file['related'] = isset($file['config']['related']) ? explode(" ", $file['config']['related']) : null; $file['content'] = Markdown($content); diff --git a/lib/model.php b/lib/model.php index 85cd0f8..acb213a 100644 --- a/lib/model.php +++ b/lib/model.php @@ -86,6 +86,9 @@ class Model if (isset($this->config->config->show_featured) && !$this->tag) { $entries_args['show_featured'] = true; } + if (isset($this->config->config->archived) && !$this->tag) { + $entries_args['archived'] = true; + } $this->entries = get_entries( $request['path'], $entries_args); // pagination diff --git a/pages/cv b/pages/about similarity index 94% rename from pages/cv rename to pages/about index 0fde032..f8cc16c 100755 --- a/pages/cv +++ b/pages/about @@ -1,5 +1,4 @@ template = page -title = c/v --
@@ -8,7 +7,8 @@ title = c/v Gabriel Labov Dunne studio (at) gabrieldunne (dot) com 1242 Market St, FL 2 -San Francisco, CA 94102 +San Francisco, CA 94102 +[blog](http://quilime.com)

@@ -20,7 +20,7 @@ San Francisco, CA 94102
-###### select exhibitions / projects +###### exhibition 2013 [Stars](/stars) SomArts 'NightLight', San Francisco CA 2013 [FaceReplace](/facereplace) @ ArtHackDay "Lethal Software, San Francisco CA 2012 [Audio ShaderToy](/audioshadertoy) @ Creators Project SF, collab w/ Ryan Alexander, Reza Ali, San Francisco, CA @@ -55,7 +55,7 @@ San Francisco, CA 94102
-###### talks / teaching / workshops +###### talks / teaching 2012 Film/Code/Remix, BAVC, San Francisco 2012 Processing, ACCU, Symantic, Palo Alto 2012 Processing, ACCU Davis Linux Users Group, Davis, CA diff --git a/templates/archive.html.tpl b/templates/archive.html.tpl index 204ac17..c4a3320 100644 --- a/templates/archive.html.tpl +++ b/templates/archive.html.tpl @@ -1,28 +1,46 @@ - include_template('head-inc.html.tpl') ?> - <?=SITE_TITLE?><?=$this->page_title(TITLE_DELIMITER);?> - - - -
-
    +include_template('nav.html.tpl', array('index' => true)) ?> + +entries; + $this->assign('pagination', $m->pagination); + $tag = ""; +?> + + +
    + -
    + + include_template('pagination.html.tpl') ?> + include_template('footer.html.tpl') ?> - include_template('nav.html.tpl') ?> diff --git a/templates/entry.html.tpl b/templates/entry.html.tpl index 213ad45..0ec7762 100644 --- a/templates/entry.html.tpl +++ b/templates/entry.html.tpl @@ -14,7 +14,7 @@ ' . $entry->content); ?>
-is_single) && $entry->is_single) || $show_metadata) : ?> +is_single) && $entry->is_single) || (isset($show_metadata) && $show_metadata)) : ?>