Jump to content

[SOVLED]Padloper how do i add quanitity when ordering a product


picarica
 Share

Recommended Posts

So what i am looking for is when you order a product you can type in how many quanitys you want to add to your basket so far i have it like this

        if ($page->variations->count) {
            $content .= "<form method='post' class='padloper-cart-add-product' action='" . $config->urls->root . "padloper/add/'>";
            foreach ($page->variations as $p) {
              $content .= "<input type='radio' name='product_id' value='{$p->id}'>" . $p->color->title . " " . $p->size->title . "</input><br />";
            }
            $content .= "<input type='submit' name='pad_submit' value='" . __("Add to cart") . "' /></form>";
          } else {
            $content .= $modules->get("PadRender")->addToCart();
          }
          echo $content;

but i am not sure how do i tell padloper's API to usee that inputed number to add correlating quanities simply adding <input type='number' name='quantity' min='1'> didnt worked

 

EDIT: nevermind i just had to edit name="quantity" as name='qty'

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...