*

abhkhan

  • ***
  • 60 posts
How to show promote button to only Listing's User?
« on: March 23, 2018, 07:38:13 AM »
Currently, the provided code to show promote button is showing the button to all users.

How to make this button only shown to users who posted that listing. Other viewers shouldn't see this button, as the listing product owner only wants to promote the listing.

Marked as best answer by abhkhan on March 23, 2018, 12:26:06 PM
*

MB Themes

Re: How to show promote button to only Listing's User?
« Reply #1 on: March 23, 2018, 09:31:24 AM »
@abhkhan
You can wrap button into code:
Code: [Select]
<?php if(osc_item_user_id() > && osc_item_user_id() == osc_logged_user_id()) { ?>
....button
<?php ?>

  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots

*

abhkhan

  • ***
  • 60 posts
Re: How to show promote button to only Listing's User?
« Reply #2 on: March 23, 2018, 12:30:08 PM »
@abhkhan
You can wrap button into code:
Code: [Select]
<?php if(osc_item_user_id() > && osc_item_user_id() == osc_logged_user_id()) { ?>
....button
<?php ?>


Thanks, but you missed the semicolon ( ;)  :)
Code: [Select]
  <?php ;  } ?> 

*

MB Themes

Re: How to show promote button to only Listing's User?
« Reply #3 on: March 23, 2018, 12:39:48 PM »
@abhkhan
I did not, it should not be there.
  To get fast support, we need following details: Detail description, URL to reproduce problem, Screenshots