Vous avez reçu un message "Your GitLab account has been locked ..." ? Pas d'inquiétude : lisez cet article https://docs.gricad-pages.univ-grenoble-alpes.fr/help/unlock/

Commit 8d2dbd1d authored by Mathieu Mangeot's avatar Mathieu Mangeot
Browse files

Première version du thème basique

parent ff18f3ee
body {
font-family: "Lucida Grande",Tahoma,Helvetica,sans-serif;
}
header {
display: block;
text-align: center;
color: navy;
}
header fieldset, header fieldset legend {
border: 2px solid blue;
}
header nav {
display:block;
}
#menuprincipal ul {margin: 0; padding: 0;
list-style-type: none; list-style-image: none; }
#menuprincipal li {display: inline; }
#menuprincipal ul li a {text-decoration:none; margin: 4px;
padding: 5px 20px 5px 20px; color: blue;
background: pink;}
#menuprincipal ul li a:hover {color: purple;
background: yellow; }
#legendemenuprincipal {
float:left;
}
fieldset {
margin: 10px;
}
fieldset, legend {
background-color: #eee;
border-radius: 5px;
}
legend {
border-top-left-radius: 5px;
border-top-right-radius: 5px;
font-weight: normal;
font-style: italic;
font-size: 1em;
text-shadow: #fff 1px 1px 1px;
}
#fieldsetcontent, #fieldsetcontent fieldset, #fieldsetcontent legend, .post, .entry fieldset, .entry legend {
border: 2px solid red;
}
aside {
float: right;
}
#fieldsetsidebar, #fieldsetsidebar legend {
border: 2px solid green;
}
footer fieldset, footer fieldset legend {
border: 2px solid purple;
}
footer {
display: block;
text-align: center;
}
<footer>
<p>Le footer.php commence ici. La barre d'en-tête d'admin de WP s'ajoute dans le footer.</p>
<fieldset>
<legend>footer.php: &lt;footer&gt; avec <code>wp_footer()</code></legend>
<div class="site-info">
<div class="site-info">
<!-- It’s there for you to use if you want to add credit text/links via your child theme -->
<?php do_action( 'didactique_credits' ); ?>
<a href="http://wordpress.org/" title="<?php esc_attr_e( 'Une plate-forme sémantique de publication personnelle', 'didactique' ); ?>" rel="generator"><?php printf( __( 'Honteusement propulsé par %s', 'didactique' ), 'WordPress' ); ?></a>
<span class="sep"> | </span>
<?php printf( __( 'Thème : %1$s par %2$s.', 'didactique' ), 'Didactique', 'Mathieu Mangeot' ); ?>
</div><!-- .site-info -->
</fieldset>
<?php wp_footer(); ?>
</footer>
</body>
......
<?php
/* commentaire */
/*--------------------------------------------------------------
Title WordPress Implementation
--------------------------------------------------------------*/
function theme_support() {
add_theme_support( 'title-tag' );
}
//add_action( 'after_setup_theme', 'theme_support' );
......@@ -2,10 +2,22 @@
<html <?php language_attributes(); ?>>
<head>
<meta charset="<?php bloginfo( 'charset' ); ?>" />
<title><?php wp_title(); ?></title>
<title><?php bloginfo('name');?> - <?php bloginfo('description');?></title>
<link rel="profile" href="http://gmpg.org/xfn/11" />
<link rel="pingback" href="<?php bloginfo( 'pingback_url' ); ?>" />
<link rel="stylesheet" type="text/css" href="<?php echo get_template_directory_uri();?>/css/site.css"></style>
<?php if ( is_singular() && get_option( 'thread_comments' ) ) wp_enqueue_script( 'comment-reply' ); ?>
<?php wp_head(); ?>
</head>
<body>
<header>
<fieldset>
<legend>header.php: &lt;head&gt; avec <code>wp_head()</code> + &lt;header&gt;</legend>
<h1>Titre du site <code>bloginfo('name')</code> : <?php bloginfo( 'name' ); ?></h1>
<h2>Slogan <code>bloginfo('description')</code> : <?php bloginfo( 'description' ); ?></h2>
<nav id="menuprincipal">
<div id="legendemenuprincipal">Menu principal <code>wp_page_menu('show_home=1'):</code></div>
<?php wp_page_menu('show_home=1'); ?>
</nav>
</fieldset>
</header>
<?php
// pris du thème ltt, à comprendre
// à utiliser avec front-page.php
//wp_redirect(site_url());
//exit;
?>
<?php get_header(); ?>
<p>Le header est terminé. Il n'y a que le contenu du head</p>
<section id='content'>
<aside>
<fieldset id="fieldsetsidebar">
<legend>index.php: &lt;aside&gt; + <code>get_sidebar()</code></legend>
<?php get_sidebar(); ?>
</aside>
<fieldset id="fieldsetcontent">
<legend>index.php: contenu avec the_loop <code>while ( have_posts() )</code></legend>
<?php if ( have_posts() ) : while ( have_posts() ) : the_post(); ?>
<div class="post">
<fieldset class="post">
<legend>Article <code>the_post()</code> :</legend>
<!-- Display the Title as a link to the Post's permalink. -->
<h2><a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
<h2>Titre de l'article <code>the_title()</code>: <a href="<?php the_permalink(); ?>" rel="bookmark" title="Permanent Link to <?php the_title_attribute(); ?>"><?php the_title(); ?></a></h2>
<!-- Display the date (November 16th, 2009 format) and a link to other posts by this posts author. -->
<small><?php the_time('F jS, Y'); ?> by <?php the_author_posts_link(); ?></small>
<small>Date et auteur <code>the_time('j F Y à G:i')</code> : <?php the_time('j F Y à G:i'); ?> par <code>the_author_posts_link()</code> : <?php the_author_posts_link(); ?></small>
<!-- Display the Post's content in a div box. -->
<div class="entry">
<fieldset>
<legend>Contenu de l'article <code>the_content()</code></legend>
<?php the_content(); ?>
</fieldset>
</div>
<p style="font-size:.9em;">
<!-- Display the number of comments. -->
Cet article a <code>comments_number(...)</code><a href="<?php the_permalink(); ?>#comments"><?php comments_number( 'aucun commentaire', 'un commentaire', '% commentaires' ); ?></a>.
<!-- Display a comma separated list of the Post's Categories. -->
<span class="postmetadata">Posté dans <code>the_category(', ')</code><?php the_category( ', ' ); ?></span>
</p>
<p class="postmetadata"><?php _e( 'Posted in' ); ?> <?php the_category( ', ' ); ?></p>
</div> <!-- closes the first div box -->
<fieldset style="margin-left:10%;">
<legend>Commentaires : <code>comments_template()</code></legend>
<?php
if ( comments_open() || get_comments_number() ) :
comments_template();
endif;?>
</fieldset>
</fieldset> <!-- closes the first div box -->
<?php endwhile; else : ?>
<p><?php _e( 'Sorry, no posts matched your criteria.' ); ?></p>
<?php endif; ?>
</fieldset>
</section>
<p>voici la sidebar:</p>
<?php get_sidebar(); ?>
<p>Fin de la sidebar</p>
<?php get_footer(); ?>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment