- 한글 워드프레스 : 지원 (wordpress.com)
- 워드프레스 디벨로퍼 : Functions | WordPress Developer Resources
블록 사용법 등의 기본적인 내용은 한글 지원에 거의 내용이 다 있고, 리소스 수정할 때 php 함수 등 찾아볼 때는 디벨로퍼 사이트에서 검색하면 나온다.
일단 나는 카테고리를 눌렀을 때 상단에 ‘카테고리 : 일상’ 이런 식으로 나오는 걸 ‘일상’ 만 나오게 하거나 아예 없애고 싶었는데. 없애려면 archive.php 에서 the_archive_title 함수를 찾아 아래 디스크립션까지 같이 날려주면 아예 없어지고, 일상만 나오게 하려면 워드프레스 자체의 php 함수가 정의 되어있는 wp-includes/general-template.php 로 들어가서 해당 함수의 ‘category :’ 를 날려주면 된다. 함수 검색할 때 옵션 및 폴더 위치 까지 다 알려준다.
하단 소셜 링크는 링크에 따라 아이콘이 자동 생성됨. secondary menu에서 조정할 것. 메일은 mailto:
블록 생성시 양쪽 2개로 나뉘는 컬럼 생성후 겹치는 설정 아래 위로 공백 넣어줘서 간격 조정
.archive header span {display:none;}
function prefix_category_title( $title ) {
if ( is_category() ) {
$title = single_cat_title( '', false );
}
return $title;
}
add_filter( 'get_the_archive_title', 'prefix_category_title' );
.category .page-header {
overflow: hidden;
}
.category .page-title {
margin-left: -4.7em;
}
function my_theme_archive_title( $title ) {
if ( is_category() ) {
$title = single_cat_title( '', false );
} elseif ( is_tag() ) {
$title = single_tag_title( '', false );
} elseif ( is_author() ) {
$title = '<span class="vcard">' . get_the_author() . '</span>';
} elseif ( is_post_type_archive() ) {
$title = post_type_archive_title( '', false );
} elseif ( is_tax() ) {
$title = single_term_title( '', false );
}
return $title;
}
add_filter( 'get_the_archive_title', 'my_theme_archive_title' );
