 | [Solved]SMS MOD |  |
Posted: 08/03/2007 6:52 AM |
|
|
|
|
|
| Citation |
| Posts |
487 |
| Word Cnt. |
35,729 |
| BDay |
Oct 3 |
| Sign |
Libra |
| Sex |
 |
|
|
|
Joined: Oct 29, 2006
Local time: 11:03 PM
Location: Klang, Malaysia
|

|
|
|
|
 |
I just want to know this MOD last step~ This step is ask me open sms.php and find the << I cannot find this word on the sms.php. Can you help me to explain? Issit i need to add the it manual? But if yes, which place i need to add it?
| Code:
|
#
#-----[ OPEN ]------------------------------------------
#
sms.php
#
#-----[ FIND ]------------------------------------------
#
yournumber@yourprovider.com
#
#-----[ REPLACE WITH ]--------------------------
#
This is where you put your cell phone number email address,If you dont know,call or email your
cell phone provider,they might tell you.It is usally in a form of
#
#-----[ FIND ]------------------------------------------
#
you@yoursite.com
#
#-----[ REPLACE WITH ]--------------------------
#
Your email address
|
I have second error msg on my admin panel .Got 2 black line on subsilver templates Configuration,But the avalanche templates are no have.
How to delete the black line? Is the blank line got some fucntion?
P/S: Im installing this MOD with manually before . I has also check some MOD code already inside my files. |
|
Last edited by masteranu84 on 08/07/2007 7:11 AM; edited 1 time in total |
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/04/2007 12:36 AM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 7:03 PM
Location: St Pete, FL
|

|
|
|
|
 |
Yes, since the sms.php file is included with the MOD, you need to be modifying it manually to suit your email addy and cell phone provider addy. You can remove that section from the MOD script and modify the code in the sms.php file before you install the MOD so that you don't have to do it afterwards...
The COPY section is wrong too. Ok, try this:
OPEN
SMS Contact install.txt
FIND
| Code:
|
#
#-----[ COPY ]------------------------------------------
#
sms.php
sms_install.php
templates/subSilver/images/icon_mini_sms.gif
|
REPLACE WITH
| Code:
|
#
#-----[ COPY ]------------------------------------------
#
copy sms.php to sms.php
copy templates/subSilver/images/icon_mini_sms.gif to templates/subSilver/images/icon_mini_sms.gif
|
You might as well fix the SQL section while you're there too:
FIND
| Code:
|
#
#-----[ SQL ]------------------------------------------
#
INSERT INTO phpbb_config (config_name, config_value) VALUES ('sms_disable', '0');
or run the sms_install.php
|
REPLACE WITH
| Code:
|
#
#-----[ SQL ]------------------------------------------
#
INSERT INTO phpbb_config (config_name, config_value) VALUES ('sms_disable', '0');
|
And since you will be correcting this in the sms.php file before you install it, you can do this:
FIND & DELETE
| Code:
|
#
#-----[ OPEN ]------------------------------------------
#
sms.php
#
#-----[ FIND ]------------------------------------------
#
yournumber@yourprovider.com
#
#-----[ REPLACE WITH ]--------------------------
#
This is where you put your cell phone number email address,If you dont know,call or email your
cell phone provider,they might tell you.It is usally in a form of
#
#-----[ FIND ]------------------------------------------
#
you@yoursite.com
#
#-----[ REPLACE WITH ]--------------------------
#
Your email address
|
Since you support alternate languages in your forum, you will also have to correct this:
FIND
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
$lang['Board_disable_explain'] = 'This will make the board unavailable to users. Administrators are able to access the Administration Panel while the board is disabled.';
|
REPLACE WITH
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
$lang['Board_disable_explain'] =
|
FIND
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
$lang['Board_disable'] = 'Sorry, but this board is currently unavailable. Please try again later.';
|
REPLACE WITH
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
$lang['Board_disable'] =
|
Save, upload, and try again using EM...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/04/2007 12:40 AM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 7:03 PM
Location: St Pete, FL
|

