Steam Gamer / Teamspeak Community - Cake2
Hi Apologies if this is against group rules, I'm not sure it is. I run a gaming community and I set the site up in CakePHP 2, I am busy with work so I'd love to reach out to any gamer devs who'd like to check it out and possibly get involved to help us grow. No links provided at this point just in case. Community is a year old and does well, I have 6ish years experience specialising in Cake. www.stephenspeakman.co.uk <- my neglected blog. Kind Regards Stephen -- Sign up for our Newsletter for updates. http://cakephp.org/newsletter/signup We will soon be closing this Google Group. But don't worry, we have something better coming. Stay tuned for an updated from the CakePHP Team soon. Like Us on FaceBook https://www.facebook.com/CakePHP Follow us on Twitter http://twitter.com/CakePHP --- You received this message because you are subscribed to the Google Groups "CakePHP" group. To unsubscribe from this group and stop receiving emails from it, send an email to cake-php+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.
Re: Add class to active links
In the options array add 'class' => 'myclass' Echo $this->Html->link('my link', array('controller' => 'users', 'action' => 'index'), array('class' => 'mylink')); If my memory serves me correctly that is Sent from my iPhone On 29 Feb 2012, at 07:48, Kiran Ambati wrote: Hi I am using cakphp 'link' to generate anchor tags. Now i awnt to add a class to active links to apply some styling to those links. Is there a way to that. -- Thank you, Kiran. -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: MVC design for shopping cart
Write re-usable query methods in the appropriate models. If you're dealing with product id's then use the products controller and any tax calculations etc can be handled in a model or if need be component. Im not sure why you would need a 'cart controller' if you don't have cart records. If you really need a table for this functionality look up temporary mysql tables, but i wouldn't recommend using $this->query instead i'd write efficent querys and index my tables My 2 cents... Sent from my iPhone On 28 Feb 2012, at 21:06, Christian wrote: Hi, I'm currently trying to create a shopping cart solution with cake 1.3. In the current design, only the product id of a chosen product will be saved in the session, each time the customer lists the cart items, all information needs to be read out of the database. My idea was to create a seperated model (no relation to any table) where all cart calculations can happen in, which can then be used in several controllers. However, this would mean that this cart class would need to use several other product related models (product details, taxes, countrydetails, etc.), which is not easily supported by cake, since it breaks the MVC model. The workaround would be to implement the logic in a controller where I can easily access all models, however, this breaks two other basics, once the "fat model skinny controller" rule and on the other hand the code is not easily reusable for other purposes. My question is now how where to implement the cart functionality (e.g. summary price, discount, taxes calculation, etc.) without breaking MVC but with sticking to "fat model skinny controller" and the re- usability of my code. Thanks, Christian -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: Multisite (like WPMU + domain mapping)... possible?
Im working on a setup at the moment which does what you need by using http_host in the global web root but its done inefficently. It merges full apps together.. Im using 'nuts and bolts' method of running multiple apps from one cake folder. I have then developed a plugin which is shared between all the apps, this holds shared functionality and admin is done in one place. Sent from my iPhone On 25 Feb 2012, at 01:57, Benjamin Allison > wrote: So I'm just starting to play with CakePHP and was wondering if the following was possible: A single install of Cake, with a super admin login. Then, admins that have access to specified "sub sites", and the ability to create/edit content and users on those sub sites. Finally, the ability to map domain names (not subdomains, but unique domains) to the routes; so instead of mysite.com/subsite/posts/1 it would just be newdomain.com/ posts/1 Essentially, I'm looking to replicate the experience of using Wordpress Multi-user (with domain mapping). Is this possible? If so, what should I be looking to? -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: Error: Index.phpController could not be found
Quick summary (Do read the docs!) www.site.com/ - cake/libs/controllers/pages_controller.php OR CREATE - app/controllers/pages_controller.php - PagesController::display() www.site.com/users/ - app/controllers/users_controller.php - UsersController::index() www.site.com/users/login - app/controllers/users_controller.php - UsersController::login() Regarding pages controller never edit files in /cake/.. Override or extend them. (see docs) By default you shouldn't need an index.php, you should enable mod rewrite and allow cakephp to read the urls correctly Try checking your .htaccess and server config to ensure .htaccess can be read. Finally the way it reads the URL www.site.com/controller/action/param1/param2/param3 And so on, you can have as many parameters as you wish. Also check out routing for custom urls. Hopefully your app will work and you can start the blog tutorial to learn more Sent from my iPhone On 22 Feb 2012, at 23:46, amg55nj wrote: Completely new to CakePHP. Tried doing a search with no results. I installed CakePHP to my localhost Apache directory. Other programs such as PHPMyAdmin work just fine. I am getting this error: Missing Controller Error: Index.phpController could not be found. Error: Create the class Index.phpController below in file: app \Controller\Index.phpController.php Notice: If you want to customize this error message, create app\View \Errors\missing_controller.ctp What do I do? I tried creating that PHP file and putting it in the app\Controller directory but that did not work. -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: Media Plugin of David Persson is for cake 1.3 and for cake 2.0?
It may be an idea to make changes to the media plugin for 2.x and share it if lisences arent an issue. I'm still on 1.3 for now but it would be nice to contribute. Sent from my iPhone On 22 Feb 2012, at 17:01, byqsri wrote: Hi I would open a discussion between all developers that use cakephp. I think that a frequent problem in development is the File Upload. For Cake 1.3 exists the fantastic Media Plugin of David Persson that for me is it the best plugin about File Upload. But Media Plugin of David Persson hasn't a version for Cake 2.0. My question is : Which is the best plugin to use in Cake 2.0 to manage File Upload? Many Thanks -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: Custom model association column
Something i need to bear in mind when mapping my models, no joining between two connections. Could you not find a behaviour to create a temporary table as a very last resort? Sent from my iPhone On 21 Feb 2012, at 21:37, jeremyharris wrote: Does Containable not work? $this->HospitalAdmission->find('all', array( 'contain' => array( 'Subject' => array( 'Contents' ) ) )); -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: The Great Web Framework Shootout
It's good to hear somebody who views CakePHP in the same practical light as myself. I can develop more efficient applications in a much faster timescale than expected of me in my new job, if my first appraisal is a good one.. A toast to cake and donation to cakephp :) Sent from my iPhone On 22 Feb 2012, at 06:18, Greg Skerman wrote: @euromark Its how any sensible developer should think about it. The only benchmark I'd ever be interested in seeing would be one where 2 developers of comparable skill showed down the building of a fully featured blog in competing frameworks. This isn't to say CakePHP is perfect, obviously improvements in the performance department are welcomed. But take a guess at how many hours the framework has already saved you on authoring just plain CRUD boilerplate code in the last 12 months? No really, go do it... multiply by your hourly rate... thats profit, or time with your family On Wed, Feb 22, 2012 at 11:20 AM, euromark wrote: @greg right on - you express to 100% what I feel about this ;) On 22 Feb., 00:51, Greg Skerman wrote: > Performance is often the very last thing I look at - Productivity is more > important. > > My clients care about seeing/touching/feeling a piece of software early and > often so they can inject changes and enhancements to the process. CakePHP > wins for me here because it is just so incredibly fast to develop with - > spend an hour on your DB schema, bake and scaffold everything and you've > got a piece of software which you can use to drive a discussion with your > clients. > > Pulling features off the scaffold into more concrete views and controllers > is trivial and if I like I can show enormous progress towards a client's > goals each and every day. > > This is the power of a RAD framework. If you want pure speed, you wouldn't > use a framework at all - but performance can be dealt with by purchasing > hardware, caching strategies, db indexing...all of which is comparatively > cheap when compared to development time. > > Have tried other frameworks, can't code as quickly in them as I can with > Cake that is all I need to know. > > On Tue, Feb 21, 2012 at 10:28 PM, Thiago Belem wrote: > > > > > > > > > It's like comparing toolboxes based on airplane turbine *specs*. > > > -- > > Thiago Belem, > > Desenvolvedor WEB > > > Enviado do meu Android > > Em 21/02/2012 10:25, "Stephen" escreveu: > > > Having the fastest lap time on the page load track doesn't interest me or > >> persuade me to use a framework, I care more about the tools in the toolkit, > >> the way it's built and how long it takes. > > >> -- > >> Kind Regards > >> Stephen > > >> http://www.ninjacodermonkey.co.uk > > >> -- > >> Our newest site for the community: CakePHP Video Tutorials > >>http://tv.cakephp.org > >> Check out the new CakePHP Questions sitehttp:// ask.cakephp.organd help > >> others with their CakePHP related questions. > > >> To unsubscribe from this group, send email to > >> cake-php+unsubscr...@googlegroups.com For more options, visit this group > >> athttp://groups.google.com/group/cake-php > > > -- > > Our newest site for the community: CakePHP Video Tutorials > >http://tv.cakephp.org > > Check out the new CakePHP Questions sitehttp:// ask.cakephp.organd help > > others with their CakePHP related questions. > > > To unsubscribe from this group, send email to > > cake-php+unsubscr...@googlegroups.com For more options, visit this group > > athttp://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
useDbConfig strange bug
Hi everyone Im developing an inhouse plugin to be shared by many apps. This plugin has an app model which states that it should use a separate database config which was working initially. The problem occured when I set up a "hasMany - belongsTo" relationship between universe_client.php and universe_client_host.php The app is now searching for the universe_client_hosts table in the default connection. I've tried caching, checking persistent, using useDbConfig in each model, making sure the username and password for each connection are unique. Besides a cheap hack can anybody think of a solution? Cheers in advance Stephen www.ninjacodermonkey.co.uk Sent from my iPhone -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: Need Help: A variable is losing value
It's possible your $_SESSION['nId'] is actually overwriting the parameter being passed to the controller with 0? Assuming you're accessing the method like such: /networks/add_network/ If you want to avoid creating a new record try: $this->Network->id = $nId; $this->Network->save($this->data); Kind Regards Stephen On 11/02/2012 08:44, chris varick wrote: I am hoping someone can help me out here. I am pulling my hair out. For some reason when I go to save "edited" information, form a form, it is creating an entire new record in the database instead of just updating the current record at hand. I am using variable $nId to reference the record id on _save(); For some reason it is setting the $nId to 0. I do not know what is happening. Any suggestions? Take a look at the line that has: $mySaveId = ($nId)?$nId:0; you will see where I attempt to save to the current record. [code] public function add_network($nId = 0) { // Capture for Debuging $_SESSION['nId'] = $nId; if($nId){ $net_info = $this->Network->find('first', array('conditions' => array('id' => $nId))); self::set('network', $net_info); self::set('page_title', "View | Edit Network". $net_info['Network']['network_name']." ID: ".$_SESSION['nId']); } else { self::set('network', null); self::set('page_title', "Add Network"); } $alert = null; if ($this->data['network']) { if ($this->data['network']['network_name']) { $data['network_name'] = addslashes($this- data['network']['network_name']); $data['sub_id'] = addslashes($this->data['network'] ['sub_id']); $data['active'] = 1; //Save form data to Networks database. //If we are editing a network, then make sure to save data to record ID ($nId) $mySaveId = ($nId)?$nId:0; $networkId = $this->Network->_save($mySaveId, $data); if ($networkId == $mySaveId) { $alert = "Changes to network: ". $data['network_name']." were saved."; } else { $alert = "New network: ".$data['network_name']." was added.". " ".$networkId; } } } switch($this->data['window']['flag']){ case "networks": self::redirect("/admin/manage_network"); break; } // switch self::set('logo', $this->Session->read('logo')); self::set('wbtitle', $this->Session->read('wbtitle')); self::set('alert', $alert); self::set('networkId', isset($networkId)?$networkId:null); } [/code] -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: How to send a fax
If you don't sign up for a service I don't think you can send a fax using anything. I'd suggest using an API or service, aql.com have a great fax service (I only know of incoming) but I'm sure they do outgoing as well - it's usually linked to email. Kind Regards Stephen On 06/02/2012 16:29, Yves S. Garret wrote: Anyone know how I can send a fax with CakePHP? Bonus points if I can do it with straight PHP. And no, I cannot use a service such as interfax or the like. This will include sending company sensitive info and I'd prefer to keep this within the bounds of the intranet of my organization. -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re: Using Join Tables in Cakephp - result in view.ctp
Hi I may not know the answer to your question but shouldn't your model be named: sport_group.php and SportGroup extends AppModel ? port_groups_entity table should be named "port_group_entities" PortGroupEntities I would personally correct all the filenames, class names and $this->Model lines etc to represent proper CakePHP conventions, then I would use pr($this->SportGroup->findByUrl($url)); etc to view the results retrieved from the query... If name isn't in there maybe it's an error with your MySQL table? Maybe check recursive? (Apologies if I missed any info, my thunderbird client isn't threading mail list topics =/) Kind Regards Stephen On 05/02/2012 17:18, TheMuller wrote: Hi, I have looked, search and founded, but not the answer to my questions: How do I get the result of my join table in my view.ctp? Am I doing something wrong? I have followed some guides from bakery and other blogs, and created a setup like shown below. But why does the error in view.ctp say: "Notice (8): Undefined index: name" Code: models/sportsgroup.php controllers/sports_groups_controllers.php array('Jquery'), 'Javascript', 'GoogleMapView'); var $name = 'SportsGroups'; function index() { $this->SportsGroup->recursive = 0; $this->set('sportsgroups', $this->SportsGroup->find('all', array('joins' => array( array( 'table' => 'port_groups_entity', 'alias' => 'GroupsEntity', 'type' => 'inner', 'conditions'=> array('SportsGroup.group_id = GroupsEntity.guid') ) ) ))); $this->set('title_for_layout', 'Sportsclubs online'); } function view($url = null) { if (!$url) { $this->Session->setFlash('Invalid id for Post.'); $this->redirect('/sportsclub/'); } $this->set('post', $this->SportsGroup->findByUrl($url)); } } ?> view/sportsgroups/index.ctp (or view.ctp) (it catches this one) (but not this one) view/sportsgroups/view.ctp (it catches this one) (but not this one) The database table are like: sports_groups: id | group_id | title groups_entity: guid | name Please help me, I used 2-3 days on this one.. /TheMuller -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php
Re:
Hi Manouchehr You should be able to use a HasMany / BelongsTo relationship. Courses belongsTo CoursePrerequisites CoursePrerequisites HasMany Courses This way you can have say 15 Course Prerequisites and 10 courses, some courses can share some of the same prerequisites. On 05/02/2012 14:25, Manouchehr Boshaq wrote: hi first i'm member of group but i cant post to moderator . second: i have a table for storing course data. any course has 1 or more prerequisites of courses. how can i relate HABTM table with itself. thanks -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group, send email to cake-php+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php