Re: 1.2 Documentation has made amazing progress
On May 9, 3:06 pm, Ma'moon <[EMAIL PROTECTED]> wrote: > The online manual is great and a very big thank you for everyone who put an > effort on it! but i have a small note if i am allowed to say so, the font of > the content is relatively small and i think making it a lil bit bigger would > feel much more comfortable while reading rather than pressing "Ctrl + {+}" > every time the visitor visits the Manual pages. All arguments on the merits of font-size aside, one of the key things I've noticed with the documentation is the ease of scan-ability. How easily can I skim to find the content I'm looking for. I suspect you're increasing the font-size to solve this. When I notice it, I've been trying to make small edits to the documentation to making scanning easier. Chunking up data into smaller bites and including things in code blocks, even if it's just a one line example. As many have said, the documentation has come a long way and I'm happy with how it's working out. But having seen all the new features in 1.2, we still have a long ways to go. :) > 2) Also I wish the structure was more cookbook like > with recipes which is small examples for doing different things. I think this will evolve once the main functionality gets filled out more. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Email Component 1.2 -- Problems with HTML and SMTP
On Apr 22, 9:56 pm, Schuchert <[EMAIL PROTECTED]> wrote: > Could this be the reason that my html messages only come in as text? To be honest, I'm not sure. I'd probably have to pick apart the code to understand for sure. Try the MIME-Version header and see what happens. I'm leaning towards an issue with how the component is building the multi-part email, rendering the html as text. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Email Component 1.2 -- Problems with HTML and SMTP
Grab the latest version from the nightlies, if you can, as many issues have been resolved with the exception of the newline problem which I've already submitted a bug for and have talked to Felix about it. I use SMTP and use HTML templates. $this->Email->to = '[EMAIL PROTECTED]'; $this->Email->bcc = array('[EMAIL PROTECTED]'); $this->Email->subject = "my subject"; $this->Email->from = 'Example Name <[EMAIL PROTECTED]>'; $this->Email->template = 'processorder'; $this->Email->sendAs = 'html'; //Send as 'html', 'text' or 'both' (default is 'text') $this->Email->delivery = 'smtp'; if(!$this->Email->send()) { $this->set('senderror', $this->Email->smtpError ); }; The template needs to be in /views/elements/email/html/ and you need a layout file in /views/layouts/email/html/default.ctp Also, to fix the newline issue, I made the following change to line 750 of the email component: @fwrite($this->__smtpConnection, preg_replace("/([^\r])\n/", "$1\r\n", $data)); That basically ensures that all line feeds are CRLF and not just LF. -Jonathan Snook http://snook.ca/ On Apr 21, 9:28 pm, Schuchert <[EMAIL PROTECTED]> wrote: > I tried specifying the template and it was a no go. It still sends in > text format. > > I also switched back to smtp and everything is being jammed into the > TO field. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: #sql_968_0
On May 19, 8:13 am, cake_cooker <[EMAIL PROTECTED]> wrote: > My query joins columns from mainly 2 tables and adds some more tables > 'booked' , 'available', etc... computing the previous columns. > So in my View i get the results like grouped according on the table > the come from (ex 'products', 'products_wedding_wishlist', etc.). But > the computed columns do not have a table so they are grouped under > '#sql_968_0'. Can you help me to try to give a defined name like > 'computed' or something else? So I can use it in the view more > efficiently This is a known problem and has yet to be addressed in the Cake core. (it's been difficult for them to diagnose as a solid test case is required to duplicate the problem.) The problem occurs because mysql assigns a temporary table name (#sql_968_0 in this case) to the fields due to the complexity of your query. In the meantime, one solution I came up with was to declare a constant in the config and then use that to pull out those fields. I did this because once you move this code to production, that temporary table name will be different. It seems to be consistent every call be different per server. Hope that helps. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Ever heard of tags.ini.php ?
the tags.ini.php file was a 1.1 thing that you had to copy over from the /cake/ folder. For 1.2, check out: http://www.thinkingphp.org/2007/02/21/use-html-401-in-cakephp-12/ --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Adding/Calling a new class in my application... how please ?
you should never have to touch anything in the cake folder. To include a custom class, you'll need to drop it into the vendors folder -- either the one in the root or the one in the app folder if you only want to use it for this project. From there, you can include it in an action with "vendor('filename')". You should now be able to instantiate the class. On Apr 10, 9:17 pm, "Dan Ballance" <[EMAIL PROTECTED]> wrote: > Hello good people of the list ! > > I would like to use the php class available here: > > http://lwest.free.fr/doc/php/lib/date-en.html > > to handle dates. I have downloaded their file date.php and tried dropping it > into cake/libs, but when i try to call it from a controller, i get: > > Fatal error: Undefined class name 'date' in... > > Can anyone explain how or where i can add an additional class to my > application ? > > many thanks in advance, > > dan :-) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Database Views
On Apr 9, 4:14 pm, "sumanpaul" <[EMAIL PROTECTED]> wrote: > well it should work. if there seems to be problem try baking the > model. It should show the view. If not then there might be some > problem with view itself. > it works for me. may be cake guys need more info to figure out why u r > having problem. Just to clarify what Joshua is looking for: he's not speaking of Cake views but rather of database views. Views should appear to look and act just like tables. Joshua, you mention it's not finding the table. Have you taken a look at the query Cake is generating? If so, have you tried running it against the db directly to see if there's something going on. Maybe some pluralization gone wrong? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Scary associations with recursive calls
On Apr 9, 12:01 am, "Mariano Iglesias" <[EMAIL PROTECTED]> wrote: > This sounds like a scream for help, and expects() is up to the challenge ;) > > http://bakery.cakephp.org/articles/view/185 I've used expects() and in my opinion, should become a core feature of CakePHP. It feels a lot more natural than the bind and unbinding of associations. It's succinct. And because it's built on top of the bind/ unbind approach, you can still use it if necessary. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: WithCake.com ideas (Was Re: WithCake.com relaunched)
> Kind of developer and company rankings would be cool. Especially > cake is lacking some good documentations; so probably add some field > stating how many articles were published by that developer (this is > also good to Cake itself) or so... something like: That's not a bad idea. The biggest problem is how the system works: the profiles are transitory. Once they're gone, they're gone. The site acts more like a job site than it does a directory of companies and developers where rankings might be more relevant or useful. However, maybe creating a "directory" portion to the site would be advantageous allowing for rankings. I'll definitely keep the idea in mind. Thanks. :) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: WithCake.com relaunched
On Mar 24, 4:52 pm, "jonathan.snook" <[EMAIL PROTECTED]> wrote: > There's still two main features that I need to add: > 1) RSS feeds for the job listing > 2) a way for people to contact you through the site Both of these are now in. At this point, the site is essentially "feature complete" although if anybody comes up with some cool ideas, I'm not averse to it. :) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: Link / URL Best Practices
> That said, I've never had it not work because the default php.ini > setting is on. But if you don't have control over your server, or the > code is for wide distribution, it's not the best idea. I hear this argument repeatedly, about using the short form, but why would it not be enabled? What has been the percentage of people that have actually had a problem with using the short form? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: WithCake.com relaunched
> There's still two main features that I need to add: > 1) RSS feeds for the job listing Correction, just added the RSS feeds but haven't added buttons on the page, yet. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
WithCake.com relaunched
So, awhile back I launched WithCake.com as a blog about the stuff I ran into doing CakePHP development. I decided to scrap that idea and move the content back into my site, Snook.ca. I ended up with a domain that needed "something"... After seeing a job wiki for CodeIgniter, I thought it might be interesting to do something similar for CakePHP. And that's exactly what I've done. Check it out at http://withcake.com/ There's still two main features that I need to add: 1) RSS feeds for the job listing 2) a way for people to contact you through the site I'll see about getting those in sometime within the week. Thanks. (I hope this doesn't come across as spammy but I didn't want to post this on my blog just yet. Of course, thoughts and suggestions are most welcome.) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: model::query different output with different version of php - a bug or?
Yes, it's an unfortunate side effect of using custom queries, especially when joins or nested queries are involved. For a project, I modified the core to use "0" as the alias if the table name returned didn't match a list of model names. In the database.php file, I declared a list of all available model names. This ensured consistent naming on output. On Mar 20, 7:30 am, "sawa" <[EMAIL PROTECTED]> wrote: > Yes, probably different php-mysql library or something similar..but > it's really annoying --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: CakePHP versus Symfony ?
On Mar 3, 4:52 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> wrote: > Symfony currently has a better datalayer t2hen cake . It uses propel, > a ORM solution. with cake we still work with (unconvenient) data- > arrays > iirc the cake 2.0 release will contain an object-based datalayer > (written by the cake team) Well, depends on what you consider better. As nate's example points out, Propel is extremely verbose, especially for handling conditionals (aka: criteria). I prefer Cake's approach. The difference between the use of arrays and objects isn't huge, imho. I prefer arrays as it allows me to easily inject additional properties at runtime if need be. -js --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
Re: custom queries and mysql_fetch_field
On Nov 18, 5:51 pm, "nate" <[EMAIL PROTECTED]> wrote: > I had this happen once. I believe it has something to do with how your > database encoding is set up. Upon further inspection, I believe it occurs when MySQL has to create a temporary table during the SELECT process. This is more likely to occur in a GROUP BY or ORDER BY (according to the docs). The question is whether you could reliable identify a temporary table. It seems to have a consistent naming convention (#sql_XXX_0). Not sure how much you'd want to rely on that. Alternatively, you could do one of two things: 1. check all configured models in the app and if the table name isn't one of them, give it a consistent name (I believe it's '0' currently but maybe something like '_unknown' would be more accurate). 2. do a 'show tables' on the database and compare against that. If it's not in the list, it's temporary. You could cache this info like you would a 'DESC tablename'. Anyways, those are my thoughts. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---
custom queries and mysql_fetch_field
So, I've been trying to track down a solution to this problem and I haven't found it yet. (I should probably open a trac ticket but figured I'd shoot out the question here first). Okay, I have a custom query doing some fun stuff, but anytime I'm using mysql functions (like COUNT or SUBSTRING or whatever) I alias the name to something meaningful like 'fieldcount'. The problem is the array I get back: Array ( [Item] => Array ( [name] => asdfas ) [#sql_13b_0] => Array ( [mydate] => 1983-03-21 21:00:00 ) ) As you can see, the #sql_13b_0 part isn't what I want. In trying to trace things back through the code, I'm noticing that it may in fact be MySQL returning this value during a mysql_fetch_field call. Question is... can I specify something more meaningful or have it at least default to something consistent? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~--~~~~--~~--~--~---