|
|
|
|
 |
| masteranu84 wrote:
|
I have second error msg on my admin panel .Got 2 black line on subsilver templates Configuration,But the avalanche templates are no have.
How to delete the black line? Is the blank line got some fucntion?
.
|
It looks like you have already correct this problem:
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/04/2007 3:49 AM |
|
|
|
|
|
| Citation |
| Posts |
487 |
| Word Cnt. |
35,729 |
| BDay |
Oct 3 |
| Sign |
Libra |
| Sex |
 |
|
|
|
Joined: Oct 29, 2006
Local time: 11:03 PM
Location: Klang, Malaysia
|

|
|
|
|
 |
Ok, i has manul to uninstall the sms mod..now i want using the EM to install it.But get this error.
| Code:
|
Error Detail
Critical Error
FIND FAILED: In file [templates/subSilver/admin/board_config_body.tpl] could not find:
<tr>
<td class="row1">{L_DISABLE_BOARD}<br /><span class="gensmall">{L_DISABLE_BOARD_EXPLAIN}</span></td>
<td class="row2"><input type="radio" name="board_disable" value="1" {S_DISABLE_BOARD_YES} /> {L_YES} <input type="radio" name="board_disable" value="0" {S_DISABLE_BOARD_NO} /> {L_NO}</td>
</tr>
MOD script line #198 :: FAQ :: Report
|
|
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/05/2007 2:39 PM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 7:03 PM
Location: St Pete, FL
|

|
|
|
|
 |
Yes, this is another perferct example of a MOD author including far more information in the FIND statement and reducing the odds that it can install cleanly on most sites. So this is how you minimize the FIND so that it has a much better chance of working for you:
OPEN
SMS Contact install.txt
FIND
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
<tr>
<td class="row1">{L_DISABLE_BOARD}<br /><span class="gensmall">{L_DISABLE_BOARD_EXPLAIN}</span></td>
<td class="row2"><input type="radio" name="board_disable" value="1" {S_DISABLE_BOARD_YES} /> {L_YES} <input type="radio" name="board_disable" value="0" {S_DISABLE_BOARD_NO} /> {L_NO}</td>
</tr>
|
REPLACE WITH
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
{S_DISABLE_BOARD_YES}
</tr>
|
I can see that the following is going to be a problem too, so you might as well fix it while you're there:
FIND
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
<a href="profile.php?mode=editprofile" class="mainmenu"><img src="templates/subSilver/images/icon_mini_profile.gif" width="12" height="13" border="0" align="top" alt="Profile" hspace="3" />Profile</a>
#
#-----[ AFTER ADD ]--------------------------
#
<a href="{U_SMS}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_sms.gif" border="0" align="top" alt="SMS Contact" hspace="3" />{L_SMS}</a>
|
REPLACE WITH
| Code:
|
#
#-----[ FIND ]------------------------------------------
#
{L_PROFILE}
#
#-----[ IN-LINE FIND ]------------------------------------------
#
#
#-----[ IN-LINE AFTER, ADD ]--------------------------
#
<a href="{U_SMS}" class="mainmenu"><img src="templates/subSilver/images/icon_mini_sms.gif" border="0" align="top" alt="SMS Contact" hspace="3" />{L_SMS}</a>
|
I also see that many of the MOD commands are wrong, so EM would not recognize them. So you need to do this:
FIND
REPLACE ALL INSTANCES WITH
Save, upload, and try again using EM...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/05/2007 9:04 PM |
|
|
|
|
|
| Citation |
| Posts |
487 |
| Word Cnt. |
35,729 |
| BDay |
Oct 3 |
| Sign |
Libra |
| Sex |
 |
|
|
|
Joined: Oct 29, 2006
Local time: 11:03 PM
Location: Klang, Malaysia
|

|
|
|
|
 |
| Ok, i has success to install the MOD, but how i edit my phone number ? I did't see any edit number option on my administralpanel . |
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/06/2007 12:46 AM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 7:03 PM
Location: St Pete, FL
|

