root/trunk/website/blog/admin/podform.cfm @ 29

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

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

Line 
1<cfsetting enablecfoutputonly = "true">
2<cfprocessingdirective pageencoding="utf-8">
3<!---
4        Name         : Pods Display
5        Author       : Scott Pinkston
6        Created      : October 14, 2006
7        Last Updated :
8        History      :
9--->
10
11<cfparam name="url.pod" default="">
12
13<cfset dir = expandPath("../includes/pods")>
14<cfset podContent = "">
15
16<cfif len(url.pod) and fileExists(dir & "/" & url.pod)>
17        <cffile action="read" file="#dir#/#url.pod#" variable="podContent">
18</cfif>
19
20<cfset url.pod = rereplace(url.pod,".cfm","","ALL")>
21
22 
23<!--- ********************** --->
24<cfset podTemplateStart =
25"<cfsetting enablecfoutputonly='true'>
26<cfprocessingdirective pageencoding='utf-8'>
27<!---
28   Name : __PAGENAME__
29   Author : PodGenerator (based on archives.cfm by Raymond Camden)
30--->
31
32<cfmodule template='../../tags/podlayout.cfm' title='__TITLE__'>
33<!---
34Your Pod text goes here -
35Remember it has to be in cfoutput
36tags or it will not be displayed
37--->
38<cfoutput>
39">
40
41<cfset podTemplateEnd = "
42</cfoutput>             
43</cfmodule>
44<cfsetting enablecfoutputonly='false'/>">
45<!--- ********************** --->
46
47<cfmodule template="../tags/adminlayout.cfm" title="Pods">
48       
49        <cfoutput>
50        <br /> 
51        <fieldset>
52                <legend>Create/Edit Pod</legend>
53                        <cfform action="pod.cfm" method="post">
54                                Pod Name: <cfinput value="#url.pod#" validateat="onBlur" validate="regular_expression" pattern="[A-Za-z]" message="Please enter only Alpha characters for the Pod Title" type="text" name="NewPod" size="25"><br>
55
56<cfif len(podContent)>
57        <textarea rows="30" cols="75" name="NewPodText">#podContent#</textarea>
58        <br><input type="submit" value="Save Changes">
59<cfelse>
60        <textarea rows="30" cols="75" name="NewPodText">#podTemplateStart#
61        #podTemplateEnd#
62        </textarea>
63        <br><input type="submit" value="Create New Pod">       
64</cfif>         
65                        </cfform>
66                Note: The file will be created in the includes/pods folder.<br />
67        </fieldset>
68        </cfoutput>
69</cfmodule>
70
71
72<cfsetting enablecfoutputonly="false">
73
74<!--- eof --->
Note: See TracBrowser for help on using the browser.