CodeIgniter Reactor

Welcome to the CodeIgniter Reactor! This is where ideas spark, igniting new code and changes from both EllisLab and the community to keep CodeIgniter awesome.

CodeIgniter needs ... so that ...

You've used all your votes and won't be able to post a new idea, but you can still search and comment on existing ideas.

There are two ways to get more votes:

  • When an admin closes an idea you've voted on, you'll get your votes back from that idea.
  • You can remove your votes from an open idea you support.
  • To see ideas you have already voted on, select the “My feedback” filter and select “My open ideas”.
(thinking…)
Reset

Enter your idea and we'll search to see if someone has already suggested it.

If a similar idea already exists, you can vote and comment on it.

If it doesn't exist, you can post your idea so others can vote on it.

Enter your idea and we'll search to see if someone has already suggested it.

  • Hot ideas
  • Top ideas
  • New ideas
    1. Allow CI_Session to store OBJECTS of Model types

      The problem at hand:
      CI_Session does not allow storing objects.
      It does however store a bunch of objects itself which seems like unnecessary overhead (CI object with lots of CI objects and recursions etc).

      More detailed: If you store objects (instances of Models in my case) in the Session right now, the data cannot be accessed, because any object you store there will have a “incomplete object error” which makes the data unusable. This is, because the object definitions in the classes (models) is loaded AFTER the session is started.
      I would have expected, that auto-loading the respective models would… more

      8 votes
      Vote 0 votes Vote Vote
      Vote
      Sign in
      Check!
      (thinking…)
      Reset
      or sign in with
      • facebook
      • google
        Password icon
        I agree to the terms of service

        You'll receive a confirmation email with a link to create a password (optional).

        Signed in as (Sign out)
        You have left! (?) (thinking…)
      • 3 votes
        Vote 0 votes Vote Vote
        Vote
        Sign in
        Check!
        (thinking…)
        Reset
        or sign in with
        • facebook
        • google
          Password icon
          I agree to the terms of service

          You'll receive a confirmation email with a link to create a password (optional).

          Signed in as (Sign out)
          You have left! (?) (thinking…)
        • Allow encryption and decryption of URI segments as a uri_protocol option in APPPATH.'config/config.php' file. so http://example.com/control

          Allow for auto encryption and decryption of URI segments as a uri_protocol option in APPPATH.'/config/config.php' file such that:

          http://example.com/controller/method/param-1/value/.../param-N/value

          BECOMES

          http://example.com/c9Zmxo7VSwyF0gnHtw4D.

          encryption and decryption is done internally so this feature is version compatible...

          3 votes
          Vote 0 votes Vote Vote
          Vote
          Sign in
          Check!
          (thinking…)
          Reset
          or sign in with
          • facebook
          • google
            Password icon
            I agree to the terms of service

            You'll receive a confirmation email with a link to create a password (optional).

            Signed in as (Sign out)
            You have left! (?) (thinking…)
          • move system folder into its own github repo

            makes it much easier make structure changes in the root folder, also gives users ability to use as submodule

            26 votes
            Vote 0 votes Vote Vote
            Vote
            Sign in
            Check!
            (thinking…)
            Reset
            or sign in with
            • facebook
            • google
              Password icon
              I agree to the terms of service

              You'll receive a confirmation email with a link to create a password (optional).

              Signed in as (Sign out)
              You have left! (?) (thinking…)
            • OAuth 2.0 server and client library

              OAuth 2.0 being the de-facto standard for third party communication an OAuth server (auth server & resource server) and client library similar to the XML-RPC implementation would be very helpful.

              Some attempts have already been made by Alex Bilbie (https://github.com/alexbilbie/CodeIgniter-OAuth-2.0-Server).

              29 votes
              Vote 0 votes Vote Vote
              Vote
              Sign in
              Check!
              (thinking…)
              Reset
              or sign in with
              • facebook
              • google
                Password icon
                I agree to the terms of service

                You'll receive a confirmation email with a link to create a password (optional).

                Signed in as (Sign out)
                You have left! (?) (thinking…)
              • Form validation method exists

                Why you dont add this new method to the validation process..
                It will be just as is_unique but with the opposite result ..

                It can be very usefull for all developers.

                For example at LOGIN(almost all site have logins..) we can check for username, email, with this validation.
                Currently either we have to extend Form_validation class or to write our own error method for this simple check.

                4 votes
                Vote 0 votes Vote Vote
                Vote
                Sign in
                Check!
                (thinking…)
                Reset
                or sign in with
                • facebook
                • google
                  Password icon
                  I agree to the terms of service

                  You'll receive a confirmation email with a link to create a password (optional).

                  Signed in as (Sign out)
                  You have left! (?) (thinking…)
                • Exception (Error) handling

                  Whenever CodeIgniter encounters an error it simply dies (show_error).
                  However, I would like to decide myself whether an error or failure should result in an exit. (For example, I would like to load a language file, but even if it does not exist I still want to continue or use a fallback.)
                  Therefore instead of the different show_error functions, Exceptions should be thrown so we could try-catch them.
                  To retain the functionality of showing the error, if no catch-block is defined, set_exception_handler can be used to set the default exception handler.

                  19 votes
                  Vote 0 votes Vote Vote
                  Vote
                  Sign in
                  Check!
                  (thinking…)
                  Reset
                  or sign in with
                  • facebook
                  • google
                    Password icon
                    I agree to the terms of service

                    You'll receive a confirmation email with a link to create a password (optional).

                    Signed in as (Sign out)
                    You have left! (?) (thinking…)
                  • Join method on CI_DB_active_record to support string-based joins

                    I recently had a problem whereby I needed custom join conditions based on user values. This is not allowed in the join method, as it ends up surrounding the value like so: `'value`', which results in an SQL error. This is easily solved by ensuring that the join() method can support join strings, like so:
                    public function join($table, $cond = '', $type = '') {
                    $num_args = func_num_args();
                    if ($num_args == 1) {
                    // only 1 arg passed, full join string
                    $this->ar_join[] = $table;
                    return $this;
                    }

                    The $table argument then becomes a multi-purpose variable (probably worth changing the name… more

                    4 votes
                    Vote 0 votes Vote Vote
                    Vote
                    Sign in
                    Check!
                    (thinking…)
                    Reset
                    or sign in with
                    • facebook
                    • google
                      Password icon
                      I agree to the terms of service

                      You'll receive a confirmation email with a link to create a password (optional).

                      Signed in as (Sign out)
                      You have left! (?) (thinking…)
                    • Add function to get the array (instead of a string) when validation fails

                      This will be helpful when handling the errors of a form validation from the client side, allowing us to mark which fields were invalid instead of blindly throwing the entire string anywhere.

                      I took the code from validation_errors() (./system/helpers/form_helper.php) and modified it to return the array. You can see the code here: http://codeigniter.com/forums/viewthread/211917/

                      4 votes
                      Vote 0 votes Vote Vote
                      Vote
                      Sign in
                      Check!
                      (thinking…)
                      Reset
                      or sign in with
                      • facebook
                      • google
                        Password icon
                        I agree to the terms of service

                        You'll receive a confirmation email with a link to create a password (optional).

                        Signed in as (Sign out)
                        You have left! (?) (thinking…)
                      • better image library

                        we need something like http://wideimage.sourceforge.net

                        right now you cant do zoom crop and other basic image manipulation without writing tons of code, so i end it up always using wideimage in CI

                        examples:
                        1)
                        - you need a thumb (fixed size)
                        - you upload several images, they have different aspect ratio and sizes
                        - thumb must be generated without any border left, so you need to resize up if the image is already smaller than the thumb, scale up if its bigger (by choosing one of the axis) and crop the rest

                        2) you need to resize and merge png… more

                        3 votes
                        Vote 0 votes Vote Vote
                        Vote
                        Sign in
                        Check!
                        (thinking…)
                        Reset
                        or sign in with
                        • facebook
                        • google
                          Password icon
                          I agree to the terms of service

                          You'll receive a confirmation email with a link to create a password (optional).

                          Signed in as (Sign out)
                          You have left! (?) (thinking…)
                        • Do this ... instead of this ...

                          Do this (just an example):

                          /* End of file ./application/config/routes.php */

                          or even:

                          /* End of ./application/config/routes.php */

                          Instead of this:

                          /* End of file routes.php */
                          /* Location: ./application/config/routes.php */

                          19 votes
                          Vote 0 votes Vote Vote
                          Vote
                          Sign in
                          Check!
                          (thinking…)
                          Reset
                          or sign in with
                          • facebook
                          • google
                            Password icon
                            I agree to the terms of service

                            You'll receive a confirmation email with a link to create a password (optional).

                            Signed in as (Sign out)
                            You have left! (?) (thinking…)
                          • multi_query support

                            CI supports mysqli driver which has got mysqli_multi_query method.

                            On some forums there are opinions that CI is not suitable for more complex tasks. Lack of multi_query support seems to confirm this "bad" idea.

                            As far as I understand there is also no PDO_MySQL support, and also as I read somewhere DB class is the only not extendable class which make things harder for community support.

                            1 vote
                            Vote 0 votes Vote Vote
                            Vote
                            Sign in
                            Check!
                            (thinking…)
                            Reset
                            or sign in with
                            • facebook
                            • google
                              Password icon
                              I agree to the terms of service

                              You'll receive a confirmation email with a link to create a password (optional).

                              Signed in as (Sign out)
                              You have left! (?) (thinking…)
                            • Isolate helpers in classes instead of declaring global functions

                              Helpers could be like this :

                              $this->load->helper('text_helper');

                              and called like this :

                              $this->text_helper->the_function().

                              This would avoid conflicts when using Codeigniter with other applications.

                              10 votes
                              Vote 0 votes Vote Vote
                              Vote
                              Sign in
                              Check!
                              (thinking…)
                              Reset
                              or sign in with
                              • facebook
                              • google
                                Password icon
                                I agree to the terms of service

                                You'll receive a confirmation email with a link to create a password (optional).

                                Signed in as (Sign out)
                                You have left! (?) (thinking…)
                              • CodeIgniter needs next page links on online documentation

                                The online documentation needs next page buttons... it adds extra work to open drawer each time. Thanks.

                                11 votes
                                Vote 0 votes Vote Vote
                                Vote
                                Sign in
                                Check!
                                (thinking…)
                                Reset
                                or sign in with
                                • facebook
                                • google
                                  Password icon
                                  I agree to the terms of service

                                  You'll receive a confirmation email with a link to create a password (optional).

                                  Signed in as (Sign out)
                                  You have left! (?) (thinking…)
                                • log current page url into log file when show_404() is called without any parameter.

                                  Codeigniter logs the value of $page parameter into file but if not supplied, it doesn't log any url. This makes it difficult to identify which page was accessed when the 404 occured. It's better to make the default value of $page to current url by using something like $CI->uri->uri_string();

                                  1 vote
                                  Vote 0 votes Vote Vote
                                  Vote
                                  Sign in
                                  Check!
                                  (thinking…)
                                  Reset
                                  or sign in with
                                  • facebook
                                  • google
                                    Password icon
                                    I agree to the terms of service

                                    You'll receive a confirmation email with a link to create a password (optional).

                                    Signed in as (Sign out)
                                    You have left! (?) (thinking…)
                                  • "Rails" Style application logging

                                    I would love to see application logging in code igniter like as happens in ruby in rails by default.

                                    Here is a snippet from the rails application log (in production mode)

                                    Processing ClientsController#index (for 192.168.1.179 at 2011-12-18 19:27:18) [GET]
                                    Session ID: BAh7CToOcmV0dXJuX3RvMDoMdXNlcl9pZGkGOgxjc3JmX2lkIiVmMGYxMmVj
                                    MWFhNjRiZDg3ODJlNDZjZjY1YzhiZjU5YyIKZmxhc2hJQzonQWN0aW9uQ29u
                                    dHJvbGxlcjo6Rmxhc2g6OkZsYXNoSGFzaHsABjoKQHVzZWR7AA==--4f94c0adec212d51709562b2a6f4996ef0ef5e99
                                    Parameters: {"action"=>"index", "controller"=>"clients"}
                                    Rendering template within layouts/clients
                                    Rendering clients/index
                                    Completed in 0.04318 (23 reqs/sec) | Rendering: 0.03273 (75%) | DB: 0.00295 (6%) | 200 OK [http://testsite.com
                                    /clients]

                                    This log snippet tells me what controller & action are being used, input parameter, how long it takes, and what url has been hit etc.

                                    I would like… more

                                    10 votes
                                    Vote 0 votes Vote Vote
                                    Vote
                                    Sign in
                                    Check!
                                    (thinking…)
                                    Reset
                                    or sign in with
                                    • facebook
                                    • google
                                      Password icon
                                      I agree to the terms of service

                                      You'll receive a confirmation email with a link to create a password (optional).

                                      Signed in as (Sign out)
                                      You have left! (?) (thinking…)
                                    • Cache/Output Library Improvements (Overhaul)

                                      1. (at least optionally:) HTTP Cache Headers that match the server-side cache expirations. (Google doesn't need to crawl a page again and again if we know for sure it hasn't changed. Proper HTTP headers would resolve this.)
                                      2. The ability to selectively flush pages from the cache. (I do it with a ?flush_cache query string, but there's probably some better method).
                                      3. Query-string aware.
                                      4. GZip content before caching it and then serve it in its GZipped form to browsers that support decompression (and decompress it for the edge case that doesn't), to cut down on both disk space and… more

                                      4 votes
                                      Vote 0 votes Vote Vote
                                      Vote
                                      Sign in
                                      Check!
                                      (thinking…)
                                      Reset
                                      or sign in with
                                      • facebook
                                      • google
                                        Password icon
                                        I agree to the terms of service

                                        You'll receive a confirmation email with a link to create a password (optional).

                                        Signed in as (Sign out)
                                        You have left! (?) (thinking…)
                                        planned  ·  2 comments  ·  Admin →
                                      • Smarter crop function

                                        I would like a smarter crop function. If you upload a normal photo (1000x750px) and want a 80x80 thumbnail for that, you get some sky in an 80x80 box.

                                        The best thing (imo) would be to resize the image until the width or height hits 80px, then crop the rest.
                                        Right now it can be done, but it's a hassle and the file needs to be written to disk twice.

                                        Or maybe you can, but I'm not seeing it.

                                        19 votes
                                        Vote 0 votes Vote Vote
                                        Vote
                                        Sign in
                                        Check!
                                        (thinking…)
                                        Reset
                                        or sign in with
                                        • facebook
                                        • google
                                          Password icon
                                          I agree to the terms of service

                                          You'll receive a confirmation email with a link to create a password (optional).

                                          Signed in as (Sign out)
                                          You have left! (?) (thinking…)
                                        • a road map of changes

                                          I would like to see a road map of planned changes so we as a community know what changes are coming down the line

                                          52 votes
                                          Vote 0 votes Vote Vote
                                          Vote
                                          Sign in
                                          Check!
                                          (thinking…)
                                          Reset
                                          or sign in with
                                          • facebook
                                          • google
                                            Password icon
                                            I agree to the terms of service

                                            You'll receive a confirmation email with a link to create a password (optional).

                                            Signed in as (Sign out)
                                            You have left! (?) (thinking…)
                                          • get_where() to behave more like where()

                                            get_where() currently only supports an Array in the where clause.

                                            ie. from the user guide:
                                            $query = $this->db->get_where('mytable', array('id' => $id), $limit, $offset);

                                            Yet where() has 4 ways of specifying a where condition:
                                            Simple key/value method...Custom key/value method...Custom string and so on.

                                            Why can't we supply the same 4 formats used in the where() function as in get_where()?

                                            Even the function comment reads...

                                            /**
                                            * Get_Where
                                            *
                                            * Allows the where clause, limit and offset to be added directly
                                            *
                                            * @param string the where clause

                                            Yet, a string doesn't work :(

                                            6 votes
                                            Vote 0 votes Vote Vote
                                            Vote
                                            Sign in
                                            Check!
                                            (thinking…)
                                            Reset
                                            or sign in with
                                            • facebook
                                            • google
                                              Password icon
                                              I agree to the terms of service

                                              You'll receive a confirmation email with a link to create a password (optional).

                                              Signed in as (Sign out)
                                              You have left! (?) (thinking…)
                                            ← Previous 1 3 4 5 6 7 8 9 10 11 12 13
                                          • Don’t see your idea?
                                          • Post a new idea…
                                          • CodeIgniter Reactor

                                            Knowledge Base and Helpdesk