I am new to wordpress development and now I am stuck.
I need to change style and add some buttons in default wordpress logout template (when i am redirected to http://example.com/wp-login.php?action=logout ).
But the question is where i can find that template?
Thanks in advance.
Regards.
Ivelin Georgiev
Right...
There (unfortunately) isn't a template page for the login page. I'm not sure why this is, maybe its for security or something, I dunno. In any case you can't edit it directly without messing with the wordpress core.
However there are various hooks and actions you can add to in order to do some customisations. Here is some sample code from my own applications:
// this adds stuff to the head. You can add a stylesheet
// if you want, or just css like I have.
add_action("login_head", "cust_login_head");
function cust_login_head()
{
// this just changes the logo
?>
<style>
body.login #login h1 a {
background: url('<?=plugins_url('images/logomed.png',__FILE__)?>') no-repeat scroll center top transparent;
height: 64px;
width: 307px;
margin-left: 10px;
}
</style>
<?php
}
// these change the default links from wordpress to whatever you want
add_filter('login_headertitle', create_function(false, "return 'http://website.com';"));
add_filter('login_headerurl', create_function(false, "return 'http://website.com';"));
Stick that into your functions.php file in your theme to get it to work.
There will be other such methods and hooks you can change and add to, you just need to find them.
Use Themed login plugin - It allows to make login and registration process themeable using site's theme.
Related
I have a WordPress website and in my website I have two fields for which I want to write a condition with CSS that if the user is logged in, the field will be displayed, otherwise it will not be displayed.
thanks for your help..
Check for this class in the body tag:
.logged-in
It's a class Wordpress will add if someone is logged in. Note that not all themes may support this.
Then, use that in your css selector:
.logged-in #my-div { display: block } //or whatever display you want
I am building a website (using Wordpress, Neve theme and Elementor Pro) with teaching resources for teachers, under the picture of each resource I want to place a download button with the URL link to download the resource, is it possible to make this download button with the link only accessible to logged-in users using Custom CSS or what would be the easiest way to do this?
In WordPress, you would probably have to use something like this:
.your-button {
display: none;
}
.logged-in .your-button {
display: block;
}
Please notice that the button is only visually hidden and could still be accessed via the dev tools.
It's not safe to use CSS, or anything on the frontend to hide the download button if it's important that for example students cannot get at the resources/answers.
In the backend you can add this where you are creating the button:
if ( is_user_logged_in() ) {
... the code outputting the download button and info ...
}
I'm newbie in wordpress. I got website: http://xn--lnepengerprivat-hlb.com/ and on homepage (it's page, not a post!) I've got Last Update date. How to delete it? Please help me
Add this css in your style.css or find in your theme file and remove the php code.
.page-last-modified {
display: none;
}
You could hide the page post date by using CSS, either in a styles.css file or in the custom CSS editor of WP Customizer.
.page-last-modified {
display: none;
}
Another solution would be to delete the whole block in the page template file of your child theme.
Hi I'm trying to to remove gravatar completely for my website. I've already disabled gravatar on the discussion page setting of wordpress. However, I'm using a paywall plugin which uses gravatar (called memberful) and its account popup always shows the profile avatar regardless if its disabled or not on the discussion page.
Example:
I think the profile-window is actually an iframe...
To here: https://dylogue.memberful.com/account/subscriptions
Do you have access to this endpoint, or is it created by a script? Changing the general CSS wont help you if you do not have access to inserting css into this endpoint.
The stylesheets are in weird places:
https://d1zgk03a9fsd43.cloudfront.net/assets/reach/style-4556bac86321e164130eb81bc9c1bd3e8ad4f00e3a7f1b803ef1e7e272baf184.css
https://d1zgk03a9fsd43.cloudfront.net/packs/member-bafbfb186fc0b252fb994416a369b793.css
I didn't see the link to create an account and test this, but does this CSS work?
.memberful-account-header img {
display: none;
}
.memberful-account-header hgroup * {
margin-left: 0 !important;
}
I have purchased MasterStudy theme for my website and It doesn't have a template with no header or footer to create a landing page. My question is: how can I create a page with such template via its child theme and use visual composer to add the content? Is this possible?
Not sure if I completely understood your situation, but I'll try to help anyway.
Have you checked all the Theme Options? Sometimes you can easily delete the footer and header through the Theme Options. In case you have and there's not an option to do so, the smart move would be to create a custom page to fit your needs. You'll find some information about how to do so right here http://www.wpbeginner.com/wp-themes/how-to-create-a-custom-page-in-wordpress/
Remember that the visual composer only edits the content of the webpage per se, meaning, it can't modify the template structure (footer and header in this case).
Hope it helps!
Actually, the solution is much more simple than I thought. I resolved it by adding custom CSS to hide the header and the footer of the page by mentioning Its ID. Here is the Code I used >>
.page-id-2114 #header {
display: none;
}
.page-id-2114 footer {
display: none;
}