I have installed Mozilla Firefox 3.6 Beta 2 and enjoying using it. Its ‘persona’ feature is really cool! With one click you can install and use it. When you visit persona section you get a lots of personas so far. Take you mouse over the persona image, and your browser’s look is changed! What a live preview. Other changes to Firefox are not that much visible. I am fan of Firefox and using it for more than 2 years. In fact, I have not installed and tried IE8, after using Firefox. You can get the beta of Firefox 3.6 from here: http://en-us.www.mozilla.com/en-US/firefox/3.6b2/releasenotes/. Have a look at it.
In this two-part article , we are going to use Flash for decorating our Joomla! site. On completion of this article you will be able to use:
Flash-based templates for your Joomla! website
Flash logos
Flash headers
Flash banners
In this article, we will mainly focus on the visual design of our site. To acquire the information presented here, it is assumed that you have some basic understanding of Joomla!’s visual design including templates, components, module position, and so on.
Adding Flash in templates
If you are familiar with Joomla! templates, then you will understand that there are two ways to display Flash in a template:
By hardcoded embedding of Flash items
By dynamically loading Flash objects at module positions
We have seen many modules that can display Flash objects. Therefore, in this section, we will be looking into the embedding of Flash objects within templates. It will also be helpful if we understand the structure of Joomla! templates.
Generally templates for Joomla! include headers in Flash. Flash animations are included in the header area of a Joomla! template. Some templates include the mechanism to show images from a specific directory. For example, the template shown in the following screenshot, available for download at http://joomlatp.com/joomla-1.5-templates/Templates-has-flash-header.html, is designed to show a Flash header comprised of the images kept in a directory:
The following sections briefly describe the structure of a Joomla! template and the ways to embed a Flash object in this template.
Structure of a Joomla! template
The look and feel of Joomla! is determined by templates. You can apply a template to the frontend as well as to the backend. Templates for the Joomla! frontend reside in the /templates directory of the Joomla! webroot, while those for the administration panel are found in the /administrator/templates directory. You can install multiple templates and apply one or more templates to the different sections. However, you must designate one default template for the site.
To designate a default template, go to Extensions | Template Manager. Select the desired template and click on the Default button on the toolbar. For assigning a template to a specific section of the site, click on a template, except the default template, and then select the section or the menu item for which you want to assign the template from the Menu Assignment section.
If you examine the directory structure of a Joomla! template, you will find at least the following subdirectories in the templates directory:
Directory
Description
mx_joofree2
This is the main template directory. It contains some subdirectories and at least the following files under its root:
•index.php: This is the main file for a template. The basic structure of a Joomla! template is defined in this file. We will examine this file later.
•templateDetails.xml: This XML file defines the template by mentioning its designer, the different files bundled with it, the positions and parameters available, and so on.
•params.ini: This file contains the parameters and their default values. For example, a template may use several colors for theming, but users can select a preferred color as a parameter for this template, and that information is stored in this file.
mx_joofree2/css
This directory contains all the cascading stylesheets to be used for a Joomla! site. This directory will contain at least one stylesheet namedtemplate_css.css. It may also contain a stylesheet namedtemplate_ie6.cssand other stylesheets.
mx_joofree2/html
This folder may contain some definitions for the custom rendering of certain parts of the site. For example, themx_joofree2template contains two files—module.phpandpagination.php. These two files define custom module rendering and pagination for Joomla!. For more information on using HTML overrides, refer tohttp://docs.joomla.org/How_to_override_the_content_from_the_Joomla!_core.
mx_joofree2/images
This folder contains the images for the template. It may contain a logo image, a background image, and so on. It may also contain some subdirectories, for example, themx_joofree2template contains a subdirectoryimages/headers, where the header images for the template are stored.
Joomla! with Flash
Build a stunning, content-rich, and interactive web site with Joomla! 1.5 and Flash CS4
Build an attractive web site integrating Flash objects into Joomla!
Create stunning photo galleries with Flash transition and animation effects
Use interactive Flash-based maps, charts, animations, videos, MP3 players, logos, headers, and banners in Joomla!-based web sites
Turn your Joomla! web site into a feature-rich multimedia enhanced site through this step-by-step easy-to-follow guide enriched with screenshots
As you know, the main structure of a Joomla! template is defined in the index.php file. The file looks as follows:
<?php // no direct access defined( '_JEXEC' ) or die( 'Restricted index access' );
This line of code is to prevent direct access to the file. This is a convention to prevent direct access to any file in Joomla!. After this, the following lines define some variables for the template that will be used later on in the template:
Whatever is included after the following lines will be considered as included in the <head> section. Generally, stylesheets, JavaScript, and site-wide files are included in a template’s <head> section with the following lines:
The following block checks whether any module for position user4 is enabled. If the count of enabled modules is greater than zero, then a <div>element with an ID search is displayed, and modules specified for position user4 are displayed as children of this <div> element:
Having placed the modules for the position user4, the following block now defines where to show the site’s logo. This block of code dynamically selects the site’s logo and links that to the site’s home page:
This code block first checks whether the variable for showing a Flash header is checked or not. If it is checked, then a <div> element will be created, under which the Flash object is embedded using the tags.
The following code block is used to display the current date on the site:
The following block defines another module position. Modules designated for the user3 position will be displayed here. Note that modules are included with the <jdoc:include type=”modules” name=”position-name” /> markup:
The following code block displays another module called breadcrumbs. First, it checks whether the parameter is set to show breadcrumbs or not. If it is, then the breadcrumbs module will be displayed in the block:
<?php if ($show_breadcrumbs == "true") : ?> <div class="path"> You are here: <jdoc:include type="module" name="breadcrumbs"/> </div> <?php endif; ?>
The next code block counts the number of modules available for the user1 and user2 positions and then includes the modules designated for these two positions. Note the highlighted line of code in this code block. It shows the component currently selected:
All this code in the index.php file when rendered with template_css.css and other stylesheets will display a layout like the one shown in the following screenshot:
In a Joomla! template, the site’s data comes from the database and fits in different positions. When you are planning for Flash-based Joomla! templates, you should first identify where to put the Flash objects and where to display the dynamic data for the site. In the template layout, we have seen that a suitable place for adding a Flash object are the logo and the header positions. We can also use some extensions to display Flash headers. The following sections explain how to use extensions for showing Flash logos and headers.
Using Flash logos
You can replace the ordinary image with Flash-animated logos by embedding it in that position. As we have seen earlier, Flash objects are embedded in Joomla! templates using the XHTML element. For styling purposes, you may put this element under a <div> element, as shown in the following code:
As you can see, the tag can contain child elements. We pass parameters to the Flash objects using the <param> element. For example, we have passed the name of a movie file using the highlighted tag in the previous code.
Some of you may already know about the SWFObject JavaScript library. It is used to embed Flash files using JavaScript. You can also use it to embed Flash objects in Joomla! and can also generate Flash objects. It is freely available at http://code.google.com/p/swfobject/. Brief documentation on its usage is also available there.
Zen Cart: E-commerce Application Development by Suhreed Sarkar
There are various types of Content Management Systems (CMS) which are widely used for building and managing a website. Although Zen Cart is very good for running an online shop, it cannot be used for building a company website. Your organization may have a website running a CMS, and as you are going to open an online shop, you may need to integrate Zen Cart with that existing CMS. In my book Zen Cart: E-commerce Application Development, I have added an chapter of integrating Zen Cart with several popular content management systems.
The publisher of my book, Packt Publishing Limited, has kindly made this chapter available to public. You may like to have a look at it and find your solution for building a shopping application which can be integrated with your existing CMS. Check the article at http://www.packtpub.com/article/integrating-zen-cart-with-content-management-systems.
আপনার নিকট ফিডোরা লিনাক্স ডিভিডি থাকলে সেখান থেকে বিভিন্ন প্যাকেজ ইনস্টল করতে পারবেন yum এর সাহায্যে। এজন্য ডিভিডি ড্রাইভে ডিভিডি ঢুকিয়ে দিন। তারপর localinstall অপশনসহ yum কমান্ড চালান। ধরা যাক আপনি যে ডিভিডি প্রবেশ করিয়েছেন তা /media/Fedora লোকেশনে মাউন্ট হয়েছে। তাহলে সেই ডিভিডি থেকে কোনো প্যাকেজ ইনস্টল করার জন্য কমান্ড হবে নিচের মতো:
# yum localinstall /media/Fedora/Packages/aspell-it-*
Loaded plugins: refresh-packagekit
Setting up Local Package Process
Examining /media/Fedora/Packages/aspell-it-2.2_20050523-3.fc11.i586.rpm:
50:aspell-it-2.2_20050523-3.fc11.i586
Marking /media/Fedora/Packages/aspell-it-2.2_20050523-3.fc11.i586.rpm
to be installed
Resolving Dependencies
--> Running transaction check
---> Package aspell-it.i586 50:2.2_20050523-3.fc11 set to be updated
--> Processing Dependency: aspell >= 12:0.60 for package: aspell-it
--> Running transaction check
---> Package aspell.i586 12:0.60.6-5.fc11 set to be updated
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================
Package Arch Version Repository Size
================================================================================
Installing:
aspell-it i586 50:2.2_20050523-3.fc11
/media/Fedora/Packages/aspell-it-2.2_20050523-3.fc11.i586.rpm
2.0 M
Installing for dependencies:
aspell i586 12:0.60.6-5.fc11 fedora 947 k
Total size: 3.0 M
Total download size: 947 k
Is this ok [y/N]: y
উপরের কমান্ডে আমরা aspell-it প্যাকেজ ইনস্টল করতে বলেছি। শেষে * চিহ্ন ব্যবহার করায় একাধিক প্যাকেজ ইনস্টল হতে পারে। একদম নির্দিষ্ট কোনো প্যাকেজ ইনস্টল করতে চাইলে সেই প্যাকেজের নাম হুবহু উল্লেখ করতে হবে। এজন্য আগেই ডিভিডি থেকে সেই প্যাকেজের নাম দেখে নেয়া ভাল।
এভাবে লোকাল ডিভিডি থেকে yum এর মাধ্যমে ইনস্টল করার সুবিধা হলো এর ফলে yum সেই প্যাকেজের নির্ভরশীলতা যাচাই করে দেখবে এবং প্রয়োজনমতো সেগুলো প্রথমে ডিভিডিতে ও পরে অন্যান্য রিপজিটরিতে খুঁজে দেখবে। প্রয়োজনমতো সুবিধাজনক রিপজিটরি থেকে সেই প্যাকেজ ডাউনলোড ও ইনস্টল করা হবে।