Can I enable a paywall with specific permisions inWordPress? - wordpress

I'm learning to code, and I know the basics to get a WebApp up and running with react + firebase and also have done some Laravel tutorials but right now I need to ship something as quick as possible since I'm at an accelerator.
I know WordPress has the themes and plugins but not sure if I will be able to tie everything together.
Basically what I need is a kind of reddit with a paywall. So I know I can integrate Stripe with some plugins, but will I be able to give access to members to specific groups without much trouble?
Thanks!

With your level of coding knowledge (if I understood you correctly), I might recommend trying or at least starting with a Wordpress plugin. If you're feeling up to it, you might try something like this tutorial to create a custom one.

A basic PHP server is pretty handy (XAMPP, LAMP, etc.) and super quick to get up and running (since almost anyone will host it for cheap). Another great approach is Code.xyz (https://code.xyz/) or even Runkit (https://runkit.com/).
Hope that helps!

Related

Wordpress construction worksite induction solution

I'm considering the creation of an in-house construction site induction (or onboarding, I suppose) solution using Wordpress. This would detail the site location (with maps), the site rules and any other relevent information that people working on the site (or visitors) need. Immediate thought is to use an LMS (learning management system) plugin where each 'course' would be a different construction site. Has anybody done something similar and have recommendations?
I've done something similar to this but it would work much better in a multi-site environment. Utilizing an LMS as the solution for this could get complicated in the long run and need some coding changes to work effectively.
Through Multi-Site, you could have a member platform that allows the user to see the relevant information after logging in. Also keeps things more clean and separate on the admin side of things.

The correct step in setting up a Wordpress block tutorial?

While I do have experience working in WP and creating WP themes. I am new to learning about blocks. Therefore, someone gave a link to learn about blocks: https://developer.wordpress.org/block-editor/tutorials/block-tutorial/. However, I thought I should start with the prerequisites in which I can set up development environment and a new wordpress site, which is at: https://developer.wordpress.org/block-editor/tutorials/devenv/.
However, I got stuck after the step "install npm -g install #wordpress/env" It said after this: "Start the environment from an existing plugin or theme directory, or a new working directory:" I thought I was missing something so I tried to look around online if someone followed the Block tutorial and wrote about what they did. I also came across https://davidyeiser.com/tutorials/docker-wordpress-theme-setup that should help me set up a new environment and new Wordpress site with Docker.
Is this the correct way I should be going before I download the "https://github.com/WordPress/gutenberg-examples" to work with as I go through the tutorial?
It's hard to say what is the right or wrong way to start learning developing blocks for Gutenberg. Personally I started in a similar way as you are talking about. I just did the beginners tutorial, and after I understood how that was connected I modified that plugin to my taste. Since then I've just been using that plugin and workflow for every project I have. It's worth mentioning that I had some experience with React before I started working with this which came in really handy to understand the system.
After that I would recommend looking into wp-bg.com for a better visualization, examples and snippets of the different components that Gutenberg offers. The documentation that WordPress themselves provides on Gutenberg is a bit limited regarding the different components and tools that comes with Gutenberg.

Please advice about security issue when using bitbucket

I am new and I am not sure if this is a place to ask this question.
I developed a web site alone using wordpress framework.
Now, I got a guy who I don't know much to join me to develop the site. We live in different countries and we decide to use Bitbucket for code management.
I do not have any experiences in team working, Bitbucket.
My concerns are:
1. Do I need to upload both source code and database to Bitbucket?
Do you think he will just take all the source code and database and make his own website and become my competitor?
What should I be careful when working in a team? I mean sharing code.
I know maybe I am quite small-minded. I am worried about security problems.
But definitely, I need to have someone to work with me to develop the site.
Please advice and write any sources that are useful for this problem.
Thank you.
I'm not an expert in Wordpress, but the concept still applies:
Source code: yes. Database: no, only the database schema/ SQL scripts to recreate it.
Depends on his ethics. You should reach an agreement with him that guarantees that he won't do so, by writing a contract for example.
Take the following into consideration: coding standards, conventions are followed in naming variables, pages, urls, etc, repository privacy is set correctly, repository privileges are distributed to enable the contributors to do only what they're supposed to do.
I'll leave the rest to you and other fellows on this website to figure out depending on your experience :)

Drupal site profiling

Trying to locate the bottleneck in our drupal site. I've installed xhprof to profile but honestly I have no idea what "normal" numbers would be on Drupal. I was hoping I could get some pointers or if anyone knows of a tutorial that goes over this specifically for Drupal...?
Here are the top items when I sort by Exclu. CPU. Again I'm not sure what columns are most important to look at and what is "normal". I'll gladly add more info if needed.
What database engine are you using? _db_query functions shouldn't take up that much of the load time. Make sure you have a clean connection to the database server, and that its set up properly.

Module development tutorial in Drupal

I'd like to learn how to create modules in drupal- modules which can interact with the user, database, assign permissions, views.
Is there any good video tutorial or a simple sample module which covers these things?
Thanks.
My suggestion would be to pick up a copy of Pro Drupal Development and start working your way through. I think that book is the best one stop option for providing an easy to follow, yet in depth start for learning Drupal development.
If you really wanted to get by without purchasing a book, I would suggest checking out the Lullabot site for whatever free content they have available.
After an initial background, the Drupal api pages should be helpful for you, . Hit the search box in the upper left hand corner for type ahead search to find detailed info on drupal functions. This would be a great resource for getting some more background on the functions googletorp listed. I agree with googletorp that those are a good list of functions to get started with.
It requires some effort to learn how to develop in Drupal. You might be able to find some good videos, but you will only really master this when you get your hands dirty and start coding.
How hard this will be for you, is also highly dependent on your background. A seasoned PHP developer wont find it that difficult to develop with Drupal.
There are some key points that you need to understand though.
The hook system. This is Drupal's way to do OOP. The idea is that modules or Drupal core can define and run hooks when an event happen that other modules want to react to. An example could be the creation of a user or the display of a node. To implement a hook, you simply create a function with the correct name. You need replace the "hook" in the name of the hook with your module name.
Drupal has a lot of API functions and it takes time to find them and learn how to use them. Take your time, as using the right API functions can make a big difference. Drupal has a nice API site
From your description you should take a look at these functions:
hook_user
hook_perms
hook_menu
db_query
In addition to what googletorp and mike munroe already said, check out the module developers guide on drupal.org. On the api site, check out the well documented example modules.
I have learnt drupal from beginner to advanced with CodeKarate. its one of the best website for drupal.
http://www.codekarate.com
There is a very good, easy to follow tutorial on developing JQuery/Javascript modules on Drupal. Check it out as well.

Resources