This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Add to functions.php | |
// REMOVE ACCENTS on uploaded WP files | |
add_filter('sanitize_file_name', 'remove_accents' ); | |
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var socket = io.connect('http://localhost:8080'); // changement du port | |
// quand tu reçois news | |
socket.on('news', function (data) { | |
console.log(data); // afficher les data reçues par le server | |
socket.emit('my other event', { my: 'data' }); // émet un nouvel évent | |
}); | |
socket.on('world',function(data){ | |
console.log(data); | |
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1° Copier le contenu de la partie index.html et le coller après la balise de fermeture de l'article de l'exercice 20 | |
Attention : supprimer la fermeture de section et le reste du document | |
2° remplacer le fichier mi-ca.css par le nouveau (faire du copier-coller pour conserver les accents) | |
3° remplacer le fichier main.js par le nouveau (faire du copier-coller pour conserver les accents) | |
4° remplacer le fichier plugin.min.js par le nouveau (utiliser le bouton row) | |
5° sur le serveur copier-coller le fichier "screenshot_ex.zip" dans votre dossier "img" puis SUPPRIMER le dossier "ex" existant, | |
déziper le "screenshot_ex.zip" et finalement supprimer le "screenshot_ex.zip" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Instructions pour la mise à jour | |
des exercices css v3.0 | |
-- 13 oct. 2014 -- | |
********************************* | |
1° Fichier: css/mi-ca.css | |
Ligne 8 changer la valeur du z-index de 1 à 10 | |
z-index:1; -> z-index:10; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Instructions pour la mise à jour | |
des exercices css v3.0 | |
-- 12 jan. 2015 -- | |
********************************* | |
1° Fichier index.html | |
line ~36 | |
Ajouter un nouvel élément de menu jQuery |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$args = array( | |
'post_type'=>'events', | |
'posts_per_page'=>1 | |
); | |
$the_query = new WP_Query( $args ); | |
// The Loop | |
if ( $the_query->have_posts() ) : ?> | |
<ul> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<main> | |
<article> | |
<header> | |
<h1>Titre art 1</h1> | |
<span>▼</span> | |
</header> | |
<div class="content"> | |
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Minime vero, inquit ille, consentit. At certe gravius. Duo Reges: constructio interrete. Negat enim summo bono afferre incrementum diem. Haec et tu ita posuisti, et verba vestra sunt. Qui ita affectus, beatum esse numquam probabis; Cupit enim dícere nihil posse ad beatam vitam deesse sapienti. Cum autem in quo sapienter dicimus, id a primo rectissime dicitur. Laboro autem non sine causa; </p> | |
<p>Sed quanta sit alias, nunc tantum possitne esse tanta. Tertium autem omnibus aut maximis rebus iis, quae secundum naturam sint, fruentem vivere. Omnes enim iucundum motum, quo sensus hilaretur. Ut in voluptate sit, qui epuletur, in dolore, qui torqueatur. Quamquam id quidem, infinitum est in hac urbe; Cur ipse Pythagoras et Aegyptum lustravit et Persarum magos adiit? </p> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Slugify a string | |
* @param {String} text | |
* @return {String} | |
*/ | |
export function slugify(text) { | |
return text.toString().toLowerCase() | |
.replace(/([å,ä])/g, 'a') // Replace å and ä with aa | |
.replace(/(ö)/g, 'o') // Replace ö with o | |
.replace(/\s+/g, '-') // Replace spaces with - |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* check media queries | |
* @return {string} tablet | desktop | phone | |
* @author CAILLET Michael <https://mi-ca.ch> | |
*/ | |
function checkMQ(){ | |
if(window.matchMedia('(min-width: 40em) and (max-width: 64em)').matches){ | |
return "tablet"; | |
} | |
else if(window.matchMedia('(min-width: 64em)').matches){ |
OlderNewer