Forum Replies Created
-
AuthorPosts
-
February 5, 2019 at 12:57 pm in reply to: Custom post type protection not working? Plugin has been installed #17277
tombyrom
ParticipantSorry now I can’t access those pages as an administrator so we can’t check the content on the front end?
I had a look in settings but cant find a way of allowing this?
What would you suggest?
Thanks
February 5, 2019 at 12:42 pm in reply to: Custom post type protection not working? Plugin has been installed #17276tombyrom
ParticipantThanks for response
Yes I was referring to the first addon you posted.
I just tried the second addon ‘full page protection’ and it now works like a charm.
Not sure why but glad its now fixed!
Thanks
TomSeptember 4, 2016 at 1:22 pm in reply to: Login re-directs to homepage, need to just refresh current #8146tombyrom
ParticipantOk so I’ve managed to get my work around working using this:
<a href="http://mysite.co.uk/membership-login/?swpm_redirect_to=<?php echo get_permalink( $post->ID ); ?>">Log in</a>So I will now show a log in link and then redirect back to the page I was trying to access.
The reason I have hard coded everything in is because we only have one membership level and there will be lots of different custom posts, this way I protect everything including archives, taxonomies, single post, pages. Just makes life easier… and means the client doesn’t have to remember to protect everything they upload. It’s all automated
September 4, 2016 at 1:02 pm in reply to: Login re-directs to homepage, need to just refresh current #8143tombyrom
ParticipantI had already checked this page, nothing in it helps in my situation. Any other ideas?
What code would I need to add the swpm_redirect_to query parameter to my own link so it redirects to the current/last page?
Just found out as well that using the normal way of protecting posts/pages doesn’t seem to work with custom page templates?
Is this correct? As it only works on default page templates any I have created its doesn’t stop people from accessing them…even when its check to protect them.
Thanks
September 4, 2016 at 8:27 am in reply to: Is it possible to add my wordpress admin user account to a membership level? #8134tombyrom
ParticipantPS. Or just use this plugin it allows you to add multiple roles to a user account, so admin and member
https://wordpress.org/plugins/user-role-editor/
EDIT:
Just be sure to create a new user as you can’t change or add more capabilities to the admin account you are logged in as… weirdly
September 4, 2016 at 8:18 am in reply to: Is it possible to add my wordpress admin user account to a membership level? #8133tombyrom
ParticipantI would also find this helpful.
A workaround that I’ve yet to do is create a membership level with the role of admin call it ‘super admin’ create a new a new member/account and use that as your main login it will be both a member and have admin rights.
Cheers
September 4, 2016 at 8:10 am in reply to: Login re-directs to homepage, need to just refresh current #8132tombyrom
ParticipantHi,
Yes latest version running. I had tried that plugin, sorry that was what I was referring too but it wont work and it doesn’t because in the documentation it says:When this feature is enabled, if you click on the “Login” link of a protected post or page, it will send you to the login page with “swpm_redirect_to” query parameter in the URL (meaning this feature is active).
The way I’m set up if they try to access a page that only members can see then it checks whether they are logged in and if they aren’t it doesn’t show the content it shows a login form and subscribe form instead, on the same page; so they don’t click through to another page to login meaning the query parameter is not added to that URL.
Obviously the way I am doing it is much cleaner everything happens on page instead of going through to another page to be redirected back.
But after they login it goes to the homepage I just need them to stay on the current page or at least just refresh the current page as they will then be logged in and the page will see they are logged in and display the content.
Many thanks
Tom -
AuthorPosts