I'm stumped and I need some guidance. I can't find anything on this in virtuemart documentation, or forums, nor the documentation or forums of an extension I had to use.

Background: I set up an ecommerce website using Joomal and Virtuemart. A problem we had to address is that site visitors did not know the product they need, nor were they likely to know that part number. They would know what they already owned that the site's products would fit. Basically, we needed to set up a cross reference system. Found a GPL extension from redComponents that seemed to be a close fit, called vmproductfinder. It allowed the association of tags with products.

As an aside, the product is a bit rough around the edges and the documentation and forum are nearly worthless, but you can't look at either unless you have a support subscription, so you'd never know beforehand. At least it is GPL.

Here's my problem: I need the system to make 'add to cart' buttons for every product that comes up in the search results.

I've looked through the virtuemart forums, and I've found some code for placing 'add to cart' buttons on joomla pages. I'm not averse to doing this, at least as a temporary measure, but when I tried it, I couldn't get it to work, I think because it requires the virtuemart or joomla system to generate a unique identifier number. Here's a snippet from the code:

<div class="vmCartContainer">
<form class="addtocart_form" id="addtocart_4b7069c5ac8f5" name="addtocart" method="post" action="">

I've looked through the browse and flypage files, and I see code like this:

            <div style="text-align: center;">
            <span style="font-style: italic;"></span><?php echo $addtocart ?><span style="font-style: italic;"></span></div>


  </div>
  <div style="float:left;width:32%"><?php echo $form_addtocart ?>
  </div>

I'd really like to use that to put the add to cart button on the search results page, but when I paste that into the file and view the results, nuthin'.

I don't know where the $addtocart and $form_addtocart objects are generated, or how to access them.
And I don't know how the Joomla system 'includes' other files.

Hopefully somebody can clue me in.

Thanks,
Mark





_______________________________________________
New York PHP SIG: Joomla! Mailing List
http://lists.nyphp.org/mailman/listinfo/joomla

NYPHPCon 2006 Presentations Online
http://www.nyphpcon.com

Show Your Participation in New York PHP
http://www.nyphp.org/show_participation.php

Reply via email to