Modules not appearing in page

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.
2/16/2015 11:12:28 AM
Gravatar
Total Posts 30

Modules not appearing in page

I am adding modules to pages through the code. I have used the function Module.Save() to insert module to page. Although I can see them in the database, but when I try to access the page its still navigating me to the content wizard where I should choose to insert a module. Should I use any other function or any additional code should be added to get the modules shown on my page ?

 

Best.

2/17/2015 4:55:35 AM
Gravatar
Total Posts 30

Re: Modules not appearing in page

no answer ?

2/17/2015 8:42:15 AM
Gravatar
Total Posts 2239

Re: Modules not appearing in page

We're a volunteer forum so questions may not get answered as quickly as you like but they do generally get answered.

I built a module a couple of years ago which needed to publish modules programmatically so I took a quick look at that code. I think you might be running into a caching issue. Try using the mojoPortal.Web.WebHelpers.CacheHelper.ClearModuleCache() method for that. Also, be sure that the date you're setting for the publishBeginDate on when calling Module.Publish is either localized to the users time zone or use DateTime.MinValue.

If these steps do not work, please check in the database that the modules are actually published on the page you're expecting them to be published.

HTH,
Joe D.
 

2/17/2015 9:04:40 AM
Gravatar
Total Posts 18439

Re: Modules not appearing in page

I'm on vacation so I don't respond much this week, but one clue for you, mp_pagemodules is what puts a module on a page, again review existing code that adds modules to a page

2/17/2015 9:09:35 AM
Gravatar
Total Posts 30

Re: Modules not appearing in page

thanks a lot guys, your support is really appreciated. I will follow your advice.

 

2/17/2015 9:16:32 AM
Gravatar
Total Posts 30

Re: Modules not appearing in page

My problem was with the table mp_FriendlyUrls . I was inserting the wrong page id. Now everything works perfectly. Thanks a lot guys.

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