Auto check categories of interest according to my current user

[ad_1]

Hello everyone,

I am making a list of all the interest categories that my list has. I would like the checkboxes to be ticked according to whether the logged in user is in the list with that category of interest or not.

Either I can get all the categories of interest of my user on a hidden field and in javascript I check the checkboxes whose value is filled in this field.

Or I have to synchronize in true/false a meta in my user account for each existing category of interest and retrieve the value through a form variable?

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer