Sidati
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Hide page from non logged in usersPlease checkout this link to understand the concept of “Page template” ;),
TMALSS; you need to create new php file in your current theme and put that code in it and save it, then from the admin dashboard go to edit the page you want to protect and choose the template you just created.
Forum: Fixing WordPress
In reply to: Dashboard error 404 not foundTry this
Forum: Fixing WordPress
In reply to: Hide page from non logged in usersHi @nikkiapt,
For multiple pages use, i suggest to create a template page like so :<?php /** * Template Name: Protected page */ get_header(); ?> <?php if is_user_logged_in() : ?> <article> <h1><?php the_title() ?></h1> <div><?php the_content() ?></div> </article> <?php else : ?> <p><?php _e('Sorry! Only logged-in users are allowed to see the content'); ?></p> <?php endif ?> <?php get_footer(); ?>
Then every page you want to make it protected, just assign this template to it, check out this link
Forum: Fixing WordPress
In reply to: How to delete cache from other peoples browsersTry to add this code at the top of your
index.php
file, this will force the browser to get the new version since the expiration date was already passed16 May 1990
My birthday :p<?php header("Cache-Control: no-cache, must-revalidate"); header("Expires: Wed, 16 May 1990 00:00:00 GMT"); ?>
But this make the browser clear the cache every time, so add for 24 hours to be sure all your users are “cache cleared” then remove it ??
- This reply was modified 7 years, 6 months ago by Sidati.
Forum: Developing with WordPress
In reply to: Remove ‘my site’ with dashbord in admin barOK, there are 2 options.
Option #1
if you want to disable the whole admin bar for all users then just add this line to your
functions.php
file :add_filter('show_admin_bar', '__return_false');
Options #2
if you want just hide the site name ad keep the admin bar, then hide it with CSS is simplest way :P, add this code to yourstyle.css
file#wp-admin-bar-site-name { display:none !important;}
Hope this help ??
Forum: Fixing WordPress
In reply to: Instagram Images Aren’t Displayed Properlydoes all pictures are like this ??
Forum: Fixing WordPress
In reply to: Making the backend look like part of your main site?You need to do A LOT OF WORK to reach that and its not good idea, if you want to create a custom back-end just create new one on the front-end, it will be mush easier than re-design the old one and add just what you need.
I got tired of just thinking about it ??
Forum: Fixing WordPress
In reply to: Instagram Images Aren’t Displayed ProperlyIts your theme :(,
You can fix it with copy/paste this code on your style.css.video-container { height: auto !important; display: block !important; padding-top: 0 !important; } .video-container iframe { height: auto !important; position: static !important; }
Forum: Fixing WordPress
In reply to: Weird Media Library image preview problemDid you check if your new hosting is supporting GD library
php-gd
, its a php extension ??Forum: Fixing WordPress
In reply to: Switch to WordPress.comForum: Fixing WordPress
In reply to: I want only one category on my front page but it will not displayGlad you figured it out
Forum: Fixing WordPress
In reply to: Please help with Multiple linked thumbnailsYou’re welcome
Forum: Fixing WordPress
In reply to: One wp to a new wp same server migrationYou’re welcome @mcdrewblue
Forum: Fixing WordPress
In reply to: I want only one category on my front page but it will not displayMmmmh!! can you please activate the default theme and tell us if the issue still exist ??
Try to deactivate all plugins and delete your
.htaccess
then go to :
Dashboard -> settings -> Permalinks -> click Save Changes, and see if its working.if so try to activate plugins one by one and every time you activated a plugin see if pages still working so you can locate the “bad plugin.