cancel
Showing results for 
Search instead for 
Did you mean: 

How to use custom css for html file in KM

Former Member
0 Kudos

Hi,

Have created a new HTML file in KM.

would like to use my own css for this....

tried uploading the css file in KM and additing it to the HTML like

<link href="/irj/go/km/docs/wpccontent/CoPT_PWS/site/site/styles/cochin-port.css" rel="stylesheet" type="text/css" />

however this is not working..

Do i have to use repository filters for this..?

Please advise

Thanks,

Rocky

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

No, you've got the right idea.

Here's some same code (header) that's works fine:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<link href="/irj/go/km/docs/documents/Public%20Documents/Employee%20Self%20Service/css/default.css" rel="stylesheet" type="text/css" />

<title>Annual Data Review Introduction</title>

</head>

Former Member
0 Kudos

Hi Kevin,

this is not working...

anything extra i need to add.?

Former Member
0 Kudos

Hi,

Please try to copy the css file in the same folder as of html and check whether it is working. Only use css file name in link href. If it is working fine check the permission of css repository folder.

Regards

Baby

Former Member
0 Kudos

Hi there,

I've found that if I put a css file and images in the same folder (or as a sub-folder) as the KM documents (mine are in Public Documents > Employee Handbook) then it all works fine from within KM: I can navigate to the web pages and the styles and images show up properly.

But if I make KM Document iViews and put them into Portal pages and those into a role, then to get the links to css files and images working I have to use the long link, e.g. /irj/go/km/docs/z_cmpublicdocuments/Employee Handbook/

Tom