Adding custom jQuery scripts

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.
7/18/2011 12:33:04 PM
Gravatar
Total Posts 3

Adding custom jQuery scripts

Hi,

I'm currently trying to add some custom jQuery scripts and have been searching this forum trying to figure it out..

In the developer docs it says as follows : The above is no longer valid, the latest versions of mojoPortal now load the jquery files in the head so now you don't have to worry about loading scripts in pre-render event, you can load your scripts about any way you like and they should always come in after the jquery scripts.

And all threads i can find about the subject, states that this is the way to do it...

So, how do you actually add a custom script??

Thanks in advance

Christian

7/18/2011 12:53:10 PM
Gravatar
Total Posts 18439

Re: Adding custom jQuery scripts

The way you load any javascript has not really changed and is documented correctly in Adding Custom Javascript, previously you had to wait until the Pre-Render event to load scripts that depended on jQuery because if you registered them during page load event they would be registered before the main jQuery scripts and would come in above the main jquery scripts and therefore would not work, that is the only thing that has changed so now it doesn't matter much which event you register scripts in because the main jQuery scripts will always be first. But how you add scripts in mojoPortal is the same as in any ASP.NET application.

Hope that helps,

Joe

7/19/2011 2:02:44 AM
Gravatar
Total Posts 3

Re: Adding custom jQuery scripts

Thank you very much for your reply, i'm still a bit new to the whole jQuery world and got a bit confused..

Cheers

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