Nội dung chính
Tùy biến trang đăng nhập không cần Plugin cho WordPress: Trên mạng có rất nhiều Plugin để bạn tùy biến trang đăng nhập cho WordPress và trên Thạch Phạm cũng có hướng dẫn tùy biến nhưng lại bằng plugin.
Mình thì không thích dùng Plugin cho lắm nên hôm nay rảnh mình tùy biến trang đăng nhập không cần Plugin cho WordPress, chia sẻ cho anh em nào cần nhé.
Tùy biến trang đăng nhập không cần Plugin cho WordPress
Để có thể tùy biến trang đăng nhập không cần Plugin cho WordPress trong hướng dẫn này của mình thì các bạn sẽ tùy chỉnh trong file Function của theme bạn đang dùng.
Lưu ý: Bạn nên sao lưu lại file function của bạn trước nhé, tránh trường hợp bị lỗi cấu trúc web nhé.
# Thêm Action trong Function
Đầu tiên bạn phải khai báo chức năng để nó kết nối với trang đăng nhập của WordPress
add_action('login_head', 'change_my_login_page');
# Thêm Css tùy biến trang đăng nhập
Sau khi bạn đã thêm Action tiếp theo là bạn bắt đầu làm đẹp cho trang đăng nhập. Các bạn show code trang đăng nhập WordPress ra và bạn kiểm tra xem bạn muốn thay đổi những đoạn nào
Ví dụ Css trên trang của mình luôn, các bạn tham khảo và thay đổi cho phù hợp với Blog của bạn nhé
function change_my_login_page() {
echo '<style>
body {
background-image: url("https://f4vnn.com/wp-content/uploads/2021/01/bg-image.jpg");
-webkit-background-size: cover !important;
background-size: cover !important;
font-family: "Tahoma", Arial;
}
.login h1 a {
background-image: url("https://f4vnn.com/wp-content/uploads/2021/01/f4vnn-logo-min.png");
-webkit-background-size: cover !important;
background-size: cover !important;
height: 80px;
width: 390px;
}
.login form {
background-color: rgba(255,255,255,0.14);
font-weight: 700;
width: 330px;
max-width: 330px;
}
.login label {
text-align: center;
color: #fff;
line-height: 2.5;
margin-bottom: 5px;
}
#login form p {
text-align: center;
}
.login * {
text-align: center;
}
.login form .input, .login form input[type=checkbox], .login input[type=text] {
background-color: rgba(255,255,255,0.14);
color: #fff;
}
.login #backtoblog a, .login #nav a {
color: #fff;
}
.login #nav {
text-align: left;
}
.login #backtoblog, .login #nav {
text-align: left;
}
.login .privacy-policy-page-link {
text-align: left;
}
.login #login_error {
width: 352px;
max-width: 352px;
}
.login #login_error, .login .message, .login .success {
width: 352px;
max-width: 352px;
}
</style>';
}
Kết luận
Sau khi đã tùy biến xong thì lưu lại và xóa cache để tận hưởng thành quả của mình nhé. Hy vọng bài viết tùy biến trang đăng nhập không cần Plugin cho WordPress mà Blog thủ thuật máy tính f4vnn đã chia sẻ sẽ có ích với bạn. Chúc bạn thành công.
Bài Viết Cùng Chuyên MụcGame & Apk Mod Acapella Việt Template BLogspot Liên Kết URL
Welcome to f4vnn.com: là một web/blog cá nhân, chủ yếu chia sẻ kiến thức về máy tính, internet, công nghệ và thủ thuật WordPress, Blogger... Mình hi vọng một điều là: Tại đây, các bạn có thể học thêm được rất nhiều kinh nghiệm và thủ thuật khi sử dụng máy tính ^_^
ĐỪNG QUÊN ĐĂNG KÝ FANPAGE ĐỂ NHẬN THỦ THUẬT MỚI NHẤT NHÉ!
I just like the valuable information you provide in your articles.
I’ll bookmark your blog and take a look at again right here regularly.
I’m slightly certain I’ll learn many new stuff right here!
Best of luck for the following!
I am in fact pleased to read this weblog posts which contains tons of
helpful information, thanks for providing these
statistics. https://parbriz-auto-bucuresti.ro/parbriz-bmw-x5.html
This site truly has all of the information and facts I wanted concerning this subject and
didn’t know who to ask. https://parbriz-auto-bucuresti.ro/parbriz-volvo.html
Hello to all, how is all, I think every one is getting more
from this web page, and your views are fastidious in favor of new people. https://parbrize-originale.ro/parbrize-originale/parbriz-originale-volkswagen-transporter_iii-1980-124941.html
Hello i am kavin, its my first time to commenting anyplace, when i read this
paragraph i thought i could also create comment due to this
brilliant piece of writing. https://parbrize-originale.ro/parbrize-originale/parbriz-originale-opel-kadett_estate-1984-2996.html
Ahaa, its nice dialogue concerning this post here at this webpage, I have read all that, so at this
time me also commenting at this place. https://anunturi-parbrize.ro/parbriz-peugeot-52.html
This website was… how do you say it? Relevant!! Finally I have found something
which helped me. Thanks a lot! https://parbrizeladomiciliu.ro/luneta-mercedes-slr.html
Can you tell us more about this? I’d like to
find out more details. https://parbrize24ore.ro/oferta-parbrize.php?an=2010&produs=coltar&marca=FORD&model=KUGA+I+&foto=parbriz-ford.png
Hello, I want to subscribe for this blog to get most recent
updates, therefore where can i do it please help. https://parbriz-auto-bucuresti.ro/parbriz-opel.html
I loved as much as you’ll receive carried out right here.
The sketch is attractive, your authored material stylish.
nonetheless, you command get got an nervousness
over that you wish be delivering the following. unwell unquestionably come
further formerly again as exactly the same nearly very often inside case you shield
this hike. https://parbriz-auto-bucuresti.ro/parbriz-citroen-jumpy.html
I am extremely impressed with your writing skills as well
as with the layout on your weblog. Is this a paid theme or did you modify it yourself?
Anyway keep up the nice quality writing, it is rare
to see a great blog like this one these days. https://anunturi-parbrize.ro/parbriz-volkswagen-72.html
Thank you, I have just been looking for information approximately this topic
for a while and yours is the best I have came upon so far.
But, what concerning the conclusion? Are you certain about the
supply? https://anunturi-parbrize.ro/parbriz-fiat-22.html
Genuinely no matter if someone doesn’t know afterward its up to other
people that they will help, so here it happens. https://anunturi-parbrize.ro/parbriz-dodge-20.html
Hi there, everything is going fine here and ofcourse every one is sharing data, that’s really good, keep up writing. https://parbriz-auto-bucuresti.ro/parbriz-audi-r8.html