Loading...
 
Skip to main content

History: Perspectives

Source of version: 30 (current)

Copy to clipboard
            ! Perspectives
New feature in ((Tiki4)). Please also see: ((Workspace))

Perspectives are useful to override a preference depending on a category of an object assigned to a perspective or simply by switching the perspective view. Think ((Theme Control)) but for any of 1000 preferences. In fact, it's all the ((Preferences)) that have been converted to ((dev:Dynamic preferences)) less the features which shouldn't be override-able per workspace.

!!# Configure perspectives
As a user with admin rights:
# Ensure that you have enabled the feature (Admin > Features)
# Create one perspective through __tiki-edit_perspective.php__. Provide any name.
# Search for preferences at the search box that you will see at the bottom. For instance, logo, theme, site title, home page, ... 
# Once found the preference that you were looking for, drag and drop it on the section above corresponding to the perspective that you have created.
# Repeat the previous step as many times as needed
# Click on Save

You can edit this perspective at any time on a later stage.

If using different subdomains, you can set them up linked to perspectives through:
__Admin > General > General configuration > Multi-domain > Multi-domain Configuration__:
* subdomain1, 1
* subdomain2, 2
* whateverdomain, IdX


!!# Use perspectives
You can use the Perspective module included in Tiki to change perspectives. See: ((module perspective))

Another trick is to use a link like
{CODE()}
tiki-index.php?page=testpage&perspectiveId=4
{CODE}
This is a one time use of that perspective, as after, the perspective reverts back.

!!# Admin perspectives
Starting in ((Tiki5)), you can manage via __tiki-edit_perspective.php__ (It is probably better to be in the default perspective when you are using __tiki-edit_perspective.php__)

!!# Test profile
To get going quickly, you can use the ((pr:Jailroot_Demonstration|Jailroot demonstration)). 

!!# Switch perspective 
Besides using the Perspective module, switching perspectives can be invoked by calling the -+tiki-switch_perspective.php+- script; e.g., -+tiki-switch_perspective.php?perspective=3+- will switch to the Perspective ID 3. Calling it alone without the perspective parameter will switch it back to the default site view.

Starting in ((Tiki7)), you can switch and stay on the same page by adding a -+&back+- to the switch perspective link.

!!# Plugin Perspective
* ((PluginPerspective)) permits to display content based on the reader's current perspective
!!# Mobile
((Mobile)) mode is essentially a mobile view perspective. If you want some modules to appear or not to appear in your mobile perspective, find out what your mobile perspective ID is (__tiki-edit_perspective.php__) and configure ((Modules)) accordingly. For example, If you wish to hide your login box in mobile version (mobile perspective) of your website, then simply go to Admin > Modules > login_box > Visibility > Perspective and enter value "0" and click Assign. By doing so your login box would be visible only to your original website view and invisible to your mobile perspective. This method can be used to simplify your mobile version (to load less modules).
*Note: "0" is default perspective for Tiki website while "1" or "2" etc. are for custom made perspectives.


!!# Simple explanation of perspectives, categories, category jail, etc.

{QUOTE(replyto="Torsten")}Generally speaking I promised to extend the perspectives related documentation since a while.
Still I am too busy with private stuff and not completely up to date with all the knowledge about perspectives, workspaces etc.

For that we do not forget things and that other users can anyway benefit from the help that was given to me, I just summarize my points where I think we are right now.

I do that a bit quick and dirty and will do a wrap up later on.

-- Torsten{QUOTE}

*Perspectives: 
+different points of view / layers of the website

*Categories:
+"responsible" for an important part of the roles&rights / permissions management

*Category jail:
+applies to a perspective and is kind of a preference
+limits search results and listings to content wich categories are applied to a category jail in a perspective
+categories IDs are typed in as numbers, seperated by semicolons
+search results just give the typed in perspectives 
+all content can be seen in all perspectives at this point, if appropriate rights 

__Tip:__

For a start, I just name the perspectives and categories the same way and set them up in the same order.
So the first some same named categories and perspectives have the same Ids, what eases work especially for a beginner with that.

At some point, thats not working out any more, but then it woulkd be still possible to remind the IDs to the names.
Names of perspectives and categories should apply either to the content or to the use case of the perspective or to both, if possible That eases life aswell.

*Perspectives plus categories -> workspaces:
+with perspectives and categories and some kind of smart structuring you can +create kind of "logical areas" in between the Tiki website.
+that means you can create spaces for workgroups, usergroups, subwebsites, etc.
+perspectives and categories are the features with that you can create workspaces, thus a workspace is more a logical area of the site and not a feature by itself.

*Multidomain
+using for example subdomains for workspaces, not only the categories can be jailed in respect of search results and listing, but further more the hole content of  different perspectives can be kept apart from each other independently.

*Switch perspective and stay at content
+recently a nice feature was added by Louis-Philippe:
+ at the perspectives module, there is a tick box now, where you can set either switching the perspective staying in the existing content, for ex. to just get different modules or to switch to the new perspective's home page.

