vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Pig's Subscription Gift (https://vborg.vbsupport.ru/showthread.php?t=105553)

boozehound 01-16-2006 10:00 PM

Pig's Subscription Gift
 
Description

Allows users to pay for a paid subscription for another user.
  • Five plugins
  • One new template
  • Three new phrases
  • Three template edits

Installation
  • Install the product XML through the product manager.
  • Edit template 'subscription' in 'Paid Subscriptions Templates'.

    Find:
    Code:

    <if condition="$show['activesubscriptions']">
    Insert before that, this code:
    Code:

    $giftbits
    Find:
    Code:

    <input type="hidden" name="do" value="order" />
    Insert after that, this code:
    Code:

    <if condition="$giftuser != null">
    <input type="hidden" name="gift" value="$giftuser[userid]" />
    </if>

  • This step may be altered according to taste. I chose to insert the link that userA would click to pay for userB into userB's profile, i.e. MEMBERINFO, but it could just as easily be put in 'postbit'. Anyway...

    Edit template 'MEMBERINFO' in 'Member Info Templates'.

    Find:
    Code:

            <td class="vbmenu_control">
                    <if condition="$show['addbuddylist']">

    Add before that, this code:
    Code:

            <td class="vbmenu_control">
            <a href="payments.php?$session[sessionurl]gift=true&userid=$userinfo[userid]"><phrase 1="$userinfo[username]">$vbphrase[buy_x_a_sub]</phrase></a>
            </td>

And you're done.

Notes
  • Active subscriptions are never shown on the paid subscriptions page, either for the donor or the recipient, when visiting the paid subscriptions page through the gift subscription link.
  • The identity of the donor is not revealed to the recipient. An admin will have to check out the payment info if the recipient wants to know who gave them the subscription.

Screenshots
  • screen1.png: Member profile page containing link to subscription gift page
  • screen2.png: Subscription page showing that the user is about to pay for someone else

Skyline_GT 01-17-2006 06:05 AM

this mod looks cool..
thanks.,

FleaBag 01-17-2006 10:52 AM

Yeah definitely very nice! Thanks. :D

nexialys 01-17-2006 11:05 AM

really, i can't imagine to live without it now that it exists... lol

damn this is a good idea for a sharing community!

Princeton 01-17-2006 11:57 AM

Superb idea!!

chader144 01-17-2006 01:51 PM

very nice mod.. any chance we can get it in a plugin? (very lazy admin here)

ConqSoft 01-17-2006 02:00 PM

Umm. It is a plugin. Plugins can't modify templates though, so manual template changes are always going to be required.

Snake 01-17-2006 03:19 PM

Awesome. I'll probably install this tonight! ;)

Reeve of shinra 01-17-2006 03:24 PM

Great idea!

bashy 01-17-2006 05:42 PM

Hi

I have installed and clicked install...

I get this error now when i got my donations page????

Warning: Division by zero in /includes/functions.php(4320) : eval()'d code on line 10

Any ideas please?


All times are GMT. The time now is 07:23 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01105 seconds
  • Memory Usage 1,734KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (6)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete