I'm creating an internal CMS blog site using Umbraco 7. We need to show the content based on member's language preferences. Every member has to login to the site to view the blog content. Therefore I'm using Umbraco member functionality to cater that scenario.
I noticed there is a language selection while creating users for the back-office. Also, I'm aware of creating multiple site contents to support each language.
I went though https://our.umbraco.com/documentation/tutorials/multilanguage-setup/ article. But this is not what I'm looking for.
Are there any other way to specify Mermeber's language preference and show the content based on that after login to the system?
Or any other thoughts?
You could add a "Preferred Language" property to your Member type (just a Content Picker I guess). Then you would have to do something in the front-end as well, perhaps like this: https://24days.in/umbraco-cms/2014/razor-language-switcher/ . You'd also have to add code that updates the member property to whichever start node whenever a new one is selected, as well as a redirect mechanism so whenever a member enters the site they'd end up on the correct site.
If you're asking if all this exists already - in a package or something - I don't think so :-/
Related
I have a project and i want my ASP.Net to be able to have same capabilities like windows insider. For example i want to give some of the users the new features and functionality to test same like share point allows to deploy new feature to some of the users. Is there any platform available that i can use or i will have to modify my application to have this capability?
E.g. the Sharepoint today has this capability that we can select some users and then provide them access to have new feature and version or outlook allows you to see new features but user has capability to turn it of.
There is one strategy:
You can do something like request forwarding.
You can install another web application with new features.
Then when user comes to your site you can ask them whether they want to see old application / new application.
If they select new, then on server side, you can redirect user to new web setup.
Once you aware that most of the people are going to new web tier, you can then shutdown old servers.
Obviously there will be other factors, like
is this only UI level change or you have some data store and that is
also going to change.
If it requires change in underlying database, then how are you going
to make sure that new application gets data from old database
You will have to think through and decide strategy best applicable for your solution.
I know this does not provide direct solution to your question, but this should given enough information on your question so that you can get started with some approach.
One option is to use an Authorize Attribute on a new controller defined for the new feature and add users who you want to have access to a role.
For example you could put users A, B and C into the Role "CanUseNewFeature" and just put a conditional if on the view something like:
#if(User.IsInRole("CanUseNewFeature")
<a href="yourlink" /> Check out new feature! </a>
and the controller
[Authorise(Roles ="CanUseNewFeature")]
public class NewFeatureController : Controller
I am helping a friend of mine to edit a few things on his website that was built using Umbraco. I am not the original author and I am pretty new to Umbraco but, I can't seem to find the answer anywhere. There is a form that is being used to send an email whenever someone wants to order supplies from the website. The form was previously working. However, he has lost access to the email account and had to create a new one. The problem is I cannot seem to locate the model to look inside of it and change where the emails are being sent.
I cannot locate the Models (there are multiple) in the Umbraco hierarchy even though I can find references to where they're are called inside of the different forms. See below:
#inherits Umbraco.Web.Mvc.UmbracoViewPage<Aeon.Models.OrderSuppliesModel>
I know this is not a URL so I am a little confused on why this is not in any of the Umbraco hierarchy. I know that since it is referencing something and previously worked it has to be there somewhere. The only other place I would think they could be is in the root directory which I don't have access to yet. Could they possibly be located there? Any type of help on this matter would be greatly appreciated.
Since you don't have access to the code, you will have to hope there is a variable somewhere which lets you set the email, rather than it being hardcoded into the controller.
Umbraco nodes
Sometimes Umbraco developers store the email on a field on a node in Umbraco. The common places are:
on the page node which has the form on it
on a settings node
on the home page node
Web.config
The Web.config also has a section which can be used to easily setup variables. Checkout the <appSettings> section to see if there are keys and/or values which might indicate they're used for email.
Also, you haven't specifically said if it is the SMTP email account which has broken, or if it's the email account which submissions are being sent to. Look for the <mailSettings> section on the Web.config if you want to see the SMTP settings. There may be a 'from' field on the <smtp> element.
umbracoSettings.config
In the umbracoSettings.config there is an element which will look something like this:
<notifications>
<!-- the email that should be used as from mail when umbraco sends a notification -->
<email>your#email.here</email>
</notifications>
Forms are not directly handled within Umbraco. I am assuming you are using ver 6+.
To get a form to work you rely on the core MVC functionality, which means you create a Surface Controller with Get and POST actions to handle the logic.
There will be a reference to the specific model being passed to the view within the controller logic, but its common for standard static configuration information to be stored in an Umbraco node itself. Example of such are "SMTP server" "From Address" & "Use Encryption" etc. Some people as an alternative store this information as keys in web.config.
If you are specifically looking to change the model being passed to the form (OrderSuppliesModel), if you are using Visual Studio, the model should be colored in a teal color and when you hover over it, it shows the full namespace. Click it and press F12. This should link you directly to the class module.
hope it helps.
If you're lucky, they're using Umbraco Forms/Contour. When you log into the back office, do you see a section called either "Forms" or "Contour"?
If so, you should be able to find the form in the Forms tree, and at the bottom of the form you should be able to edit the workflows, which will allow you to change who gets emails sent to them etc.
If you don't have those sections, could you post the view that has the form on so we can see what it's doing please?
I have a multiple site Sitecore solution. All the sites share a product range which is stored inside a 'Shared data' node that sits at the same level as the root nodes of the sites. The individual product pages on a site use a wildcard item to lookup the product based on the last part of the URL.
This means that we can't use internal links in the rich text editor to point to the product page on any of the sites because the product item does not have a specific site URL.
Does anyone know of a way to overcome this, or perhaps know of a way to augment the default behavior of interal links?
Have you considered using cloned items, see here for details.
This would allow you to share the content whilst having the appearance to the end user of the Products being inside the content tree allowing you to use the RTE and internal link look ups?
For extra information about clones, see here and here
You'd also need to do some work in the link provider to link to the cloned version of a product if you wanted. See this question.
I have a web part which shows data in one of 3 different formats. The format is selected by clicking one of 3 buttons in the web part. This works fine.
A request has come through to store the last selected state so that the user does not always have to click their favourite view.
It seemed logical to define a Property and define Personalizable(PersonalizationScope.User) but this does not seem to work for most users as they only have Read rights for the page.
What is the best way forward here? Is Sharepoint the right place to store such info or should I be using my own storage?
Thanks
Using your own storage is an option but this means its some more development work for you. How about this option.
Modify your WebPart and add the option to the Web Part property.
Create a new permission level and add the following permission
Update Personal Web Parts - Update
Web Parts to display personalized
information.
This will make sure that users with read only access can only update webparts.
Step 2 will allow them to odify all webparts. You can modify each webpart and remove the following option for webparts which you dont want you users to edit.
Allow Editing in Personal View [Advanced]
This way you can lock all webparts except the one you want.
I'm working on an umbraco website just now and one of the requirements is to have a custom section in the back end that can be used to manage publish smaller micro-sites.
I have been able to create the new section and added some nodes to it. What I can't get to work is publishing them and making them viewable at the correct url.
As an example, say i have created a new section called microsite, inside that there is a folder called myportfolio. this should route to something like www.myumbracosite.com/microsite/myportfolio.
Does anyone know how to get this sort of thing working? Is it even possible to publish content from outsite of the main content section?
Any help would be greatly apprechiated.
Kind Regards
Colin G
From my understanding the custom sections are for linking to custom databases or data somewhere that needs an interface.
That said, you can use UrlRewriting and an existing content page with a macro to do something like that.
If you had a page called microsite, then using UrlRewriting you could make the parameter passed in to microsite.aspx (a content page in Umbraco) be "myportfolio".
With a user control on the microsite template it could display some content from your external database (or wherever your custom section stores it).
Not sure that's what you're looking for...
Why are you trying to create a new section for more content? The current Umbraco content area has all kinds of permissions for both users and members. Are the microsites all in the same install of Umbraco?
Another option is that the custom section could simply be used as a setup wizard for the new sites. You could create new content and users in their normal places and just use the new section to create them. It's not too hard to create content from C#, so it would probably be the same as doing it from a user control.
Could you provide a little more info?