Cant access custom app under Mojoportal root

Post here for help with installing or upgrading mojoPortal pre-compiled release packages. When posting in this forum, please provide all relevant details. You may also want to review the installation or upgrading documentation.

If you have questions about using the source code or working with mojoPortal in Visual Studio, please post in the Developer forum.

Post here for help with installation of mojoPortal pre-compiled release packages

When posting in this forum, please try to provide as many relevant details as possible. Particularly the following:

  • What operating system were you running when the bug appeared?
  • What database platform is your site using?
  • What version of mojoPortal are you running?
  • What version of .NET do you use?
  • What steps are necessary to reproduce the issue? Compare expected results vs actual results.

You may also want to review the installation or upgrading documentation.

If you have questions about using the source code or working with mojoPortal in Visual Studio, please post in the Developer forum.

This thread is closed to new posts. You must sign in to post in the forums.
9/13/2011 9:23:38 AM
Gravatar
Total Posts 83
-- Joe

Cant access custom app under Mojoportal root

I am helping a non-profit move from an old CMS (Subdreamer) on a different host provider to Mojoportal on DiscountASP.NET.

The Mojoportal CMS is installed in the folder /Mojoportal under the root.  ex: www.mysite.org/Mojoportal 

I also have another custom coded application under the root  www.mysite.org/CustomApp

Right now all is fine.

As we are ready to switch to Mojoportal CMS, I copied the folder structure from under /Mojoportal to the root.  Mojoportal CMS worked fine.

The problem is I cannot access my Custom application now.  www.mysite.org/CustomApp  The CustomApp is setup as an Application is IIS - and I removed the Application setup for www.mysite.org/Mojoportal

So I moved the Mojoportal folder structure back under /Mojoportal and all works fine again.

Does anyone know why I cant acces my CustomApp when under Mojoportal? 

The error was a generic one from DiscountASP.NET   I dont have the exact message now (as I moved it all back) but it was basically like "Sorry we are having problems with this application.  Please contact our support department for assistance"

Thanks in advance for any help!

-- Joe

 

9/13/2011 9:30:48 AM
Gravatar
Total Posts 18439

Re: Cant access custom app under Mojoportal root

Hi,

See the links in the first item of our Developer FAQ.

Also regarding moving a site from a sub directory to root you should probably review the article Moving an Installation of mojoPortal to a Different Server, even though it is not a different server in this case the notes about moving a site still apply.

Hope that helps,

Joe

9/13/2011 10:18:46 AM
Gravatar
Total Posts 83
-- Joe

Re: Cant access custom app under Mojoportal root

Thanks Joe - I will try that tonight.  It would seem that i need to add <location inheritInChildApplications="false"> to allow my CustomApp to work.

BTW - really starting to love Mojoportal.  Thank you for your amazing work on it.

10/24/2011 10:21:00 AM
Gravatar
Total Posts 83
-- Joe

Re: Cant access custom app under Mojoportal root

After I moved the MojoPortal files to the root, and edited the Mojoportal WEB.CONFIG file adding the section:

<location path="." inheritInChildApplications="false">
</location>

around the <system.web>...</system.web> section. 

Would anyone know why I now get the following error in my sub application?

Server Error in '/MyCustomApp' Application.

Could not load file or assembly 'mojoPortal.Web' or one of its dependencies. The system cannot find the file specified.

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.IO.FileNotFoundException: Could not load file or assembly 'mojoPortal.Web' or one of its dependencies. The system cannot find the file specified.

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.

Assembly Load Trace: The following information can be helpful to determine why the assembly 'mojoPortal.Web' could not be loaded.

WRN: Assembly binding logging is turned OFF.To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1.Note: There is some performance penalty associated with assembly bind failure logging.To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].

Stack Trace:

[FileNotFoundException: Could not load file or assembly 'mojoPortal.Web' or one of its dependencies. The system cannot find the file specified.] System.RuntimeTypeHandle._GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark, Boolean loadTypeFromPartialName) +0 System.RuntimeTypeHandle.GetTypeByName(String name, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark) +64 System.RuntimeType.PrivateGetType(String typeName, Boolean throwOnError, Boolean ignoreCase, Boolean reflectionOnly, StackCrawlMark& stackMark) +58 System.Type.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) +65 System.Web.Compilation.BuildManager.GetType(String typeName, Boolean throwOnError, Boolean ignoreCase) +342 System.Web.Configuration.ConfigUtil.GetType(String typeName, String propertyName, ConfigurationElement configElement, XmlNode node, Boolean checkAptcaBit, Boolean ignoreCase) +52

10/25/2011 7:43:43 AM
Gravatar
Total Posts 18439

Re: Cant access custom app under Mojoportal root

are you sure the app folder is configured as an application not just a folder or virtual directory?

I would try removing that path attribute from the location element or set it to match the folder name like /foldername/

you may also need to wrap a location element around system.webServer section

Hope that helps,

Joe

10/26/2011 2:09:25 PM
Gravatar
Total Posts 83
-- Joe

Re: Cant access custom app under Mojoportal root

So in removed the application configuration from IIS - and received a more generic web.config error "An error occurred reading the integrated module list from system.webServer/modules. The error is 0x80070021."

Then I setup the app again "This folder is setup as a web application" and received the same error "Server Error in '/MyCustomApp' Application. Could not load file or assembly 'mojoPortal.Web' or one of its dependencies. The system cannot find the file specified."

Restarted the IIS server and also recycled the app pool.  No luck.

Removed the path="*" from the <location> tag, no luck.

Unwrapped the <location> tag from <system.web> (<location inheritInChildApplications="false"></location>) no luck.

In all cases Mojoportal is working either at the root or in the /mojoportal subfolder I created - and myCustomApp is only working when Mojoportal is in the subfolder.

Any other ideas?

 

10/27/2011 11:58:29 AM
Gravatar
Total Posts 18439

Re: Cant access custom app under Mojoportal root

I would make sure both apps are using the same version of .NET, ie if one is .NET 4 and the other is .NET 3.5 it might cause problems such as this. I'd use an Integrated Application pool by preference but I'd also try a Classic app pool and see if it makes any difference.

Hope that helps,

Joe

11/30/2011 10:01:40 AM
Gravatar
Total Posts 83
-- Joe

Re: Cant access custom app under Mojoportal root

Both apps are .NET 3.5

I've tried Integrated Application Pool and Classic - no luck

Any other ideas? 

1/13/2012 10:54:15 AM
Gravatar
Total Posts 83
-- Joe

Re: Cant access custom app under Mojoportal root

Upgraded to the latest version and tried this again and BINGO!  It works now!  Ahhh the relief!  Thanks for all the help

 

2/7/2012 9:01:11 AM
Gravatar
Total Posts 30

Re: Cant access custom app under Mojoportal root

I just upgraded to the latest version of mojoportal and instantly my custom app failed.

After searching through this forum I kept landing on this thread over and over until I found another thread that indicated what I had to do.  I've added a reply here because this is where google kept sending me. Probably because I'm also with DiscountASP.Net (which is normally rocking for MojoPortal hosting).

In addition to the <location path="."  inheritInChildApplications="false"> around <system.web>  tag

I also needed this:

<location inheritInChildApplications="false"> around  <system.webServer>

At that point everything just worked.  Otherwise I kept getting:

"Could not load file or assembly 'mojoPortal.Web' or one of its dependencies." as per Joe Vago's post.

2/7/2012 9:08:24 AM
Gravatar
Total Posts 18439

Re: Cant access custom app under Mojoportal root

This is also mentioned in our Developer FAQ.

Best,

Joe

You must sign in to post in the forums. This thread is closed to new posts.