link to subscriptions

This topic contains 7 reply and 2 voices, and was last updated by trevor 10 years, 2 months ago
Viewing 7 Posts - 1 through 7 (of 7 total)
Author Posts
February 12, 2014 at 10:10 am 15369
trevor Hi , I have created subscription plans and the work well but what I cant work out how to do is to place a link on the page that says " you must purchase a pack before posting" I know I can place a short code and that works fine but I only want it to show if the user is not signed up to a package. Can you tell me how I can achieve this. Many thanks.
February 12, 2014 at 4:06 pm 15377
trevor trevor

Anyone?

February 13, 2014 at 2:15 am 15389
Tareq Hasan Tareq Hasan

Unfortunately there is no way doing this without adding some texts in php file. You can do that in /class/subscription.php in line 394.

February 13, 2014 at 7:24 pm 15412
trevor trevor

Thanks for the suggestion,

I don’t know much about code so how would I enter code to render the available subscription packages and or;

a link saying click here to select view subscription packages.

Thanks.

February 14, 2014 at 2:57 am 15435
trevor trevor

Did you have any thoughts on this?

February 14, 2014 at 11:35 am 15442
Tareq Hasan Tareq Hasan

[php]
if ( $force_pack == ‘yes’ && WPUF_Subscription::has_user_error() ) {
return __( ‘You must purchase a pack before posting’, ‘wpuf’ );
}[/php]

Change this to the following:
[php]if ( $force_pack == ‘yes’ && WPUF_Subscription::has_user_error() ) {
return sprintf( __( ‘You must <a href="%s">purchase a pack</a> before posting’, ‘wpuf’ ), ‘http://your-link-goes-here.com&#8217; );
}[/php]

February 15, 2014 at 5:14 am 15471
trevor trevor

Great, Thank you this worked a charm, I also put a redirect to the selection page, works well.
Thank you!

February 20, 2014 at 1:45 am 15665
trevor trevor

Hello Tareq,

Thanks for getting back to me,

I see the line. So if I wanted display the plans how would I do that , I assume I can’t just put a short code in the php?

How would I get subscription packs to show here

Thank you

Kind Regards,

Trevor

From: weDevs Team [mailto:support@mail333.us4.mandrillapp.com] On Behalf Of weDevs Team
Sent: 12 February 2014 20:16
To: trevor@tekclub.co.uk
Subject: Re: [weDevs] link to subscriptions

Tareq Hasan wrote:

Unfortunately there is no way doing this without adding some texts in php
file. You can do that in `/class/subscription.php` in line 394.

Viewing 7 Posts - 1 through 7 (of 7 total)