484 Topics

Member Avatar for
Member Avatar for game4tress

I'm creating a chat system and the problem is that when testing with two users, the secound user (entering the system) can see the first user (already loged in), but the first user will never see the next user(s) entering the system. I know that the problem comes from the …

0
203
Member Avatar for iamthwee

Hi friends, I'm wondering what is the best way to go about validating my forms with both php and ajax. For example, I want to use the form_validation library but also jquery such that the page doesn't require a refresh or redirect. How best to do this what is best …

Member Avatar for iamthwee
0
4K
Member Avatar for iamthwee

Hey guys, just wondering what is the best practice to do mysql queries in CI. Do I need to escape the query using db->query->escape? Additionally, outputing stuff from the db so it doesn't break my html form what's the difference between using xss_escape and using php's htmlentities() functions. Thanks in …

Member Avatar for veedeoo
0
245
Member Avatar for iamthwee
Member Avatar for iamthwee
0
7K
Member Avatar for archie.herbias

i have created a codeigniter application and when i tried to access it locally, it says "No direct script access allowed". i don't know what's the problem .i'm using ubuntu . i need some help with this :)

Member Avatar for gabrielcastillo
0
128
Member Avatar for mohan@nano

A Database Error Occurred Unable to connect to your database server using the provided settings. the above error am getting when i load the localhost and my database.php and db_driver codings are given below $db['default']['hostname'] = "etc.com"; $db['default']['username'] = "etc"; $db['default']['password'] = "etc@etc"; $db['default']['database'] = "visiting_link"; $db['default']['dbdriver'] = "mysql"; $db['default']['dbprefix'] …

0
162
Member Avatar for game4tress

