1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Cron Jobs

Discussion in 'XenForo Development Discussions' started by netkingZ, Mar 3, 2014.

  1. netkingZ

    netkingZ Active Member

    Hello ,
    I'm doing an add-on when I'm using the method Cron Jobs (Crontab) and I got to the point where I make the call to a specified file using this system. The problem occurs when I make a call to a file with class and function the answer I get is:

    This means that the Cron Jobs are reading something that is there but does not know what to do even though the controls are right.
    For verification I tried to write the same code outside the class and function and work properly.

    At this point I think I'm wrong class and function are as follows:

    xenOne_Model_xenOne class extends XenForo_Model
      public function getSomeData ()
    how can I do?
  2. Aayush

    Aayush Well-Known Member

  3. netkingZ

    netkingZ Active Member

    Thanks I have a few things clear:
    1 - next to the Cron Entry I have created says "the next launch will take place March 4 at 6:20", but if you have already 6:30 how do you do it? Perhaps it is the word that comes out wrong?

    2 - In the code I have created a place where I put this code:

      $thread_qry5= "SELECT * FROM xenProve_prove ORDER BY view_count DESC LIMIT 5";
                                            $row5 = XenForo_Application::get('db')->fetchAll($thread_qry5);
                                            foreach ( $row5 AS $rows5 ) {
                                                $viewid = $rows5['thread_id'];
                                                $viewtitle = $rows5['title'];
                                                $viewuser = $rows5['username'];
                                                  $MostView .= 'div style="height:30px; width:640px; border-bottom:1px solid #999;padding:5px;">
                                                          <div style="height:40px; width:500px;float:left">
                                                              <div style="height:20px; width:650px; font-size:16px;color:#6d3f03;">'.$viewtitle.'</div>
                                                              <div style="height:20px; width:650px; font-size:12px;color:#6d3f03;">'.$viewuser.'</div>
    In this code is present this code "$MostView .= ' ...." how can replace this symbol .= ?
  4. netkingZ

    netkingZ Active Member

  5. netkingZ

    netkingZ Active Member

  6. netkingZ

    netkingZ Active Member


Share This Page