Forum Index
Download, Support, Documentation
Donate to to support the project

   - News
   - Bug report/Patches
   - Future Features
   - Version 1.3m  (Core /Lang /Mods)
   - Version 1.2m  (Core /Lang /Mods)
   - Version 1.0m  (Core /Lang /Mods)
   - All
   - Features
   - Documents
   - How-Tos
   - About
   - English
   - German
   - Changlog
   - Requests
   - Team
   - CVS
   - Website of the Month
   - Websites
   - Community Forum
   - Member

Log in to check your private messagesLog in to check your private messages
Log inLog in

Changing start time auctions
Sun Feb 07, 2010 4:33 am FR
Easy: what code to use to update sql table?
Fri Oct 16, 2009 8:39 am guyb
Unlimited products(downloads)
Wed Oct 14, 2009 7:09 pm hoimyr
Seller chooses currency
Sun Oct 11, 2009 8:00 pm hoimyr
Cant select end date without getting error
Sun Oct 11, 2009 6:43 pm hoimyr

Author: FR
Brookfresh, Brad Lawryk, Crogon, DaMysterious, EklipzeDesigns, ML, musashi, phpBB Group, phpBB-Auction-Team, php-styles, sanman, Tel, Vampy, wGEric

Supported Sites

User: 21025
Posts: 18401
Latest User: BlockchainPaw

On configuring Mod for post-sale commission payments

Post new topic   Reply to topic Forum Index -> Support
View previous topic :: View next topic  
Author Message
Small-Cap Auctioneer
Small-Cap Auctioneer

Joined: 22 Oct 2008
Posts: 21

PostPosted: Sat Oct 25, 2008 9:59 am    Post subject: On configuring Mod for post-sale commission payments Reply with quote

This is a fantastic mod and my gratitude to FR and his team for developing it. I'm using this with a phpbb2 backend on a site which also uses mx-publisher with phpbb3 - and it all looks fine. I'm actually happy I'm using this mod with phpbb2 because more mods are available for it.

When this site was down last week I started posting my 'experiment' here, but now that this board is back up I'll write it here.

I'm posting the steps of an idea I'm trying to implement (with thanks to much thanks to Lumpy Burgertushie, Brf and poyntesm), but I do have a question or two at the end - I need a little help.

the business model I'm trying to use is that I would receive a commission only if an item sells (i.e. I get paid after someone has used the service).

The MOD isn't set up to guarantee that will work, so I have to hotwire it - and for this to work I need two things sorted out:
1. Payment: I would get paid by the buyer, I would ask seller to ship the merchandise, and then I would transfer his share of payment to him (i.e. an escrow style payment arrangement)
2. Security: I need to prevent buyer and seller from exchanging full contact details before close of sale, otherwise I could get cut out from receiving payment.

possible solutions: I'm posting my solutions / requests for help in separate postings below

Last edited by guyb on Sat Oct 25, 2008 10:37 am; edited 2 times in total
Back to top
View user's profile Send private message
Small-Cap Auctioneer
Small-Cap Auctioneer

Joined: 22 Oct 2008
Posts: 21

PostPosted: Sat Oct 25, 2008 10:06 am    Post subject: Reply with quote

Possible solution for "security":

to prevent buyers and sellers from seeing each others contact details, I had to add special conditions in certain files such that only ADMIN and MOD would be able to see email addresses, ICQ's, MSN messengers etc.

I wanted ideally a compound conditional statement so that more than 1 permission level could see these details.

The key issue here was that regardless of the permission nomenclature used by this mod (i.e. "AUCTIONEER"), only the usual phpbb2 names like ADMIN and MOD could be used.

The "If" command became:
if ( $userdata['user_level'] == ADMIN || $userdata['user_level'] == MOD )

And I used it like this (but for every mention of email, msn, www, etc.):

if ( $userdata['user_level'] == ADMIN || $userdata['user_level'] == MOD )
$email_uri = ( $board_config['board_email_form'] ) ? append_sid("profile.$phpEx?mode=email&" . POST_USERS_URL .'=' . $auction_offer_row['user_id']) : 'mailto:' . $sellerrow[0]['user_email'];

             $email_img = '<a href="' . $email_uri . '"><img src="' . $images['icon_email'] . '" alt="' . $lang['Send_email'] . '" title="' . $lang['Send_email'] . '" border="0"></a>';
             $email = '<a href="' . $email_uri . '">' . $lang['Send_email'] . '</a>';
         $email_img = '&nbsp;';
         $email = '&nbsp;';

