title: PHP syntax error: unexpected T_PAAMAYIM_NEKUDOTAYIM on Line 78
body: <p>I checked all possible answers, but I'm sorry, I couldn't figure this out. I tried making the properties non-static but code pad shows the error on the line:</p>
  
  <pre><code>$task = new sfCacheClearTask($sfContext::getInstance()-&gt;getEventDispatcher(), new sfFormatter());
  </code></pre>
  
  <p>Refer <a href="http://codepad.org/zcqrkVoY" rel="nofollow">http://codepad.org/zcqrkVoY</a></p>
  
  <p>Pl help resolve this. Thanks</p>
  
  <pre><code>class doSokiJobTask extends sfBaseTask {
  
      CONST STATUS_PENDING = 0;
      CONST STATUS_DONE = 1;
      CONST STATUS_IN_PROGRESS = 2;
      CONST STATUS_FAILED = 3;
      CONST STATUS_CANCELLED = 4;
  
      CONST TIME_TO_DIE = 60;
  
      public $context = null;
      public $job_name = null;
      public $done = null;
      public $status = null;
      public $start = 0;
  
      protected function setJobName($name) {
          $this-&gt;job_name = strtolower($name);
      }
  
      protected function configure() {
          $this-&gt;addArguments(array(
                  //new sfCommandArgument('build', sfCommandArgument::REQUIRED, ''),
          ));
  
          $this-&gt;addOptions(array(
              new sfCommandOption('env', null, sfCommandOption::PARAMETER_OPTIONAL, 'Env to use', 'dev'),
              new sfCommandOption('application', null, sfCommandOption::PARAMETER_OPTIONAL, 'Env to use', 'frontend'),
              new sfCommandOption('job-type', null, sfCommandOption::PARAMETER_REQUIRED, 'Job to be executed', 'job'),
              new sfCommandOption('daemon', null, sfCommandOption::PARAMETER_REQUIRED, 'Daemon running the job', 0),
          ));
  
          $this-&gt;namespace = 'soki';
          $this-&gt;name = 'job';
          $this-&gt;briefDescription = 'Lets you run jobs in the background';
          $this-&gt;detailedDescription = &lt;&lt;&lt;EOF
  The [setup|INFO] task helps run jobs in the background.
  Call it with:
  
    [php symfony setup|INFO]
  EOF;
  //$this-&gt;filesystem = new sfFilesystem(null, $this-&gt;formatter);
      }
  
      protected function execute($arguments = array(), $options = array()) {
          $this-&gt;start = $ts_start = microtime(true);
          $options['quiet'] = 'true';
          $configuration = ProjectConfiguration::getApplicationConfiguration($options['application'], $options['env'], true);
          new sfDatabaseManager($configuration);
          $sfContext = sfContext::createInstance($configuration);
          $this-&gt;context = $sfContext;
          $this-&gt;setJobName($options['job-type']);
          if (true) {
              $file_logger = new sfFileLogger($this-&gt;dispatcher, array('file' =&gt; $this-&gt;configuration-&gt;getRootDir() . '/log/jobs.log'));
              $this-&gt;dispatcher-&gt;connect('command.log', array($file_logger, 'listenToLogEvent'));
          }
  
          try {
              if (!$this-&gt;job_name)
                  $this-&gt;logSection('INVALID', 'Job Type could not be identified', null, 'ERROR');
  
              switch ($this-&gt;job_name) {
                  case 'clear-cache':
                      $task = new sfCacheClearTask($sfContext::getInstance()-&gt;getEventDispatcher(), new sfFormatter());
                      $task-&gt;run(array(), array('env' =&gt; $options['env'], 'app' =&gt; $options['application']));
                      $this-&gt;done = true;
                      break;
                  case 'send-email':
                      $task = new sfProjectSendEmailsTask($sfContext::getInstance()-&gt;getEventDispatcher(), new sfFormatter());
                      $task-&gt;run(array(), array('env' =&gt; $options['env'], 'application' =&gt; $options['application'],
                          'message-limit' =&gt; sfConfig::get('sf_spool_message_limit', 25)));
                      $this-&gt;done = true;
                      break;
                  case 'chmod':
                      if (!chmod(sfConfig::get('sf_root_dir') . "/data_society", 0755))
                          throw new Exception('CHMOD failed on ' . sfConfig::get('sf_root_dir') . "/data_society");
                      $this-&gt;done = true;
                      break;
                  case 'disable-install':
                      $this-&gt;done = Application::secureSokiInstaller(true);
                      sokiUtil::clearCacheAsync();
                      break;
                  /* case 'enable-install':
                    Application::secureSokiInstaller(false);
                    sokiUtil::clearCacheAsync();
                    break; */
                  case 'job':
                      $this-&gt;executeJob($arguments, $options);
                      break;
                  default:
                      $this-&gt;logSection('UNKNOWN', 'Job Type could not be identified', null, 'ERROR');
                      break;
              }
              $ts_end = microtime(true);
              $this-&gt;logSection($this-&gt;job_name, ($this-&gt;done ? 'DONE' : 'FAILED') . ' in ' . round($ts_end - $ts_start) . 's @ ' . $options['env'] . '/' . $options['application'], null, 'INFO');
          } catch (Exception $e) {
              $this-&gt;logSection($this-&gt;job_name, $e-&gt;getMessage(), null, 'ERROR');
              throw $e;
          }
      }
  </code></pre>