codeigniter

FineCMS

牧云@^-^@ 提交于 2020-04-09 18:20:52
FineCMS介绍 http://finecms.net/ 产品简介 FineCMS(简称免费版、企业版、公益版)是一款基于PHP+MySql+CI框架开发的高效简洁的中小型内容管理系统,面向多终端包括Pc端网页和移动端网页,支持自定义内容模型和会员模型,并且可以自定义字段,可面向中小型站点提供重量级网站建设解决方案,适用于小型站点、企业级网站、新闻内容网站等,个人站长及中小企业的首选建站系统。 免费开源无任何商业限制 FineCMS系统免费并开放源代码,推荐开发者或公司在此基础上进行二次开发或者发行,本人一直提倡免费开源,希望在此基础上开发的开发者也能保持免费开源,为本土的开源事业做一点贡献。 FineCMS以“小巧、精干、轻量”为设计理念,不用太多复杂的功能,有一套强大和稳定内容管理机制足以,以简洁的基础 CMS程序+多样化插件为开发目的。 FineCMS是不要钱的程序,没有那么多条条款款限制,喜欢用就拿去用,无论你改名字发布还是去申请版权都是可以的。 有人会问,国内大大小小CMS程序已经很多了,但是为什么还要继续这么一个CMS?其实也是有很多原因的!最主要的原因是不放弃最初的信念,开始主要为了提高自己的PHP开发水平以及对手头正在做的网站项目所使用的开发方式和开发规范并不是很满意,所以就开始写了这个CMS。 FineCMS v1:2009年开始开发

Stop execution after call $this->load->view()

与世无争的帅哥 提交于 2020-04-07 02:49:10
问题 In Codeigniter, How could we stop the execution after load a view? I have tried this function index() { $this->load->view('myView'); die(); //do not execute next code } but it resulting blank screen. 回答1: https://www.codeigniter.com/user_guide/general/views.html There is a third optional parameter lets you change the behavior of the function so that it returns data as a string rather than sending it to your browser. This can be useful if you want to process the data in some way. echo $this-

How to split array into groups based on one field value in PHP Codeigniter [duplicate]

故事扮演 提交于 2020-03-28 07:02:07
问题 This question already has answers here : php array group (18 answers) Closed 10 days ago . I am having an array like this: Array ( [0] => stdClass Object ( [vendor_id] => 11 [name] => Telkom Pin Airtime R100.00 [provider] => Telkom Mobile [service] => Pre-Paid Airtime Recharge ) [1] => stdClass Object ( [vendor_id] => 12 [name] => Telkom Pin Airtime R100.00 [provider] => Telkom Mobile [service] => Pre-Paid Airtime Recharge ) [2] => stdClass Object ( [vendor_id] => 13 [name] => Telkom Pin

codeigniter get_where with mysql functions in check values

試著忘記壹切 提交于 2020-03-26 02:46:51
问题 Just a question about the get_where function of codeigniter Active Records. I wanted to get a query which should be like this: Select * from foo where date = STR_TO_DATE('$month/$day/$year','%m/%d/%Y') and time = STR_TO_DATE('$hour:$minute$ampm', '%l:%i%p') Now I created a function in my model which appears like this: public function validate_if_existing($month,$day,$year,$hour,$minute,$ampm) { $event_date = "STR_TO_DATE('$month/$day/$year','%m/%d/%Y')"; $event_time = "STR_TO_DATE('$hour:

How can I pass input value from view to controller and model to fetch data correctly? Codeigniter

你离开我真会死。 提交于 2020-03-25 18:22:47
问题 I am trying to fetch a data that has the same id of my input hidden value. I cannot fetch the id or input hidden value of the data To start with, this is what I've done to make things clearer for me to debug things I made a hard coded form and a button to bring me to the page In View - groups/index.php As you can see I made the posts/index/1 which is a hard coded value but I can change that later easily that is not my problem <?php echo form_open('posts/index/1') ?> <input type="hidden" name=

How can I pass input value from view to controller and model to fetch data correctly? Codeigniter

放肆的年华 提交于 2020-03-25 18:22:13
问题 I am trying to fetch a data that has the same id of my input hidden value. I cannot fetch the id or input hidden value of the data To start with, this is what I've done to make things clearer for me to debug things I made a hard coded form and a button to bring me to the page In View - groups/index.php As you can see I made the posts/index/1 which is a hard coded value but I can change that later easily that is not my problem <?php echo form_open('posts/index/1') ?> <input type="hidden" name=

How to debug Codeigniter 4

情到浓时终转凉″ 提交于 2020-03-23 10:43:28
问题 whatever error occurs in Codeigniter 4 Its always showing default message How to get exact error message in Codeigniter 4 回答1: Rename the env file as .env , then removed # from CI_ENVIRONMENT and modified CI_ENVIRONMENT = production into CI_ENVIRONMENT = development 回答2: go to .env file in base file uncomment #CI_ENVIRONMENT = development to CI_ENVIRONMENT = development 来源: https://stackoverflow.com/questions/60501607/how-to-debug-codeigniter-4

update_batch in codeigniter

喜你入骨 提交于 2020-03-21 10:36:08
问题 Here is my code that i used to update all the rows that am getting for that i used update_batch function but its not working properly public function edit_project_involved($users) { foreach ($users as $v_user) { $data=array('involved'=>1); $v=$this->db->where('user_id',$v_user); $query=$this->db->update_batch('tbl_users',$data,$v); } if($query) { return true; } } my $users var_dump looks like this C:\wamp64\www\spectra\application\models\Project_model.php:536: array (size=3) 0 => string '40'

神秘的.user.ini文件

為{幸葍}努か 提交于 2020-03-20 10:19:01
3 月,跳不动了?>>> 啥? .user.ini 删不掉,是不是觉得自己真的不行了? [root@Tech1024] # rm -rf .user .ini rm : cannot remove ‘ .user .ini ’: Operation not permitted 来看一下,该文件的属性 [root@Tech1024] # lsattr .user .ini ----i--------e-- .user .ini 没错,文件被锁定了,不能修改,那么我们去除文件锁定属性 补充: ##防跨目录设置## LNMP 1.1及之前的版本使用php.ini里面, open_basedir设置 LNMP 1.2及更高版本防跨目录功能使用.user.ini,该文件在网站根目录下,可以修改.user.ini 里面的open_basedir的值来设置限制访问的目录或删除来移除防跨目录的设置。 .user.ini文件无法直接修改,如要修或删除需要先执行:chattr -i /网站目录/.user.ini 可以使用 winscp文件管理 、 vim编辑器 或 nano编辑器 进行修改。 删除的话rm -f /网站目录/.user.ini 就可以。 修改完成后再执行:chattr +i /网站目录/.user.ini .user.ini不需要重启一般5分钟左右生效,也可以重启一下php

How to receive a ajax response from a codeigniter controller?

时光总嘲笑我的痴心妄想 提交于 2020-03-18 08:56:47
问题 I have a controller that send the data to the model and the model insert this data in the mysql. I want to know the last ID of the row inserted, but I want this ID in my ajax function to use to uptade the table with the information. Here what I have: The model: public function add($nome, $documento) { $dados = array ( 'nome' => $nome, 'documento' => $documento ); $this->db->insert('clientes', $dados); return $this->db->insert_id(); } The Controller: public function add() { // validar $nome =