sharing a folder of content between plone lineage subsites - plone

I have collective.lineage installed. I have /site1 as a subsite and I have /sharedfolder as a folder with content in my root site. I want to make this folder visible within site1 (or site2 as well). I can create a link which in my subsite to sharedfolder, which is /site1/sharedfolder. This works however the top level navigation and the breadcrumbs reflect the root site not the subsite.
Is there another way to share this content or is this a bug?

This can be a solution:
Use adi.dropdownmenu (disclaimer: I am the author) for the mainmenu on top, assign two dropdownmenus ('Navigation extended') on the sharefolder, one mirroring the folder-structure of site1 and one for site2.
Assign users of site1 to group1 and users of site2 to group2 and apply two stylesheets that by condition are only delivered to members of group1, respectively group2. Stylesheet1 should hide menu2 and vice versa.
EDIT: Instead for using a groupmembership as condition for the stylesheets you can also distinct where the user came from, f.e. like this:
python: context.REQUEST.get('HTTP_REFERER').contains('idOfSite1')

Related

Create Folder Structure to Organize Content in Umbraco

I have many pages in the content section of Umbraco but some of the pages I would like to organize for departmental reference not necessarily for hierarchical site reference. For example, my pages might be A, B, C, D ... Z on the website but on the backend we have various teams that need their content grouped together. i.e. Team 1 folder has A-G in it. Team 2 folder has H-Q. Team 3 has R-Z in it. How can this be achieved so instead of seeing all the content on the root of the content page I only see these 3 team folders?
You have to be carefull in achieving this. When you create new nodes under your Home root node, eg new pages or folders, they are referenced with an url.
So If you have a page called A, this will be accessed using the url http://www.example.com/a. When you create folders to organize pages and you place page A under HQ, then your page will now be accessed by http://www.example.com/hq/a.
After that you can use url rewriting rules to avaid these folders indications in your url but that will be messed up if you have many pages.
I will suggest if you don't want to see these folder indications in your url, to just add all the nodes under your Home node and using Permission to allow/disallow departments to the nodes.
If you don't care about the folder indications in your url, let me know then I will edit this answer with the solution to achieve this.
EDIT
How to add folder structure in your content nodes.
Step 1
Create a new Document Type called Content Folder.
Go to Settings > Document Types > click on the 3 dots > Create.
Give it the name Content Folder.
As icon select the folder icon
Add a new property Redirect with alias umbracoRedirect with type Content Picker
Save changes
The builtin property umbracoRedirect is used to redirect one node to
another using its id. So for each folder set this property to the first child page.
Step 2
Allow your child node types in this folder.
Go to the structure tab of your Content Folder property
Check the child types that you want to allow under this folder
Save changes
Step 3
Allow this folder under your root Home node.
Go to the structure tab of your Home root property
Check the ContentFoldertype to allow as a child
Save changes
Step 4
Add you folder structure and add pages.
Go to your content
Add a new folder under your root node of type Content Folder
Give it the name HQ
Add a new page called A that's allowed under your folder
In your HQ set the Redirect property to your first A page
Do this for all your folders and pages
Save changes and publish
And thats it!
Another way of doing this is with a custom URL Provider and Content Finder. This is where you create a new provider for working out the URL of the pages on your site, overriding the default folder structure.
You can add your own logic out strip out folders from the URLS, so /folder/a/content could become /folder/content. Obviously you'd need to be careful that the other folders don't contain items with the same names, or you may get the wrong content returned.
The advantage of a URL Provider is that whenever you call the Umbraco methods to get the URL of a content item, you'll ALWAYS get the custom URL.
The content finder is a way for the site to match the modified URLs back to the original content. You'll need both for it to work.
Here is a link to an in depth article about using these two in conjunction in an Umbraco site.

.htaccess Wordpress Category Redirects Multiple Domains

I'm running a Wordpress Site with two domains, which share some contents, especially a shop, but have some separate contents which should be reachable with the same Sub-URLs. Right now I have:
domain1.com/press/
domain2.com/press2/
because I can't create two categories with the same name/permalink. I'd like to have
domain2.com/press/
showing the contents of the category press2
Is there a way to do this in .htaccess?

