Error

Non-static method SiteController::createJobLink() cannot be called statically

/var/www/freshersworld-ui/protected/modules/jobs/controllers/FeedController.php(331)

319             $company_name = isset($job -> company -> name) ? $job -> company -> name : '';
320             $seo_title = isset($job -> seo_title) ? $job -> seo_title : '';
321             $category_slug=isset($job -> category_slug[0]) ? $job -> category_slug[0] : '';
322             $category_link = '';
323             if($category_slug != ''){
324             $category_url=Yii::app() -> params['fwUrl'].'/jobs/category/'.$category_slug.'-job-vacancies?src=rssalert';
325             $category_url=strtolower($category_url);
326             $seo_description = isset($job -> seo_description) ? $job -> seo_description : '';
327             $category_link = '<p><a href="'.$category_url.'"><i>For more '.ucwords($category_slug).' Jobs click here</i></a></p><hr>';
328             }
329             $last_date = isset($job -> last_date) ? $job -> last_date : '';
330             $new_description = $seo_description."<br/>Last Date of Application : ". date("d M Y", strtotime($last_date)).$category_link;
331             $url_dst_withoututm = SiteController::createJobLink($job -> id, $company_name, $job_position, $seo_title, false);
332             $url_dst = $url_dst_withoututm . '?utm_source=feedburner&amp;utm_medium=email&amp;utm_campaign=rssfeed&amp;src=email_rssfeed';
333             echo '<item><title><![CDATA[' . $seo_title . ']]></title>';
334             echo '<link>' . $url_dst . '</link>
335                 <description><![CDATA[' . $new_description . ']]></description>';
336             echo '<guid>' . $url_dst . '</guid>
337                 </item>
338                 ';
339         }
340         echo '</channel></rss>';
341     }
342 
343     function NonUtf8CharRemoval($string) {

Stack Trace

#8
+
 /var/www/freshersworld-ui/index.php(26): CApplication->run()
21 defined('YII_DEBUG') or define('YII_DEBUG',true);
22 // specify how many levels of call stack should be shown in each log message
23 defined('YII_TRACE_LEVEL') or define('YII_TRACE_LEVEL',3);
24 
25 require_once($yii);
26 Yii::createWebApplication($config)->run();
2024-03-01 20:56:40 nginx/1.18.0 Yii Framework/1.1.19
Application Log
Timestamp Level Category Message
20:56:39.633763 trace system.CModule
Loading "log" application component
in /var/www/freshersworld-ui/index.php (26)
20:56:39.633861 trace system.CModule
Loading "request" application component
in /var/www/freshersworld-ui/index.php (26)
20:56:39.633893 trace system.CModule
Loading "urlManager" application component
in /var/www/freshersworld-ui/index.php (26)
20:56:39.633940 trace system.CModule
Loading "cache" application component
in /var/www/freshersworld-ui/protected/components/MyUrlManager.php (554)
in /var/www/freshersworld-ui/index.php (26)
20:56:39.636169 trace system.caching.CFileCache
Serving "Yii.CUrlManager.rules" from cache
in /var/www/freshersworld-ui/protected/components/MyUrlManager.php (554)
in /var/www/freshersworld-ui/index.php (26)
20:56:39.636571 trace system.base.CModule
Loading "jobs" module
in /var/www/freshersworld-ui/index.php (26)
20:56:40.111624 info components.services.ServicesClient
GET 
/jobs?date_of_posting_from=1709240199&date_of_posting_to=1709326599&limit=1000
-- 474.70808029175ms
in
/var/www/freshersworld-ui/protected/components/services/ServicesClientV2.php
(31)
in
/var/www/freshersworld-ui/protected/modules/jobs/controllers/JobsController.php
(20905)
in
/var/www/freshersworld-ui/protected/modules/jobs/controllers/FeedController.php
(286)
20:56:40.125047 error exception.Error
Error: Non-static method SiteController::createJobLink() cannot be called
statically in
/var/www/freshersworld-ui/protected/modules/jobs/controllers/FeedController.php:331
Stack trace:
#0 /var/www/yii/framework/web/actions/CInlineAction.php(49):
FeedController->actionrss_feed()
#1 /var/www/yii/framework/web/CController.php(308):
CInlineAction->runWithParams()
#2 /var/www/yii/framework/web/filters/CFilterChain.php(134):
CController->runAction()
#3 /var/www/yii/framework/web/CController.php(291): CFilterChain->run()
#4 /var/www/yii/framework/web/CController.php(265):
CController->runActionWithFilters()
#5 /var/www/yii/framework/web/CWebApplication.php(282): CController->run()
#6 /var/www/yii/framework/web/CWebApplication.php(141):
CWebApplication->runController()
#7 /var/www/yii/framework/base/CApplication.php(185):
CWebApplication->processRequest()
#8 /var/www/freshersworld-ui/index.php(26): CApplication->run()
#9 {main}
REQUEST_URI=/feed
---
20:56:40.125252 trace system.CModule
Loading "errorHandler" application component