Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

It is important to know that you need to edit the cmsUrl to your url of choice. I for my part have two instances of magnolia installed at cms and cmspublic (why 2? Well, thats the way Magnolia works - you need to have an Author and a Public instance), so I redirect my calls to "http://localhost:8080/cmspublic".

Step 5 Which further steps do I need to consider?

This setup so far will fetch any content from the url defined at cmsUrl. You will still need to create a groovy script of your own that will pass the given site parameters (defined as query) to the the "runCMSQuery"-service and then display the results. This can be done through a script in a groovy/bsh file similar to the following:

...

The code above will, once called, affectively parse a url defined as contentUrl to the service and return the result, so that you can display it on your site. For instance, if you wish to display the content located at http://localhost:8080/cmspublic/main.htmlImage Removed in your freemarker template file (.ftl) you will need to call the function getContentFromUrl in a way similar to this at the end of your groovy file and add the results to the context:

...