root/trunk/website/forums/admin/threads.cfm @ 28

Revision 5, 1.5 kB (checked in by DanWilson, 17 years ago)

Initial Commit Of ModelGlue? Website (upgrade to blogcfc 511)

Line 
1<cfsetting enablecfoutputonly=true>
2<!---
3        Name         : threads.cfm
4        Author       : Raymond Camden
5        Created      : June 09, 2004
6        Last Updated : February 26, 2007
7        History      : Removed mappings, changed cols (rkc 8/27/05)
8                                   Changed cols (rkc 9/9/05)
9                                   added filtering (rkc 2/26/07)                                   
10        Purpose          :
11--->
12
13<cfparam name="url.search" default="">
14<cfparam name="form.search" default="#url.search#">
15
16<cfmodule template="../tags/layout.cfm" templatename="admin" title="Thread Editor">
17
18<!--- handle deletions --->
19<cfif isDefined("form.mark") and len(form.mark)>
20        <cfloop index="id" list="#form.mark#">
21                <cfset application.galleon.thread.deleteThread(id)>
22        </cfloop>
23        <cfoutput>
24        <p>
25        <b>Thread(s) deleted.</b>
26        </p>
27        </cfoutput>
28</cfif>
29
30<!--- get threads --->
31<cfset threads = application.galleon.thread.getThreads(false)>
32
33<cfif len(trim(form.search))>
34        <cfquery name="threads" dbtype="query">
35        select  *
36        from    threads
37        where   lower(name) like <cfqueryparam cfsqltype="cf_sql_varchar" value="%#lcase(form.search)#%">
38        </cfquery>
39</cfif>
40
41<cfoutput>
42<p>
43<form action="#cgi.script_name#?#cgi.query_string#" method="post">
44<input type="text" name="search" value="#form.search#"> <input type="submit" value="Filter">
45</form>
46</p>
47</cfoutput>
48
49<cfmodule template="../tags/datatable.cfm"
50                  data="#threads#" list="name,lastpost,forum,conference,messagecount,sticky,active"
51                  editlink="threads_edit.cfm" linkcol="name" label="Thread" />
52
53
54</cfmodule>
55
56<cfsetting enablecfoutputonly=false>
Note: See TracBrowser for help on using the browser.