O'Reilly logo

Mastering Joomla! 1.5 Extension and Framework Development by Chuck Lanham, James Kennard

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Assets

It is common to want to include additional assets in our extensions. Assets are normally media. An example would be image files. This is a list of common files that we might classify as assets:

  • JavaScript
  • Image
  • Cascading Style Sheet
  • Video
  • Flash

We deal with asset files in two common ways.

We can use the media tag in our extension XML manifest files to add assets to the Joomla! Media Manager. This is ideal if we want to allow users the right to modify the assets.

Within the media tag, we must detail each file that we intend to add. Unlike copying extension files, we cannot define folders that we want to copy into the Media Manager.

This example demonstrates how we can copy two images, foo.png and bar.jpg, from a folder in the extension archive named ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required