Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

How to add an external javascript or css file to magento?

Answer Posted / Lakhpat Ram

To include an external JavaScript or CSS file in Magento, you can use the following methods:n1. Using layout XML files: Add a reference to the script/stylesheet in the appropriate layout handle. For example, for CSS files, add it inside `<head>` tags within your theme's `local.xml` or `page_html.xml`. For JavaScript files, use `<action method="insertPhtmlBeforeBodyEnd">`.n2. Directly in your pHTML file: Add the script tag to your custom pHTML file.nFor example for CSS:n```n<link rel="stylesheet" type="text/css" href="your_url.css">n```nFor JavaScript:n```n<script src="your_url.js"></script>n```

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Which is the latest version of magento?

2