- Posts: 4
- Thank you received: 0
onHikashopAfterDisplayView double printed
- shahryarjb
-
Topic Author
- Offline
Less
More
10 years 2 weeks ago #249508
by shahryarjb
onHikashopAfterDisplayView double printed was created by shahryarjb
hi
my code
plz see pic (attached)
I need a print (1 time) in the page
tnq
my code
Code:
function onHikashopAfterDisplayView(&$view) {
echo "hello";
}
I need a print (1 time) in the page
tnq
Please Log in or Create an account to join the conversation.
10 years 2 weeks ago #249527
by Jerome
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Replied by Jerome on topic onHikashopAfterDisplayView double printed
Hi,
You need to use the $view object to retrieve the current view name and current layout name in order to just display your content on the page you're targeting.
You have a sample here :
www.hikashop.com/forum/orders-management...hipping-invoice.html
Regards,
You need to use the $view object to retrieve the current view name and current layout name in order to just display your content on the page you're targeting.
You have a sample here :
www.hikashop.com/forum/orders-management...hipping-invoice.html
Regards,
Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.
Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.
Please Log in or Create an account to join the conversation.
- shahryarjb
-
Topic Author
- Offline
Less
More
- Posts: 4
- Thank you received: 0
10 years 2 weeks ago #249534
by shahryarjb
Replied by shahryarjb on topic onHikashopAfterDisplayView double printed
hi
used and worked
Code:
function onHikashopAfterDisplayView(&$view) {
//print_r($view->getName()); or onHikashopBeforeDisplayView
if($view->getName() == 'product') {
if($view->getLayout() == 'show_quantity') {
echo "hellow";
}
}
used and worked
Please Log in or Create an account to join the conversation.
Time to create page: 0.190 seconds