Some time ago I made a product relationship attempt, but it was not functional and I think it was not the right way, I confess, the same is bad, what I did was basically this:
I look for the lines (Categories) and just below where the checks are ready the products of this category and select the product that I want to relate, this can be seen in this image:
Mycheksareconfiguredlikethis:
<inputtype="checkbox" name="produto[]" id="produto[]" value="<?php echo $row_produtos['id_produto']; ?>" /><?php echo $row_produtos['codigo']; ?>
I'm limiting the amount of 10 products, I'm confused and I can not understand what I should write to my bank, product_id, category_id to later fetch and display on my page.
What I would like to know is, how is the correct way to develop this solution in the visual, what would the registration look like?