简体   繁体   English

在GroceryCrud中插入时发生错误

[英]An error occurred on insert in GroceryCrud

I face this error when I'm trying to save the add form from Grocery Crud.. 我在尝试从Grocery Crud保存添加表单时遇到此错误。

在此处输入图片说明

this error only show up at my server where i change the http port into 88 for port forwarding issue, but the script were working normally in my localhost at my own laptop.. 此错误仅在我的服务器上显示,该服务器将http端口更改为88,以解决端口转发问题,但是该脚本在我自己的便携式计算机上的localhost中正常运行。

did the port change impact the grocery crud? 港口的变化对杂货杂货产生了影响吗? can some one tell me how to fix it since I really have to change the port since port 80 and 8080 is already used.. 有人可以告诉我如何修复它,因为由于已经使用了端口80和8080,因此我真的必须更改端口。

使用您正在使用的端口(在application / config / config.php中)配置Codeigniter base_url属性:

$config['base_url'] = 'http://localhost:88/';

I had the same issue, but I'm using bootstrap theme 我遇到了同样的问题,但是我正在使用引导主题

1.first set bootstrap theme: 1.首先设置bootstrap主题:

$crud->set_theme('bootstrap'); $ crud-> set_theme( '自举');
2.in the file grocery_crud/themes/bootstrap/js/form/add.min.js replace the code: error:function(){alert(message_insert_error),a("#FormLoading").hide()} with the code: error:function(data){alert(JSON.stringify(data)),a("#FormLoading").hide()} 2.在文件Bistro_crud / themes / bootstrap / js / form / add.min.js中,将代码替换为:error:function(){alert(message_insert_error),a(“#FormLoading”)。hide()}替换为代码:error:function(data){alert(JSON.stringify(data)),a(“#FormLoading”)。hide()}

and it will show you what the error is about 它会向您显示错误的原因

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM