public function __construct($id, &$sitepress, &$wpdb)
 {
     parent::__construct($id);
     $this->wpdb =& $wpdb;
     $this->sitepress =& $sitepress;
     $this->wp_post = get_post($id);
     $this->element_type = 'post_' . $this->wp_post->post_type;
     $this->language_code = $this->sitepress->get_language_for_element($id, $this->element_type);
 }
 public function __construct($id, &$sitepress, &$wpdb)
 {
     parent::__construct($id);
     $this->wpdb =& $wpdb;
     $this->sitepress =& $sitepress;
     $this->string = $this->get_string($id);
     $this->element_type = 'string';
     $this->language_code = $this->get_language_for_element($id, $this->element_type);
 }