Drupal 6 Views: selection rules and affiliate domains

I'm having a problem with a View not showing up on an affiliate domain.
There are two new domains which are both to serve up the same content as another existing domain. All content to be served resides in the Drupal database.
We have two main sites w/content, a US version and a European version. The new domains are to serve up the European site.
I added the two new domain records via the domain access module and then went through and added those two new domains to the "Publish to" for all affiliate content that was currently on the European site.
I went through Pages and modified the selection rules to include the new domains.
The particular page has a pane containing a view. That page is at the url 'xxx/press'.
On the Euro site, everything works fine. On the new domains, all content shows and menus work except on the xx/press page, the view doesn't show. The page is coming up and the header node shows so it's just the specific view.
Since that view is on a Page content-type and that Page has selection rules which specify the new domains as a means to show, I'm not sure why it's not showing up.
Is there anywhere else besides the selection-rules of the actual Page that the view is being called on that could limit when/where that View shows?
I found the answer. Too much control!! For the record, in the Views there was one language setting under Filters and the language setting of the new domains didn't match that one.
Amazing that exclusion of content occurs in so many areas and ways! It's like visiting Photoshop all over again and looking at ways to make drop shadows.

Localization For Two Different Regions/Domains with the Same Language

I have a Wordpress site which is based in US (ex. www.example.com). We've been tasked to create a UK/GB version of the site which has it's own domain (ex. www.example.co.uk), but shares the same common pages/posts/backend. About 75% of the pages are the same on both versions but there will be a few sections (like About and Contact) where they are different to account for regional differences.
Example
US site (www.example.com) has 4 Pages:
Home
About
Services
Contact
UK Site (www.example.co.uk) also has 3 pages (2 different, 1 the same)
Home (The same as US, but the URL should be www.example.co.uk)
About (Different content, the URL should be www.example.co.uk/about)
Services (The same as US, but URL should be www.example.co.uk/services)
Contact (Different content, the URL should be www.example.co.uk/contact)
How do I go about setting up the UK/GB version of the site which use the same backend and most of the same content from the base site, but has a few page differences and different domain?
I'd use WPML plugin, it allows tranlations of posts, pages, categories, menus, and plugins that have language files. It will let your end use login from the same admin area, and then add translations to the existing content.
The tricky bit will be setting it up to work on domain detection, normally it works on a subdomain, or add's a variable to the end of the URL, like ?lang=uk
But that said it should be possible though with a bit of tinkering to setup something based on the URL. And the documentation is pretty comprehensive. Good luck!
It's also possible to make it differently. For our shops we pretend there's a new domain, but in fact there isn't. This also works for SEO because we do make sure the language tags and such are correct. We replace only a few parts such as a few javascripts and conversion pixels and then we are done. See for example on Keepershandschoenen-shop.be. This site is in fact a clone so we don't need wpml. We don't even need a wordpress, magento or whatever CMS installation...
So then you have the same backend, with .com acting as .co.uk also.

Elegantly adding basic pages as sub-pages in Drupal

I have a main page (let's call it "GROUP") accessible from a site-wide navigation bar. I've created other sub-pages ("SUB1" through "SUBn") and set their Parent item to "GROUP" in the Edit Basic page panel, but am at a loss as to how I can get each such SUBn to show up on the GROUP page.
I could simply create a <ul> of permalinks to the SUBn's, but that seems a bit inelegant and inflexible. Is there a native Drupal way of doing this?
Add GROUP to a menu (usually Primary Links for a small site), then add SUB1...SUBn as subpages on the menu, so you have an arrangement like:
Home
GROUP
SUB1
...
SUBn
Contact Us
Etc
Then use Menu Block from http://drupal.org/project/menu_block to create a block that shows entries at the first level and have the block show up on the pages where you want the subpage list to appear.
You can also use Bones module to automate the node/menu structure creation.

Resources