Pm To All Club Members

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Pm To All Club Members

    pm 2 all club members.. I SEARCHED it.. but no results

    #2
    for lava script...

    Comment


      #3
      here :
      Code:
      else if($action=="gocl")
      {
        $clid = $_GET["clid"];
        $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id='".$clid."'"));
          addonline(getuid_sid($sid),"Viewing A Club","");
          $clnm = htmlspecialchars($clinfo[0]);
          echo "<card id=\"main\" title=\"$clnm\">";
      
          echo "<p align=\"center\">";
          echo "[size="1"][b]$clnm[/b][/size]
      ";
          if(trim($clinfo[4])=="")
          {
            echo "<img src=\"images/logo.jpg\" alt=\"logo\"/>";
          }else{
              echo "<img src=\"$clinfo[4]\" alt=\"logo\"/>";
          }
          echo "</p>";
          echo "
      
      [size="1"]";
          echo "Club ID: [b]$clid[/b]
      ";
          $uid = getuid_sid($sid);
          $cango = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND uid=&#39;".$uid."&#39; AND accepted=&#39;1&#39;"));
          echo "Owner: <a href=\"index.php?action=viewuser&amp;who=$clinfo[1]&amp;sid=$sid\">".getnick_uid($clinfo[1])."</a>
      ";
            $mems = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;1&#39;"));
            echo "Members: <a href=\"lists.php?action=clmem&amp;sid=$sid&amp;clid=$clid\">$mems[0]</a>
      ";
            echo "Created On: ".date("d/m/y", $clinfo[6])."
      ";
            echo "Plusses credit: $clinfo[5]
      ";
            $fid = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_forums WHERE clubid=&#39;".$clid."&#39;"));
            $rid = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_rooms WHERE clubid=&#39;".$clid."&#39;"));
            $tps = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE fid=&#39;".$fid[0]."&#39;"));
            $pss = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts a INNER JOIN ibwf_topics b ON a.tid = b.id WHERE b.fid=&#39;".$fid[0]."&#39;"));
            if(getuid_sid($sid)==$clinfo[1])
            {
            echo "<a href=\"index.php?action=pmallmem&amp;sid=$sid&amp;clid=$clid\">PM to All Club Members</a>
      ";
        }
          if(($cango[0]>0)||isowner($uid))
          {
                      if($clid==161) {
                  echo "<a href=\"http://space.sihalawap.com/modcp.php?action=clubup;sid=$sid&amp;clid=$clid\">Uploader</a>
      ";
          }
                  if($clid==248) {
                  echo "<a href=\"http://space.sihalawap.com/modcp.php?action=clubup2;sid=$sid&amp;clid=$clid\">Uploader</a>
      ";
          }
              $noa = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_announcements WHERE clid=&#39;".$clid."&#39;"));
              echo "
      <a href=\"lists.php?action=annc&amp;sid=$sid&amp;clid=$clid\"><img src=\"images/annc.gif\" alt=\"!\"/>Announcements($noa[0])</a>
      ";
              $noa = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_chat WHERE rid=&#39;".$rid[0]."&#39;"));
              echo "<a href=\"chat.php?sid=$sid&amp;rid=$rid[0]\"><img src=\"images/chat.gif\" alt=\"*\"/>$clnm Chat($noa[0])</a>
      ";
              echo "<a href=\"index.php?action=viewfrm&amp;sid=$sid&amp;fid=$fid[0]\"><img src=\"images/1.gif\" alt=\"*\"/>$clnm Forum($tps[0]/$pss[0])</a>
      
      ";
              $ismem = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND uid=&#39;".getuid_sid($sid)."&#39;"));
              
              if($ismem[0]>0)
              {
                  //unjoin 
                  if($clinfo[1]!=$uid)
                  {
                      echo "<a href=\"genproc.php?action=unjc&amp;sid=$sid&amp;clid=$clid\">Unjoin Club</a>";
                  }
              }else{
                  echo "<a href=\"genproc.php?action=reqjc&amp;sid=$sid&amp;clid=$clid\">Join Now!</a>";
              }
              if(isowner(getuid_sid($sid)))
              {
                  echo "
      <a href=\"admincp.php?action=club&amp;sid=$sid&amp;clid=$clid\">Admin Tools</a>";
              }
              if($clinfo[1]==$uid)
            {
              //club owner
              $mems = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;0&#39;"));
              echo "
      <a href=\"lists.php?action=clreq&amp;sid=$sid&amp;clid=$clid\">»Requests($mems[0])</a>
      ";
            }
          }else{
            echo "Topics: [b]$tps[0][/b], Posts: [b]$pss[0][/b]
      ";
            echo "[b]Description:[/b]
      ";
            echo htmlspecialchars($clinfo[2]);
            echo "
      
      ";
            echo "[b]Rules:[/b]
      ";
            echo htmlspecialchars($clinfo[3]);
            echo "
      
      ";
            echo "Seems Good? <a href=\"genproc.php?action=reqjc&amp;sid=$sid&amp;clid=$clid\">Join Now!</a>";
          }
          echo "[/size]</p>";
          echo "<p align=\"center\">";
          echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
      echo "Clubs list</a>
      ";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
      echo "Home</a>";
        echo "</p>";
          echo "</card>";
      }
      else if($action=="pmallmem")
      {
          $clid=$_GET["clid"];
          $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
              addonline(getuid_sid($sid),"PMing Club Members","index.php?action=$action");
          echo "<card id=\"main\" title=\"sihalawap.com\">";
          echo "<p align=\"center\">";
          echo "[b]PM All Members Of The $clinfo[0] Club[/b]
      
      ";
          echo "Please enter the message You Wish To Send To ALL Members Below
      ";
          echo "<input name=\"pmtext\" maxlength=\"500\"/>
      ";
          echo "<anchor>SEND<go href=\"index.php?action=sendclpm&amp;sid=$sid\" method=\"post\">";
          echo "<postfield name=\"clid\" value=\"$clid\"/>";
          echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
          echo "</go></anchor>
      </p>";
          echo "<p align=\"center\">";
          echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
          echo "Clubs list</a>
      ";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
          echo "Home</a>";
           echo "</p>";
          echo "</card>";
          }
      else if($action=="sendclpm")
      {
          $clid=$_POST["clid"];
          $pmtext=$_POST["pmtext"];
          $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
          $owner = $clinfo[1];
              addonline(getuid_sid($sid),"PMing Club Members","index.php?action=$action");
          echo "<card id=\"main\" title=\"sihalawap.com\">";
          echo "<p align=\"center\">";
          echo "[b]PM All Members Of The $clinfo[0] Club[/b]
      
      ";
          $mems = mysql_query("SELECT uid FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;1&#39;");
          while($row=mysql_fetch_array($mems))
          {
            $tm = time();
        $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$owner."&#39;, touid=&#39;".$row[0]."&#39;, timesent=&#39;".$tm."&#39;");
      }
        if($res)
        {
      
          echo "<img src=\"images/ok.gif\" alt=\"O\"/>";
          echo "PMs sent successfully
      
      ";
          echo parsepm($pmtext, $sid);
        }else{
          echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
          echo "Can&#39;t Send PM
      
      ";
        }
        echo "</p>";    
          echo "<p align=\"center\">";
          echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
          echo "Clubs list</a>
      ";
          echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
          echo "Home</a>";
           echo "</p>";
          echo "</card>";
          }
      Hate romains that take codes from here and tell to all that they had made that

      Comment


        #4
        Could U post the html code

        Comment


          #5
          thanks bro.... i&#39;ll try it...

          stop repeating same text

          Comment


            #6
            Code automatically PM to the owner of the club received in the club. Some claim that it received in the club and to get the PM of the owner when it receives in the club? Whether someone can do this code? please
            sigpichttp://happy.srecnica.com/web

            Comment


              #7
              when a member register to a club the owner to recive a pm ? :D
              Hate romains that take codes from here and tell to all that they had made that

              Comment


                #8
                <div class='quotetop'>QUOTE (ionutxp @ Jan 10 2009, 09:15 PM) <{POST_SNAPBACK}></div>
                when a member register to a club the owner to recive a pm ? :D[/b]
                Yes, just this as when a member registers on the forum and receive PM welcome from the owner of the Forum, so that a new member of the club receives from the owner of the club PM...
                sigpichttp://happy.srecnica.com/web

                Comment


                  #9
                  something like this:
                  Code:
                  else if($action=="reqjc")
                  {
                    $uid = getuid_sid($sid);
                    $clid = $_GET["clid"];
                    addonline(getuid_sid($sid),"Joining A Club","");
                    echo "<head>";
                    echo "<title>$sitename</title>";
                    echo "</head>";
                    echo "<body>"; 
                      echo "<p align=\"center\">";
                      $uid = getuid_sid($sid);
                      $isin = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE uid=&#39;".$uid."&#39; AND clid=&#39;".$clid."&#39;"));
                      if($isin[0]==0){
                          $res = mysql_query("INSERT INTO ibwf_clubmembers SET uid=&#39;".$uid."&#39;, clid=&#39;".$clid."&#39;, accepted=&#39;0&#39;, points=&#39;0&#39;, joined=&#39;".time()."&#39;");
                          if($res)
                          {
                              echo "<img src=\"images/ok.gif\" alt=\"o\"/>Request sent! The club owner should accept your request";
                  $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                  $pmtext = "I wanna join your [club=$clid]$clinfo[0] [/club] club[br/][br/][small](this is an auto pm)[/small]";
                  $tm = time();
                  $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$uid."&#39;, touid=&#39;".$clinfo[1]."&#39;, timesent=&#39;".$tm."&#39;");
                          }else{
                              echo "<img src=\"images/notok.gif\" alt=\"x\"/>Database Error!";
                          }
                          }else{
                              echo "<img src=\"images/notok.gif\" alt=\"x\"/>You are already in this club or request sent and waiting for acception";
                          }
                      echo "
                  
                  <a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
                  echo "Home</a>";
                    echo "</p>";
                      echo "</body>";
                     exit(); 
                  }
                  i couldnt be bothered to test it

                  Comment


                    #10
                    <div class='quotetop'>QUOTE (ionutxp @ Nov 19 2008, 07:23 AM) <{POST_SNAPBACK}></div>
                    here :
                    Code:
                    else if($action=="gocl")
                    {
                      $clid = $_GET["clid"];
                      $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                        addonline(getuid_sid($sid),"Viewing A Club","");
                        $clnm = htmlspecialchars($clinfo[0]);
                        echo "<card id=\"main\" title=\"$clnm\">";
                    
                        echo "<p align=\"center\">";
                        echo "[size="1"][b]$clnm[/b][/size]
                    ";
                        if(trim($clinfo[4])=="")
                        {
                          echo "<img src=\"images/logo.jpg\" alt=\"logo\"/>";
                        }else{
                            echo "<img src=\"$clinfo[4]\" alt=\"logo\"/>";
                        }
                        echo "</p>";
                        echo "
                    
                    [size="1"]";
                        echo "Club ID: [b]$clid[/b]
                    ";
                        $uid = getuid_sid($sid);
                        $cango = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND uid=&#39;".$uid."&#39; AND accepted=&#39;1&#39;"));
                        echo "Owner: <a href=\"index.php?action=viewuser&amp;who=$clinfo[1]&amp;sid=$sid\">".getnick_uid($clinfo[1])."</a>
                    ";
                          $mems = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;1&#39;"));
                          echo "Members: <a href=\"lists.php?action=clmem&amp;sid=$sid&amp;clid=$clid\">$mems[0]</a>
                    ";
                          echo "Created On: ".date("d/m/y", $clinfo[6])."
                    ";
                          echo "Plusses credit: $clinfo[5]
                    ";
                          $fid = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_forums WHERE clubid=&#39;".$clid."&#39;"));
                          $rid = mysql_fetch_array(mysql_query("SELECT id FROM ibwf_rooms WHERE clubid=&#39;".$clid."&#39;"));
                          $tps = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_topics WHERE fid=&#39;".$fid[0]."&#39;"));
                          $pss = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_posts a INNER JOIN ibwf_topics b ON a.tid = b.id WHERE b.fid=&#39;".$fid[0]."&#39;"));
                          if(getuid_sid($sid)==$clinfo[1])
                          {
                          echo "<a href=\"index.php?action=pmallmem&amp;sid=$sid&amp;clid=$clid\">PM to All Club Members</a>
                    ";
                      }
                        if(($cango[0]>0)||isowner($uid))
                        {
                                    if($clid==161) {
                                echo "<a href=\"http://space.sihalawap.com/modcp.php?action=clubup;sid=$sid&amp;clid=$clid\">Uploader</a>
                    ";
                        }
                                if($clid==248) {
                                echo "<a href=\"http://space.sihalawap.com/modcp.php?action=clubup2;sid=$sid&amp;clid=$clid\">Uploader</a>
                    ";
                        }
                            $noa = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_announcements WHERE clid=&#39;".$clid."&#39;"));
                            echo "
                    <a href=\"lists.php?action=annc&amp;sid=$sid&amp;clid=$clid\"><img src=\"images/annc.gif\" alt=\"!\"/>Announcements($noa[0])</a>
                    ";
                            $noa = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_chat WHERE rid=&#39;".$rid[0]."&#39;"));
                            echo "<a href=\"chat.php?sid=$sid&amp;rid=$rid[0]\"><img src=\"images/chat.gif\" alt=\"*\"/>$clnm Chat($noa[0])</a>
                    ";
                            echo "<a href=\"index.php?action=viewfrm&amp;sid=$sid&amp;fid=$fid[0]\"><img src=\"images/1.gif\" alt=\"*\"/>$clnm Forum($tps[0]/$pss[0])</a>
                    
                    ";
                            $ismem = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND uid=&#39;".getuid_sid($sid)."&#39;"));
                            
                            if($ismem[0]>0)
                            {
                                //unjoin 
                                if($clinfo[1]!=$uid)
                                {
                                    echo "<a href=\"genproc.php?action=unjc&amp;sid=$sid&amp;clid=$clid\">Unjoin Club</a>";
                                }
                            }else{
                                echo "<a href=\"genproc.php?action=reqjc&amp;sid=$sid&amp;clid=$clid\">Join Now!</a>";
                            }
                            if(isowner(getuid_sid($sid)))
                            {
                                echo "
                    <a href=\"admincp.php?action=club&amp;sid=$sid&amp;clid=$clid\">Admin Tools</a>";
                            }
                            if($clinfo[1]==$uid)
                          {
                            //club owner
                            $mems = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;0&#39;"));
                            echo "
                    <a href=\"lists.php?action=clreq&amp;sid=$sid&amp;clid=$clid\">»Requests($mems[0])</a>
                    ";
                          }
                        }else{
                          echo "Topics: [b]$tps[0][/b], Posts: [b]$pss[0][/b]
                    ";
                          echo "[b]Description:[/b]
                    ";
                          echo htmlspecialchars($clinfo[2]);
                          echo "
                    
                    ";
                          echo "[b]Rules:[/b]
                    ";
                          echo htmlspecialchars($clinfo[3]);
                          echo "
                    
                    ";
                          echo "Seems Good? <a href=\"genproc.php?action=reqjc&amp;sid=$sid&amp;clid=$clid\">Join Now!</a>";
                        }
                        echo "[/size]</p>";
                        echo "<p align=\"center\">";
                        echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
                    echo "Clubs list</a>
                    ";
                        echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
                    echo "Home</a>";
                      echo "</p>";
                        echo "</card>";
                    }
                    else if($action=="pmallmem")
                    {
                        $clid=$_GET["clid"];
                        $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                            addonline(getuid_sid($sid),"PMing Club Members","index.php?action=$action");
                        echo "<card id=\"main\" title=\"sihalawap.com\">";
                        echo "<p align=\"center\">";
                        echo "[b]PM All Members Of The $clinfo[0] Club[/b]
                    
                    ";
                        echo "Please enter the message You Wish To Send To ALL Members Below
                    ";
                        echo "<input name=\"pmtext\" maxlength=\"500\"/>
                    ";
                        echo "<anchor>SEND<go href=\"index.php?action=sendclpm&amp;sid=$sid\" method=\"post\">";
                        echo "<postfield name=\"clid\" value=\"$clid\"/>";
                        echo "<postfield name=\"pmtext\" value=\"$(pmtext)\"/>";
                        echo "</go></anchor>
                    </p>";
                        echo "<p align=\"center\">";
                        echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
                        echo "Clubs list</a>
                    ";
                        echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
                        echo "Home</a>";
                         echo "</p>";
                        echo "</card>";
                        }
                    else if($action=="sendclpm")
                    {
                        $clid=$_POST["clid"];
                        $pmtext=$_POST["pmtext"];
                        $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                        $owner = $clinfo[1];
                            addonline(getuid_sid($sid),"PMing Club Members","index.php?action=$action");
                        echo "<card id=\"main\" title=\"sihalawap.com\">";
                        echo "<p align=\"center\">";
                        echo "[b]PM All Members Of The $clinfo[0] Club[/b]
                    
                    ";
                        $mems = mysql_query("SELECT uid FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;1&#39;");
                        while($row=mysql_fetch_array($mems))
                        {
                          $tm = time();
                      $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$owner."&#39;, touid=&#39;".$row[0]."&#39;, timesent=&#39;".$tm."&#39;");
                    }
                      if($res)
                      {
                    
                        echo "<img src=\"images/ok.gif\" alt=\"O\"/>";
                        echo "PMs sent successfully
                    
                    ";
                        echo parsepm($pmtext, $sid);
                      }else{
                        echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
                        echo "Can&#39;t Send PM
                    
                    ";
                      }
                      echo "</p>";    
                        echo "<p align=\"center\">";
                        echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
                        echo "Clubs list</a>
                    ";
                        echo "<a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
                        echo "Home</a>";
                         echo "</p>";
                        echo "</card>";
                        }
                    [/b]

                    you can change this in XHTML and to a global pm message for ALL recorded users (not only in clubs)?
                    sigpicthe italian/international COMMUNITY of friendship
                    http://people2000.netne.net
                    WAP/WEB
                    peoplemailbox@katamail.com

                    Comment


                      #11
                      [quote]
                      here : [code]else if($action=="gocl")
                      {
                      $clid = $_GET["clid"];
                      $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rule
                      sigpicthe italian/international COMMUNITY of friendship
                      http://people2000.netne.net
                      WAP/WEB
                      peoplemailbox@katamail.com

                      Comment


                        #12
                        <div class='quotetop'>QUOTE (something else @ Jan 11 2009, 02:11 PM) <{POST_SNAPBACK}></div>
                        something like this:
                        Code:
                        else if($action=="reqjc")
                        {
                          $uid = getuid_sid($sid);
                          $clid = $_GET["clid"];
                          addonline(getuid_sid($sid),"Joining A Club","");
                          echo "<head>";
                          echo "<title>$sitename</title>";
                          echo "</head>";
                          echo "<body>"; 
                            echo "<p align=\"center\">";
                            $uid = getuid_sid($sid);
                            $isin = mysql_fetch_array(mysql_query("SELECT COUNT(*) FROM ibwf_clubmembers WHERE uid=&#39;".$uid."&#39; AND clid=&#39;".$clid."&#39;"));
                            if($isin[0]==0){
                                $res = mysql_query("INSERT INTO ibwf_clubmembers SET uid=&#39;".$uid."&#39;, clid=&#39;".$clid."&#39;, accepted=&#39;0&#39;, points=&#39;0&#39;, joined=&#39;".time()."&#39;");
                                if($res)
                                {
                                    echo "<img src=\"images/ok.gif\" alt=\"o\"/>Request sent! The club owner should accept your request";
                        $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                        $pmtext = "I wanna join your [club=$clid]$clinfo[0] [/club] club[br/][br/][small](this is an auto pm)[/small]";
                        $tm = time();
                        $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$uid."&#39;, touid=&#39;".$clinfo[1]."&#39;, timesent=&#39;".$tm."&#39;");
                                }else{
                                    echo "<img src=\"images/notok.gif\" alt=\"x\"/>Database Error!";
                                }
                                }else{
                                    echo "<img src=\"images/notok.gif\" alt=\"x\"/>You are already in this club or request sent and waiting for acception";
                                }
                            echo "
                        
                        <a href=\"index.php?action=main&amp;sid=$sid\"><img src=\"images/home.gif\" alt=\"*\"/>";
                        echo "Home</a>";
                          echo "</p>";
                            echo "</body>";
                           exit(); 
                        }
                        i couldnt be bothered to test it[/b]


                        This work, but PM the owner receives a club member who was elected to the club ... member should receive PM not the owner that it has received ... member should receive a notification from the owner that it has received and not the owner receives the PM that the member received Come a little if you can edit ... that members receive from the owner and PM not the owner of a member
                        sigpichttp://happy.srecnica.com/web

                        Comment


                          #13
                          <div class='quotetop'>QUOTE (honkytonkman @ Jan 11 2009, 05:14 PM) <{POST_SNAPBACK}></div>
                          you can change this in XHTML and to a global pm message for ALL recorded users (not only in clubs)?[/b]

                          this html
                          Code:
                          else if($action=="pmallmem")
                          {
                              $clid=$_GET["clid"];
                              $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                                  addonline(getuid_sid($sid),"[b]Salje PP svim clanovima kluba  $clinfo[0] [/b]","index.php?action=$action");
                              $pstyle = gettheme($sid);
                              echo xhtmlhead($clnm,$pstyle);
                          echo "<p align=\"center\">";
                              echo "<form action=\"index.php?action=sendclpm&amp;sid=$sid\" method=\"post\">";
                              echo "<input type=\"hidden\" name=\"clid\" value=\"$clid\"/>";
                              echo "<center>Text:<input name=\"pmtext\" maxlength=\"500\"/>
                          ";
                              echo "<input type=\"submit\" value=\"Posalji\"/></center";
                          
                              
                              echo "</form>
                          </p>";
                              echo "<p align=\"center\">";
                              echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
                              echo "Klubovi</a>
                          ";
                               $thid = mysql_fetch_array(mysql_query("SELECT themeid FROM ibwf_users WHERE id=&#39;".$uid."&#39;"));
                              $themeimageset = mysql_fetch_array(mysql_query("SELECT themedir FROM ibwf_iconset WHERE id=&#39;".$thid[0]."&#39;"));  
                              echo "<img src=\"images/themes/$themeimageset[0]/home.gif\" alt=\"*\"/> <a href=\"index.php?action=main&amp;sid=$sid\">";
                          echo "HAPPY</a>";
                            echo "</p>";
                              echo xhtmlfoot();
                              }
                          else if($action=="sendclpm")
                          {
                              $clid=$_POST["clid"];
                              $pmtext=$_POST["pmtext"];
                              $clinfo = mysql_fetch_array(mysql_query("SELECT name, owner, description, rules, logo, plusses, created FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                              $owner = $clinfo[1];
                                  addonline(getuid_sid($sid),"[b]Salje PP za sve clanove kluba $clinfo[0] [/b]","index.php?action=$action");
                              $pstyle = gettheme($sid);
                              echo xhtmlhead($clnm,$pstyle);
                              echo "<p align=\"center\">";
                              echo "[b]PP za sve clanove kluba   $clinfo[0] [/b]
                          
                          ";
                              $mems = mysql_query("SELECT uid FROM ibwf_clubmembers WHERE clid=&#39;".$clid."&#39; AND accepted=&#39;1&#39;");
                              while($row=mysql_fetch_array($mems))
                              {
                                $tm = time();
                            $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$owner."&#39;, touid=&#39;".$row[0]."&#39;, timesent=&#39;".$tm."&#39;");
                          }
                            if($res)
                            {
                          
                              echo "<img src=\"images/ok.gif\" alt=\"O\"/>";
                              echo "PP je uspesno poslata
                          
                          ";
                              echo parsepm($pmtext, $sid);
                            }else{
                              echo "<img src=\"images/notok.gif\" alt=\"X\"/>";
                              echo "Nemoguce je poslati PP
                          
                          ";
                            }
                            echo "</p>";    
                              echo "<p align=\"center\">";
                              echo "<a href=\"index.php?action=clubs&amp;sid=$sid\">";
                              echo "Klubovi</a>
                          ";
                               $thid = mysql_fetch_array(mysql_query("SELECT themeid FROM ibwf_users WHERE id=&#39;".$uid."&#39;"));
                              $themeimageset = mysql_fetch_array(mysql_query("SELECT themedir FROM ibwf_iconset WHERE id=&#39;".$thid[0]."&#39;"));  
                              echo "<img src=\"images/themes/$themeimageset[0]/home.gif\" alt=\"*\"/> <a href=\"index.php?action=main&amp;sid=$sid\">";
                          echo "HAPPY</a>";
                            echo "</p>";
                              echo xhtmlfoot();
                              }
                          sigpichttp://happy.srecnica.com/web

                          Comment


                            #14
                            couldnt be bothered to test it but something like this:
                            Code:
                            else if($action=="acm")
                            {
                              
                              $clid = $_GET["clid"];
                              $who = $_GET["who"];
                              addonline(getuid_sid($sid),"Adding a member to club","");
                                  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\">";
                                $uid = getuid_sid($sid);
                                $cowner = mysql_fetch_array(mysql_query("SELECT owner, name FROM ibwf_clubs WHERE id=&#39;".$clid."&#39;"));
                                if($cowner[0]==$uid){
                                    $res = mysql_query("UPDATE ibwf_clubmembers SET accepted=&#39;1&#39; WHERE clid=&#39;".$clid."&#39; AND uid=&#39;".$who."&#39;");
                                    if($res)
                                    {
                                        echo "<img src=\"../images/ok.gif\" alt=\"o\"/>Member added to your club";
                            
                            $pmtext = "You are now a member of the [club=$clid]$cowner[1] [/club] club[br/][br/][small](this is an auto pm)[/small]";
                            $tm = time();
                            $res = mysql_query("INSERT INTO ibwf_private SET text=&#39;".$pmtext."&#39;, byuid=&#39;".$uid."&#39;, touid=&#39;".$who."&#39;, timesent=&#39;".$tm."&#39;");
                            
                            
                            
                                    }else{
                                        echo "<img src=\"../images/notok.gif\" alt=\"x\"/>Database Error!";
                                    }
                                    }else{
                                        echo "<img src=\"../images/notok.gif\" alt=\"x\"/>This club ain&#39;t yours";
                                    }
                              echo "
                            
                            [b]0 [/b]<a accesskey=\"0\" href=\"index.php?action=main&amp;sid=$sid\"><img src=\"../images/home.gif\" alt=\"\"/>Home</a>";
                              echo "</p>";
                              echo "</body>";
                            }
                            :P

                            Comment


                              #15
                              something else ....yes beybe ... work! Come and have all received? ... tnx...:P
                              sigpichttp://happy.srecnica.com/web

                              Comment

                              Working...
                              X