Author Topic: Tracing product price  (Read 1124 times)

mk3lai

  • Beginner
  • *
  • Posts: 2
Tracing product price
« on: March 07, 2011, 23:20:58 pm »
Hi, I am a vm newbie so please bear with me.  I am doing some customization with $product_price in \components\com_virtuemart\themes\vmtheme036\templates\product_details\flypage.tpl.php.  This file has the following code:

      <div class="browsePriceContainer">
         <?php echo $product_price ?>
      </div>

I don't see $product_price being defined anywhere so I think it is global.  However, when I do a global search (grep) on $product_price throughout all the vm php files, I couldn't find $product_price being defined anywhere as a global variable.  Is my assumption wrong or am I looking in the wrong place?  If I am looking in the wrong place, where is it defined?

Thanks.

stinga

  • Contributing Developer
  • Full Member
  • *
  • Posts: 872
    • Squangle ltd
Re: Tracing product price
« Reply #1 on: March 08, 2011, 00:18:00 am »
G'day,

I did
Code: [Select]
find . -name "*php" -exec grep \$product_price {} \; -ls|grep rw
and got
Code: [Select]

./administrator/components/com_virtuemart/html/basket.php
./administrator/components/com_virtuemart/html/shop.product_details.php
./administrator/components/com_virtuemart/html/shop.browse.php
./administrator/components/com_virtuemart/html/ro_basket.php
./administrator/components/com_virtuemart/html/savedbasket.php
./administrator/components/com_virtuemart/html/product.product_price_form.php
./administrator/components/com_virtuemart/classes/ps_checkout.php
./administrator/components/com_virtuemart/classes/ps_order_edit.php
./administrator/components/com_virtuemart/classes/ps_order_change.php
./components/com_virtuemart/themes/default/templates/browse/browse_2.php
./components/com_virtuemart/themes/default/templates/browse/browse_5.php
./components/com_virtuemart/themes/default/templates/browse/browse_4.php
./components/com_virtuemart/themes/default/templates/browse/browse_1.php
./components/com_virtuemart/themes/default/templates/browse/browse_3.php
./components/com_virtuemart/themes/default/templates/browse/browse_lite_pdf.php
./components/com_virtuemart/themes/default/templates/product_details/driver_restore_flypage.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/flypage-ask.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/flypage_new.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/flypage.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/includes/addtocart_form.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/includes/addtocart_list_multi.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/garden_flypage.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/flypage_driver.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/flypage_lite_pdf.tpl.php
./components/com_virtuemart/themes/default/templates/product_details/flypage_images.tpl.php
Stinga.
614869 products in 747 categories with 15749 products in 1 category.
                                             Document Complete   Fully Loaded
                Load Time First Byte Start Render   Time      Requests      Time      Requests
First View     2.470s     0.635s     1.276s          2.470s       31            2.470s      31
Repeat View  1.064s     0.561s     1.100s          1.064s       4             1.221s       4

mk3lai

  • Beginner
  • *
  • Posts: 2
Re: Tracing product price
« Reply #2 on: March 08, 2011, 05:31:34 am »
Yes, I know that.  But I don't see any of those files that define $product_price as a global.  I am curious where that is defined.  Thanks.