vistasucks
Forum Replies Created
-
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…Can you point me to them? I’ve tried checking here:
https://www.ads-software.com/extend/plugins/search.php?q=securForum: Fixing WordPress
In reply to: Can someone help me hide the sidebar based on login status?Ok I did that and at first it appeared to work. I logged in as a regular user to see if the sidebar became visible but I got a badly distorted site and the error:
WordPress database error: [You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ‘) ORDER BY post_date
DESC LIMIT 0, 10′ at line 1]
SELECT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts WHERE 1=1 AND (post_type = ‘post’ AND (post_status = ‘publish’ OR post_author = 9 AND post_status = ‘private’)) AND ID NOT IN () ORDER BY post_date DESC LIMIT 0, 10Although if I click a page link the site looks normal again. Clicking a month in archives returns the page to the distorted version again.
I logged out and then logged back in as admin. when I viewed the site it looked normal but with no sidebar. Clicking on a page link makes the sidebar visible again after the new page loads. Click home takes the sidebar away again.
Forum: Fixing WordPress
In reply to: Can someone help me hide the sidebar based on login status?will that show the sidebar to a logged in user though? I only want to hide from those that aren’t logged in.
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…Can you paste your entire index.php file in and not just that one bit?
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…This is not working. Clearly we have some kind of communication problem.
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…Please just spell it out for me!!!
This is what I have (based on my understanding of what you’ve told me.)
index.php :
<?php get_sidebar(); ?> <!-- This is my test code to keep the sidebar hidden unless use is logged in. --> <? get_currentuserinfo() ; global $user_level; if ($user_level > 0) { echo "use get_sidebar();"; } else { no } ?> <!-- This is my test code to keep the sidebar hidden unless use is logged in. --> <?php get_footer(); ?>
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…I tried adding the above code into index.php in my theme folder in between
<?php get_sidebar(); ?>
and
<?php get_footer(); ?>
I tried modifying
echo "yes";
into
echo "sidebar";
and
echo "sidebar.php";
but that gave me errors. What am I doing wrong?
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…Thanks Kahil. But can you tell me which .php file in which directory that code goes into? Is it the index.php or the sidebar.php in my chosen theme folder?
Am I understanding right that the line would be something like:
echo "sidebar";
or
echo "categories";
with ‘ where the ” are?
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…I want to keep both posts and sidebar widget contents invisible until the user is logged in. Thus preventing unauthorized viewing of sensitive info. Currently the WP installation dir is pw protected but would rather it be WP’s login that protects the site’s contents.
My category’s posts are already protected via a plugin but I don’t want the sidebar contents (comments, category names etc.) to be visible either.
Forum: Fixing WordPress
In reply to: Hiding more than just post content unless admin…I agree someone should make a plugin.
I’m a total php newb and am reading instructions that assume a certain level of knowledge.
Can someone talk me through adding this code?
Forum: Fixing WordPress
In reply to: Making a sidebar detect login show different menuthx
Forum: Fixing WordPress
In reply to: Making a sidebar detect login show different menuAnyone?
Forum: Fixing WordPress
In reply to: Making a sidebar detect login show different menuor is there already?
Forum: Fixing WordPress
In reply to: can I hide categories?Already have that installed. Works fine.
But the sidebar listings still shows the categories existing even if you can’t view the contents of them.
ie: I wouldn’t want Bob to see a category named “Things I hate about Bob” even if he can’t see or read the posts in that category.
Forum: Fixing WordPress
In reply to: Making a sidebar detect login show different menudeleted