projects
/
fms.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
version 0.1.15
[fms.git]
/
src
/
http
/
pages
/
execquerypage.cpp
diff --git
a/src/http/pages/execquerypage.cpp
b/src/http/pages/execquerypage.cpp
index
f86579a
..
50d3f0c
100644
(file)
--- a/
src/http/pages/execquerypage.cpp
+++ b/
src/http/pages/execquerypage.cpp
@@
-14,6
+14,20
@@
const std::string ExecQueryPage::GeneratePage(const std::string &method, const s
SQLite3DB::Recordset rs=m_db->Query((*queryvars.find("query")).second);
\r
\r
content+="<table>";
\r
SQLite3DB::Recordset rs=m_db->Query((*queryvars.find("query")).second);
\r
\r
content+="<table>";
\r
+ if(rs.Count()>0)
\r
+ {
\r
+ content+="<tr>";
\r
+ for(int i=0; i<rs.Cols(); i++)
\r
+ {
\r
+ content+="<th>";
\r
+ if(rs.GetColumnName(i))
\r
+ {
\r
+ content+=rs.GetColumnName(i);
\r
+ }
\r
+ content+="</th>";
\r
+ }
\r
+ content+="<tr>";
\r
+ }
\r
while(!rs.AtEnd())
\r
{
\r
content+="<tr>";
\r
while(!rs.AtEnd())
\r
{
\r
content+="<tr>";
\r