-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Locking posts #4
Comments
I had the same idea today. My thoughts were there would be a page level block settings with a checkbox. Once the checkbox is checked there would be page level lock settings underneath. |
One thing could be to also allow full collections of posts to be locked (thru basically addition of a tag or category that locks them all) |
I made a little progress on this. However, to do that we need to find an easy way to have vs |
@SolomonFoskaay What about this one? Would you be interested in working on it for $300? |
@julien51 Yes, if you can help adjust the price between $300-$500. |
I have agreed to $300 on that one |
How are you doing on this front @SolomonFoskaay ? |
Yeah, currently working through understanding the plugin source codes and how they work they work together. I have tried about 2 methods for this which involved editing multiple of the plugin PHP file but not yet give the desired result. So, I decided to spend some time getting familiar first with all the code base. within 2 weeks time, should be able to have something for you to test out on this. |
Hum. Ok. Please keep me posted frequently and regularly because we may need earlier than that and in that case I'll take care of it. |
Okay, will keep you updated and added it as a higher priority. Let's see what I can have for you to check in 1 week's time. |
@julien51 Have spent the last 3dys to study the about 50 code files of the Unlock plugin repo and today I have a more comprehensive understanding of it and have a more defined way to implement and fix this feature. In the process, will surely need your support and will be posting them here. For now, see attached screenshot and help answer the following please: (2) For now, I have the webpack build working fine and will have to always build the changes done in the |
You do not need to run a server at all times. You can just use |
Yeah, am using the symlink method with localwp already. will just stick to that. Work still on will keep you updated |
@julien51 Here comes the updates. Very sorry it coming this evening, promised morning earlier. I have been able to achieve the full post-locking feature but with some explanation. So to make things easy will divide the full post/page content-locking issue into two parts: PART 1: PART 2: I have successfully achieved the PART 1 and here comes a demo (for now the locking is for the post type, the lock works on page type too but need some cleanup) to see it in action. I used an Ethereum wallet address as the unlocking, when PART 2 is integrated, then the Unlock Protocol workflow will handle the unlocking with NFT as usual. UnlockProtocol-WP-Plugin-V04a-DEMO-Full-Post-Locking.mp4The demo shows using the Unlock Protocol Wordpress plugin (Dev version) to add the full post content locking and unlocking. NEXT STAGE:I have spent the last 1week (70Hours+) and 90% of it went to understanding the codebase and trying to maintain the style of the existing code to integrate the new feature but I won't deceive you, it was a pain due to how the plugin class + singleton was set up which makes it tougher and harder to even see new features I added to show up after several hours and changes to it. Thus, I decided to bypass the current codebase and within the last 24 hours, that made it possible for me to achieve the desired full post content lock/unlock. (if you watch the above demo video, you will notice at 0:26-0:45, it showed how I had to include the new "locks" folder and the PHP file used to code the full post lock/unlock feature directly in the main plugin file which allowed it to load and function well when the plugin was activated.). Therefore, moving forward I have this proposal: (OPTION 1)I will push to the Unlock repo the feature for the full post/page lock/unlocking as it is. PAYMENT: (OPTION 2)If you want me to handle the PART 2 also. Then, this will involve completely re-writing the plugin's current Unlock Protocol locking/unlocking with NFT workflow used to handle the PART 2 in a more flexible way than the existing code base. This will not only make it easy to integrate this PART 1 I have done above, but it will also make adding more new features to the plugin easier for contributing developers now and in the future. Just like we removed the previously used local wp dev setup using PAYMENT:
Looking forward to your response soon to move forward to the next stage. |
UPDATE: Am glad to inform you that after the update, I put in some work and now have it working with pages too. See below:
This means I now have the PART 1: Full Post/Page Content Locking/Unlocking feature achieved and ready to be integrated with PART 2 (Unlock Protocol NFT Lock/Unlocking workflow). So, looking forward to your response to yesterdays update for this to move on further and faster too. |
This is fantastic! I am excited about seeing these screenshots! Let me respond in more details shortly! Please do open a PR as well so I can start making early feedback on the code itself! |
@julien51 Okay, still awaiting your response on the option you concluded on going with from the above. |
The plugin firm was in fact created by a team that's a leading WP firm and recommended by Automattic themselves so I think it probably uses the right approach... https://rtcamp.com/
No I am sorry, if we assign bounties is for these to be solved. If our team has to then redo the work then I am not sure I understand the point of these bounties :)
I am sorry but I am really confused here. If you want to create another plugin then please go ahead... but we don't need someone to create the plugin from scratch again. |
Please push your code anyway so I can make sense of it and recommend next steps? |
@julien51 Okay. When I have the full post/page content lock feature completely integrated with the unlock flow, will push the full code to you for the check. Regards! |
Thanks great news @SolomonFoskaay ! If you want to push some code I can certainly look and give you early feedback... |
@julien51 I have pushed a PR #67 so you can help check the code and provide support. Things done for #4 so far:
Pending issue:
IMPORT NOTE:Even though, I do agree the initial Unlock Plugin developers were from a recommended high rank wp platform but that does not mean they did not do bad design choices (we have seen it that even big brands sometimes have flaws that even unrecognized startups avoid) As I mentioned earlier, the Singleton design pattern adopted by the Unlock plugin developer is a complex design that is usually used for specific cases and when used, should not be used for 100% of all classes in the plugin but they used it in all. Now, it makes it difficult to introduce new features side by side with existing ones without the need to tamper with the existing code base. A little bit of Googling will reveal to you that this is indeed a complicated design pattern which most modern plugin design do not adopt. It is hard to even see a helpful guide up to date about using Singleton for Wp plugin design that is not outdated in about 3-5 years ago. |
@julien51 I have been able to fix this issue completely and pushed a new PR for it #68 . Kindly check and let me know if there is a need for further adjustment. Though I have tried to minimize having you spend more time with errors in the code. Meanwhile, the following was done: 3 Important Things:
Full Post Content Lock + Unlock Protocol Flow: Full Page Content Lock + Unlock Protocol Flow: Considering I had to refactor the existing codebase for the Unlock protocol flow, PLEASE I will appreciate it if you can consider compensation for the extra weeks spent on those extra that are not part of this issue bounty. I do appreciate your understanding and consideration in advance. Thanks! |
Hello, Just to add, I was able to achieve locking full content post/page with custom coding built into our platform (3Pad) early version. We also implemented more customizable options for users . Visual
Lock ConfigPaywall
This wall all implemented to give users as much options as possible, similar to the unlock checkout builder. Here's a video demonstrating the use https://youtu.be/HTuG-uJ_9RE?t=636 Also you can view the code here https://github.com/3Pad/3pad/blob/main/wp-content/themes/3pad/files/unlock-protocol.php#L359 These custom fields use (ACF). I haven't tried implementing this into unlock plugin but it can be achieved . I look forward to seeing more customizable lock options for the plugin. |
@julien51 Thanks and really appreciate it including the extra fixes you did on my PR too. Polygon: Thanks! |
Thanks for your work on this @SolomonFoskaay ! |
@julien51 Confirmed. |
Our current approach is to let WP users lock "blocks" easily. We should let them also easily lock posts where by default (maybe in the template?) the content of the post is locked. This can be set with a toggle in the settings.
The text was updated successfully, but these errors were encountered: