I am following the instructions in the "Membership / Subscription Only" to setup a subscription service. Step a (modifying login.tpl.php) and b (modifying account.tpl.php) worked. However I am lost as to what to do next (Basic Page Protection). Am I suppose to set the "return URL" after PayPal to some php file that check membership status? I try that (I don't speak php) but ended up with one big blank screen. Here's the php suggested:
<?php
if (!tep_session_is_registered('customer_id')) {
$navigation->set_snapshot();
tep_redirect(tep_href_link(FILENAME_LOGIN, '', ''));
}
define('NAVBAR_TITLE', 'title 1');
define('HEADING_TITLE', 'title 2');
define('TEXT_INFORMATION', 'All of my Text & HTML is inserted here');
?>
Latest News: (loading..)
Membership / Subscription Only - after step b, what do I do next?
Started by ecs1749, Aug 21 2012 06:44 PM
1 reply to this topic
#1
Posted 21 August 2012 - 06:44 PM
#2
Posted 22 August 2012 - 06:39 PM
ecs1749, on 21 August 2012 - 06:44 PM, said:
I am following the instructions in the "Membership / Subscription Only" to setup a subscription service. Step a (modifying login.tpl.php) and b (modifying account.tpl.php) worked. However I am lost as to what to do next (Basic Page Protection). Am I suppose to set the "return URL" after PayPal to some php file that check membership status? I try that (I don't speak php) but ended up with one big blank screen. Here's the php suggested:
<?php
if (!tep_session_is_registered('customer_id')) {
$navigation->set_snapshot();
tep_redirect(tep_href_link(FILENAME_LOGIN, '', ''));
}
define('NAVBAR_TITLE', 'title 1');
define('HEADING_TITLE', 'title 2');
define('TEXT_INFORMATION', 'All of my Text & HTML is inserted here');
?>
<?php
if (!tep_session_is_registered('customer_id')) {
$navigation->set_snapshot();
tep_redirect(tep_href_link(FILENAME_LOGIN, '', ''));
}
define('NAVBAR_TITLE', 'title 1');
define('HEADING_TITLE', 'title 2');
define('TEXT_INFORMATION', 'All of my Text & HTML is inserted here');
?>
Got a little further. Now the top of my index.php page looks like this:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<?php
ini_set('display_errors', 'On');
require('http://www.mydomain.com/catalog/includes/application_top.php');
if (!tep_session_is_registered('customer_id')) {
$navigation->set_snapshot();
tep_redirect(tep_href_link('http://www.mydomain.com/catalog/create_account.php' '', ''));
}
?>
<html>
<head>
...rest of html...
No error reported but still white screen - it neither send me to log-in, nor display the contents. Help!!!









