Jump to content

techker

Members
  • Posts

    812
  • Joined

  • Last visited

Posts posted by techker

  1. Hey guys , i have my own IPTV provider and i would like to make a web portal .

     

    in iptv there are some providers that offer a web viewer if you have no source for streaming like a Mag box..

     

    the link is all M3U

     

    we login and we see the channels and EPG guide(tv guide)

     

    so in m3 u mode we get a link:

    http://stb.spades-tv.xyz:25461/client_area/live.php
    

     and if you use a M3u player like VLC or perfect player you  get

     

    http://stb.spades-tv.xyz:25461/get.php?
    username=xxxxx&password=xxxxx&
    type=m3u_plus&output=ts

    in a m3u file :

    #EXTVLCOPT:http-user-agent=tttttttiiii LibVLC/3.0.0-git
    #EXTINF:-1,SFR Sport 1HD Fr
    http://rmd.primatv.club:8899/live/BestTV.FB/OAfllsYAJy/1464.ts
    

    gives you the channel and icon and link to video

     

     

    so the question is what can i use to play this?HTML5? i know the php is to get the files...

     

     

  2. Hey guys when i create a button in step 3 click the box add variables..

     

    so i tried different formats:

     

    UserId=1

     

     

     

    or even html and when i generate the code i don't see it?

     

     

     

    and once this works how do i see the value?when the clients pays it will send me the value?

     

     

  3. ya i got it going. i need to incluse the phpmailer in all the sites i do.

     

    i got the mailer to work for one client.still need to to an array and send emails out to all emails in the array..

     

     

    this is the page that gathers info :

    $con=mysqli_connect("localhost","8","8","8");
    // Check connection
    if (mysqli_connect_errno())
      {
      echo "Failed to connect to MySQL: " . mysqli_connect_error();
      }
    
    
    $todayDate = date("Y-m-d");
    //Add 
    $dateOneMonthAdded = strtotime(date("Y-m-d", strtotime($todayDate)) . "+1 month");
    //echo "After adding one month: ".date('l dS \o\f F Y', $dateOneMonthAdded)."<br>";
    $fiveDays = date ("Y-m-d", strtotime ($today ."-3 days"));
    $fiveDays3 = date ("Y-m-d", strtotime ($today ."+3 days"));
    
    $sql = 'SELECT * FROM Client_Data';
    $result = mysqli_query($con, $sql);
    
                    
    
    if (mysqli_num_rows($result) > 0) {
                while($row = mysqli_fetch_assoc($result)) {
                  
    				$ClientDate = $row['Date_registered'];
    				$dateOneMonthAdded = strtotime(date("Y-m-d", strtotime($ClientDate)) . "+1 month");
    				$ID = $row['Cid'];
    				$Client = $row['ClientID'];
    				$ClientE = $row['Email'];
    				$DatabaseDate = $row['Date_registered'];
    				$DateEx = date('l dS \o\f F Y', $dateOneMonthAdded);
    				
    				
    				
    				$startdate = date("Y-m-d");
    				$expire = strtotime($startdate. ' + 3 days' );
    				$today = $row['Date_registered'];
    
    if($today >= $expire || $today <  $startdate ){
    	
        echo "expired";
    	            echo "<meta http-equiv=Refresh content=1;url=test.php?ClientName=$Client&ClientEmail=$ClientE&Expire=$DatabaseDate&CID=$ID>";
    	
    	
    											} else 	{
    	
    	
    	
        											echo "active";
    													}
    				
    									               
             	 
     }	
    }
    	 
             mysqli_close($con);
    
    

    send

    require 'phpmailer/class.phpmailer.php';
    
    $mail = new PHPMailer;$ClientEmail = $_GET['ClientEmail'];$CLientName = $_GET['ClientName'];$DateExpiring = $_GET['Expire'];$ID = $_GET['ID'];
    
    $mail->IsSMTP();                                      // Set mailer to use SMTP
    $mail->Host = 'mail.tech-xxx.info';                 // Specify main and backup server
    $mail->Port = 2525;                                    // Set the SMTP port
    $mail->SMTPAuth = true;                               // Enable SMTP authentication
    $mail->Username = '[email protected]';                // SMTP username
    $mail->Password = 'qwer12345';                  // SMTP password
    $mail->SMTPSecure = 'plain';                            // Enable encryption, 'ssl' also accepted
    
    $mail->From = '[email protected]';
    $mail->FromName = '[email protected]';
    $mail->AddAddress($ClientEmail, 'xx');  // Add a recipient
    //$mail->AddAddress('[email protected]');               // Name is optional
    
    $mail->IsHTML(true);                                  // Set email format to HTML
    
    $mail->Subject = 'Membership';
    $mail->Body    = $CLientName. " Your membership is set to expire on ".$DateExpiring."<br>";
    $mail->AltBody = 'This is the body in plain text for non-HTML mail clients';
    
    if(!$mail->Send()) {
       echo 'Message could not be sent.';
       echo 'Mailer Error: ' . $mail->ErrorInfo;
       exit;
    }
    
    echo 'Message has been sent';
    
    
  4. ok i got the the triage part done!lol

    if($today >= $expire || $today <  $startdate ){
    			echo $to . " " . $Name. " " .$today;  
    			  
        //echo "expired";
    	//echo "<meta http-equiv=Refresh content=1;url=send1.php?ClientName=$Client&ClientEmail=$ClientE&Expire=$DatabaseDate>";
                                                  } 
    

    From there i need to send it to a page that will email all...

  5. Hey guys..spent a few hours on this and going nuts..lol

     

    can somebody help?

     

    explanation:

     

    I need to loop in database and check to see if any clients are expired

     

    if they are expired or going to be expired soon to send a notification by email

     

     

    Problem 1 : can only use SMTP since they disabled Mail() on my server...

     

    Problem 2 don't know how to send to multiple people..

     

    So i got the connection (Mysqli)

     

    got the query part and also the array in my for loop:

    $remind_query1 = "SELECT * From Client_Data"; //Sql query to find users that reminders dates match current date.
              
        
    	if($run1 = $con->query($remind_query1))
        {
    	 $rows = $run1->num_rows;
    				
          
          for ($j = 0; $j < $rows; ++$j)//loop through each user in results and send a reminder email.
          {
    		  
    		  
          	$run1->data_seek($j);
          	$row = $run1->fetch_array(MYSQLI_NUM);
          	$to = $row[4];
            $Date = $row[2];
    
            $Name = $row[1]; 
          	
              echo($to); echo($Name);
              echo "<br>";
    	//echo "<meta http-equiv=Refresh content=1;url=send3.php?ClientName=$Name&ClientEmail=$to>";
    		  
    	}
    	}
    

    So i have a send.php with mail function for smtp

     

    i was thinking of passing the array to that page and the it could send the emails

     

    that is were im stuck..

  6. Hey guys i set up my SMTP send file with my business name and noreply@my buisness to try to avoid my emails going to spam..

     

    but in all my emails i get 

    This message may not have been sent by

     

    what is the way to remove that message??

  7. Hey guys is there a way to pass an ID to a Modal ?

     

    i have a product page and would like on click it opens my modal with the product information.

     

    <a href="#" data-toggle2="tooltip" data-placement="top" title="Quick View" data-toggle="modal" data-target="#quick-view-modal"></a>   

  8. the selection of the clients is done like in my first post,

     

    i setled the insert in new database not doing since they are alreay there..

     

    i would like to update the databse mark all expired clients with a flag.

     

    so i need to loop tru all the clients expired and update there profile with an expired flag

     

    that part im confused

  9. Hey guys i have a script that runs with a CRON job every day

    while ($row2 = $result->fetch_assoc()){
    	
    $todays_date = date("Y-m-d");
    	
    $Dates=$row2['DateServices'];
    	
    if ($todays_date < $Dates) {
            echo 'Subscription is ok';
    	echo "<br />\n";
    	echo $row2['name'];
    	echo "<br />\n";
    	echo $todays_date ;
    	
        }else{
    	
    	echo 'Subscription is expired';
    	echo "<br />\n";
    	echo $row2['name'];
    	echo "<br />\n";
    	echo $Dates ;
    	
    	
    }
    	
        }
    
    
    

    So im having a hard time taking all the data (clients expired and inserting it in a Exired database (inserts email and date expired.

     

     

    one im ok ,but if there is 3 clients how can i take the info and insert one by one in the database?

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.