mojoPortal in WebMatrix Web Gallery

If you have questions about using mojoPortal, you can post them here.

You may want to first review our site administration documentation to see if your question is answered there.

This thread is closed to new posts. You must sign in to post in the forums.
11/20/2012 4:18:06 AM
Gravatar
Total Posts 14

mojoPortal in WebMatrix Web Gallery

Hi.
I have made a few sites using mojoPortal with acceptable results.  I do not consider myself an experienced web developper, though.
I have also done some experimentation with WebMatrix.  Now, I am interested in making a WebMatrix site based on the mojoPortal Web Gallery template.  SQL Server is installed on my development machine.  I was asked for password for administrator user sa.   On the web, I have found advice on how to retrieve a SQL Server password.  Before I try that, I would like to ask if there is another, perhaps simpler way to proceed?

Regards, Gudni

11/20/2012 5:37:46 AM
Gravatar
Total Posts 14

Re: mojoPortal in WebMatrix Web Gallery

Hi, again.

I have been consulting the mojoPortal documentation and have decided to use WebMatrix to run the SqlCe version of mojoPortal.
I have been using SqlCe in other projects and appreciate it very much.  In many cases, SQL Server is somewhat of an overkill.

So, I downloaded the mojoportal-2-3-9-4-sqlce-net40-deploymentfiles.zip, unzipped it and launched it in WebMatrix.

The mojoPortal documentation says:
When the web browser opens mojoPortal, it will detect from expected errors that the SQL CE database has not yet been created, so it will redirect to the /Setup/Default.aspx page which will create the SQL CE database automatically and then run the installation scripts.

That did not happen, instead I got the following message:

mojoPortal Content Management System
Welcome to mojoPortal Setup
Probing system...
File system permissions ok.
The system cannot connect to the SqlCe database. Please check your connection string.

System.Data.SqlServerCe.SqlCeException (0x80004005): The path is not valid. Check the directory for the database. [ Path = C:\WebMatrixExperimantation\wwwroot\App_Data\mojodb.sdf ] at System.Data.SqlServerCe.SqlCeConnection.Open(Boolean silent) at System.Data.SqlServerCe.SqlCeConnection.Open() at mojoPortal.Data.DBPortal.DatabaseHelperGetConnectionError(String overrideConnectionInfo) in c:\_joe\__projects\__mojoportal\_code\cleanbuilds\net40\sqlce\mojoPortal.Data.SqlCe\DBPortal.cs:line 660

Any help will be welcome.

Regards, Gudni

11/20/2012 8:26:55 AM
Gravatar
Total Posts 18439

Re: mojoPortal in WebMatrix Web Gallery

Hi Gudni,

I just tested it and it worked correctly for me. My steps were:

1. download and extract mojoportal-2-3-9-4-sqlce-net40-deploymentfiles.zip

2. copied the www root folder to a location on my hard drive where I want the site files

3. I renamed the wwwroot folder as sqlce2394matrix

4. I installed the latest WebMatrix 2 from the Platform Installer sinc eI did not have it installed

5. In windows explorer I right click the folder sqlce2394matrix and choose "Open as Web Site In WebMatrix"

6. When WebMartix opens I click in the upper left corner Run in Internet Eplorer

7. The setup page creates the database and runs the scripts and the site works after that

Hope that helps,

Joe

11/20/2012 9:05:13 AM
Gravatar
Total Posts 14

Re: mojoPortal in WebMatrix Web Gallery

Hi, Joe and thanks for the reply.

I went through all the same steps as you.  After I got your message, I also renamed the wwwroot folder as sqlce2394matrix.  This is a location on my hard drive (C:\WebMatrixExperimentation\sqlce2394matrix).  When I open the site in WebMatrix, the database is still not created.  This is what I get (same result in FireFox as in IE8):

Welcome to mojoPortal Setup

Probing system...
File system permissions ok.
The system cannot connect to the SqlCe database. Please check your connection string.

System.Data.SqlServerCe.SqlCeException (0x80004005): The path is not valid. Check the directory for the database. [ Path = C:\WebMatrixExperimantation\sqlce2394matrix\App_Data\mojodb.sdf ] at System.Data.SqlServerCe.SqlCeConnection.Open(Boolean silent) at System.Data.SqlServerCe.SqlCeConnection.Open() at mojoPortal.Data.DBPortal.DatabaseHelperGetConnectionError(String overrideConnectionInfo) in c:\_joe\__projects\__mojoportal\_code\cleanbuilds\net40\sqlce\mojoPortal.Data.SqlCe\DBPortal.cs:line 660

Note: This page shows some information that is helpful during setup and upgrades but for security it would be best not to show any information when the system is up to date. You can disable setup and suppress all information on this page by setting DisableSetup=true in Web.config. When you need to upgrade, you can set this back to false. If you are logged in as Administrator setup will run and you will be able to see this page even if it is disabled in Web.config so you can easily leave it disabled and just login before upgrading. But if you are not logged in you will need to enable setup in Web.config.

Regards, Gudni

11/20/2012 9:17:58 AM
Gravatar
Total Posts 18439

Re: mojoPortal in WebMatrix Web Gallery

Does the /App_Data folder exist?

If not then create it and refresh the setup page.

I extract by right click the zip and extract files using built in windows extract functionality. If you unzip it with WinZip maybe it leaves out the empty folders.

Also make sure you are using the latest version of WebMatrix.

Hope that helps,

Joe

11/20/2012 9:41:27 AM
Gravatar
Total Posts 14

Re: mojoPortal in WebMatrix Web Gallery

Hi, Joe.

No, the /App_Data folder did not exist.  I created it, reran the setup page and, voilà, the setup finished successfully.  I am in business now!  Thanks a lot, Joe.

Regards, Gudni

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