codeigniter

What web application framework should I use for a web gallery?

Hey guys, I need to create a photo gallery for a website running IIS 4.0 or IIS 5.0 (im not sure which). It needs to display a low resolution version of the gallery to anyone, and it must show both the low and high resolution images for "priviledged" users. So I need access priviledges, photo albums and once the site is complete, the pe...

How to allow CodeIgniter GET parameters

I know that codeIgniter turns off GET parameters by default. But by having everything done in POST, don't you get annoyed by the re-send data requests if ever you press back after a form submission? It annoys me, but I'm not sure if I want to allow GET purely for this reason. Is it such a big security issue to allow GET parameters t...

Mod Rewrite rule to Zeus Server rule (Codeigniter)

Hi everyone, I'm about to go live with a Codeigniter powered site. I want to remove index.php from the url so that instead of this: http://www.mysite.com/index.php/controller I get something like this: http://www.mysite.com/controller So far, pretty straightforward. In the past I've used the mod-rewrite rule supplied by the Codeig...

Caching in Code Igniter

I have read the documentation for the CI Caching but still don't understand much about it. What exactly does it do, and what is the use of caching a dynamic website? ...

What Code Igniter authentication library is best?

I see there are a few. Which ones are best maintained and easy to use? Or should I just write my own? ...

Why is Apache mod_rewrite not behaving as expected

I want to redirect URLs from an old site that used raw URL requests to my new site which I have implemented in CodeIgniter. I simply want to redirect them to my index page. I also would like to get rid of "index.php" in my URLs so that my URLs can be as simple as example.com/this/that. So, this is the .htaccess file I have created: ...

Need insight: Transitioning from CodeIgniter to Cake PHP Framework

I picked CodeIgniter as the first PHP MVC framework to learn. I've used it for a few projects and feel quite comfortable with it. I now have the opportunity to work on a project that uses Cake. My question is, how long do you think it will take to transition to this framework if I have a good grasp on CodeIgnitor? I don't want to be ov...

Third (3rd) Click Logout in FreakAuth

I've installed the FreakAuth Lite library for CodeIgniter (http://www.4webby.com/freakauth/). Everything is working nicely (logging in/out), but I have one problem. On the third page request after a user has logged in, the user is automatically logged out. This happens if you simply refresh the page three times, or click through to 3 sep...

How do you convert a page-based PHP application to MVC?

Hello Everyone, I've been struggling for some time now with exactly how to recode a page-based php application I have to an MVC framework. (Just for background, I am having to move the app into MVC because my boss is making me :) Anyway, I've sat down and printed out the directory structure and started trying to plan how I can convert...

‘Remember Me’ login in CodeIgniter

How do you implement this in CI ? ...

CodeIgniter Table Class: How to add a link from a generated cell

I'm using the table class that autogenerates a table for me from an array of data from my database. So in my model I have: function get_reports_by_user_id($userid) { return $this->db->get_where('ss2_report',array('userid' => $userid))->result_array(); } In my controller I have: function index() { echo $this->table->generate(...

I have a mysterious PHP SOAP error on my host, but can't duplicate locally

I've run across an interesting PHP/SOAP error that has me stymied. After searching I have not found a plausible explanation, and I'd appreciate your help. Here's the background: I have a site built in PHP/CodeIgniter which uses SOAP to communicate over SSL with a back-end system provided by a third party (let's call them "Company X" to ...

How can I modify this image manipulation function done in codeigniter to be more efficient

I think this function isn't as efficient as it should be. I'd appreciate some suggestions on how I can structure it to be faster and take less memory. This is what the code does: checks to see if the image was uploaded add details about it (tags, name, details) to the database if the variable $orientation was set, rotate the image if...

Grouping SQL data in mysql side, or PHP?

I have the following tables in mysql: team: id, name, [more stuff] person: id, name, team, [more stuff] entry: id, name, team, [more stuff] registrations: id, event_id, team, status registration_people: registration_id, person_id registration_entries: registration_id, entry_id I would like to query the database and return details abou...

MVC with PHP CodeIgniter: user authentication

I am writing a web-app PHP. I want to use MVC pattern for this, and decided to go with CodeIgniter. My application will have some pages which will require authentication, some pages wont. I want to design this in a very generic way, so that there should be no code duplication. Can any one point to some good "design/class structure" fo...

CodeIgniter form validation - Get the result as "array" instead of "string"

I am writing my form validation class using CodeIgniter. Is there any way so that I can get error messages in name value pair? Say, in an example form there are four fields: ‘user_name’, ‘password’, ‘password_conf’, ‘timezone’. Among them ‘user_name’, ‘password’ validation has failed. So after executing: - $result = $this->form_valida...

Guidance related to Paypal Integration Using Codeigniter

I need some guidance related to Paypal Integration. Its not similar to regular cart. After checkout, the site offers a form for payment option, either its paypal or some other payment process. The form directs to controller after submit. A array exists which contains all items value, from here on how can I proceed to paypal site. How ca...

Trouble with encoding special chars for URL through text input

So I'm building a simple php application using CodeIgniter that is similar to Let Me Google That For You where you write a sentence into a text input box, click submit, and you are taken to a URL that displays the result. I wanted the URL to be human-editable and relatively simple so I've gotten around the CodeIgniter URL routing a bit. ...

Missing parameter in PHP POST function

Hi, I am passing some parameters to my PHP page thru POST request and in the PHP page I am reading it like; $foo = $this->input->post('myParam'); If the 'myParam' parameter is present in the POST request, then $foo will be assigned the 'myParam' value. But, How do I check if the 'myParam' is not passed in the POST request? PS: I a...

How do you refactor a Codeigniter controller function that is too long?

I have a function in my controller that has grown longer than I'd prefer and I'd like to refactor it to call a few discrete functions to make it easier to manage. How can I better organize a long function in a Codeigniter controller? What I've tried: I know you can create private functions in a controller by naming them with a leading ...