|
|
|
|
 |
The MOD author didn't provide an ACP option for changing the number. You have to change the number manually in your sms.php file if you didn't do it before you installed the MOD...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/06/2007 3:41 AM |
|
|
|
|
|
| Citation |
| Posts |
487 |
| Word Cnt. |
35,729 |
| BDay |
Oct 3 |
| Sign |
Libra |
| Sex |
 |
|
|
|
Joined: Oct 29, 2006
Local time: 11:03 PM
Location: Klang, Malaysia
|

|
|
|
|
 |
Now the sms.php file didn't have a code for the provider number. Where my provider number need to save at?
| Code:
|
<?php
/********************************************************************* ******
* sms.php
* -------------------
* begin : 2003-12-31
* copyright : (C) 2004 Shof515
* email :
*
********************************************************************* ******/
/********************************************************************* ******
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
********************************************************************* ******/
// standard hack prevent
define('IN_PHPBB', true);
$phpbb_root_path = './';
include($phpbb_root_path . 'extension.inc');
include($phpbb_root_path . 'common.'.$phpEx);
// standard session management
$userdata = session_pagestart($user_ip, PAGE_SMS);
init_userprefs($userdata);
if ( !$userdata['session_logged_in'] )
{
redirect(append_sid("login.$phpEx?redirect=sms.$phpEx", true));
}
if( $board_config['sms_disable'] && !defined("IN_ADMIN") )
{
message_die(GENERAL_MESSAGE, 'sms_disable', 'Information');
}
// End session management
// set page title
$page_title = 'SMS Contact Form';
// standard page header
include($phpbb_root_path . 'includes/page_header.'.$phpEx);
$smsto="(address here)";
$subject="SMS";
$meslength="160";
if ($action==send) {
if($fromemail==""){
$fromemail="(email adress)";
}
$bodytext="$name wrote, \"$message\"";
$body="$bodytext";
if (strlen($body)>$meslength) {
$newbody = wordwrap($body, $meslength, "<br>");
$barr = explode("<br>", $newbody);
$count=count($barr);
for($i = 0; $i < $count; $i++) {
$i2=$i+1;
$barr[$i]="($i2/$count) \n $barr[$i]";
echo"$barr[$i]<br>";
mail($smsto, $subject, $barr[$i], "From: $fromemail");
}
}
else {
mail($smsto, $subject, $body, "From: $fromemail");
}
$meta = '<meta http-equiv="refresh" content="3;url=' . append_sid("index.$phpEx") . '">';
$message = 'Thanks for your message.<br /><br />' . sprintf($lang['Click_return_index'], '<a href="' . append_sid("index.$phpEx") . '">', '</a>');
$template->assign_vars(array(
'META' => $meta)
);
message_die(GENERAL_MESSAGE, $message);
}
else
{
// assign template
$template->set_filenames(array(
'body' => 'sms.tpl')
);
$template->assign_vars(array(
'S_FORM_ACTION' => 'sms.' . $phpEx . '?action=send'
));
$template->pparse('body');
// standard page footer
include($phpbb_root_path . 'includes/page_tail.'.$phpEx);
}
?>
|
 |
|
|
 |
 |
| Back to Top |
|
|
 | Re: SMS MOD |  |
Posted: 08/06/2007 5:11 AM |
|
|
|
|
|
| Site Admin |
| Posts |
30757 |
| Word Cnt. |
2,628,690 |
| BDay |
Jul 28 |
| Sign |
Leo |
| Sex |
 |
|
|
|
Joined: Sep 25, 2004
Local time: 7:03 PM
Location: St Pete, FL
|

|
|
|
|
 |
It looks like the MOD author screwed up. None of the code that he tells you to find in the sms.php file is there. You should contact the MOD author and ask them for advice on this one...
 |
|
|
 |
 |
| Back to Top |
|
|
 | Information |  |
|