forked from 20xd6/simple_blog
Merge pull request 'Merge upstream master' (#5) from 20xd6/simple_blog:master into master
Reviewed-on: #5
This commit is contained in:
commit
8da50f2841
@ -5,6 +5,10 @@
|
||||
echo "<article><h1 id=\"page_title\">Posts by Tag</h1></article>";
|
||||
echo "<div id=\"search_inputs\"><input type=\"text\" id=\"tag_sort\" onkeyup=\"tag_search()\" placeholder=\"Search Tags...\" title=\"Type a tage to search\"><input id=\"search_toggle\" type=\"button\" value=\"Search Titles\" onclick=\"search_toggle()\"></div><!--End Div Search Inputs-->";
|
||||
function read_tags($tags_file){
|
||||
if (filesize($tags_vile) == 0){
|
||||
echo "<br/>\n<br/>";
|
||||
return;
|
||||
}
|
||||
$tags_csv = array_map('str_getcsv', file('tags.csv'));
|
||||
$tags_rows = sizeof($tags_csv);
|
||||
$tags_coloums = sizeof($tags_csv[0]);
|
||||
@ -49,6 +53,8 @@
|
||||
$empty_csv = fopen("tags.csv", "w") or die("Cannot write new tags.csv file.");
|
||||
fwrite($empty_csv, "");
|
||||
fclose($empty_csv);
|
||||
chmod('./tags.csv', 0666);
|
||||
read_tags('tags.csv');
|
||||
}
|
||||
include_once ($_SERVER['DOCUMENT_ROOT'].'/common/php/footer.php');
|
||||
?>
|
||||
|
Loading…
x
Reference in New Issue
Block a user