* a more drastic fix is to just comment out whole fields of these kinds from the user profile page (templates/XXX/profile_add_body.tpl) - the data can't be entered, so it never gets displayed either, but see my comment below about using a user_level switch in template files - this is also a good and flexible solution.

As far as I've found, the phpbb2 files which need this censoring are:

And from the auction mod:

That 2nd file also includes a text link to the seller's email ("email the seller"). That link could be disabled from its source file "languages/lang_en/lang_auction.php" but a much better solution is to use a user_level based "switch" to censor it from the templates/auction_view_offer_body.tpl file. To do that:

First, find this code in your "includes/page_header.php" file:


   $template->assign_block_vars('switch_user_logged_in', array());

then add this code just below it:

if ( $userdata['user_level'] == ADMIN )
      $template->assign_block_vars('switch_user_admin',array() );

then, in the "templates/auction_view_offer_body.tpl" file:


<span class="name">&nbsp;&nbsp;&nbsp;<a href="{AUCTION_SEND_EMAIL}" class="genmed">{L_AUCTION_SEND_MAIL}</a></span><br>

(I'm unable to post the code below in any way so I'll describe the opening and closing arrow symbols below in words - don't include any commas or quotation marks)

and precede it with:


and end it with:


Only by adding the "template -> assign_block" command in the page_header.php file can you use the switch.

* I also installed the excellent Private Message Admin mod (to prevent exhange of contact details by PM; I mention that in the site's T&C's so users know PMs are monitored).

By the way there is nothing unique in that last step: eBay censors emails for exactly the same anti-collusion purpose.

edit: originally I'd written that it may be tempting to add a word censor mod in too but that the problem is that at some point the buyer and seller do have to exchange their details (i.e. after I receive the payment).

It then occurred to me that the auctioneer (us) may want to be the permanent go-between with the contact details for all sales: because if buyer and seller exchange details directly now, come the next auction they'll already know each others emails/websites/phone numbers and close the sale on their own. So, a censor mod may be a good addition to the arsenal - this one looks quite good. It checks private messages but it would need to be adapted into the auction mod's main pages too by us (aucton_offer.php, auction_offer_view.php, the relevant feedback page) - a bit of a headache...

caution: with all the mods available it's tempting to get carried away with 'over-security'. About the only fix I didn't mention above was signatures - for the auction mod these are useless as the mod doesn't display them, and they can only contain unecessary details. Instead of cracking teeth installing complex mods for this, just disable the option altogether in the forum control panel.

Last edited by guyb on Thu Oct 30, 2008 7:20 pm; edited 16 times in total
Back to top
View user's profile Send private message
Small-Cap Auctioneer
Small-Cap Auctioneer

Joined: 22 Oct 2008
Posts: 21

PostPosted: Sat Oct 25, 2008 10:18 am    Post subject: Reply with quote

Possible solution for "Payment":

to receive the payment, I want to make my moneybookers/paypal account a fixed "answer" in the field which asks auction users which payment method they accept when they register a new auction item for uploading (i.e. my email address would be hardcoded in there / no editing possible).

Ideally I would like a way of qualifying the hardcoding with a permission level as I did with the access to email address etc. above.

This was harder for me to accomplish, and this is what I did in the "auction_offer.php" file kind of randomly on line 340:


if ( ($userdata['user_level'] == ADMIN) OR ($userdata['user_level'] == MOD) )
$template->assign_var('AUCTION_OFFER_ACCEPTED_PAYMENTS' , '' );
$template->assign_var('AUCTION_OFFER_ACCEPTED_PAYMENTS' , 'Paypal only, pay to:' );

I edited this post as the specific formulation of the "If" statement above works better than what I posted before: now the condition does work and the relevant user_levels see what they're supposed to.

BUT: the fixed answer appears in the field and is editable - it is not a 'fixed' text answer which appears in place of the field.

Question: Is there a way, on a user_level conditional basis, to make that prepared answer a fixed and unalterable line of text?

Last edited by guyb on Thu Oct 30, 2008 7:25 pm; edited 2 times in total
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Forum Index -> Support All times are GMT
Page 1 of 1

Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum - Developed by
Sponsored by: - - - -