par
zyrius » 20 juil. 2009, 14:22
bonjour
je viens de récupere un calendrier tout bete tt simple et je souhaiterais le mettre en forme grace au css, j ai suivi un tuto sur developpez mais cela ne fonctionne pas .voici un morceau du code.
j ai bien sur crée le fichier calendrier.css
<html>
<head>
<style type="text/css" href="calendrier.css">
</style>
</head>
<body>
<?php
//Creating general vars
$year = date("Y");
if(!isset($_GET['month'])) $monthnb = date("n");
else {
$monthnb = $_GET['month'];
$year = $_GET['year'];
if($monthnb <= 0) {
$monthnb = 12;
$year = $year - 1;
}
elseif($monthnb > 12) {
$monthnb = 1;
$year = $year + 1;
}
}
$day = date("w");
$nbdays = date("t", mktime(0,0,0,$monthnb,1,$year));
$firstday = date("w",mktime(0,0,0,$monthnb,1,$year));
calendrier.css
<style>
/* Feuille de style pour Calendrier */
body { background-color: #CCCCCC; }
<style>
bonjour
je viens de récupere un calendrier tout bete tt simple et je souhaiterais le mettre en forme grace au css, j ai suivi un tuto sur developpez mais cela ne fonctionne pas .voici un morceau du code.
j ai bien sur crée le fichier calendrier.css :lol:
[php]<html>
<head>
<style type="text/css" href="calendrier.css">
</style>
</head>
<body>
<?php
//Creating general vars
$year = date("Y");
if(!isset($_GET['month'])) $monthnb = date("n");
else {
$monthnb = $_GET['month'];
$year = $_GET['year'];
if($monthnb <= 0) {
$monthnb = 12;
$year = $year - 1;
}
elseif($monthnb > 12) {
$monthnb = 1;
$year = $year + 1;
}
}
$day = date("w");
$nbdays = date("t", mktime(0,0,0,$monthnb,1,$year));
$firstday = date("w",mktime(0,0,0,$monthnb,1,$year));
[/php]
calendrier.css
[php]
<style>
/* Feuille de style pour Calendrier */
body { background-color: #CCCCCC; }
<style>
[/php]