PodManager for BlogCFC
Comments (0) || ColdFusion 4249 ViewsBlogCFC has been going through a lot of changes recently and keeps getting better. One of the smaller things that we have locally talked about was a Pod Manager to control the display and order of pods. Then Ray mentions that he has been toying with the same thing. I'm sure his solution will trump mine but I wanted to go ahead and put this out as a learning experience for me. You can download the zip file from below. In getting started, I wanted to accomplish a couple of things.
- wanted to store the data in a XML file.
- Least amount of changes to BlogCFC core files as possible
I was able to get the core changes down to three files: application.cfm, layout.cfm and adminlayout.cfm. I included the changed adminlayout.cfm but left the other BlogCFC files alone.
Application.cfm
<cfset application.pod = createObject("component", "org.camden.blog.pods")>
Adminlayout.cfm
Layout.cfm
Download the zip, put the new files out, make the changes listed above then go into BlogCFC's admin interface. Prior to using it, you will need to refresh your blogs cache by clicking on the link Refresh Blog Cache or adding reinit=1 to your url. You can now click on Pod Manager to begin the setup.
Open the Pod Manager, select the Pods you want displayed and enter a numeric value for the sort order. In the screenshot, pages.cfm is 1,general.cfm is 2 and so on. After entering the sort order, click on Update Pods.
Refresh your blog and you should see the pods in the order you entered.
You can add & delete pods, and see a preview of the pods output from the manager. On adding new pods, I put a sample pod in, you can either use that or delete it and enter your own.
For any experts out there, I welcome any comments. I learn something new everyday.
Edit: Updated typo in the cfinclude line for the layout.cfm corrected the readme.txt
DOWNLOAD was removed. See http://podmanagerblogcfc.riaforge.org/ for the latest code.







Recent Comments
USC-28
Gary Funk said: Ahhh, the life of a USACES Comm Jockey. Oh how I miss those days. [More]
MacBook Pro Color Profile
randy troppmann said: Quite an improvement on my 5 month old MBP. Now I just need a better one for my 23" cinema dis... [More]
MacBook Pro Color Profile
Tom Cornilliac said: Not bad, thanks for sharing! [More]
MacBook Pro Color Profile
rob said: I agree - that makes the display look much "warmer". It looks horrible on a Cinema display... [More]
MacBook Pro Color Profile
Mike Harman said: Thanks, made a big difference! [More]