To Apply Javascript code through out the website using Cascade server

Ghulam Nabi's Avatar

Ghulam Nabi

12 Jul, 2010 03:47 AM

We want to apply some javascript throughout the intranet website even when a new page is created it should apply those scripts automatically on that page, so there should be no manual copy and paste the javascript on every page that we create in the website.

Please adivce on this.

  1. 1 Posted by Eric L. Epps on 12 Jul, 2010 07:21 AM

    Eric L. Epps's Avatar

    I just put the JavaScript in a text (or XHTML) block and then apply it to the base asset for the Asset Factory.

  2. 2 Posted by Ghulam Nabi on 12 Jul, 2010 11:25 AM

    Ghulam Nabi's Avatar

    Hi Eric,

    Thank so much for your help on this.

    Can you please elaborate more on applying scripts on Aset factories as i am novice in CASCADE SERVER.

  3. Support Staff 3 Posted by Tim on 12 Jul, 2010 03:23 PM

    Tim's Avatar

    Hi Ghulam,

    As Eric mentioned, the easiest thing to do is to create a Block which contains your Javascript, then simply plug this Block in either at the Asset Factory level or at the Template or Configuration level.

    To do this, you'll first need to create a new system region in your Template.

    Then, you need to create a Block. For more information on tText, XML, and XHTML Blocks, see the following page on our Knowledge Base:

    Once the Block has been created, you can plug it into the Template region that you made. (please note that you can also plug the block in either at the Configuration level or at the page level).

  4. 4 Posted by kenton.hankins on 12 Jul, 2010 07:12 PM

    kenton.hankins's Avatar

    If you use a header that is a php file, you can also put it there. This way you will not have to republish the whole site when you make a change to the script, just the php file.

  5. 5 Posted by Ghulam Nabi on 13 Jul, 2010 11:36 AM

    Ghulam Nabi's Avatar

    I have updated the javascript code in one of the templates but I don't get any publish tab/button in the menu bar to publish this template.

    Please help on this.

  6. 6 Posted by Eric L. Epps on 13 Jul, 2010 12:19 PM

    Eric L. Epps's Avatar

    Templates don't need to be published. Templates are applied to Configuration
    Sets, which are part of Content Types, which are applied to pages, which can
    be published.

  7. 7 Posted by Ghulam Nabi on 20 Jul, 2010 01:07 PM

    Ghulam Nabi's Avatar

    I dont have admin rights, would i able to update templates, I tried to add few lines of Javascript code in templates but couldnot get the expected result.

    Please Advice

  8. 8 Posted by Eric L. Epps on 20 Jul, 2010 01:16 PM

    Eric L. Epps's Avatar

    Sounds like you need to talk to your Cascade Server administrator.

  9. 9 Posted by Ghulam Nabi on 20 Jul, 2010 02:29 PM

    Ghulam Nabi's Avatar

    Can you please send me the complete list of step to apply javascript throughout the website , as Chris & Tim already knows that we are not trained in CASCADE SERVER, actually we have self studied the CASCADE SERVER so far.

  10. Support Staff 10 Posted by Tim on 20 Jul, 2010 02:40 PM

    Tim's Avatar

    Hi Ghulam,

    This is a public forum where users try to provide others with helpful tips and information. Unfortunately, the question you are asking would be better handled via a training session. Please have your team contact [email blocked] and request information about training. We'll be happy to help you via that route.


  11. Tim closed this discussion on 20 Jul, 2010 02:40 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac