customization – Assistance with plugin choice for Driving School Booking System

Driving School Website | Scenario
I’m building a Driving School Website for a client where their customers can log in to their personal accounts and make bookings for their appointments (which are limited to 10 hrs worth of lessons which can be either 1hr/2hr sessions).
I also might want to implement a payment system where customers can buy the 10 lessons package and immediately after the purchase get their auto-generated log-in details. Also, they should be able to buy additional lessons and then the original 10hr limit should increase.

Plugin Assistance
Which plugins should I use?
I did quite a lot of research on booking systems but can’t really find anything for this project. I saw something about LMS’s but not sure if that fits this project.

Thanks for the help in advance.

hooks – How to update global variables in plugin activation callback?

Sorry for being such a noob, I’m sure this is an easy question for most. I’m trying to register activation and deactivation hooks for my plugin. In the docs, they warn about the activation callback not having access to global variables:



If you’re using global variables, you may find that the function you pass to register_activation_hook() does not have access to global variables at the point when it is called, even though you state their global scope within the function like this:

The main body variables are therefore in the scope of the activate_plugin() function and are not global, unless you explicitly declare their global scope:

global $myvar;
$myvar = 'whatever';

function myplugin_activate() {

   global $myvar;
   echo $myvar; // this will be 'whatever'
}
register_activation_hook( __FILE__, 'myplugin_activate' );


So, following that advice, I set up my code like this:

global $post_id;
$post_id = 0;

function install_xxx() {
    global $post_id;

    $post = array(
        'post_title'    => __( 'Thank You', 'xxx' ),
        'post_content'  => __( 'Lorem ipsum dolor.', 'xxx' ),
        'post_status'   => 'publish',
        'post_name'     => 'thank-you',
        'post_type'     => 'page'
    );

    $post_id = wp_insert_post( $post, true );
    error_log('Inserted page: ' . $post_id);
}

function uninstall_xxx() {
    global $post_id;
    error_log('Removing page: ' . $post_id);
    $post = wp_delete_post( $post_id, true );
}

register_activation_hook( __FILE__, 'install_xxx' );
register_deactivation_hook( __FILE__, 'uninstall_xxx' );

But in my logs, it will echo something like:

Inserted page: 109

Removing page: 0

And of course, the page isn’t removed.

In other words, the global $post_id isn’t being updated. Any clue what I’m doing wrong?

TagList vim plugin is not working

I have issues in using taglist. For example if I TlistOpen, it shows an error E117: Unknown function: taglist#Tlist_Window_Toggle

I am using a Ubuntu18.04 , with vimrc looks like as follows;

test@test-VirtualBox:~/.vim/taglist/plugin$ cat ~/.vimrc
set nocompatible              " be iMproved, required
filetype off                  " required

" set the runtime path to include Vundle and initialize
set rtp+=~/.vim/bundle/Vundle.vim
set rtp+=~/.vim/taglist/plugin/
call vundle#begin()
" alternatively, pass a path where Vundle should install plugins
"call vundle#begin('~/some/path/here')

" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'

" The following are examples of different formats supported.
" Keep Plugin commands between vundle#begin/end.
" plugin on GitHub repo
Plugin 'tpope/vim-fugitive'
" plugin from http://vim-scripts.org/vim/scripts.html
" Plugin 'L9'
" Git plugin not hosted on GitHub
Plugin 'git://git.wincent.com/command-t.git'
" git repos on your local machine (i.e. when working on your own plugin)
Plugin 'file:///home/gmarik/path/to/plugin'
" The sparkup vim script is in a subdirectory of this repo called vim.
" Pass the path to set the runtimepath properly.
Plugin 'rstacruz/sparkup', {'rtp': 'vim/'}
" Install L9 and avoid a Naming conflict if you've already installed a
" different version somewhere else.
" Plugin 'ascenator/L9', {'name': 'newL9'}

Plugin 'taglist.vim'
" All of your Plugins must be added before the following line
call vundle#end()            " required
filetype plugin indent on    " required
" To ignore plugin indent changes, instead use:
"filetype plugin on
"
" Brief help
" :PluginList       - lists configured plugins
" :PluginInstall    - installs plugins; append `!` to update or just :PluginUpdate
" :PluginSearch foo - searches for foo; append `!` to refresh local cache
" :PluginClean      - confirms removal of unused plugins; append `!` to auto-approve removal
"
" see :h vundle for more details or wiki for FAQ
" Put your non-Plugin stuff after this line
set tags=/home/test/code/tags

I have my taglist cloned to .vim/taglist/plugin. My Exuberant Ctags is installed in /usr/bin/ctags and the path is available in PATH. I have installed the vim plugin manager vundle. I have my cscope and ctags set for the directory code. However when I TlistOpen in vim, it thros an error message E117: Unknown function: taglist#Tlist_Window_Toggle

WordPress plugin called “YITH WooCommerce Questions and Answers Premium”, Its data is not showing in REST API’s


Your privacy


By clicking “Accept all cookies”, you agree Stack Exchange can store cookies on your device and disclose information in accordance with our Cookie Policy.




Woocomerce plugin is not working properly

Hello recently i had to rollback woocomerce plugin’s version due incompatibility with openpay plugin unfortunately this just made my full system unstable and now the shop page shows blank and cant edit at all the changes are saved but not showed on the front end im new at developing with wordpress any idea ?
thank you very much in advance

plugin development – Error 404 change permalink term custom term taxonomy

I’m trying to change the permalink structure of the terms for a custom taxonomy, but it’s returning page 404. I want the URL to be: example.com/products/category/category-name.

I tried to use the term_link filter, I even tried to put a slug different from the custom post type, however, without success. I have also updated wp_options on permanent links

add_action( 'init', 'register_sps_products_post_type' );
function register_sps_products_post_type() {
    register_post_type( 'sps-product',
        array(
            'labels' => array(
                'name' => 'Products',
                'menu_name' => 'Product Manager',
                'singular_name' => 'Product',
                'all_items' => 'All Products'
            ),
            'public' => true,
            'publicly_queryable' => true,
            'show_ui' => true,
            'show_in_menu' => true,
            'show_in_nav_menus' => true,
            'supports' => array( 'title', 'editor', 'author', 'thumbnail', 'comments', 'post-formats', 'revisions' ),
            'hierarchical' => false,
            'has_archive' => 'products',
            'taxonomies' => array('product-category'),
            'rewrite' => array( 'slug' => 'products' )
        )
    );
    register_taxonomy( 'product-category', array( 'sps-product' ),
        array(
            'labels' => array(
                'name' => 'Product Categories',
                'menu_name' => 'Product Categories',
                'singular_name' => 'Product Category',
                'all_items' => 'All Categories'
            ),
            'public' => true,
            'hierarchical' => true,
            'show_ui' => true,
            'rewrite' => array( 'slug' => '%sps-product%/category', 'with_front' => false ),
        )
    );
}

add_filter('term_link', 'idinheiro_permalink_archive_cpt', 10, 2);
function idinheiro_permalink_archive_cpt( $url ) {
    if ( false !== strpos( $url, '%sps-product%') ) {
        $url = str_replace( '%sps-product%', 'products', $url );
    }
    return $url;
}

Theme or plugin? profile listing

Hi,
I'm looking for a (directory) wordpress theme (or plugin), where people can create a free 'personal profile listing'. The free listing includes just a few fields. Or they create a paid profile, which offers more fields to fill out. Any (theme/ plugin) recommendations ?

java – Looking for help on minecraft adventure server plugin

Okay, so I found this Bukkit plugin which gives administrators the ability to load community-made adventure maps and play them with a group of players on one single server instance.

https://dev.bukkit.org/projects/adventureplugin
https://github.com/smith61/AdventurePlugin

This plugin is exactly what I was looking for and I can’t seem to find something else that suits my needs.
(FYI: we have a pretty big bungeecord server running with a group of students and we wanted to create a new section on the server where people can play community made adventure and puzzle maps)

So I thought I’d give it a try to update it myself.
I loaded the latest paperMC jar (1.16.5) and started to mess with it in a new Intellij project, copying pieces of code one by one. I added comments in most files and I tried to understand most of the code.

Where am I now? The plugin gets loaded in a clean server without errors, the commands get registered successfully, and it looks like everything almost works as it should.

Unfortunately I am now stuck. When you load a new adventure map, it looks like the world gets transferred correctly, but you end up in a newly generated world. I have inspected all relevant code but I think my experience with Java and Bukkit is too limited for this, I don’t really understand what is going on.

I forked the project and uploaded my new files to the following repo:

https://github.com/freddo256/AdventurePlugin

Any help would be really really really appreciated, and if there are people interested in collaborating on this project you can always contact me!

Thanks in advance!

WPtouch Plugin errors.. forever?

Hello friends, after I installed this plugin (WPtouch Plugin), and then deleted it, this happened a few years ago.

Then, I found all of my pagination links like this:

https://www.websitename.com/page/2?wptouch_switch=desktop&redirect=%252Fpage%252F4&vpage=38

Code (markup):

These bad links show “duplicate content” in search results, and errors in the console.

I want normal and default links; Such as: google search console

https://www.websitename.com/page/2

Code (markup):

help me please!
SEMrush

 

architecture – Plugin system with AssemblyLoadContext and unloading

I’m building a game engine from scratch and trying to implement a basic plugin system within my engine.

Using AssemblyLoadContext to load the target dll dynamicly and unloading it with AssemblyLoadContext.Unload()

However it seems even if there is a one class instance created from this assembly hanging somewhere in the whole app domain AssemblyLoadContext.Unload() does not unload it until the all the instances are dereferenced.

This is where my problem begins.

There are infinite number of scenarios whether a class which belongs to the plugin can be instantiated and used across the whole appdomain right?.

So how do i keep track of the plugin instances across the whole AppDomain.

(How unity unloads the user scripts and cleans every last one of the instances i wonder)

My engine system is nearly identical to both unreal and unity.

I have entities and the components just like unity.

My current unload workflow is like this.

  1. Loop through every component via reflection and check if one the assembly classes instantiated then set that field/property null
  2. Loop through every assembly and check for static fields/properties which might contain some instance
  3. Now unload it.

However the approach above seems well idiotic and sluggish not to mention it should be slow as hell.

It seems i have a desing problem within my plugin system and i fear if i overcomplicated things.

Are there better way to cleanup assembly instances or am i missing something? (Please tell me im missing something obvious)