Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Websites
/
SlimSpots Wiki
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Issues
0
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
Commit 85262474
authored
2015-01-28 16:28:10 +0000
by
Aleksandar Hristov
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
Concept changed
1 parent
0223ee00
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
37 deletions
html/test.php
html/test.php
deleted
100644 → 0
View file @
0223ee0
<?php
require
"libs/Smarty.class.php"
;
$db
=
new
SQLite3
(
'wiki.db'
);
$smarty
=
new
Smarty
;
$current_page
=
$_SERVER
[
'SCRIPT_NAME'
];
$current_page
=
str_replace
(
".php"
,
""
,
$current_page
);
function
sidebar_navigation
()
{
global
$db
,
$smarty
;
$page
=
$db
->
query
(
"SELECT * FROM page"
);
$num_pages
=
count
(
$page
);
$menu_pages
=
array
();
$i
=
0
;
while
(
$row
=
$page
->
fetchArray
())
{
$menu_pages
[
$i
]
=
$row
[
1
];
$i
++
;
}
return
$menu_pages
;
}
$smarty
->
assign
(
"menu_pages"
,
sidebar_navigation
());
$smarty
->
assign
(
"page_title"
,
"Slimspots Wiki"
);
$smarty
->
assign
(
"current_page"
,
$current_page
);
//$smarty->assign("menu_sections", $menu_sections);
$smarty
->
display
(
'index.tpl'
);
?>
\ No newline at end of file
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment