Author Topic: Bank Interest????  (Read 5719 times)

Offline upgrant

Bank Interest????
« on: October 24, 2006, 01:19:23 pm »
I have searched and searched. I cannot get the bank interest to work! i am using shop 2.3

What is da code and where about do i change it.

Hope you can help

Peace

Offline Daniel15

Re: Bank Interest????
« Reply #1 on: October 27, 2006, 06:46:02 pm »
Take a look at the instructions at http://www.daniel15.com/smfshop_wiki/Bank_Interest :)

Offline Maniakc

Re: Bank Interest????
« Reply #2 on: January 10, 2007, 04:45:45 pm »
Sorry for bumping this, but Im using GoDaddy and they dont have the same kind of CPanel, is there another way to do it?

Offline Daniel15

Re: Bank Interest????
« Reply #3 on: January 11, 2007, 09:23:30 am »
Sure, take a look at the Bank interest without cron job? Read this! topic :)

Offline Maniakc

Re: Bank Interest????
« Reply #4 on: January 12, 2007, 07:17:53 am »
Displays:

Warning: main(/home/content/m/a/n/html/forums/SSI.php): failed to open stream: No such file or directory in /home/content/m/a/n/maniakc/html/forums/dointerest.php on line 14

Warning: main(/home/content/m/a/n/html/forums/SSI.php): failed to open stream: No such file or directory in /home/content/m/a/n/maniakc/html/forums/dointerest.php on line 14

Warning: main(): Failed opening '/home/content/m/a/n/html/forums/SSI.php' for inclusion (include_path='.:/usr/local/lib/php') in /home/content/m/a/n/maniakc/html/forums/dointerest.php on line 14

Fatal error: Call to undefined function: db_query() in /home/content/m/a/n/maniakc/html/forums/dointerest.php on line 17
« Last Edit: January 12, 2007, 12:13:02 pm by Maniakc »

Offline Daniel15

Re: Bank Interest????
« Reply #5 on: January 13, 2007, 02:08:33 pm »
Make sure the include line at the top of that script looks like:
Code: [Select]
include('/home/content/m/a/n/maniakc/html/forums/SSI.php');

Offline Maniakc

Re: Bank Interest????
« Reply #6 on: January 14, 2007, 04:07:12 am »
Its likely that its the simplest thing, I know nothing about php.
Code: [Select]
<?php
/**********************************************\
| SMFSHOP (Shop MOD for Simple Machines Forum) |
|         (c) 2005 DanSoft Australia           |
|      http://www.dansoftaustralia.com/        |
\**********************************************/

//File: dointerest.php
//      The file to add interest to member's bank

//VERSION: 1.31 (Build 7)
//DATE: 10th December 2005

include('/home/content/m/a/n/maniakc/html/forums/SSI.php');

$interest_rate $modSettings['shopInterest'] / 100;
db_query("UPDATE {$db_prefix}members
SET moneyBank = moneyBank + (moneyBank*
{$interest_rate})"__FILE__
__LINE__);

echo 
"Interest added at ".date("d/m/Y h:i:s A");
?>


Its probably just something I forgot to add.

Offline Daniel15

Re: Bank Interest????
« Reply #7 on: February 24, 2007, 09:08:47 am »
Hmmmm... Does SSI.php exist in the forum's directory?

Offline Maniakc

Re: Bank Interest????
« Reply #8 on: February 24, 2007, 11:38:41 am »
It works, now, its all good ;)