Some questions, how to extend mojo, and how to integrate with own web application?

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

Please do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.

This forum is for discussing mojoPortal development

This forum is only for questions or discussions about working with the mojoPortal source code in Visual Studio, obtaining the source code from the repository, developing custom features, etc. If your question is not along these lines this is not the right forum. Please try to post your question in the appropriate forum.

You can monitor commits to the repository from this page. We also recommend developers to subscribe to email notifications in the developer forum as occasionally important things are announced.

Before posting questions here you might want to review the developer documentation.

Do not post questions about design, CSS, or skinning here. Use the Help With Skins Forum for those questions.
This thread is closed to new posts. You must sign in to post in the forums.
11/25/2009 8:11:58 AM
Gravatar
Total Posts 192

Some questions, how to extend mojo, and how to integrate with own web application?

hi.

I'm really impressed with the great CMS of mojoPortal (and have been wondering for some days how can joe create such a great system, how many hours a day he works??)

I need to make some big customizations to mojo and do a big work for a customer. There are things I need to do, and for doing them I had to review many codes, and get how mojo works. but I thought I could ask them in the forum and some guides would be very helping.

If you don't want to give full description, some general answers like, "this is in the X table of database" or "for this, you need to change table X of database, and also change code file X" would also make me very thankful. of course the more details, the better!

I want to develop my own application, and for some of the features, want to use mojoPortal. I want to create some general pages using CMS system of mojo, and want to use features of it like forum and polls and skinning and administration and all the good stuff. I want to integrate the authentication and authorization of mojo in my own application. my application would have it's own database tables, and it's own aspx pages and codes.

these are my questions:

1. I want to add more options for a user, when registring. not all info mojo gets by default, is enough for my application. as I said the application and mojo will use same auth & auth system. how can I do that? what db table and code models do I need to change?

2. I may need to get different info for different types of users. (say some are students, and some are teachers). how can this be done? what your Idea about how to implement them?

3. how could HttpModules configured for mojo, affect my aspx pages? could they cause problems?

4. Is adding links of my application pages to mojo menues easy? (can I add new pages in mojo, but make underlying address a link to my existing pages of the application?)

5. how easy is it to create a profile page for users? something like the myPage page of mojoPortal. (honestly, myPage is just spreading negative energy! I really loved everything with mojo. but the myPage, just made me feel bad about mojoPortal.) can it simply be done with creating new modules? or I need more changes? leaving room for future advances to making it a home page of a social networking site.

my questions may not be well-described, this is just because I have no experience with mojoPortal. anyway, I need your help for the start.

thanks for the answers.

11/25/2009 11:59:35 PM
Gravatar
Total Posts 192

Re: Some questions, how to extend mojo, and how to integrate with own web application?

hello?

11/26/2009 8:44:31 AM
Gravatar
Total Posts 18439

Re: Some questions, how to extend mojo, and how to integrate with own web application?

Hi,

Sorry but the volume of forum posts is too much for me to answer every question, especially long lists of open ended questions. Not to mention today is Thanksgiving and I should be relaxing not answering forum posts.

1. You should not modify any mojoPortal code or mojoPortal tables. As soon as you do that you have created a fork and will have a hard time ever upgrading without losing your changes. All your custom code should be in your own projects and if you need custom tables you should create your own. You should read the developer documentation and you should study how existing features work to learn how to build your own features that can plug in. If you build a feature that plugs in you do not need to do anything to use the built in authentication since users will sign into the mojoportal site.

2. We do not have built in support for different kinds of users registering, though you can add custom profile properties and make them require for registration. You can create custom Register page in a separate project to do whatever you like and use a post build event to copy it up to replace the built in version, but then you will need to maintain it and always produce your own build to package mojoPortal with your custom features included.

3. Custom HttpModules can be plugged into the pipeline via the Web.config whether they affect page content or cause problems depends what they do. You should not plug in any httpmodules unless you understand exactly what they do and how they affect things.

