最赞回答 / Um
在组件里添加条件。$tags = Yii::$app->request->get('tag');if($tags) { $tag = new PtModel(); $post_id = $tag->getPostid($tags); if ($post_id) { foreach ($post_id as $v) { $id[] = $v['post_id']; } $cond = ['id' => ...
2017-03-16
最新回答 / Gigure
是否使用url美化??http://frontend.hyii2.com/post/create或者http://frontend.hyii2.com/post/create.html
2017-03-04
最赞回答 / 明天4034464
<?phpnamespace frontend\models;use Yii;use yii\base\Model;use common\models\PostsModel;use yii\base\Object;//文章表单模型class PostForm extends Model{ public $id; public $title; public $content; public $label_img; public $cat_id; public $tags; public $_lastE...
2017-02-25
最赞回答 / alds
上传图片显示上传错误,按下面的方式处理应该可以解决问题:在common/widgets/ueditor/Uploader.php文件的getFullName()函数中,修改$randNum这一行为$randNum=rand(1, 9999) . rand(1, 999);
2017-02-24