Cron.php

Discuss about Seo Panel Bugs and Issues

Moderators: sendtogeo, hellow0rld, eugene

Cron.php

Postby basty_dread » Thu Jul 08, 2010 5:30 am

i have successfully installed SEOPanel but my problem is when i visit the cron.php.
http://domain.com/seopanel/cron.php

i could not click the proceed button even after selecting a website,and seo tools.. i think the problem is that the javascript function is not added.,
please help.. thank you so much..
if only i know where to add the <script link=....
basty_dread
 
Posts: 2
Joined: Thu Jul 01, 2010 6:16 am

Re: Cron.php

Postby seopanel_forum » Fri Jul 09, 2010 11:55 am

Hi,


You can't access http://domain.com/seopanel/cron.php due to security, otherwise other users will execute your report generation script frequently and that will eat your bandwidth.

To set up cron, you can refer following link

http://www.seopanel.in/install/setup-cron/

Please contact us, If you have any issues.
Thanks,
Seo Panel Team
http://www.seopanel.in
seopanel_forum
Site Admin
 
Posts: 1383
Joined: Sat Apr 17, 2010 6:42 pm
Location: India

Re: Cron.php

Postby basty_dread » Mon Jul 12, 2010 4:01 am

:D that is really fast reply. thanks for leaving a message.
i thought it was created for running the cron manually or generating manual report.

i am thinking if it is for security reason.. you could not actually go to that cron.php if you are not logged in the seopanel.
Thanks anyway.. keep it up guys..
basty_dread
 
Posts: 2
Joined: Thu Jul 01, 2010 6:16 am

Re: Cron.php

Postby seopanel_forum » Tue Jul 13, 2010 5:38 pm

Actually we can't access cron.php through browser if you not logged in as admin in browser. Please check it.

If you want to execute it through the browser, copy following code to file inside seopanel directory.

Code: Select all
# the section for generate reports using system cron job
include_once("includes/sp-load.php");
include_once(SP_CTRLPATH."/cron.ctrl.php");
$controller = New CronController();

$includeList = array();   // the only included seo tools id
$controller->executeCron($includeList);


Eg: copy it to a file called spcron.php

Then access it like

http://domain.com/seopanel/spcron.php

This will satisfy your requirements.
Thanks,
Seo Panel Team
http://www.seopanel.in
seopanel_forum
Site Admin
 
Posts: 1383
Joined: Sat Apr 17, 2010 6:42 pm
Location: India

Re: Cron.php

Postby jesswu » Mon Jul 19, 2010 10:38 am

in my case, cron run very well in the beginning.

But after a while, after adding and deleting some websites from database,
the cron become abnormal, it just executes the first few websites and then stop.

What's going on about that?? is it related with succeeding website id or some other problems else?

Jess
jesswu
 
Posts: 2
Joined: Mon Jul 19, 2010 8:04 am

Re: Cron.php

Postby seopanel_forum » Tue Jul 20, 2010 10:36 am

Hi Jess,

I checked this issue and found that it is due to the object destroyed before execution. To fix this please replace beloe function with following code.

1) Open controllers/cron.ctrl.php file

2) Replace following function

Code: Select all
# common cron execute function
   function executeCron($includeList=array()) {
      
      $this->loadCronJobTools($includeList);
      
      $userCtrler = New UserController();
      $userList = $userCtrler->__getAllUsers();
      $websiteCtrler = New WebsiteController();
      foreach($userList as $userInfo){
         
         $websiteList = $websiteCtrler->__getAllWebsites($userInfo['id']);
         foreach($websiteList as $websiteInfo){
            
            $this->websiteInfo = $websiteInfo;
            $this->routeCronJob($websiteInfo['id'], '', true);
         }
      }      
   }


with following code

Code: Select all
# common cron execute function
   function executeCron($includeList=array()) {
      
      $this->loadCronJobTools($includeList);
      
      $userCtrler = New UserController();
      $userList = $userCtrler->__getAllUsers();
      foreach($userList as $userInfo){
          $websiteCtrler = New WebsiteController();   
         $websiteList = $websiteCtrler->__getAllWebsites($userInfo['id']);
         foreach($websiteList as $websiteInfo){
            
            $this->websiteInfo = $websiteInfo;
            $this->routeCronJob($websiteInfo['id'], '', true);
         }
      }
   }

with following code

I think this will fix this issue.
Thanks,
Seo Panel Team
http://www.seopanel.in
seopanel_forum
Site Admin
 
Posts: 1383
Joined: Sat Apr 17, 2010 6:42 pm
Location: India

haire

Postby stepolin » Tue Aug 03, 2010 7:12 am

its superb
fantastic :ugeek:
stepolin
 
Posts: 1
Joined: Tue Aug 03, 2010 7:07 am

Re: Cron.php

Postby irineujunior » Thu Aug 12, 2010 1:52 am

Thanks man.. it fixed my cron too...
irineujunior
 
Posts: 1
Joined: Thu Aug 12, 2010 1:48 am

Re: Cron.php

Postby magnus_leffa_81 » Fri Oct 29, 2010 1:31 pm

Hi, the cron no work.


1 1 * * * php /var/www/html/seopanel/cron.php

Code: Select all
I tried to start over SSH
[root@sip1 seopanel]# ./cron.php
./cron.php: line 1: ?php: No such file or directory
./cron.php: line 2: syntax error near unexpected token `$_SERVER['REQUEST_METHOD']'
./cron.php: line 2: `if(!empty($_SERVER['REQUEST_METHOD'])){'



Monica del castillo
http://addphone.net/
magnus_leffa_81
 
Posts: 5
Joined: Sun Aug 15, 2010 3:37 pm

Re: Cron.php

Postby seopanel_forum » Wed Nov 03, 2010 6:20 pm

You can't execute cron like

[root@sip1 seopanel]# ./cron.php



Please check following url to set up cron

http://www.seopanel.in/install/setup-cron/
Thanks,
Seo Panel Team
http://www.seopanel.in
seopanel_forum
Site Admin
 
Posts: 1383
Joined: Sat Apr 17, 2010 6:42 pm
Location: India

Next

Return to Seo Panel Bugs and Issues

Who is online

Users browsing this forum: No registered users and 6 guests