Skip to content

Commit

Permalink
adding files and main README-JP.md
Browse files Browse the repository at this point in the history
  • Loading branch information
patriciogonzalezvivo committed Aug 5, 2015
1 parent 7e1cc55 commit 9b83d28
Show file tree
Hide file tree
Showing 23 changed files with 390 additions and 177 deletions.
26 changes: 13 additions & 13 deletions 00/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@

$path = "..";
$subtitle = ": about this book";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header">
<p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a> </p>
<p>Translations: <a href=".">English</a> - <a href="?lan=jp">Japanese</a></p>
</div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

$README = "README";
if(!empty($_GET['lan']))
$README .= '-'.$_GET['lan'];
include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents($README.'.md'));

Expand Down
26 changes: 13 additions & 13 deletions 01/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@

$path = "..";
$subtitle = ": What is a shader?";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header">
<p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a> </p>
<p>Translations: <a href=".">English</a> - <a href="?lan=jp">Japanese</a></p>
</div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

$README = "README";
if(!empty($_GET['lan']))
$README .= '-'.$_GET['lan'];
include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents($README.'.md'));

Expand Down
26 changes: 13 additions & 13 deletions 02/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@

$path = "..";
$subtitle = ": Hello world!";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header">
<p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a> </p>
<p>Translations: <a href=".">English</a> - <a href="?lan=jp">Japanese</a></p>
</div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

$README = "README";
if(!empty($_GET['lan']))
$README .= '-'.$_GET['lan'];
include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents($README.'.md'));

Expand Down
26 changes: 13 additions & 13 deletions 03/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@

$path = "..";
$subtitle = ": uniforms";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header">
<p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a> </p>
<p>Translations: <a href=".">English</a> - <a href="?lan=jp">Japanese</a></p>
</div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

$README = "README";
if(!empty($_GET['lan']))
$README .= '-'.$_GET['lan'];
include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents($README.'.md'));

Expand Down
26 changes: 13 additions & 13 deletions 04/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@

$path = "..";
$subtitle = ": Running your shader";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header">
<p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a> </p>
<p>Translations: <a href=".">English</a> - <a href="?lan=jp">Japanese</a></p>
</div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

$README = "README";
if(!empty($_GET['lan']))
$README .= '-'.$_GET['lan'];
include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents($README.'.md'));

Expand Down
26 changes: 16 additions & 10 deletions 05/index.php
Original file line number Diff line number Diff line change
@@ -1,19 +1,25 @@
<?php

$path = "..";
$subtitle = ": shaping functions";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$subtitle = ": Shaping functions";
$README = "README";
$language = "";

echo '
<div class="header"><p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a></p></div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents ('README.md'));
include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents($README.'.md'));

echo '
</div>
<hr>
Expand Down
22 changes: 14 additions & 8 deletions 06/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,23 @@

$path = "..";
$subtitle = ": color";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header"><p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a></p></div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents ('README.md'));
echo $Parsedown->text(file_get_contents($README.'.md'));

echo '
</div>
Expand Down
22 changes: 14 additions & 8 deletions 07/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,23 @@

$path = "..";
$subtitle = ": Shapes";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header"><p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a></p></div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents ('README.md'));
echo $Parsedown->text(file_get_contents($README.'.md'));

echo '
</div>
Expand Down
22 changes: 14 additions & 8 deletions 08/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,23 @@

$path = "..";
$subtitle = ": 2D Matrices";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header"><p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a></p></div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents ('README.md'));
echo $Parsedown->text(file_get_contents($README.'.md'));

echo '
</div>
Expand Down
22 changes: 14 additions & 8 deletions 09/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,23 @@

$path = "..";
$subtitle = ": Patterns";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header"><p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a></p></div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents ('README.md'));
echo $Parsedown->text(file_get_contents($README.'.md'));

echo '
</div>
Expand Down
22 changes: 14 additions & 8 deletions 10/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,23 @@

$path = "..";
$subtitle = ": Random";
include($path."/header.php");
include($path."/src/parsedown/Parsedown.php");
$README = "README";
$language = "";

echo '
<div class="header"><p><a href="http://patriciogonzalezvivo.com/2015/thebookofshaders/">The Book of Shaders</a> by <a href="http://patriciogonzalezvivo.com">Patricio Gonzalez Vivo</a></p></div>
<hr>
<div id="content">
';
if ( !empty($_GET['lan']) ) {
if (file_exists($README.'-'.$_GET['lan'].'.md')) {
$language = '-'.$_GET['lan'];
$README .= $language;
}
}

include($path."/header.php");
include($path."/chap-header.php");
echo '<div id="content">';

include($path."/src/parsedown/Parsedown.php");
$Parsedown = new Parsedown();
echo $Parsedown->text(file_get_contents ('README.md'));
echo $Parsedown->text(file_get_contents($README.'.md'));

echo '
</div>
Expand Down
Loading

0 comments on commit 9b83d28

Please sign in to comment.