Hi Chad
After the latest update with markdown-functions it is no longer possible for me to create and save content with the regular or WYSIWYG-editor.
I can type whatever I want but after hitting "update" and returning to the content edit-page the site is blank. However, if I activate the markdown-setting all works like it should.
It works perfectly now! Thank you so much.
I really like your plugin but I have one suggestion to make. If a blog post isn't published it shouldn't be possible to access it without logging in. Otherwise I don't get the real point of having such field.
Hi Sung,
can you try editing line 65 of /plugins/radiantweb/problog/components/Post.php to this:
if(!$this->post || $this->post->published < 1)
Let me know if this correctly 404's for unapproved posts.
ChadStrat
Technically that should likely be:
if(!$this->post || ($this->post->published < 1 && !$this->user()))
With the following method added to the Post controller:
/**
* Returns the logged in user, if available
*/
public function user()
{
if (!Auth::check())
return null;
return Auth::getUser();
}
ChadStrat
Hi again Chad
I have tried your suggestion but now I get this error when entering: .../backend/radiantweb/problog/posts:
The component 'Radiantweb\Problog\Components\Post' does not contain a method 'user'.
PHP Content
EXCEPTION
Cms\Classes\CmsException
if (method_exists($this, $method))
return call_user_func_array([$this, $method], $parameters);
if (method_exists($this->controller, $method))
return call_user_func_array([$this->controller, $method], $parameters);
throw new CmsException(Lang::get('cms::lang.component.method_not_found', [
'name' => get_class($this),
'method' => $method
]));
}
/**
Last updated
1-7 of 7