*Go to a specific page in a specific perspective
+once you type the address https://foo.bar/PageName, you will be sent to PageName in the default perspective.
+using perspectives for navigation purposes you would need a number of subdomains, if you´d like users be able to copy and paste links to appropriate content/perspective combinations
+using additional ?perspectiveId=X in the context: http://foo.bar/PageName?perspectiveId=X you will be linked to PageName in Perspective X (thank LPH for mentioning that)
+a shortener like http://foo.bar/PageName?PId=X is requested.

*Next focus
+next to learn would be how to use Datachannels on the one hand – to setup automatically a set of a number of perspectives / categories / workspaces / project management tools with preset configuration
+and 
+organic group including leadership and demoting / promoting etc.

!!# FAQ-alike IRC conversation (helpful)

__Following an excerpt of an IRC conversation between mikebeary and nkoth, that the both guys allowed to use for the documentation:__

{QUOTE()}
__mikebeary__
 can someone please give me a __general idea of how workspaces are different than perspectives__? I'm having trouble finding a concise definition

__nkoth__ 
a workspace is a use case - there is technically __not really  a workspace feature__. Perspectives, combined with other features such as category jailroots are the features that enable -+create+- workspaces

__mikebeary__ 
so its a general term that just describes the work area a person is in based on what they've clicked on, who they are, etc.?  As opposed to a separate page or something?

__nkoth__ 
yes, workspaces is a rather general term describing a work area that could consist of a certain way it looks, certain permissions that exist in that state, and things presented, etc..

__mikebeary__ 
I want to create a wiki that begins with a site for all the colleges in a Missouri, from which you select your college, and then select your campus and then your club.  Would each of the different colleges just have their own workspace and then each campus would have their own workspace, etc? as opposed to making a totally separate page?  I'm guessing perspectives and jailroot features would bring them to their workspace based on them selecting their college or their campus?

__nkoth__ 
possibly , but you have to consider what is your reason for dividing up the wiki into multiple workspaces to begin with. 
Is it to prevent one person from seeing the other group's things? 
Is it to present a different screen layout? 
Is it to limit the amount of things a person is seeing while in a particular workspace so that he is not information overloaded but he can still switch between workspaces?

__mikebeary__
not to limit, but just so that each level can have their own calendar, their own forums, their own file galleries, etc.

__nkoth__ 
Sounds like you need to create some categories some perspectives and then configure each of the different perspectives to have different jailroot
each perspective would have also its own different home page so that when you switch to it -+(the perpective)+-, the user sees that home page

__mikebeary__ 
ok

__nkoth__ 
and while they are in that perspective they are exposed only to things in the category jail root of that perspective

__mikebeary__ 
really, it'd be the same .php file, but a different theme kind of thing?

__nkoth__ 
basically tiki has a lot of preferences right?

__mikebeary__ 
yes

__nkoth__ 
for each perspective you can have a different "setup" of preferences

__mikebeary__ 
ok

__nkoth__ 
so the possibilities are really up to your imagination the UI is at tiki-edit_perspective.php
you search for a pref, drag it into the perspective and configure it (basically overriding the global value) for that specific perspective

__mikebeary__ 
So say for instance I go to Missouri's website.  I'd be at the tiki-index.php.  Then I'd select my local college.  Are you saying at that point, I could be at my college's "site" but without ever leaving tiki-index.php?  I'd just be changing everything based on jailroot and persepective settings?

__nkoth__ 
right
the link to switch perspectives is tiki-switch_perspective.php?perspective=3 to switch to perspective 3
So that could very well be how you "goto" to the college's "site" which is perspective 3

__mikebeary__
And essentially what I’ve done by selecting my college's "site" is to select a different workspace

__nkoth__ 
technically speaking, you switch to a different perspective which yeah I suppose it sounds synonymous with workspaces, but the point is that a perspective could be used for something as simple as say, having a different page header __and not necessarily to the extent of creating workspaces__ which is what you are doing.

__mikebeary__ 
ok, that makes sense.

__mikebeary__ 
and what exactly is a jailroot

__nkoth__ 
it is a pref (and so you can configure it globally or for any specific perspective)
Basically it is a list of category IDs . If you set it to e..g 2, 3, and 5, then users can only see/search for/are exposed to items that are in categories 2, 3, and 5

__mikebeary__ 
so kind of like bulk-processing for perspectives? So you don't have to change a whole lot of perspectives to achieve what you can with categories?

__nkoth__
not exactly. 
well, the point is that categories are just that, you put things in them and you can set permission for them by setting a category jailroot for a perspective, say the college's perspective
you are basically saying that "while a user is in the college's 'site' he is exposed only to things inside those categories specified in that jailroot
it could just be one category, or it could be many categories - it's up to you

__nkoth__ 
if you could perhaps cut and paste this conversation into the wiki page where you expected this info to be in the first place on doc.tiki.org, it could be useful for now, until you have developed more fancy documentation liek that youtube video you talked about

__mikebeary__ 
Ok, I will definitely do that.
{QUOTE}

-= Related=-
* ((workspace))
* ((pr:Perspective Handler))

-=Alias=-
* (alias(Perspective))