Error in code on the extended FBA Commerce webshop...
- Hello,
We created an NTLM authentication webshop and now we've extend the webshop to an FBA authentication webshop on a different port number.
The NTLM website works good, but when we want access the FBA site, it gives the following error;
Parser Error Message: The control type 'Microsoft.Commerce.Portal.UI.OrdersSharePoint.WebParts.SPMiniCartWebPart' is not allowed on this page. The type is not registered as safe.
Line 191: <div class="MiniCartText"> Line 192: Line 193: <Commerce:SPMiniCartWebPart id="miniCart" runat="server" XslTemplateUri="[Templates]/MiniCart/DefaultSite_MiniCart.xslt" __WebPartId="{B9D043A2-47E5-496F-A388-51E109FCD387}"/> Line 194: Line 195: </div>
I have already editted the web.config of the FBA webshop in the PageParserPaths. This is what I added; (this was also added in the web.config of the NTLM authetication webshop)
<PageParserPath VirtualPath="/_catalogs/masterpage/CSDefaultSite.master" CompilationMode="Always" AllowServerSideScript="true" />
But the error persists...
Someone with an solution?
Thanks!
Stefan
Answers
- I found it!
The file ProfileResources.resx was not copied to the App_GlobalResources folder of the extended FBA site.
Thanks for your help!
Stefan- Marked As Answer bystefan_br Monday, November 09, 2009 10:43 AM
All Replies
- Hi Stefan,
If you have not deployed your URL as a SharePoint solution (WSP file) through STSADM you will need to manually add your new assembly to the SafeControls list within the web.config of the SharePoint site. This will allow the assembly to be used to render webparts.
The lines you are looking for are similar to this:
Thanks,<SafeControls> <SafeControl Assembly="Microsoft.SharePoint.Portal, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" Namespace="Microsoft.SharePoint.Portal.WebControls" TypeName="*" /> <SafeControl Assembly="Microsoft.Office.Server.Search, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" Namespace="Microsoft.Office.Server.Search.WebControls" TypeName="*" Safe="True" /> <SafeControl Assembly="System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Namespace="System.Web.UI" TypeName="*" Safe="true" /> </SafeControls>
Lewis
Follow Me on Twitter: @LewisBenge Or check out my blog: http://www.geekswithblogs.com/pointtoshare/- Proposed As Answer byLewisBenge Wednesday, November 04, 2009 9:22 PM
- Hi Lewis,
Thanks for pointing me in the right direction!
I've added the Safecontrol lines to the web.config and that seems to help. Well I got a different error...
The next error was about the resources, so i looked in the App_GlobalResources folders of both directories and the FBA site was missing some files. So I copied those files from the other.
Then the site started, but there are some problems.
1. The Searchbox doesn't work (WebPart can not be displayed. General error rendering the web part.)
2. When I clicked on a product category it shows only; WebPart can not be displayed. WebPart can not be displayed.
3. When I want to login my browser gives an HTTP 403 Forbidden
4. When I click on the 'My Account' button I get an 401 Unauthorized
5. And when I click on the basket on top it gives the following error;
The operation service has encountered an error while processing the request. The error details have been logged by the service.
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.ServiceModel.FaultException`1[[Microsoft.Commerce.Contracts.Faults.GeneralOperationFault, Microsoft.Commerce.Contracts, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35]]: The operation service has encountered an error while processing the request. The error details have been logged by the service.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below.
Stack Trace:
[FaultException`1: The operation service has encountered an error while processing the request. The error details have been logged by the service.] Microsoft.Commerce.Broker.OperationService.ProcessRequest(CommerceRequest request) +504 Microsoft.Commerce.Common.OperationServiceAgent.ProcessRequest(CommerceRequestContext requestContext, CommerceRequest request) +61 Microsoft.Commerce.Portal.Common.BrokerHelper.Execute() +257 Microsoft.Commerce.Portal.Common.ShoppingController.GetBasketWithQuery(String basketName, Boolean refreshBasket) +70 Microsoft.Commerce.Portal.Common.ShoppingController.GetBasket(String basketName, Boolean forceGet, Boolean refreshBasket) +82 Microsoft.Commerce.Portal.UI.Orders.UserControls.CartPresenter.LoadBasket() +40 Microsoft.Commerce.Portal.UI.Orders.UserControls.Cart.Page_PreRender(Object sender, EventArgs e) +383 System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +25 System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +42 System.Web.UI.Control.OnPreRender(EventArgs e) +11025518 System.Web.UI.Control.PreRenderRecursiveInternal() +108 System.Web.UI.Control.PreRenderRecursiveInternal() +224 System.Web.UI.Control.PreRenderRecursiveInternal() +224 System.Web.UI.Control.PreRenderRecursiveInternal() +224 System.Web.UI.Control.PreRenderRecursiveInternal() +224 System.Web.UI.Control.PreRenderRecursiveInternal() +224 System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +3394
I gonna try to make it work, but it would be really great if you got some useful tips to get this site working...
Thanks!
Stefan For the login and My Account problem;
I enabled on IIS, Forms Authentication and now when i click on the 'Login' or the 'My Account' button it gives the following error.
The resource object with key 'LoginPageTitle' was not found. at System.Web.Compilation.ResourceExpressionBuilder.ParseExpression(String expression, Type propertyType, ExpressionBuilderContext context)
at System.Web.UI.BoundPropertyEntry.ParseExpression(ExpressionBuilderContext context)
at System.Web.UI.ControlBuilder.FillUpBoundPropertyEntry(BoundPropertyEntry entry, String name)
at System.Web.UI.ControlBuilder.AddBoundProperty(String filter, String name, String expressionPrefix, String expression, ExpressionBuilder expressionBuilder, Object parsedExpressionData, Boolean generated, String fieldName, String formatString, Boolean twoWayBound)
at System.Web.UI.ControlBuilder.PreprocessAttribute(String filter, String attribname, String attribvalue, Boolean mainDirectiveMode)
at System.Web.UI.ControlBuilder.PreprocessAttributes(ParsedAttributeCollection attribs)
at System.Web.UI.ControlBuilder.Init(TemplateParser parser, ControlBuilder parentBuilder, Type type, String tagName, String id, IDictionary attribs)
at System.Web.UI.ControlBuilder.CreateBuilderFromType(TemplateParser parser, ControlBuilder parentBuilder, Type type, String tagName, String id, IDictionary attribs, Int32 line, String sourceFileName)
at System.Web.UI.ControlBuilder.CreateChildBuilder(String filter, String tagName, IDictionary attribs, TemplateParser parser, ControlBuilder parentBuilder, String id, Int32 line, VirtualPath virtualPath, Type& childType, Boolean defaultProperty)
at System.Web.UI.TemplateParser.ProcessBeginTag(Match match, String inputText)
at System.Web.UI.TemplateParser.ParseStringInternal(String text, Encoding fileEncoding)- Hi Stefan,
Looks like the page is trying to pull a title out of the Resource file too. Is your server setup as English-US to be it's primary language?
Thanks,
Lewis
Follow Me on Twitter: @LewisBenge Or check out my blog: http://www.geekswithblogs.com/pointtoshare/ - Hi Lewis,
Yes, the primary language is English-US
Thanks
Stefan - Hi,
Well I've got the site working now, but still i can't login.
I have set the loginpage to; /_layouts/commerceserver/CommerceLoginPage.aspx
But i keep getting the following error;
The resource object with key 'LoginPageTitle' was not found. at System.Web.Compilation.ResourceExpressionBuilder.ParseExpression(String expression, Type propertyType, ExpressionBuilderContext context)
One Question; Must we deploy some wsp files? Because there are in the SharePoint Central Administration -> Operations -> Solution Management only two soloutions deployed. (microsoftcommercewebparts.wsp & microsoftcommercewssdefaultsitev2.wsp)
Thanks!
Stefan - Check if the site's resources feature is activated in Site Collection/Site features list.
Go to Central Administration--> Application Management --> Manage Web Application Features
Go to Site Actions-->Site Settings-->Modify All Site Settings --> Site Collection Administration --> Site Collection Features
Go to Site Actions-->Site Settings-->Modify All Site Settings --> Site Administration --> Site Features - In the central administration everything is activated.
On the NTLM website all features under Site Settings are activated.
But I cannot login on the extended FBA website because of the error. The 'Sign In' and 'Login' link goes to the same URL. So I cannot check the features for the extended site. - I found it!
The file ProfileResources.resx was not copied to the App_GlobalResources folder of the extended FBA site.
Thanks for your help!
Stefan- Marked As Answer bystefan_br Monday, November 09, 2009 10:43 AM

