Staple Sharepoint 2007 feature to custom site templates - asp.net

I have a branding feature that works great and staples to everything but custom site templates (as noted at the bottom comment on this MSDN article it's not possible to staple to custom templates out of the box).
stapling.xml
staple all site defitions to BrandingChildSiteInitializer
<FeatureSiteTemplateAssociation
Id="1204A425-D105-46c5-BB2C-473A2F27B563"
TemplateName="GLOBAL" />
staple blank site template to BrandingChildSiteInitializer
<FeatureSiteTemplateAssociation
Id="1204A425-D105-46c5-BB2C-473A2F27B563"
TemplateName="STS#0" />
In summary, this does not get stapled to custom sites that one creates and adds to site template gallery. So, when a user creates a new site based off a custom template the branding doesn't get applied. How would I get this feature stapled to every site?
I was thinking of something on my feature or other features in my solution that can add custom templates to the global list? Im not sure where to start regardless.
My .wsp is purely a bunch of custom C#, ASP, HTTPHandler etc that attaches a new masterpage and changes the theme. The feature in question simply tells the newly created site to use the properties of the parent (custom masterpage, theme etc)

If you've turned on publishing at the top level; you can force all child sites to use the parent masterpage.

Have look at this post, it mentions stapling to all sites via the GLOBAL name. There might be something different that this guy has done to create the stapling declarations working compared to your files?

Related

How to have single-slug behave like a normal page in WordPress?

I'm making a website in WordPress, and I'm using a plugin ACF PRO. I'm doing the entire site with flexible content, so the WordPress site is like a page builder.
Everything is fine, however, I came to a point where I need to have same functionality for single-[custom-post-type], so I can "Add row", header, footer etc... on it, but I can't figure out on how to do it.
I know that it's possible, because e.g if you look at this site here: https://rolleragency.co.uk/our-projects/
You can see that it works. I know they are using flexible content because I worked on that site and I did there what I wanted. I can't remember how to do that.
I think I had to use a Tempate Page? Or? I can't remember.
THe site is built entirely on flexible content, so everything there is modular and it's like a drag and drop, but how do I do that on single-slug?
You have to create a page template, yes.
So something like page-projects.php then in WordPress admin you would have a page called Projects.
The template you created should be automatically applied to this page. If it doesn't for some reason you can choose which template WP should use on the right side when editing a page.
Now, you can add whatever code you need to the page-projects.php. And also any fields you may need for that page you can set up in ACF by telling ACF to apply those fields to pages that use projects template.
This is how I would and did do it on several occasions :)

Easiest way to implement a temporary page to a Drupal 7 site

I'm a WordPress developer who's been tasked to create a temporary one-pager to a Drupal site. The client would like to have a simple front page with a logo and 4 external links until their new site is ready. Normally I'd just make a simple index.html page with some CSS and call it a day. But in this case they need some of the sub-pages from the Drupal site to continue to work.
Had it been a WordPress site, I would have just created a new template file and a new page inside WordPress, and made that the front page. But as I have zero experience with Drupal, I don't know if you can do the same thing here.
What is the easiest (quickest) way to make a simple splash-page as the front page, while having the rest of the drupal site continue to work? The splash-page should ignore all CSS and JS from the original theme — preferably have a completely independant section fromt the rest of the site.
In Drupal 7 you have few "levels" of templates. First you have "most outer" template html.tpl.php It contains html head and it is usually common for all pages.
Then inside that html.tpl.php you'll include page.tpl.php. That one should again contain some common page elements, as header and footer, but again, if your design requires that, you can have more than one page template.
Page template will include node template. In drupal you have 2 basic content (node) types but you can create many more of them. Basically for every different page layout you can create new content type (but there also are lot of different ways to achieve the same thing).
Basically you should create new content type called i.e. "splash" (machine name!). Add fields to it if they need to be back-end editable.
Then you should create new template file for your content type. Name matters, so you should call it node--splash.tpl.php . You can find and copy to your theme existing node.tpl.php and change it to your needs.
Keep in mind that when ever you add/remove new template file you have to clear the cache so drupal would scan theme directory, notice and start using new templates.
And if you need also different page template for you page you'll have to put some code into you tamplate.php file:
https://www.digett.com/insights/overriding-page-templates-content-type-drupal-7
Drupal template engine design an specific file name for override front page.
You can create the file html--front.tpl.php, and this will be used only for the front page without touch any other page. You can page here your custom HTML and reference css/js.
If the page you need share common styles with the rest of the site, I would recommend to instead override page--front.tpl.php which is basically the content of the page without the tags
For more information here is a link https://www.drupal.org/docs/7/theming/howto/customize-the-front-page-template

Why is a theme needed if page builder is there in WordPress?

I am new into the arena of WordPress. I started learning about how to create website using WordPress. I am wondering if a page layout can be fully designed and customized by using a page builder, why i need to use a theme. Isn't theme is used to define how my contents are going to be shown in pages ?
A theme is actually a collection of files that control the way the site is displayed and to some degree how it behaves. While page builders typically allow you control of some aspects of the visual interface, you cannot have a Wordpress site without an active theme.

How to make a sitefinity master page without ASP.NET?

The company I am working for has a sitefinity. They want me to create custom pages from scratch for them. I have never used sitefinity, so upon research It appears that I want to create a template via .master. Then once built, I would add to my CMS and access it for use.
Is there a way to make these .master templates other than ASP.NET? ( which I have no experience with)
Essentially all am am wanting to do is create a custom page out of html,css, and jquery and then make a 'template' out of it.
You dont have to use a .master page to create a template in Sitefinity. It's nice to have that level of control but it's not necessary at all. Just go to Design > Page Templates in the Sitefinity backend section /Sitefinity
There are several built in templates you can edit from that page. You can use one of those templates, create a new template from scratch, or create a template based on any one of the templates you see there.
Once you pick a template, you can edit the Layout to add columns and global content or custom CSS.
Not really, if you want control over the markup then you'll have to use a .master page but the good news is that it really is just mostly html and css / js references. Sitefinity has a sample template here but you may want to look at their Visual Studio plugin called Thunder to register a template. It will add in a default master page as well as the default folder structure for the theme, video on that here.

Can Wordpress Duplicate An Entire Page Structure?

I have a wordpress site that i've been working on that has some pages (as in NOT posts) that a client changes content on in order to target particular keywords. these pages have been using podscms for content management.
The client now wants to be able to duplicate these pages any number of times and edit the text within them. So basically, he wants to be have a dozen or so versions of about 4 linked pages.
Does anyone know if it's possible to duplicate an entire multipage structure like this in WP?
Or any WP driven sites that implement segmentation similarly?
I think your best bet would be to use Page Templates. You define them in the theme and then for each Wordpress page you create, you can select which page template you would like to use for the page. This sounds like what you're trying to accomplish.

Resources