how to make automessage for book in lavalair? How can I make every time someone signs the book user the owner of that book arrives an automated message warning .Thanks to anyone who helps me
....silence please....
Started on the old forum in July 2010 · view the original in the archive · old links redirect here
Written automatically from the replies by a language model on our own server. It can be wrong; the posts below are the source.
how to make automessage for book in lavalair? How can I make every time someone signs the book user the owner of that book arrives an automated message warning .Thanks to anyone who helps me
....silence please....
Add it to ur site easy.
$pm = who("who[0]","$by");
sql = mysql_query("INCLUDE NOOB_BASE where id,user ORDER BY id='$id'");
thats not how it is but you got a idea..
Visit: Chat4u.mobi - The New Lay Of being a site of your dreams! Visit: WapMasterz Coming Back Soon!
SCRIPTS FOR SALE BY SUBZERO Chat4u Script : coding-talk.com/f28/chat4u-mobi-script-only-150-a-17677/ - > Best Script for your site no other can be hacked by sql or uploaders. FileShare Script : coding-talk.com/f28/file-wap-share-6596/ -> Uploader you will never regret buying yeah it mite be old now but it still seems to own others... _______…
subzero in which file? I had tried to do that long ago for the blog comments and made me ghost message
$byuid = getuid_sid($sid);
$pmtext = "<b>".$did."</b></u><br/><b>".$uid." Comment on your blog [br/][br/][small] This is an automated message, and do not respond to it [/small]";
$tm = time();
$res = mysql_query("INSERT INTO ibwf_private SET text='".$pmtext."', byuid='".$did."', touid='".$who."', timesent='".$tm."'");
or a message appeared to me or nn ghost appeared nothing, anyway I could see the message in the database 🙁 What wrong? 🙁
....silence please....
thanatos thanks for the tip and I am doing but there's a lot to learn and, If I'm not mistaken this forum should be the place to ask for help from people who make themselves available to give it 🙂
....silence please....
LadyEnigma wrote: subzero in which file? I had tried to do that long ago for the blog comments and made me ghost message
$byuid = getuid_sid($sid); $pmtext = "<b>".$did."</b></u><br/><b>".$uid." Comment on your blog [br/][br/][small] This is an automated message, and do not respond to it [/small]"; $tm = time(); $res = mysql_query("INSERT INTO ibwf_private SET text='".$pmtext."', byuid='".$did."', touid='".$who."', timesent='".$tm."'");or a message appeared to me or nn ghost appeared nothing, anyway I could see the message in the database 🙁 What wrong? :(
post the the guestbook coding and the genproc coding has well
LadyEnigma wrote: thanatos thanks for the tip and I am doing but there's a lot to learn and, If I'm not mistaken this forum should be the place to ask for help from people who make themselves available to give it :)
Thats so true they all stay like that...
thanatos wrote: ppl will never learn if they always depend on others. try learning php and mysql and see for urslf wat u cn accomplish with it
i am sure you see that she tried and cant get it thats why she is asking for help...if you dont want to help just leave the topic alone simple
wap_king wrote: post the the guestbook coding and the genproc coding has well
else if($action=="gbook")
{
$who = $_GET["who"];
$mmsg = htmlspecialchars(getsetmood(getuid_sid($sid)));
addonline(getuid_sid($sid),"sta guardando il Guestbook ($mmsg)","");
echo "<head>";
echo "<title>guestbook</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
$uid = getuid_sid($sid);
//////ALL LISTS SCRIPT <<
if($page=="" || $page<=0)$page=1;
$noi = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_gbook WHERE gbowner='".$who."'"));
$num_items = $noi[0]; //changable
$items_per_page= 5;
$num_pages = ceil($num_items/$items_per_page);
if(($page>$num_pages)&&$page!=1)$page= $num_pages;
$limit_start = ($page-1)*$items_per_page;
$sql = "SELECT gbowner, gbsigner, gbmsg, dtime, id FROM ibwf_gbook WHERE gbowner='".$who."' ORDER BY dtime DESC LIMIT $limit_start, $items_per_page";
echo "<p>";
$items = mysql_query($sql);
echo mysql_error();
if(mysql_num_rows($items)>0)
{
while ($item = mysql_fetch_array($items))
{
if(isonline($item[1]))
{
$iml = "<img src=\"../images/onl.gif\" alt=\"+\"/>";
}else{
$iml = "<img src=\"../images/ofl.gif\" alt=\"-\"/>";
}
$snick = getnick_uid($item[1]);
$lnk = "<a href=\"index.php?action=viewuser&who=$item[1]&sid=$sid\">$iml$snick</a>";
$bs = date("d m y-H:i:s",$item[3]);
echo "$lnk<br/><small>";
if(candelgb($uid, $item[4]))
{
$delnk = "<a href=\"genproc.php?action=delfgb&sid=$sid&mid=$item[4]\">[x]</a>";
}else{
$delnk = "";
}
$text = parsepm($item[2], $sid);
echo "$text<br/>$bs $delnk<br/>";
echo "</small>";
}
}
echo "</p>";
echo "<p align=\"center\">";
if($page>1)
{
$ppage = $page-1;
echo "<a href=\"lists.php?action=$action&page=$ppage&sid=$sid&who=$who\">«Indietro</a> ";
}
if($page<$num_pages)
{
$npage = $page+1;
echo "<a href=\"lists.php?action=$action&page=$npage&sid=$sid&who=$who\">Avanti»</a>";
}
echo "<br/>$page/$num_pages<br/>";
if($num_pages>2)
{
$rets = "<form action=\"lists.php\" method=\"get\">";
$rets .= "<input name=\"page\" style=\"-wap-input-format: '*N'\" size=\"2\"/>";
$rets .= "<input type=\"hidden\" name=\"action\" value=\"$action\"/>";
$rets .= "<input type=\"hidden\" name=\"sid\" value=\"$sid\"/>";
$rets .= "<input type=\"hidden\" name=\"who\" value=\"$who\"/>";
$rets .= "<input type=\"submit\" value=\"vai a pagina\"/>";
$rets .= "</form>";
echo $rets;
}
echo "</p>";
////// UNTILL HERE >>
echo "<p align=\"center\">";
if(cansigngb($uid, $who))
{
echo "<a href=\"index.php?action=signgb&sid=$sid&who=$who\">Aggiungi tuo Messaggio</a><br/>";
}
echo "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
echo "</p>";
echo "</body>";
}
genproc
else if($action=="signgb")
{
$who = $_POST["who"];
if(!cansigngb(getuid_sid($sid), $who))
{
echo "<head>";
echo "<title>$sitename</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
echo "<p align=\"center\">";
echo "You cant Sign this user guestbook<br/><br/>";
echo "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
echo "</p>";
echo "</body>";
echo "</html>";
exit();
}
$msgtxt = $_POST["msgtxt"];
//$qut = $_POST["qut"];
addonline(getuid_sid($sid),"Signing a guestbook","");
echo "<head>";
echo "<title>$sitename</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
echo "<p align=\"center\">";
$crdate = time();
//$uid = getuid_sid($sid);
$res = false;
if(trim($msgtxt)!="")
{
$res = mysql_query("INSERT INTO ibwf_gbook SET gbowner='".$who."', gbsigner='".$uid."', dtime='".$crdate."', gbmsg='".$msgtxt."'");
}
if($res)
{
echo "<img src=\"../images/ok.gif\" alt=\"O\"/>Message Posted Successfully";
}else{
echo "<img src=\"../images/notok.gif\" alt=\"X\"/>Error Posting Message";
}
echo "<br/><br/>";
echo "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
echo "</p>";
echo "</body>";
}
and in index
//////////////////////////////////////////Guestbook
else if($action=="signgb")
{
$who=$_GET["who"];
addonline(getuid_sid($sid),"Signing Users guestbook","");
if(!cansigngb(getuid_sid($sid), $who))
{
echo "<head>";
echo "<title>Firma Guestbook</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
echo "<p align=\"center\">";
echo "Puoi firmare questo guestbook<br/><br/>";
echo "<a href=\"index.php?action=main&sid=$sid\">Home</a>";
echo "</p>";
echo "</body>";
echo "</html>";
exit();
}
echo "<head>";
echo "<title>Firma Guestbook</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
echo "<p align=\"center\">";
echo "<form action=\"genproc.php?action=signgb&sid=$sid\" method=\"post\">";
echo "<input type=\"hidden\" name=\"who\" Value=\"$who\">";
echo "Testo:<input name=\"msgtxt\" maxlength=\"500\"/><br/>";
echo "<input type=\"Submit\" name=\"Add\" Value=\"Add\"></form>";
echo "<br/><br/><b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
echo "</p>";
echo "</body>";
}
Thanks in advance for your interest in my post wap king 🙂
....silence please....
no problem 🙂 just replace ur genproc with this one
else if($action=="signgb")
{
$who = $_POST["who"];
if(!cansigngb(getuid_sid($sid), $who))
{
echo "<head>";
echo "<title>$sitename</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
echo "<p align=\"center\">";
echo "You cant Sign this user guestbook<br/><br/>";
echo "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
echo "</p>";
echo "</body>";
echo "</html>";
exit();
}
$msgtxt = $_POST["msgtxt"];
//$qut = $_POST["qut"];
addonline(getuid_sid($sid),"Signing a guestbook","");
echo "<head>";
echo "<title>$sitename</title>";
echo "<link rel=\"stylesheet\" type=\"text/css\" href=\"../themes/$theme[0]\">";
echo "</head>";
echo "<body>";
echo "<p align=\"center\">";
$crdate = time();
//$uid = getuid_sid($sid);
$res = false;
if(trim($msgtxt)!="")
{
$res = mysql_query("INSERT INTO ibwf_gbook SET gbowner='".$who."', gbsigner='".$uid."', dtime='".$crdate."', gbmsg='".$msgtxt."'");
}
if($res)
{
$user = getnick_sid($sid);
$msg = " $user signed your guestbook: $msgtxt";
mysql_query("INSERT INTO ibwf_private SET text='".$msg."', byuid='$uid', touid='".$who."', unread='1', timesent='".time()."'");
echo "<img src=\"../images/ok.gif\" alt=\"O\"/>Message Posted Successfully";
}else{
echo "<img src=\"../images/notok.gif\" alt=\"X\"/>Error Posting Message";
}
echo "<br/><br/>";
echo "<b>0 </b><a accesskey=\"0\" href=\"index.php?action=main&sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
echo "</p>";
echo "</body>";
}
It works perfectly! I am very grateful wap_king with your example I did also automatic messages even for blog comment, thanks wap_king, my best regard for you 🙂
....silence please....