Skip to content

Commit

Permalink
Some fix and improvements
Browse files Browse the repository at this point in the history
  • Loading branch information
overclokk committed Jul 18, 2014
1 parent b5f4bb5 commit 9763315
Show file tree
Hide file tree
Showing 19 changed files with 91 additions and 71 deletions.
2 changes: 1 addition & 1 deletion 404.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php get_header(); ?>
<section>
<section id="error404">
<div class="container">
<div class="row">
<div class="col-md-8">
Expand Down
2 changes: 1 addition & 1 deletion LICENSE.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
The MIT License (MIT)

Copyright (c) {{year}} {{fullname}}
Copyright (c) 2013 Enea Scerba aka Overclokk

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
Expand Down
9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,15 @@ http://www.overclokk.net/italystrap-wordpress-starter-theme

##Changelog

###1.8.5

+ Add my name in licence.md
+ Add support array with all supports in custom-post-type.php
+ Add daschicon in custom post icon
+ Add ID to section tag on 404.php, archive.php, author.php, blog.php, ful-width.php, page.php, search.php, single.php, sitemap-hetml.php
+ New file and code for Entry Meta
+ Remove img-rounded class and add center-block instead

###1.8.4

+ New description README.md
Expand Down
11 changes: 3 additions & 8 deletions archive.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* The archive template file.
*/
get_header(); ?>
<section>
<section id="archive">
<div class="container">
<div class="row">
<div class="col-md-8" itemscope itemtype="http://schema.org/CollectionPage">
Expand Down Expand Up @@ -45,19 +45,14 @@
<h2><a itemprop="url" href="<?php the_permalink(); ?>" title="<?php the_title_attribute() ?>" rel="bookmark"><span itemprop="name"><?php the_title(); ?></span></a></h2>
</header>
<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section>
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'article-thumb', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'article-thumb', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
12 changes: 3 additions & 9 deletions author.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?php get_header(); ?>
<section>
<section id="author">
<div class="container">
<div class="row">
<div class="col-md-8">
Expand Down Expand Up @@ -64,20 +64,14 @@
<h2><a itemprop="url" href="<?php the_permalink(); ?>" title="<?php the_title_attribute() ?>" rel="bookmark"><span itemprop="name"><?php the_title(); ?></span></a></h2>
</header>
<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<li><?php the_category('&');?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section>
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'article-thumb', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'article-thumb', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
12 changes: 3 additions & 9 deletions blog.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Template Name: blog
*/
get_header();?>
<section>
<section id="blog">
<div class="container">
<div class="row">
<div class="col-md-8" itemscope itemtype="http://schema.org/CollectionPage">
Expand All @@ -16,20 +16,14 @@
<h2><a itemprop="url" href="<?php the_permalink(); ?>" title="<?php the_title_attribute() ?>" rel="bookmark"><span itemprop="name"><?php the_title(); ?></span></a></h2>
</header>
<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<li><?php the_category('&');?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section>
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'article-thumb', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'article-thumb', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
12 changes: 3 additions & 9 deletions full-width.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/
get_header(); ?>
<!-- Main Content -->
<section>
<section id="full-width">
<div class="container">
<div class="row">
<div class="col-md-12">
Expand All @@ -16,20 +16,14 @@
<span itemprop="headline"><?php the_title(); ?></span></a></h1>
</header>
<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<li><?php the_category('&');?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section class="margin-bottom-25">
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'full-width', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'full-width', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
6 changes: 6 additions & 0 deletions lib/comments.php
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,13 @@ function start_el(&$output, $comment, $depth = 0, $args = array(), $id = 0) {
extract($args, EXTR_SKIP);
global $post;
?>


<?php
/**
* http://codex.wordpress.org/Function_Reference/comment_class
*/
?>
<li id="comment-<?php comment_ID(); ?>" <?php comment_class('margin-bottom-25 media comment-' . get_comment_ID()); ?> itemscope itemtype="http://schema.org/Comment">

<span class="pull-left">
Expand Down
26 changes: 23 additions & 3 deletions lib/custom-post-type.php
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
<?php
// Register Custom Post Type
/**
* Register your own Custom Post Type in this file
* @link http://codex.wordpress.org/Function_Reference/register_post_type
* @link http://melchoyce.github.io/dashicons/
*
* @package ItalyStrap
* @since 1.0.0
*/
function custom_post_type() {
$labels = array(
'name' => _x( 'Prodotti', 'Post Type General Name', 'ItalyStrap' ),
Expand All @@ -17,11 +24,24 @@ function custom_post_type() {
'not_found_in_trash' => __( 'Nessun prodotto nel cestino', 'ItalyStrap' ),
);

$supports_array = array(
'title',
'editor',
'author',
'thumbnail',
'excerpt',
'custom-fields',
'comments', // (also will see comment count balloon on edit screen)
'revisions', // (will store revisions)
'page-attributes', // (menu order, hierarchical must be true to show Parent option)
'post-formats'
);

$args = array(
'label' => __( 'prodotti', 'ItalyStrap' ),
'description' => __( 'Information pages of prodotti - <strong>insert here</strong> any description of custom post page', 'ItalyStrap' ),
'labels' => $labels,
'supports' => array( 'title', 'editor', 'excerpt', 'thumbnail', 'custom-fields', ),
'supports' => $supports_array,
'taxonomies' => array( 'category', 'post_tag', 'Slide' ),
'hierarchical' => true,
'public' => true,
Expand All @@ -30,7 +50,7 @@ function custom_post_type() {
'show_in_nav_menus' => true,
'show_in_admin_bar' => true,
'menu_position' => 5,
//'menu_icon' => '',
'menu_icon' => 'dashicons-cart',
'can_export' => true,
'has_archive' => true,
'exclude_from_search' => false,
Expand Down
2 changes: 2 additions & 0 deletions lib/debug.php
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,6 @@
//}
//echo "\r\n--->";
//}

// var_dump()
?>
4 changes: 4 additions & 0 deletions lib/image_size.php
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
<?php
/**
*
* Size for image
*/
add_image_size( 'slide', 1140, 500, true);
add_image_size( 'article-thumb', 740, 370, true);
add_image_size( 'article-thumb-index', 253, 126, true);
Expand Down
2 changes: 1 addition & 1 deletion lib/related_post.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function show_related_posts() {
<span class="col-md-3 col-xs-6">
<?php if ( has_post_thumbnail() ) {
echo "<figure><span class='thumbnail'>";
the_post_thumbnail( 'thumbnail', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'thumbnail', array('class' => 'center-block img-responsive') );
echo "</span></figure>";} ?>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<p class="text-center"><a href="<?php the_permalink() ?>" rel="bookmark" title="<?php the_title_attribute(); ?>" itemprop="url"><span itemprop="name"><strong><?php the_title(); ?></strong></span></a></p>
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"description": "Ottimizzazione landing corsi",
"author": "Enea Overclokk",
"homepage": "http://www.overclokk.net/italystrap",
"version": "1.8.4",
"version": "1.8.5",
"devDependencies": {
"grunt": "~0.4.1",
"grunt-contrib-uglify": "~0.4.0",
Expand Down
12 changes: 3 additions & 9 deletions page.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/
get_header(); ?>
<!-- Main Content -->
<section>
<section id="page">
<div class="container">
<div class="row">
<div class="col-md-8">
Expand All @@ -16,20 +16,14 @@
<span itemprop="headline"><?php the_title(); ?></span></a></h1>
</header>
<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<li><?php the_category('&');?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section class="margin-bottom-25">
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'article-thumb', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'article-thumb', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
12 changes: 3 additions & 9 deletions search.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* The search template file.
*/
get_header();?>
<section id="post-<?php the_ID(); ?>" <?php post_class('class-name'); ?>>
<section id="search post-<?php the_ID(); ?>" <?php post_class('class-name'); ?>>
<div class="container">
<div class="row">
<div class="col-md-8" itemscope itemtype="http://schema.org/SearchResultsPage">
Expand All @@ -21,20 +21,14 @@
<h2><a itemprop="url" href="<?php the_permalink(); ?>" title="<?php the_title_attribute() ?>" rel="bookmark"><span itemprop="name"><?php the_title(); ?></span></a></h2>
</header>
<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<li><?php the_category('&');?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section>
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'article-thumb', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'article-thumb', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
12 changes: 3 additions & 9 deletions single.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/
get_header(); ?>
<!-- Main Content -->
<section>
<section id="single">
<div class="container">
<div class="row">
<div class="col-md-8">
Expand All @@ -17,20 +17,14 @@
</header>

<footer>
<ul class="list-inline">
<li>Del: <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li>Autore: <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>
<li><?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<li><?php the_category('&');?></li>
<?php the_tags('<li itemprop="keywords">Tags: ',' - ' , '</li>'); ?>
</ul>
<?php get_template_part('template/meta'); ?>
</footer>
<meta itemprop="image" content="<?php echo italystrap_thumb_url();?>"/>
<section class="margin-bottom-25">
<?php if ( has_post_thumbnail() ) { ?>
<div class="margin-bottom-25 thumbnail">
<?php echo "<figure>";
the_post_thumbnail( 'article-thumb', array('class' => 'img-rounded img-responsive') );
the_post_thumbnail( 'article-thumb', array('class' => 'center-block img-responsive') );
echo "</figure>";?>
</div>
<?php } ?>
Expand Down
2 changes: 1 addition & 1 deletion sitemap-html.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
*/
get_header(); ?>
<!-- Main Content -->
<section>
<section id="sitemap-html">
<div class="container">
<div class="row">
<div class="col-md-8">
Expand Down
2 changes: 1 addition & 1 deletion style.css
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Theme URI: http://www.overclokk.net/italystrap-wordpress-starter-theme
Author: Enea Overclokk
Author URI: http://www.overclokk.net
Description: Wordpess starter theme with twitter bootstrap, HTML5 boilerplate and Schema.org <a href="https://github.com/overclokk/ItalyStrap/graphs/contributors">Contribute on GitHub</a>
Version: 1.8.4
Version: 1.8.5
License: MIT License (MIT)
License URI: http://opensource.org/licenses/MIT
Tags: right-sidebar, featured-images, full-width-template, microdata
Expand Down
20 changes: 20 additions & 0 deletions template/meta.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
<?php
/**
*
* Style for entry meta for
*/
?>
<ul class="list-inline">
<li><span class="glyphicon glyphicon-calendar"></span> <time datetime="<?php the_time('Y-m-d') ?>" itemprop="datePublished"><?php the_time('d-m-Y') ?></time></li>
<li><span class="glyphicon glyphicon-user"></span> <span itemprop="author" itemscope itemtype="http://schema.org/Person"><?php the_author_posts_link(); ?></span></li>

<?php if ( comments_open() ): ?>
<li><span class="glyphicon glyphicon-comment"></span> <?php comments_number( '0 risposte', '1 risposta', '% risposte' ); ?></li>
<?php endif ?>

<?php if ( !is_page() ): ?>
<li><span class="glyphicon glyphicon-folder-open"></span> <?php the_category('&');?></li>
<?php endif ?>

<?php the_tags('<li itemprop="keywords"><span class="glyphicon glyphicon-tags"></span> ',' - ' , '</li>'); ?>
</ul>

0 comments on commit 9763315

Please sign in to comment.