4. Only CMS page are in the menu. Generally you implement a feature as a UserControl that can plug into a CMS page and this serves as the entry point to your application. From there you can link to any supporting pages of your feature and pass in the pageid and module id to keep the menu highlighted on the current page and to take advantage of built in methods of our base page for enforcing page and module level security. Though it is also possible to create a CMS page in the menu that really is just a pointer to your custom page by putting in the full url of your custom page as the url for the CMS page, but this is not really the recommended approach, it can be used.

5. MyPage is what it is, if you don't like it don't use it. I built it back when 2.0 .NET came out (around 2005) and WebParts seemed very interesting new feature at the time but less so now. I thought there would evolve an ecosystem of re-usable webparts for asp.net like Sharepoint webparts has but that never happened, it never really caught on and I don't know of any third party WebParts other than ones for Sharepoint. Whether something is easy to develop depends on the complexity and the skills of the developer.  mojoPortal is not meant to be all things to all people. It is meant to make it easy to have a web site for running a business and to be extendable but it is not meant to be a foundation of the next Facebook or MySpace.

Hope it helps,

Joe

11/26/2009 9:20:43 AM
Gravatar
Total Posts 192

Re: Some questions, how to extend mojo, and how to integrate with own web application?

yes of course it helps, thank you very much. ( to be honest, we don't have such a thing as thanksgiving day, and I didn't even know such a day)

I really wanted to make a fork of mojoPortal, and it was not much important to be able to upgrade to new versions, because current basis of mojo is more than enough for the application. (and really wanted help on what code and db tables should be changed for new features.)

I need to check the docs to see what can be done as pluggable features.

thanks again for your answer, and also for the great job of mojoPortal.

11/26/2009 9:30:32 AM
Gravatar
Total Posts 18439

Re: Some questions, how to extend mojo, and how to integrate with own web application?

I really wanted to make a fork of mojoPortal, and it was not much important to be able to upgrade to new versions, because current basis of mojo is more than enough for the application. (and really wanted help on what code and db tables should be changed for new features.)

This is a bad idea, I strongly recommend against it. Something will eventually come up where there is a security fix, a bug fix, or a new feature that you need. It is a bad assumption that you will never want or need to upgrade. Forking means you will have to maintain your fork and fix any bugs yourself. If you are building this app for someone else you do them a dis-service with this assumption, if you build it for yourself, I still think it is not a good assumption and you will later regret it.

Best,

Joe

11/27/2009 4:14:19 AM
Gravatar
Total Posts 192

Re: Some questions, how to extend mojo, and how to integrate with own web application?

If I can't do what I want using mojo addons, I will have only two choices:

  • create a new system from scratch, and maintain it myself.
  • create a fork of mojoPortal so it will fit to the needs, and still be responsible for maintaining it.

will I have any other choice?

I really think maintaining mojoFork, and trying to re-develop! (or copy) new features from newer versions (if ever needed) will be much easier than selecting the only other choice I have.

(considering the starting if) Am I not right?

11/28/2009 6:59:16 AM
Gravatar
Total Posts 18439

Re: Some questions, how to extend mojo, and how to integrate with own web application?

I recommend find strategies to keep your code separate and not modify existing tables. If you need to customize an existing content feature, clone it first to make your fork of the feature rather than a fork of the whole system and then at least it is independent from the included feature. For things like custom registration and login pages you could keep your version in separate projects and use post build events to replace the existing version with your own rather than put your own right in the mojoPortal code projects. Custom httpModules can be compiled into your own dlls and registered via Web.config.

Ultimately it is your decision, if you fork it you will have to live with your decision not me. All I ask is don't come around posting about bugs in your forked version and expect me to offer any support.

I do not think it will be trivial to backport bug fixes and new features from mojoPortal into your forked version. I've been developing and maintaining mojoPortal for over 5 years, are you going to maintain your fork for the next 5 years or more? If you are really comfortable with that idea then go for it.

Hope it helps,

Joe

11/28/2009 7:10:02 AM
Gravatar
Total Posts 192

Re: Some questions, how to extend mojo, and how to integrate with own web application?

Than you very much.

I wish I can help in development of mojoPortal in the future.

thank you again.

11/29/2009 3:06:17 PM
Gravatar
Total Posts 192

Re: Some questions, how to extend mojo, and how to integrate with own web application?

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