Chris Mina
Chris Mina
The error appears randomly. The text I posted is from the window showing the error. A screenshot will just show that!
This works: ``` PHP $this->Posts->find('all', ['contain' => ['Tags']]); ``` and in your view simply loop through the tags: ``` PHP ```
How to edit associated tags? In my edit.ctp, in the input for tags instead of seeing the tag name I see the whole object. For example I have 3 tags...
@virusvn your solution gives me the following warnings: ``` Warning (2): Invalid argument supplied for foreach() [CORE\src\ORM\Marshaller.php, line 760] Warning (2): Invalid argument supplied for foreach() [CORE\src\ORM\Marshaller.php, line 641] ```...
@virusvn the errors come just after saving. Here is my edit method: ``` public function edit($id = null) { $document = $this->Documents->get($id, [ 'contain' => ['Tags'] ]); // This results...
@virusvn thank you for your reply. The problem was resolved by simply rearranging the code as below: ```php public function edit($id = null) { $document = $this->Documents->get($id, ['contain' => ['Tags']]);...