KGRKJGETMRETU895U-589TY5MIGM5JGB5SDFESFREWTGR54TY
Server : Apache/2.4.41 (Ubuntu)
System : Linux vmi1525618.contaboserver.net 5.4.0-105-generic #119-Ubuntu SMP Mon Mar 7 18:49:24 UTC 2022 x86_64
User : www-data ( 33)
PHP Version : 8.2.12
Disable Function : NONE
Directory :  /var/www/parasoffline.edukrypt.in/application/models/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //var/www/parasoffline.edukrypt.in/application/models/Demo_blog_post_model.php
<?php 

class Demo_blog_post_model extends MY_Model {

	public $belongs_to = array(
		'category' => array(
			'model'			=> 'demo_blog_category_model',
			'primary_key'	=> 'category_id'
		),
		'author' => array(
			'model'			=> 'admin_user_model',
			'primary_key'	=> 'author_id'
		)
	);
	
	protected $where = array('status' => 'active');
	protected $order_by = array('publish_time', 'DESC');
	protected $upload_fields = array('image_url' => UPLOAD_DEMO_BLOG_POST);

	// Append tags
	protected function callback_after_get($result)
	{
		$this->load->model('demo_blog_tag_model', 'tags');
		$result = parent::callback_after_get($result);
		$result->tags = $this->tags->get_by_post_id($result->id);
		return $result;
	}
}

Anon7 - 2021