::Programmatically::
I am trying to understand how by using page types I can have a block appear on the page when a user selects the page type when adding a page.
Lets say would like to have an add block appear in the sidebar area automatically when the user selects a page type. I would like this add to still be positionable and I would like the page creator to still have the option of deleting the block.
I do not want to hard code the block into the page template just have it appear in one of the editable regions.
I have seen this in the Simpleblog block.
Also when I have created the page templates how do I install them?
Create your page type for example Sidebar (which is sidebar.php). Then go to your dashboard > pages & themes > Page Types > Sidebar > Defaults. There you can set the default blocks.
I need to know how to do it from code. I have made a package that includes template pages. I need to make the pages have a certain block on it when some one installs the package.
From looking at other peoples packages that I have downloaded it must be being set inside the database. I am still digging around as to where.
Code
Post Reply
Delete Post
You are allowed to delete your post for 5 minutes after it's posted.
I.e. adding some dummy text.
Hope that helps.