cancel
Showing results for 
Search instead for 
Did you mean: 

how to link external css file in magento static block admin ?

how to link external css file in magento static block admin ?

how to link external css file in magento static block admin ? 

3 REPLIES 3

Re: how to link external css file in magento static block admin ?

Hello @bharath553

You can try this for linking external css

<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
    <head>
        <css src="css/mycustom.css" after="-" />
    </head>
</page>

Problem solved? Click Kudos & Accept as Solution!

Re: how to link external css file in magento static block admin ?

Hi @bharath553

 

You want to link css from external link ? so css loaded on some another domain or server ?

if issue solved,Click Kudos & Accept as Solution

Re: how to link external css file in magento static block admin ?

  1. For add External Css
    <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
        <head>
            <css src="http://externalcss/external.css" src_type="url"/>
        </head>
    </page>
  2. For Add External Js
    <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
        <head>
            <script src="http://externaljs/external.js" src_type="url"/>
        </head>
    </page>

 

For more reference Check this

 

If issue solved,Click Kudos & Accept as Solution  

If Issue Solved, Click Kudos/Accept As solutions.