cformsII Support Forum
Current User: Guest *Frequently Asked Questions*
Search 
Search Forums:


 




Add cforms header to category page

Add a New Topic Reply to Post
Post

Shoemaker - Guest

2:59 am - August 14, 2008

Please replace the ??? with your data!


[desc]: I would like to get the cforms header on a category page. I added the code to the category template and it works great with header enabled for all pages, but I only want the header on the category page. 

insert_cform(); is not enough to get the header.

I'm optimizing the site for mobile devices and the javascript causes the pages to load much more slowly when the cforms js is loaded.

My example is "Ask the Expert"

http://animatedtrafficlaw.org/atlc/category/ask-the-expert/

I could probably move this to a post and work around it, but I just thought I'd ask...

Thanks,

Shoemaker

Oliver - Admin

8:07 am - August 14, 2008

posts 3562

currently, you can only limit the pages that'll contain the cforms header by providing a post or page ID under "global-settings".

If you want to apply logic that does it for categories, then you'd have to 

  • eliminate the cforms header altogether (apply a fictive post ID above)
  • and add the cforms header 'manually' to your theme header.php file
    • inside an appropriate IF clause (checking for the current cat)
Add a New Topic Reply to Post


Reply to Topic: Add cforms header to category page
PLEASE READ THE FAQs FIRST! THANK YOU.

NOTE: New Posts are subject to administrator approval before being displayed

Guest Name (Required):

Guest EMail (Required):

Guest URL (required)

Math Required!
What is the sum of: 10 + 1        (Required)

Topic Reply:


 
© Simple:Press Forum - Version 3.1.3 (Build 356)