News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Thank you for your order - how to change $this->html;

Started by Kywabara, February 03, 2012, 11:46:48 AM

Previous topic - Next topic

Kywabara

Please help. I need to change  Thank you for your order page, i looked at components/com_virtuemart/views/car/tmpl/order_done.php:
<?php


echo "<h3>".JText::_('COM_VIRTUEMART_CART_ORDERDONE_THANK_YOU')."</h3>";

echo 
$this->html;
?>


How to change "$this->html" - where can i find the file with it?

Joomla 1.7.3, Virtuemart 2RC.

Thank you.


chadgarber

#2
I am also needing to know the answer to this.
Chad Garber
Web Developer/Computer Support
770.639.4847
Garber Consulting, Inc.
http://garberconsulting.net

bolonia

Got it.
html code is in /plugins/vmpayment/standard/standard.php file, it depends on what payment type you choose, so if you using standart payment plugin, you should watch it there.

renegadesk

Quote from: bolonia on February 22, 2012, 06:45:25 AM
Got it.
html code is in /plugins/vmpayment/standard/standard.php file, it depends on what payment type you choose, so if you using standart payment plugin, you should watch it there.

Worked nicely thanks bolonia

bbw


camel007

Hi Guys
If i wanted to delete the text in red where would that be? couldn't see it in above mentioned files?

Thank you for your order!

Payment method   Direct CreditDeposit total amount owing into our bank account.
add a message to display with the order
Order Number   a2b1016
Amount   $ 359,76

cheers

Imron

I've got the same problem as above.  How do you remove the 'add a message to display with the order' text ????

Joomla 2.5 and VM 2.06

simonsays55555

Hi Everyone,

I would also like to know how to display the name and email address of the user's account. For example, I'd like the thank you page to display, Thank you "John" for your order. A confirmation email has been sent to JohnSmith@hotmail.com" where john is obviously the name of the registered user placing the order. Any help on this issue would be greatly appreciated as I have been exploring the forum and searching the web trying to find a solution for weeks.


bolonia

Ok, try to var_dump all array $order, it should be in it.

For example, i have to change order_number to normal number, not random letters and numbers, so i dump array: $html .= var_dump($order['details']);

and found it there with the name $order['details']['BT']->virtuemart_order_id. Next step — print it. Commenting original code and replacing with our:

//$html .= $this->getHtmlRow('STANDARD_AMOUNT', $currency->priceDisplay($order['details']['BT']->order_total));
$html .= $this->getHtmlRow('STANDARD_ORDER_NUMBER', $order['details']['BT']->virtuemart_order_id);


The_nino

Thanks Bolonia!!

Do you know if it is possible to override the file like we do with the view files? or we have to hack it?

Thanks again!

gothamcity

Hi all,
I tried to find the thread that is closest to my problem.
My problem is that the "thank you for your order" page with the Paypal payment plugin doesn't show my modules (e.g. my menus). When using the standard payment plugin everything works fine (as the ..../confirm page is apparently part of the cart view which I can assign to a menu entry and in turn assign modules to be shown in that entry).
I also stumbled upon this order_done.php which apprently is only being used by the standard payment plugin.

For the Paypal plugin the return page is something like ...?option=com_virtuemart&view=pluginresponse&task=pluginresponsereceived&on=<ordernumber>&pm=<payment number>

Does anyone know how I can set this Paypal "thank you for your order" page up to display a selected number of modules (actually the same that are visible in the cart view?)

Thanks

bolonia

Quote from: gothamcity on June 18, 2012, 00:55:54 AM

For the Paypal plugin the return page is something like ...?option=com_virtuemart&view=pluginresponse&task=pluginresponsereceived&on=<ordernumber>&pm=<payment number>

Does anyone know how I can set this Paypal "thank you for your order" page up to display a selected number of modules (actually the same that are visible in the cart view?)

Thanks

Try to add ItemID in link, or maybe you should create hidden menu and create menu to main virtuemart page and asign modules to that page?

gothamcity

Hi bolonia,
Thanks very much ! It works. :D

Here is how I did it (Virtuemart 2.0.6):
1) create a single article, content is not important (you cannot leave it empty, so just put some"...")
2) create a hidden menu, assign this article to a menu item. When you store, you will see the Menuitem ID in the dialogue  --> ID:  abc
3) go to the module manager and, for this menu entry, put all modules visible you like to be visible
4) For Paypal you need to edit paypal.php in \plugins\vmpayment\paypal
line 189 shows this code:
"return" => JROUTE::_(JURI::root() . 'index.php?option=com_virtuemart&view=pluginresponse&task=pluginresponsereceived&on=' . $order['details']['BT']->order_number . '&pm=' . $order['details']['BT']->virtuemart_paymentmethod_id),

Which creates the return link. Simply add &Itemid=abc to this, so the source code will look like this:

"return" => JROUTE::_(JURI::root() . 'index.php?option=com_virtuemart&view=pluginresponse&task=pluginresponsereceived&on=' . $order['details']['BT']->order_number . '&pm=' . $order['details']['BT']->virtuemart_paymentmethod_id) . '&Itemid=abc',

If you need to have it for other payment methods - I guess the procdure is the same for Payzen and others.

Best

deepakdhingra

This is exactly the page I was looking for. With small modifications to suit my website.

Thanks to Bolonia, I have now found out that I need to work on standard.php. But since I am not a programmer I do not know what to modify and how. I did try a few things but did notwork out.

What I need to do is this -

1. Change order number to order ID. (So that the issue of random numbers is done away with) OR if anyone could suggest how to streamline Order Number to a standard system. Say, YEAR-12345 or something like that

2. Customize the Thank you message. Maybe by adding a module to show up. But unlike gothamcity who needed to edit paypal.php and got the return link, I dont find any return link in standard.php. Or maybe I have missed it.

Could anyone please suggest how do I do the above?

Thanks.

Deepak