[英]CakePHP saving data in join table HABTM
CakePHP 2.4 according to the official API docs, I can call Model::saveAll() 根据官方API文档的CakePHP 2.4,我可以调用Model :: saveAll()
however , when I call the function Model::saveAll() , the browser return an error of 101(net::ERR_CONNECTION_RESET) 但是,当我调用函数Model :: saveAll()时,浏览器返回错误101(net :: ERR_CONNECTION_RESET)
instead , I can save data in a join table in a complicated way 相反,我可以以复杂的方式将数据保存在联接表中
ex: Actor Model Film Model Actor HABTM Film I have a join table named actor_film 例如:Actor Model Film Model Actor HABTM Film我有一个名为actor_film的联接表
I can do like this 我可以这样
$this->Actor->ActorFilm->save(array("ActorFilm"=>array("actor_id"=>1,"film_id"=>2)));
that's so complicated 太复杂了
Any one can help me ? 有人可以帮助我吗?
PHP 5.3.* when using the method saveAll saveMany & saveAssociated will get an error of 101, PHP 5.3。*在使用方法saveAll saveMany&saveAssociated时将出现101错误,
so just ungrade your php 所以只要取消您的PHP
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.