Most voted "codeigniter" questions
Codeigniter is a framework for developing PHP applications.
Learn more…1,026 questions
Sort by count of
-
0
votes2
answers792
viewscodeigniter - list related data
Hello, I’m trying to show the name of a channel associated with an event through a FK, but I can’t show it. Model: public function get_events() { $this->db->get('events');…
-
0
votes1
answer292
viewsHow do I install a library (Phpexcel) in a codeigniter application using NPM?
I am developing an application that needs to export data from an array that received the result of a query in Excel format, in a dynamic way, and I wanted to know how to import the library, I…
-
0
votes1
answer362
viewssimultaneous access lock - Codeigniter
I need to block Simultaneos accesses with the same login on my system, currently using Codeigniter as framework. When logging into the system, I can set 'logged in' in the BD and the logout is…
-
0
votes1
answer315
viewsHow do I sort a date field in mysql?
How do I order decreasingly (select * from tabela order by date desc) a date field inserted by the datepicker script in the format dd-mm-yyyy in Mysql? Note: The dates are being ordered only by day,…
-
0
votes0
answers67
viewsCodeigniter - A function for various controllers
I’m using the IC in my projects, but I have a question. I have several controllers that need to access the same api, currently I create the connection with a function called "apicall" in all…
-
0
votes2
answers438
viewsHow to consult with Where and like between two tables?
Guys, I have the following problem: I have two tables, the following tables : tabela mensagens +----+-------------------+-------+---------------------+ | id | mensagem | _de | hora |…
-
0
votes1
answer1025
viewsFatal error: Call to a Member Function result() on a non-object
Hello. After hours trying to solve this problem and researches I did about the problem, I came to ask you how I can remedy this question The mistake is: Fatal error: Call to a Member Function…
-
0
votes0
answers15
viewsCodeigniter application does not work with mongodb
I have a codeigniter system and I can’t make requests using mongo_db lib. It is not possible to connect, authenticate and, or search data from the database. I believe that the library is corrupted,…
-
0
votes1
answer590
viewsDoubt about ajax url
I am developing a simple crud with ajax and jquery and came across the following question... $('#btnDelete').unbid().click(function(){ $.ajax({ type: 'ajax', method: 'post', async: false, url: url,…
-
0
votes0
answers20
viewsCodeigniter, code with small bug
I am following this tutorial on codeigniter: http://www.dicascodeigniter.com.br/mini-crud-com-codeigniter-3-e-bootstrap/ When downloading and running the project, he presented me the following…
-
0
votes1
answer635
viewsSelect with Join in Codeigniter
I have a question in a select with the use of Join in codeigniter, follows: I have 2 tables. tabela jogo id | id_time1 | id_time2 99 | 1 | 2 tabela time id | time 1 | Real 2 | Barcelona I want to…
-
0
votes0
answers260
viewsCreate routes with multiple parameters in Codeigniter
I have a project developed in Codeigniter and I’m setting up some routes to get some nice Urls, but I found a problem. In a given route, I don’t know how many parameters it will come with, you can…
-
0
votes1
answer20
viewsDisables Datatables Collapse function
Good! I needed to know if there is a way to prevent Datatables from giving Collapse to the columns, and also if there is some way beyond using Columns.Visible to make the column invisible, but also…
-
0
votes1
answer24
viewsRe-populate input file type after codigniter validation error
I needed that whenever there was a validation error, when returning to the form the file fields were with the previously completed information, however I’m not getting it to happen, I tried with the…
-
0
votes1
answer776
viewsOpen modal window according to customer id
In the view I do a foreach to display customers as below: <div class="row"> <div class="col-md-12 col-xs-12"> <div class="table-responsive"> <table class="table…
-
0
votes0
answers34
viewsEncrypt parameter in link
I’m trying to encrypt a past parameter But it’s not working What I want to encrypt is $cc['CODIGO'] <?php echo anchor('financeiro/edicao/'.$cc['CODIGO'], '<span class="fa…
-
0
votes1
answer287
viewsWatermark image upload in codeigniter
Hello! I’m trying to insert watermark when registering the image, but the image is upada, only it does not insert the watermark and does not return errors, someone has some suggestion? Follows code…
-
0
votes0
answers246
viewsPHP processes never close
Hello, I’m having a problem related to a PHP system running through a Windows Service. The application works as follows: I have a folder with several files and PHP scripts that serve as an offline…
-
0
votes0
answers29
viewsrequire_once in helper codeigniter
I installed the mpdf library via Composer in codeigniter 2 and made a helper file where I call this library to generate the pdf. So within this helper I call autoload with require_once and it works…
-
0
votes1
answer108
viewsEmail Body Image - Code Igniter
I’m having trouble attaching an image to the E-email body using the standard Igniter library. I’ve done it like this: $cid = $this->email->attach('media/teste.jpg','inline'); $dados['cid']=…
-
0
votes2
answers918
viewsUse id for auto-no-increment insertion
In the MYSQL I have a table of subscribers where the primary key is the registration number which is a column that has no auto-increment, I can’t change that. I made, in Codeigniter, a method that…
-
0
votes2
answers1117
viewsEmail codeigniter SMTP error was encountered: 450 4.7.1
does that you can explain to me how I send email from a form by the servers Ocaweb, I have a website of a client hosted in Ocaweb, but the sending form does not work using the e-their mail, I wonder…
-
0
votes1
answer59
viewsStoring checkbox data from a modal window in another Codeigniter view
I need to get the selected checkbox items displayed in a modal window and move to another view however I need them to be stored in the view and I can go back and add more data without losing the…
codeigniterasked 6 years, 3 months ago RODRIGO APARECIDO DA SILVA 1 -
0
votes2
answers92
viewsSeparate clients in foreach with mpdf
my scenario is as follows, I file a pdf using mpdf library and this pdf file is a query of intervals between client code and event date. Ex.: code: 0001 to 0004 and 0000-00-00 to 0000-00-00. It is…
-
0
votes0
answers103
viewsSet up Codeigniter-friendly URL on windows server
I am having the following problem, I am developing an application in CI, and this application will stay in a windows server. would like to know how to do url friendly on this type of server, as I…
-
0
votes1
answer1006
viewsInsert data into db with codeIgniter and ajax
Hello I am trying to insert data in my database with ajax but I am not getting, always returns me the error message Controller: public function insert_user_data(){ $this->load->model('crud');…
-
0
votes1
answer93
viewsSucess Ajax does not work with Codeigniter Controller
Good afternoon, I’m beginner in development. I have a form whose I don’t want the page not to be reloaded when the user submits the form. for this I am using Ajax, I was able to perform the…
-
0
votes1
answer83
viewsReturn Date data according to month
I developed the following function: public function get_agendas() { $this->db->select("*, EXTRACT(MONTH FROM data) as mes_referencia, count(id) as total_registros");…
-
0
votes2
answers454
viewsHow do I pass an id through the url using Codeigniter?
I need to pass the id of a product through the url using the GET method, in codeIgniter as would this solution ?
-
0
votes1
answer283
viewsWork with BLOB field on ORACLE using Codeigniter
I have a system where will store certain files in a BLOB type column in my ORACLE database, but I did not find anything about it in the documentation of Codeigniter itself of how to do this, how can…
-
0
votes1
answer50
viewsPick up the start day and the end day of the specified week
Good afternoon, I’m returning from the database the number of the week in the year. ["data_hora"]=> string(16) "19/11/2018 15:26" ["num_semana"]=> string(2) "47" Where num_week is the number…
-
0
votes2
answers44
viewsSearch for more data after finding nothing related to ID
I am making a 4x4 matrix system for a client and I am having a difficulty in the following question: The system has to check if the indicated to be checked already has 4 people in the network, if…
-
0
votes0
answers67
viewsHow to receive data from a Codeigniter 3 store
Create a previous store in mysql. Using Codeigniter 3 already configured to use the mysqli driver, I tried to receive the data returned by SP but was not successful. SP: CREATE…
-
0
votes0
answers120
viewsInsert an array with codeIgniter and ajax
Hello I am trying to insert an array, but in this case, you can insert multiple lines in db. How do I pass the data to codeIgniter: var productsData = []; $(".productRow").each(function(i){ var…
-
0
votes2
answers38
viewsCodeigniter - Syntax error with select and Where
In a precise project that appears only the active publications on the main page I am using Codeigniter, I used the following lines of code: Model: $this->db->select('*');…
-
0
votes2
answers173
viewsCheck if a registered user in the bank has already registered Cpf
Hello, guys I need to check in the bank if a logged in user already has registered Cpf and return if it is false or not. I use codeigniter in the app. I’ll send you the codes. CONTROLLER: public…
-
0
votes0
answers51
viewsHelp to save data from a field to the database without creating a new record?
I have the following table in the system: When I enter the Status and click update it creates another record in the database. Follow the record in the comic book. I would like it to only record the…
-
0
votes1
answer1081
viewsHow to restrict access per user in Codeigniter
I have a system that I need to restrict access to in some areas like User Administration, for example. I’m not sure how to get the user who is logged in. I know I need to restrict access to the file…
codeigniterasked 8 years, 7 months ago fabricio_wm 1,090 -
0
votes2
answers127
viewsImage is not loaded as background
Hello, I have the following code as part of my index.php <style> #backgroundImage{ background-image: url('<?=base_url();?>bg.jpg'); } </style> <body id='backgroundImage'>…
-
0
votes1
answer1102
viewsCalling a Controller X function via a Controller Y (Codeigniter)
Hello! Well, I’ve got the following question on my head. Today I have a routine in CRON that runs a certain function of a Controller X of my application. However, I would like the user to perform…
-
0
votes1
answer45
viewsIs using Includes in Codeigniter autoload good practice?
I have a project that uses autoload to load several libraries, Helpers, using several include_once. As Inputs, Forms etc. Some are used on multiple controllers, others not so much. Would it be good…
-
0
votes1
answer24
viewsError sending pdf by Codeigniter 3
I’m getting the bug A problem was encountered while attempting to move the uploaded file to the final Destination when trying to send a pdf through the form. Follows the function that sends the…
-
0
votes1
answer158
viewsProblem copying an html block when clicking a button
I was able to make sure that when I click the add more fields button, the form is replicated. But the create button started to do the same thing as the add+fields button and not its function of…
-
0
votes1
answer139
viewsHow to pass the value of a variable through the form_open codeigniter function?
Good evening Using codeigniter how do I pass the value of a variable through the form_open() function? because here I have to inform the controller and the method that will be responsible for the…
-
0
votes1
answer955
viewsMpdf in codeigniter
I’m using the library Mpdf in my project. I installed via Composer and locally with php version 7.1 (O php of the server in production is 7.2) and is enabled composer_autoload of CodeIgniter.…
-
0
votes2
answers854
viewsPass value from a select to a link’s GET parameter
Hello, I needed to pass the value of one to a parameter of a link, this to be sent via GET. I am using the codeigniter framework. Follow the code I have: <div class="col-xs-12 col-md-3…
-
0
votes0
answers75
viewsHow to create global variable in php?
I am working with the codeigniter framework completely separate from the front-end. That is, I run the business rules and send a json to the controller. However, I am doing an authentication to…
-
0
votes2
answers218
viewsInner Join with subselect codeigniter
How to create a function that brings the same query result below using codeigniter? SELECT AC.cod_setor,AC.cod_coletor ,SUM(ac.quantidade) AS quantidade FROM item_inventarios AC INNER JOIN ( SELECT…
-
0
votes0
answers53
viewsCreate Timezone function for PHP and Mysql UTC
I am migrating to a Cloud hosting where Mysql is with Timezone UTC, I could not execute the commands to switch to GMT -3 and support does not give me another option. Today my requests are saved in…
-
0
votes1
answer65
viewsRetrieve inline CSS attributes with PHP
I have DIV’s that have dynamically generated CSS inline styles. Example: <div style="top: 275px; left: 563px;"></div> My doubt is the following, how can I recover these values "top" and…