1

내가 트위터 부트 스트랩 3.0.x의Orchard 테마에 Glyphicons 글꼴을 포함시키는 방법은 무엇입니까?

를 사용하여 과수원 테마에서 일하고 있어요 나는 MyTheme/스크립트 & MyTheme/스타일에 모든 스크립트와 스타일을 추가했다. Glyphicons 이미지를 제외한 찾기 기능이 작동합니다.

CSS 파일에서 상대 경로 (../fonts/ glyphicon .....)를 사용하여 아이콘을 참조합니다. 그래서 모든 글리 phicons 파일을 포함하는 MyTheme/fonts를 만들었습니다. 그러나 찾아 볼 때 파일을 찾을 수 없습니다 (404). 예를 들어

, 나는 소스 코드를 탐색 할 때 :

http://localhost:9100/Themes/MyTheme/Scripts/bootstrap.js -> OK 
http://localhost:9100/Themes/MyTheme/Styles/bootstrap.css -> OK 
http://localhost:9100/Themes/MyTheme/fonts/glyphicons.. -> KO 

어떤 생각을 그렇게하는?

+0

이 질문은 일반적인 설명이 필요하다고 생각합니다. –

답변

2

나는 이것이 늦었다 고 알고 있지만 어쩌면 다른 사람들에게 도움이 될 것입니다. 이처럼 보이는 내용 폴더에있는 글꼴 폴더를 두어야 :이 후

http://localhost:9100/Themes/MyTheme/Content/fonts/ 

당신은 당신의 bootstrap.css 파일 외장 CSS에 덮어 쓰고 Glyphicons의 @ 글꼴 얼굴을 bootstrap.min.css한다. 다음과 같이 상대 :

@font-face{ 
    font-family:'Glyphicons Halflings' !important; 
    src:url(../Content/fonts/glyphicons-halflings-regular.eot) !important; 
    src:url(../Content/fonts/glyphicons-halflings-regular.eot?#iefix) format('embedded-opentype'), 
     url(../Content/fonts/glyphicons-halflings-regular.woff) format('woff'), 
     url(../Content/fonts/glyphicons-halflings-regular.ttf) format('truetype'), 
     url(../Content/fonts/glyphicons-halflings-regular.svg#glyphicons_halflingsregular) format('svg') !important 
} 

과수원이 컨텐츠 폴더 외부 글꼴 등의 콘텐츠를하지 않는 것 같습니다.

관련 문제