Forum Replies Created

Viewing 2 replies - 16 through 17 (of 17 total)
  • hi,

    i have an “Notice: Trying to get property of non-object” error when saving/publishing a post.

    this line is the problem:
    [code]public function get_translation(...) {
    $slug = $this->get_language($lang)->slug;
    ....
    }[/code]

    it throws an error with a custom post type i use to add field sets to other (custom) post types with the plugin “Advanced Custom Fields”.

    is it possible to add a fallback? for me that works for the moment, but for sure its not a nice solution:
    [code]if(empty($this->get_language($lang)->slug)) {
    $slug = 'de';
    } else {
    $slug = $this->get_language($lang)->slug;
    }[/code]

    just for information:

    the replacement of “add_filter(‘parse_query’,array(&$this,’parse_query’));” also removes the new bug, that the media-layover shows no media-list, if i use an add media option.

Viewing 2 replies - 16 through 17 (of 17 total)