Search Results

Search found 768 results on 31 pages for 'cakephp 1 3'.

Page 8/31 | < Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >

  • IE Kills Session After Exporting CSV [CakePHP]

    - by OneBlueMidnight
    i have a web application that export CSV and i logged in as admin but what happened during the exportation the IE opens a new tab and export the CSV but what happens next when you click any of the link on the web app you will automatically logout! This only happen on IE. here is the header i used: header("Content-type:application/vnd.ms-excel"); header("Content-disposition:attachment;filename=".$this->filename); I am using cakephp 1.3.x.x TIA :D

    Read the article

  • coverting existin flash with cakephp website into mobile version

    - by jpramod4u
    How to convert the existing flash site into mobile version existing site in form of the cakephp frame work. We thought that html ,css,php,javascript may work all mobiles.We dont know exactly. Please tell us how many possible way to develop existing site into mobile version and also need to detect the from which browser the request is coming whether mobile browser or pc browser. The existing site link is :This site convert into mobile version

    Read the article

  • Fields in CakePHP could not be referred by JQuery

    - by kwokwai
    Hi all, I have got a simple HTMl form with one field as follows: <input type="text" name="data['User']['user_id']" id="data['User']['user_id']" value="1"> $(document).ready(function(){ $("#data['User']['user_id']").mouseover(function(){ alert("hello"); }); }); The code couldn't work, I think it may be the name of the Input text field that caused the problem, but I don't know how to alter it because this is the naming convention in CakePHP.

    Read the article

  • MeioUpload and phpThumb() does not exist error

    - by Cameeob2003
    I am currently using CakePHP v2.2.1 and MeioUpload 4.0 along with phpThumb() to try and generate image uploads and thumbnails for those images. If i set my $actAs = array() without the thumbsizes property everything is uploaded well, but when I add the following: 'thumbsizes' => array( 'small' => array('width' => 165, 'height' => 115), 'medium' => array('width' => 800, 'height' => 600) ), to generate thumbnails I get an error stating the following: "E:/xampp/htdocs/site/vendors/phpthumb/img/posts/image-name.jpg" does not exist I have tried several different methods of fixing this from around the web and nothing seems to work. I am new to cakephp so this may be an easy fix and I am just not connecting the dots to find the solution. Any help would be very much appreciated.

    Read the article

  • Cakephp, JQuery JCarousel Lite, Error

    - by ion
    I am using the following code to make an unordered list into a carousel with jcarousel lite and jquery: <?php echo $this->Html->script(array('jquery-1.4.2.min','jquery.easing.1.1','jcarousellite_1.0.1.pack','jquery.mousewheel.min'), array('inline' => false)); ?> <?php echo $this->Html->scriptStart(array('inline' => false)); ?> $(document).ready(function() { $(".mouseWheelButtons .jCarouselLite").jCarouselLite({ btnNext: ".mouseWheelButtons .next", btnPrev: ".mouseWheelButtons .prev", mouseWheel: true, circular: false, start: 0, visible: 5, easing: "easein" }); }); <?php echo $this->Html->scriptEnd(); ?> However I'm getting the following javascript error in firebug: a[0] is undefined Does anyone know what is causing the error. I am using the packed version of jcarousel lite. The thing is that the code worked in cakephp 1.2 but now i'm using 1.3 and I have updated the syntax using scriptstart, scriptEnd and Html-script.

    Read the article

  • Creating meaningful add URLs in Cakephp

    - by Loftx
    Hi there, For my site I have a number of Orders each of which contains a number of Quotes. A quote is always tied to an individual order, so in the quotes controller I add a quote with reference to it's order: function add($orderId) { // funtion here } And the calling URL looks a bit like http://www.example.com/quotes/add/1 It occurred to me the URLs would make more sense if they looked a bit more like http://www.example.com/orders/1/quotes/add As the quote is being added to order 1. Is this something it's possible to achive in CakePHP? Cheers, Tom

    Read the article

  • CakePHP: find neighbors, order on 'name' or 'order'

    - by Brelsnok
    Hi, I have a list of ordered items, ordered according to the int field order. I'm creating a gallery in CakePHP 1.2 that has a prev and next button and those should link to the previous and next item according to their ordering, not according to their id. In order to get this result I've included the 'order' parameter to the find function, and populated it with 'Item.order'=>'DESC'. Still the result is an id ordered list. My question is: what do I do wrong? My controller: $this->Item->id = 16; $neighbours = $this->Item->find('neighbors', array('order'=>array('Item.order'=>'DESC'), 'fields'=>array('id','name')));

    Read the article

  • cakephp site domain change, having 301 issues

    - by veryMickey
    I moved my cakephp site from a subdomain over to a different domain. I handled the permanent redirect in my htaccess file but in the redirect i am losing my neat/clean url handling. old site iphone.gameachievements.org new site gameachievements.org example of current redirect iphone.gameachievements.org/games/jungle-swing - gameachievements.org/index.php?url=games/jungle-swing what i want.. is iphone.gameachievements.org/games/jungle-swing - gameachievements.org/games/jungle-swing here is what my htaccess file looks like... RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)$ index.php?url=$1 [QSA,L] RewriteCond %{HTTP_HOST} iphone.gameachievements.org RewriteRule (.*) http://gameachievements.org/$1 [R=301,L] any help is appricated thanks m!

    Read the article

  • cakephp and SQL_CALC_FOUND_ROWS

    - by Lizard
    I am trying to add the SQL_CALC_FOUND_ROWS into a query (Please note this isn't for pagination) please note I am trying to add this to a cakePHP query the code I currently have is below: return $this->find('all', array( 'conditions' => $conditions, 'fields'=>array('SQL_CALC_FOUND_ROWS','Category.*','COUNT(`Entity`.`id`) as `entity_count`'), 'joins' => array('LEFT JOIN `entities` AS Entity ON `Entity`.`category_id` = `Category`.`id`'), 'group' => '`Category`.`id`', 'order' => $sort, 'limit'=>$params['limit'], 'offset'=>$params['start'], 'contain' => array('Domain' => array('fields' => array('title'))) )); Note the 'fields'=>array('SQL_CALC_FOUND_ROWS',' this obviously doesn't work as It tries to apply the SQL_CALC_FOUND_ROWS to the table e.g. SELECTCategory.SQL_CALC_FOUND_ROWS, Is there anyway of doing this? Any help would be greatly appreciated, thanks.

    Read the article

  • Cakephp doesn't write a cookie

    - by radious
    Hello! I have a problem with writing cookies in cakephp and even don't know how to debug it or where too look for a clue. I've inherited a project where cookie were only created using the Session component, of course i added 'Cookie' to $components array in app_controller and put this in beforeFilter: $this->Cookie->name = 'foo'; $this->Cookie->path = '/home/~nick'; $this->Cookie->domain = 'hostname'; $this->Cookie->secure = false; //i.e. only sent if using secure HTTPS $this->Cookie->key = 'some key'; and in some action i use: $this->Cookie->write('key', 'value'); I access page by http://hostname/home/~nick/foo and actually try to put even something so silly. I doesn't work. I would be really gratefully for any clue where to search problem. Thanks!

    Read the article

  • cakePHP - ACL tutorial & SQL Error: 1104

    - by vector
    Greetings! I run into a problem/bug in production environment with SQL Error: 1104 when deploying a project secured with the ACL tutorial. The full error: SQL Error: 1104: The SELECT would examine more than MAX_JOIN_SIZE rows; check your WHERE and use SET SQL_BIG_SELECTS=1 or SET SQL_MAX_JOIN_SIZE=# if the SELECT is okay [CORE/cake/libs/model/datasources/dbo_source.php, line 666] I've build a small site, worked through the ACL tutorial from the official cake book and locally everything is spiffy. dev. setup consists of: XAMPP: myslq 5.1.33, php 5.3 cakePHP 1.2.7 prod. setup: mysql 5.0.33 php 5.2.2 One of the differences I noticed with mysql setup between local and production servers, is that SQL_BIG_SELECTS is disabled on the production server ( and I don't have privileges to change that, posted a support ticked, didn't hear anything yet) Is there anything I can do about this from my end? Thanks in advance.

    Read the article

  • CakePHP dynamic element

    - by Logic Artist
    I am trying to create a message-board type element in a CakePHP app. This element will be displayed on all pages and views that use a particular layout. I want it to display all the messages in the model, then show the add form when a link is clicked, then return to the updated message list when submitted. All this without affecting the current view/page. I have my message model/controller/index set up, with a message board element that requests the index action. This works fine. However I am perplexed about how to return back to the original page/action from which the link was clicked. I can't use $this-referer() because that will link back to the add() action; what I want rather is to link to the page/view before that. Any general pointers on how to achieve something like this?

    Read the article

  • CakePHP Accessing Dynamically Created Tables?

    - by Dave
    As part of a web application users can upload files of data, which generates a new table in a dedicated MySQL database to store the data in. They can then manipulate this data in various ways. The next version of this app is being written in CakePHP, and at the moment I can't figure out how to dynamically assign these tables at runtime. I have the different database config's set up and can create the tables on data upload just fine, but once this is completed I cannot access the new table from the controller as part of the record CRUD actions for the data manipulate. I hoped that it would be along the lines of function controllerAction(){ $this->uses[] = 'newTable'; $data = $this->newTable->find('all'); //use data } But it returns the error Undefined property: ReportsController::$newTable Fatal error: Call to a member function find() on a non-object in /app/controllers/reports_controller.php on line 60 Can anyone help.

    Read the article

  • cakephp filter index pages according to foreign keys

    - by Marki
    Hi there, I'm pretty new to CakePHP and was missing a crucial feature not generated as scaffold: filtering. What do I have to do to provide dropdowns or multi-selects on the index pages for each field that is a (foreign) key, thereby allowing to filter the table ("OR" inside multi-select, "AND" between different multi-selects, if any)? From what my websearch has shown me there are many more people trying to accomplish the same thing, although I couldn't find anything that would work for me because either they have text fields and do wildcard filtering, or the plugins they propose only work for 1.2 whereas i now started with 1.3 etc. etc. Can someone alleviate the confusion and maybe present some working code or direct me to the definitive guide[tm] where this matter has been solved? Thx

    Read the article

  • CakePHP and jQuery - Unobtrusive actions

    - by fortysixandtwo
    I'm trying to make an unobtrusive action for deleting bookmarks in CakePHP. Allthough it's working just fine, I suspect there must be a better way to do this. Could someone please point me in the right direction? function delete($id = null) { $ok = $this->Bookmark->delete($id); if($this->RequestHandler->isAjax()) { $this->autoRender = false; $this->autoLayout = false; $response = array('status' => 0, 'message' => 'Could not delete bookmark'); if($ok) { $response = array('status' => 1, 'message' => 'Bookmark deleted'); } $this->header('Content-Type: application/json'); echo json_encode($response); exit(); } // Request isn't AJAX, redirect. $this->redirect(array('action' => 'index')); }

    Read the article

  • Cakephp - detect if unable to connect to database and recover gracefully

    - by Phantz
    I have a few sites built with Cakephp. If any of these sites lose their connection to the database for whatever reason it does not handle it well. Basically it renders itself inside itself trying to display an error over and over until the browser crashes. The rendering itself inside itself is caused by the use of requestAction from elements. What I want to know is how can I check if the database connection exists I tried this in the app_controller before filter: if(!ConnectionManager::getDataSource('default')) { die(); //this will be a message instead } but it does not seem to work. Thanks

    Read the article

  • CakePHP based project is throwing error saying " return value of new by Reference is Deprecated"

    - by Bindas
    I have upgraded my Xampp to newer version(1.7.2).But right now when I run my project(done in CakePHP) it is throwing bug saying Deprecated: Assigning the return value of new by reference is deprecated in C:\xampp\htdocs\ebayn\cake\libs\debugger.php on line 99 Deprecated: Assigning the return value of new by reference is deprecated in C:\xampp\htdocs\ebayn\cake\libs\debugger.php on line 108 Deprecated: Assigning the return value of new by reference is deprecated in C:\xampp\htdocs\ebayn\cake\libs\file.php on line 96 Deprecated: Assigning the return value of new by reference is deprecated in C:\xampp\htdocs\ebayn\cake\libs\cache\file.php on line 89 Can anyone help me how can I rectify this stuff....??? Thanks In Advance

    Read the article

  • confused of $this in cakePHP

    - by kwokwai
    Hi all, I got a few lines of codes in a Model in cakePHP 1.26: function beforeSave() { $this->data['User']['pswd'] = md5($raw['User']['pswd']); return true; } // this beforeSave() works The code above has been tested and it is working in my database. Yet, I am not sure if I can understand it well, so, I re-wrote the code in other way, and it just failed to work then. function beforeSave() { $raw=$this->data; $raw['User']['pswd'] = md5($raw['User']['pswd']); return true; } // this beforeSave() failed to work Why the second method can not work?

    Read the article

  • Cakephp, Retreive Data for HABTM Models using find

    - by user298079
    I am new to cakephp and I'm trying to accomplish something that should be relatively easy. I have 2 models projects & categories bind by HABTM relationship. I am trying to perform the following query - find all projects that belong to a category $projects = $this->Project->find('all', array('conditions' => array('Category.slug' => $category))); However when I'm doing so it generates an SQL error: SQL Error: 1054: Unknown column 'Category.slug' in 'where clause' What am I doing wrong??

    Read the article

  • CakePHP Shell issue

    - by aboxy
    Hello, I am just getting started with Cakephp shell and running into issues. My cake core library is under path d:/libs/cake My app is setup under d:/servers/htdocs/myapp I wrote a test shell under d:/servers/htdocs/myapp/vendor/shells class ReportShell extends Shell { var $uses = array('Appt'); function main() { echo $this->Appt->find('first'); } } When I try to run this code from d:/servers/htdocs/myapp , It gives me an error Warning: include_once(d:/servers/htdocs/myapp/config/database.php): failed to open stream: No such file or directory in d:/libs/cake\libs\mode l\connection_manager.php on line 23 Warning: include_once(): Failed opening 'd:/servers/htdocs/myapp/config/database.php' for inclusion (include_path='.;D:\work\xampp\php\PEAR') in d:/libs/cake\libs\model\connection_manager.php on line 23 Fatal error: ConnectionManager::getDataSource - Non-existent data source default in d:/libs/cake\libs\model\connection_manager.php on line 102 Reason is that it is trying to find database.php under 'd:/servers/htdocs/myapp/config/' and the correct path is 'd:/servers/htdocs/myapp/app/config/database.php' What am I doing wrong here? thanks

    Read the article

< Previous Page | 4 5 6 7 8 9 10 11 12 13 14 15  | Next Page >