I have fields in a table that are being constantly updated with the current time (each second). First, the controller calls a function to create the record in the database public function saveEntry($theuser='') { $data = array( 'theuser' => $theuser , 'dateentered' => date('Y-m-d') , //date('d-m-Y H:i:s') , 'gname' => …

Member Avatar for Tpojka
0
299
Member Avatar for Hayezb

Hello! I'm needing some help integrating HighCharts into my CodeIgniter application and getting data from my MySQL database! I've followed a YouTube video on actually integrating HighCharts and it was extremely straightforward. However, that method included a hardcoded array and I'm needing to generate an array from data stored in …

Member Avatar for diafol
0
2K
Member Avatar for samoual

Hello Every one i have samll Problem Here iam using codegniter and i have template that i use in all my views in some page i afound that i can use grocery crud as it will make it easer to show and it will give better look , as iam …

Member Avatar for cereal
0
287
Member Avatar for game4tress

I'm creating a chat system and I need to remove every user that did not properly logout (if for instance the computer was shutdown unexpectedly,...), such as some other tasks. One possibility is for each user's script check for inactivity (3 seconds, for instance) of every other user, but if …

Member Avatar for jkon
0
271
Member Avatar for mwenyenia07

I have created a login page using CodeIgniter 1.7. its code is shown below: <?php class login extends Controller { function login() { parent::Controller(); } function index() { $this->load->view('loginview'); } function verify() { if ($this->input->post('username')){ $uname = $this->input->post('username'); $upass = $this->input->post('password'); $result=$this->dblogin->verifyUser($uname,$upass); if($result){ redirect('dashboards','refresh'); }} } } /* End of …

Member Avatar for vjadeja
0
3K
Member Avatar for santoshkumar.palivela.7

<?php class Jcart { public $config = array(); private $items = array(); private $names = array(); private $prices = array(); private $qtys = array(); private $urls = array(); private $subtotal = 0; private $itemCount = 0; function __construct() { // Get $config array include_once('config-loader.php'); $this->config = $config; } /** * …

Member Avatar for AARTI SHRIVAS
0
2K
Member Avatar for game4tress

I'm creating a chat system using Codeigniter and I need to update a textarea with a field in the database each second. For that I'm trying to use jquery for the timer but I don't know how I can update the textarea with data from the database, with a call …

Member Avatar for game4tress
0
2K
Member Avatar for davy_yg

Hello, Rather then retyping the question, perhaps I can just place the link: http://ellislab.com/forums/viewthread/238828/ I already posted the question in CI forum, yet still does not find the answer yet. Perhaps if anyone can help me solve this problem would be great.

Member Avatar for davy_yg
0
318
Member Avatar for <M/>

So, i am going to be using a php framework to create a blog and i am curious to know what you guys think is the best framework. I, so far, am most satisfied with codeigniter (mostly) and zend. What do you guys think is the best and tell me …

Member Avatar for ashutosh08
0
207
Member Avatar for kcrazy

Ive been coding in PHP for over a year now. I was thinking to learn a PHP Framework. After googling around, i found few top frameworks such as Zend, CakePHP, CodeIgniter and Symfony. Still, im not able to choose between these. Can anyone please suggest me the best one ? …

Member Avatar for jkon
0
437
Member Avatar for davy_yg

Hello, I am trying to understand the CI code that somebody made. I saw there are two folders: site & admin folders in CI application folder. I wonder why? Is it to separate the site and admin page? Is that possible?

Member Avatar for GliderPilot
0
580
Member Avatar for renierdbruyn

This function always returns `FALSE`: function rank($applicant_id_number = 0) { $this->load->model('advert_model'); $application = $this->advert_model->get_applications(); // $user = $this->flexi_auth->get_user_by_identity_row_array(); $rank = 0; $sql1 = "SELECT * FROM applicant_details"; $results = $this->db->query($sql1)->result(); $sql3 = "SELECT * FROM job_advert"; $job_advert = $this->db->query($sql3)->result(); foreach ($results as $key => $applicant) { $applicant_age = $applicant->age; $applicant_id_number …

Member Avatar for broj1
0
257
Member Avatar for renierdbruyn

the following function "ranks" the applicants and writes them to the rank_results table in the database: function rank() { $rank = 0; $sql1 = "SELECT * FROM applicant_details"; $results = $this->db->query($sql1)->result(); $sql3 = "SELECT * FROM job_advert"; $job_advert = $this->db->query($sql3)->result(); foreach ($results as $applicant) { $applicant_age = $applicant->age; $applicant_id_number = …

Member Avatar for renierdbruyn
0
150
Member Avatar for renierdbruyn

Hi, Can some one tell me where I can find the function `get_user_by_identity_row_array() `in the flexi auth system? it is usauly called like : $this->data['user'] = $this->flexi_auth->get_user_by_identity_row_array(); I have looked every where, but maybe I’m missing it.. where can I find this? Thanks in advance.

Member Avatar for minitauros
0
202
Member Avatar for renierdbruyn

I have the following: in my **MODEL:** function get_advert() { $sql = "SELECT * FROM job_advert"; $advert = $this->db->query($sql)->result(); return $advert; } in my **CONTROLLER:** function get_detailed_list() { $job_advert = $this->ranking_model->get_advert(); echo '<pre>'; foreach ($job_advert as $j) { $job_id = $j->advert_id; $sql = "SELECT r.rank, a.advert_id AS job_id, a.job_title, d.firstname, …

Member Avatar for diafol
0
7K
Member Avatar for renierdbruyn

my goal is to list each job_title or job_id and under each job_title or job_id I want to list the candidates that qualify for that job I have this sql query: SELECT * FROM rank_results AS result WHERE result.job_id='{$job_id}' GROUP BY job_id ORDER BY rank ASC I know this is …

Member Avatar for diafol
0
204
Member Avatar for davy_yg

Hello, This I am trying to create an effective navigation code in CI. Let's say I have 10 shared pages that have the same navigation. Do I have to add the "## navigation link" codes over and over again (10 times ?) controllers/page.php <?php class Page extends CI_Controller { public …

Member Avatar for Dani
0
333
Member Avatar for davy_yg

Hello, I revised my previous discussion code by simplifying it. controllers/page.php <?php class Page extends CI_Controller { public function index() { echo "Controller loaded"; $this->load->view('homepage'); } } ?> views/homepage.php <!DOCTYPE html> <html lang="en"> <head> <link href= "<?php echo base_url('assets/css/style.css'); ?>" rel="stylesheet" type="text/css" media="screen"> </head> <body> TEST </body> </html> assets/css/style.css $('body').css('background-image', …

Member Avatar for davy_yg
0
587
Member Avatar for Dani

Receiving this CodeIgniter message in my error log every so often (and by every so often I mean quite often): ERROR - 2013-07-21 07:26:40 --> Severity: Notice --> unserialize() [<a href='function.unserialize'>function.unserialize</a>]: Error at offset 124 of 187 bytes /home/daniweb/httpdocs/system/libraries/Session.php 724 Could a problem unserializing() be caused by a session cookie …

Member Avatar for Dani
0
880
Member Avatar for rjony321

Hi Master, I cant unlink or update my uploaded image. I can successfully upload image bt i cant use unlink function or Any body help me how can i remove / Update uploaded image. Here is my Controller: public function addProfileLogo() { $data = array(); $errors = ''; if ($_FILES['logo_image']['name'] …

Member Avatar for cereal
0
6K
Member Avatar for papa10

how to create mail code when user is register then send random user name and password in CodeIgniter

Member Avatar for cereal
0
49
Member Avatar for Bijay_1

A PHP Error was encountered Severity: Notice Message: Undefined index: id Filename: controllers/event.php Line Number: 215 function addParticipant() { $data['event_id'] = $this->input->get('id', TRUE); $event_detail = $this->EventModel->getEventDetail($this->input->get('id', TRUE)); $data['event_title'] = $event_detail[1]; $this->loadpage($data, 'people', 'Add participants | BCIPN'); }

Member Avatar for cereal
0
211
Member Avatar for cgull

Hello, I am developing a site with ci 2.1.4 I used this tutorial to create an event in google calendar: [Click Here](http://www.cecilieo.com/techblog/how-to-implement-zend-framework-with-codeigniter-on-windows/) When I change a date on the view, it calls the controller function with ajax, used to work fine, now the page just hangs and I can’t figure …

Member Avatar for cgull
0
2K
Member Avatar for cmps

Hey all!! I am thinking of creating a website that may contain some buying/selling items, so I was wondering which framework is the best for shopping online. I have some experience with codeigniter, but I was using it for its MVC structure which organizes and uses files more efficently. Anyway …

Member Avatar for diafol
0
185

The End.