1 |
<? |
<? |
2 |
|
|
3 |
|
set_magic_quotes_runtime(0); |
4 |
|
|
5 |
include("inc/class.FastTemplate.pinc"); |
include("inc/class.FastTemplate.pinc"); |
6 |
include("inc/conn.inc"); |
include("inc/conn.inc"); |
7 |
include("inc/fixsql.inc"); |
include("inc/fixsql.inc"); |
17 |
startnew => "startnew.html", |
startnew => "startnew.html", |
18 |
ttable => "topics-table.html", |
ttable => "topics-table.html", |
19 |
theader => "topics-header.html", |
theader => "topics-header.html", |
20 |
|
tlheader => "topics-list-header.html", |
21 |
trow => "topics-row.html", |
trow => "topics-row.html", |
22 |
|
tlrow => "topics-list-row.html", |
23 |
reply => "reply.html", |
reply => "reply.html", |
24 |
checkboxes => "checkboxes.html" |
checkboxes => "checkboxes.html" |
25 |
) |
) |
41 |
if ($row[solution] == "t") { |
if ($row[solution] == "t") { |
42 |
$solution_room=1; |
$solution_room=1; |
43 |
$sql_poruke_where.="and poruke.solution is true"; |
$sql_poruke_where.="and poruke.solution is true"; |
44 |
|
$tpl->assign(array( ROOM => "You are in solution room" )); |
45 |
} |
} |
46 |
$tpl->assign(array( |
$tpl->assign(array( |
47 |
FULL_NAME => $row[full_name], |
FULL_NAME => $row[full_name], |
151 |
|
|
152 |
//----- end of inserts/updates... |
//----- end of inserts/updates... |
153 |
|
|
154 |
if (($what=="reply" || $what="show") && isset($t)) { |
if (($what=="reply" || $what=="show") && isset($t)) { |
155 |
$sql_where=" and topics.id=$t"; |
$sql_where=" and topics.id=$t"; |
156 |
} |
} |
157 |
|
|
180 |
COMMENTS => "<a href=\"$PHP_SELF?what=show&t=$row[topic_id]\">comments>></a>", |
COMMENTS => "<a href=\"$PHP_SELF?what=show&t=$row[topic_id]\">comments>></a>", |
181 |
PHP_SELF => $PHP_SELF |
PHP_SELF => $PHP_SELF |
182 |
)); |
)); |
|
$tpl->parse(ROWS,".theader"); |
|
183 |
|
|
184 |
if (isset($t) && $t==$row[topic_id]) { |
if (isset($t) && $t==$row[topic_id]) { |
185 |
|
$tpl->parse(ROWS,".theader"); |
186 |
$sth2 = $dbh->prepare(" |
$sth2 = $dbh->prepare(" |
187 |
select poruke.id as id,sadrzaj as topic,level,thread_id,reply_id,full_name,poruke.datum as datum,poruke.analitical as poruka_analitical |
select poruke.id as id,sadrzaj as topic,level,thread_id,reply_id,full_name,poruke.datum as datum,poruke.analitical as poruka_analitical |
188 |
from poruke,osobe |
from poruke,osobe |
233 |
DATE => $row2[datum], |
DATE => $row2[datum], |
234 |
SADRZAJ => $topic |
SADRZAJ => $topic |
235 |
)); |
)); |
|
# $tpl->parse(ROWS,".theader"); |
|
236 |
$tpl->parse(ROWS,".trow"); |
$tpl->parse(ROWS,".trow"); |
237 |
} |
} |
238 |
} else { |
} else { |
239 |
// non-unroll topics |
// non-unroll topics (list) |
240 |
$tpl->assign( array( |
$tpl->assign( array( |
241 |
SADRZAJ => $row[sadrzaj], |
SADRZAJ => $row[sadrzaj], |
242 |
COMMENTS => "<a href=\"$PHP_SELF?what=show&t=$row[topic_id]\">comments>></a>" |
COMMENTS => "<a href=\"$PHP_SELF?what=show&t=$row[topic_id]\">comments>></a>" |
243 |
)); |
)); |
244 |
# $tpl->parse(ROWS,".theader"); |
$tpl->parse(ROWS,".tlheader"); |
245 |
$tpl->parse(ROWS,".trow"); |
$tpl->parse(ROWS,".tlrow"); |
246 |
} |
} |
247 |
|
|
248 |
} |
} |