Search Results

Search found 981 results on 40 pages for 'codeigniter 2'.

Page 25/40 | < Previous Page | 21 22 23 24 25 26 27 28 29 30 31 32  | Next Page >

  • Combining a web application with another (larger).

    - by Kevin Brown
    I'm writing a web app, initially meant to be stand-alone--it's essentially a survey with user-management/authentication built on Codeigniter. The company I'm doing this for wants to merge it with their main system so that it acts like a feature, or a sub-app of their website. What is the best thing for me to do? I think I could do one of two things: Finish my application, as I had planned to initially, and let them handle the merging.It would probably save me a headache. Stop where I am in development, and migrate my authentication system to theirs, migrate the payment system to use theirs, and then finish the app. In your opinion, or experience, what is the best thing to do?

    Read the article

  • How do I handle user authorization the safest way?

    - by Irro
    I'm developing a small website where I'm going to allow user to create accounts but I'm quite clueless when it comes to safety around authorizations. I have built my project in PHP with codeigniter and found a library (Tank Auth) that could handle authorization for me. It stores password in a safe way but I'm still worried about the part when the user sends their password to my server. One easy way to do it would be to send the password in a post-request but I would guess that it's quite easy to sniff such a password. Should I do something with the password on the client side before sending it to my server? And is there any good javascript libraries for this?

    Read the article

  • URIs vs Hidden Forms

    - by NateDogg
    I'm working in the Codeigniter framework, and want to send requests to my controller/model that have several variables involved. Is there a difference between passing those variables via a hidden form (i.e. using "post") as opposed to passing them through URIs (e.g. 'travel/$month/$day/')? What about security concerns? e.g. URIs: http://www.example.com/travel/$month/$day/ Hidden Form: form_hidden('month',$month); form_hidden('day',$day);

    Read the article

  • Should I call redirect() from within my Controller or Model in an MVC framework?

    - by justinl
    I'm using the MVC PHP framework Codeigniter and I have a straight forward question about where to call redirect() from: Controller or Model? Scenario: A user navigates to www.example.com/item/555. In my Model I search the item database for an item with the ID of 555. If I find the item, I'll return the result to my controller. However, if an item is not found, I want to redirect the user somewhere. Should this call to redirect() come from inside the model or the controller? Why?

    Read the article

  • PHP - white screen of death!

    - by Industrial
    Hi everyone, After debugging a codeigniter app that were installed into a new development environment, I have started to freak out when seeing white screens with nothing more available. I have been able to solve each and every one of the errors that have caused this, but it have taken seriously way too long time. PHP error_reporting(E_ALL) & display_errors", 1 is set as well. I even installed Xdebug in hope of getting more output, but no. My logging settings are also working, but nothing is written to the log. Is there a way to get something informative printed out instead of a complete white screen? It would certainly shorten my time spent on solving the eventual errors that causes this? Thanks a lot! Reference: http://stackoverflow.com/questions/2149321/why-does-code-igniter-give-me-a-white-page

    Read the article

  • Uploading CI Website

    - by 01010011
    Hi, This is the first time I’m building a website and using CodeIgniter and I was wondering whether you have any tips on uploading CI to a free web host. Can I just upload the entire CI folder? Or do I have to upload individual files (God no!)? What are my options? What about my MySQL database - do I just upload my mysqldump to the webhost? Also, can you recommend a good free webhost. I was thinking about 000webhost. Any other suggestions will be more than welcome. Thanks!

    Read the article

  • Default controller name is removed on browser refresh (CodeigniterPHP/Nginx issue?)

    - by tim peterson
    For all pages in my codeigniter app except my default controller, when I refresh the browser the url isn't affected as one would expect. However for my default controller, main.php, when when I refresh the browser at "http://localhost/main" or "http://mysite.com/main", the main part is stripped off the url. So the browser bar shows just "http://localhost" or "http://mysite.com". Totally lost on where to start with this but was just wondering if anyone has come across this before...? Here's what I think could be the relevant part of my nginx.conf (if Nginx is the problem). if ($request_uri ~* ^(/main(/index)?|/index(.php)?)/?$) { rewrite ^(.*)$ / permanent; }

    Read the article

  • how to display a array value in view page

    - by udaya
    Hai I am using codeigniter...I my function phpcalview()... This is my function function phpcalview() { $year = $this->input->post('yearvv'); $data['year'] = $this->adminmodel->selectyear(); $data['date'] = $this->adminmodel->selectmonth(); print_r($data['date'] ); $this->load->view('phpcal',$data); } I am printing the values with print_r($data['date'] ); I get values like Array ( [0] => Array ( [dbdatenum] => 1 ) [1] => Array ( [dbdatenum] => 2 ) [2] => Array ( [dbdatenum] => 3 ) [3] => Array ( [dbdatenum] => 4 )) I want to display the array seperately as array[0],array[1] in my view page how can i do that

    Read the article

  • htaccess hotlinking problem

    - by DesperateWebDev
    Hi! Iam fighting following problem with little success. I want to block hotlinking to images in static folder from other domains than my_domain.com htaccess looks like this: RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http://(www\.)?my_domain\.com [NC] RewriteRule \.(gif|jpe?g|js|css)$ - [F,NC,L] RewriteRule ^(favicon\.ico)$ static/$1 [L] RewriteCond $1 !^(index\.php|static|robots\.txt|7e3b7a5bafcb0fa8e8dfe3ea6aca9186\.txt) RewriteRule ^(.*)$ /index.php/$1 [L] Page is on CodeIgniter and it have static folder so images can be loaded for ex: http://www.mydomain.com/static/somepic.jpg but users are linking from other sites and eat my bandwidth fast. Presented above htaccess doesnt work and I have NO idea why :( Please help!

    Read the article

  • Insert error when sending post array to activerecord

    - by Gonzalo
    I am using CodeIgniter + phpActiveRecord. I am getting all the records from the $_POST array and I want to send that same array to my activeRecord class to insert the data into the DB. This line doesn't seem to be working but I can't get the error because the page is just blank: Car::create($this->input->post()); If the names of the fields are equal to the names of the columns in the table, should it what I pasted above work? ==========SOLVED======== It is possible to do it, and in the model of the object one can add var $name_of_the_field_which_you_don't_process = FALSE; And that's it.

    Read the article

  • could you build Stackoverflow with Drupal 7?

    - by ajsie
    im wondering if one can/should build a site like Stackoverflow with Drupal 7? we all know what Stackoverflow is and how it looks like. users <- threads <- tags and the openid stuff, validation etc. if you are going to build a site exactly as SO, will you use Drupal 6/7 or a MVC framework like CakePHP, CodeIgniter...? try to be realistic here and think about the actual work to do and how to implement with or without Drupal, not just "Drupal has nice features you can use and extend". would be helpful. thanks!

    Read the article

  • Uploading a Website

    - by 01010011
    Hi, This is my first time building a website and using CodeIgniter for a school project. I was wondering whether you have any tips on uploading CI to a free web host , my database, free webhosting and basic security tips. Can I just upload the entire CI folder? Or do I have to upload individual files (God no!)? What are my options? What about my MySQL database - do I just upload my mysqldump to the webhost? Also, can you recommend a good free webhost. I was thinking about 000webhost. Any basic tips on security would also be appreciated (I've implemented many of the form_validation rules like xss_clean for starters) Any other suggestions will be more than welcome. Thanks!

    Read the article

  • Send 404 when requesting index.php through .htaccess?

    - by Daniel
    I've recently refactored an existing CodeIgniter application to use url segments instead of query strings, and I'm using a rewriterule in htaccess to rewrite stuff to index.php: RewriteRule ^(.*)$ /index.php/$1 [L] My problem right now is that a lot of this website's pages are indexed by google with a link to index.php. Since I made the change to use url segments instead, I don't care about these google results anymore and I want to send a 404 (no need to use 301 Move permanently, there have been enough changes, it'll just have to recrawl everything). To get to the point: How do I redirect requests to /index.php?whatever to a 404 page? I was thinking of rewriting to a non-existent file that would cause apache to send a 404. Would this be an acceptable solution? How would the rewriterule for that look like? edit: Currently, existing google results will just cause the following error: An Error Was Encountered The URI you submitted has disallowed characters.

    Read the article

  • Help with PHP MySQL join

    - by kester martinez
    Please help me to understand proper join syntax. I have table named inventory which has: trans_id trans_items items -> item_id trans_user employees -> person_id trans_date trans_comment trans_inventory As you can see above, trans_items is a foreign key in items table, and trans_user is a foreign key in employees table. Now what I want to do is to display in HTML the inventory table, but instead of displaying the item id, I want the ITEM NAME to be displayed. Here is what I have done. Please note I'm using CodeIgniter. public function getData(array $inputs) { $this->db->select('trans_items, trans_user, trans_date, trans_inventory, trans_comment'); $this->db->from('inventory'); $this->db->order_by('trans_date desc'); return $this->db->get()->result_array(); }

    Read the article

  • database logic for tracking each and every operation in my web application

    - by ripa
    I am developing an Web application. In my application, I need to keep track of each and every operation for every logged in user. I have planned following for achieving this task:- I will create stored procedure in mysql. I will trigger this procedure on each table's insert , update delete. This is an tough job for me. Will anybody direct me in the right way? I am using PHP based Codeigniter framework and mysql database.

    Read the article

  • Admin panel - what is the best way to display "static" data in the layout?

    - by rkj
    I'm about to write a admin panel for my CMS written in CodeIgniter. There will be some user information visible at all time - both in the layout's header section and the sidebar. I'm used to do it in a way that I personally hope and think could be done a lot easier, since I'm tired of sending the same parametres to the view over and over again, when it's dynamic data that needs to be displayed on every page anyways (such as unread messages, username, name, status, etc). I'll need controllers and models, I know that, but do I have to pass, just for an example, the user's username, unread messages etc. every time I need to load a view? Should I do some kind of library for this? Now my question is: How would I do it when it comes to best practice and for making it easy to maintain in the future? I hope my question is understandable :)

    Read the article

  • What can cause reset connection when running PHP script?

    - by marcin_koss
    I've developed a web application with CodeIgniter that works perfectly on my local machines (one with windows and one with Linux). When I moved it to my hosting server, connection gets reset when running one particular PHP script that does a few MySQL queries and some operations on arrays. The data I'm querying is small, just a few tables with up to 25 records. Firefox returns "The connection was reset" after maybe 2-3 seconds. I checked the servers error logs but there was nothing there. Unfortunately I don't have access to Apache error logs. What can cause this behavior?

    Read the article

  • Codeignitor Global Array Declaration

    - by Ajith
    I have a sequence of number like follows 1 - 25, 2 - 60, 3 - 80, 4 - 100 and so on which means that if input is 1 output will be 25 and so on...I need to store it in global array.I would like to use it in multiple pages also.In codeigniter where i can declare a global array and store all these? I am trying like as follows in constants.php $CONFIDENCEVALUE = array(); $CONFIDENCEVALUE[] = array('1'=>25,'2'=>'60','3'=>80,'4'=>100); If it is correct how can access these array value in required pages.Help me please.I am not an expert with codeignitor.Thanks

    Read the article

  • Refreshing a echoed PHP variable after jQuery AJAX success?

    - by Matt
    Hello, I have a shopping cart in Codeigniter in which products are added to the cart using (jQuery) Ajax. In the header of each page it displays the number of contents in the cart using <?php echo $this->cart->total_items(); ?> How can I update/refresh this variable when a product is added to the cart, as I am using AJAX to add products to the cart and thus the page isn't being reloaded when products are added. It seems pointless to use AJAX to do asyncronous stuff if I have to reload the page to get the new number of total items from the server. Many thanks.

    Read the article

  • is there an index to be accessed in the CI foreach with {}-Notation?

    - by helle
    Hello Guys, i'm new with Codeigniter,and whish to know if i can access any kind of iterator for the foreach with {}-Notation in my views. The thing is, i'm having a list which should be devided after each x items. example (what i would like to do: <ul> {list} <li>{items}</li> <? if ($iterator % 15 == 0) echo "</ul><ul>"; ?> {/list} </ul> thanks in advice ;-)

    Read the article

  • Github + keep file but dont track changes

    - by Mike
    I have a codeigniter framework thats using github. Within this application I have several files that i will want to have in the repo but not track any changes on.. Example is: i deploy a new installation of this framework to a new client, i want the following files to be downloaded (they have default values 'CHANGEME') and i just have to make changes specific to this client IE(database credentials, email address info, custom css styling). // the production config files i want the files but they need to be updated to specific client needs application/config/production/config.php application/config/production/database.php application/config/production/tank_auth.php // index page, defines the environment (production|development) /index.php // all of the css/js cache (keep the folder but not the contents) /assets/cache/* // production user based styling (color, fonts etc) needs to be updated specific to client needs /assets/frontend/css/user/frontend-user.css currently if i run git clone [email protected]:user123/myRepo.git httpdocs and then i edit the files above, all is great.. until i release a hotfix or patch and run git pull. All of my changes are then overwritten.

    Read the article

  • Writing an installer using codigniter

    - by RobertWHurst
    I'm just about finished my first release of automailer, a program I've been working on for a while now. I've just got to finish writing the installer. Its job is to rewrite the codigniter configs from templates. I've got the read/write stuff working, but I'd like to be able to test the server credentials given by the user without codingiter throwing a system error if they're wrong. Is there a function other than mysql_connect that I can use to test a connection that will return true or false and won't make codeigniter have a fit?

    Read the article

  • Form Input Gets 1 Word

    - by 01010011
    Hi Using Codeigniter, how do I get and display, from my controller, all of the text a user entered into a text field on a view? I only get the first word, and nothing after the spaces. Here are my form_validation rules $this->form_validation->set_rules( 'field_name','Field Name','trim|required|alpha_numeric|tolower|xss_clean'); And here is my controller public function my_method() { if ($this->input->post()) { $name = $this->input->post('search'); echo $name; } } and my view ?php echo form_open('my_controller/my_method'); ?> <?php echo form_input('search'); ?> <?php echo form_submit('submit', 'Search'); ?>

    Read the article

  • MVC Model architecture

    - by ATT
    I'm getting into CodeIgniter and trying to figure out the good architecture for my models. What kind of models would you create for the following simple example: list page of blog entries: shows part of the entry data, number of comments blog entry page: shows all the entry data, comment list (with part of the comment data) comment page: shows all the comment data I'm trying to get this right so that it's simple and effective. I don't want to load too much information (from the db) on the pages where I don't need them. E.g. should the same entry model handle both multiple entries as well as a single entry? And how should the comments be loaded? I only need the number of comments on the multiple entries (list) page but some of the comment data on the single entry page. How would you handle this?

    Read the article

  • Updating textfield in doctrine produces an exception

    - by james-murphy
    I have a textfield that contains say for example the following text:- "A traditional English dish comprising sausages in Yorkshire pudding batter, usually served with vegetables and gravy." This textfield is in a form that simply updates an item record using it's ID. If I edit part of the textfield and replace "and gravy." with "humous." So that the textfield now contains "A traditional English dish comprising sausages in Yorkshire pudding batter, usually served with vegetables and humous." I get the following exception:- Fatal error: Uncaught exception 'Doctrine_Query_Exception' with message 'Unknown component alias humous' in C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Abstract.php:780 Stack trace: C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Abstract.php(767): Doctrine_Query_Abstract-getQueryComponent('humous') C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Set.php(58): Doctrine_Query_Abstract-getAliasDeclaration('humous') C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Abstract.php(2092): Doctrine_Query_Set-parse('i.details = 'A ...') C:\Projects\nitrous\lightweight\system\database\Doctrine\Query.php(1058): Doctrine_Query_Abstract-_processDqlQueryPart('set', Array) C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Abstract.php(971): Doctrine_Query-getSqlQuery(Array) C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Abstract.php(1030): Doctrine_Query_Abstract-_execute(Array) C:\Projects\nitrous\lightweight\system\appl in C:\Projects\nitrous\lightweight\system\database\Doctrine\Query\Abstract.php on line 780 I'm using Doctrine 1.0.6 hooked into CodeIgniter 1.7.0 if anyone is interested. My doctrine query that actually performs the update looks as follows:- public function updateItems($id, $arrayItem) { $query = new Doctrine_Query(); $query->update('Item i'); foreach($arrayItem as $key => $value) { $query->set('i.'.$key, "'".$value."'"); } $query->where('i.id = ?', $id); return $query->execute(); } This seems bizarre because if i replace the entire string "A traditional English dish comprising sausages in Yorkshire pudding batter, usually served with vegetables and humous." with something completely different like just "test" it doesn't throw an exception and works just fine. This baffles me... is it a bug in Doctrine or have I missed something?

    Read the article

< Previous Page | 21 22 23 24 25 26 27 28 29 30 31 32  | Next Page >