Comments on “ Chyrp Upgrade ” http://robwilkerson.org/2008/07/12/chyrp-upgrade/feed/ 2009-01-06T23:28:21-04:00 Chyrp Tip: Commenting and Uncommenting tag:robwilkerson.org,2009-01-06:/id/19//comment_4837 2009-01-06T23:28:21-04:00 2009-01-06T23:28:21-04:00 www auto com http://emerson-elementa.kredasack.info/www-auto-com.html <p>fblga zjuefi xdgrm</p> Tip: Commenting and Uncommenting tag:robwilkerson.org,2009-01-06:/id/19//comment_4830 2009-01-06T22:12:55-04:00 2009-01-06T22:12:55-04:00 test http://1929-dodge.kredasack.info/test.html <p>ypvf pkqi gnxiht jxspvn</p> Intrepid Ibex VPN Connection Fails tag:robwilkerson.org,2009-01-06:/id/153//comment_4811 2009-01-06T18:42:29-04:00 2009-01-06T18:42:29-04:00 Keith Fisher <p>Perfect.</p> <p>The above thread worked first time for me. Many thanks!</p> SSH Host Key Checking tag:robwilkerson.org,2009-01-05:/id/164//comment_4727 2009-01-05T21:53:35-04:00 2009-01-05T21:53:35-04:00 Rob Wilkerson http://robwilkerson.org <p>Yep, I should have mentioned that. At the time I wrote this, I was working on my Ubuntu box so I wrote using that path. Thanks for clarifying.</p> <p>Actually, on my OS X machine (10.5.x) there are a couple of ssh_config files: one is in /private/etc/ssh_config (that’s the one I changed) and there’s another in /opt/local/etc/ssh/ssh_config. The latter directory is created and used by MacPorts installs, so I left it alone. I’m assuming MacPorts uses that <span class="caps">SSH</span> executable for downloading packages.</p> SSH Host Key Checking tag:robwilkerson.org,2009-01-05:/id/164//comment_4716 2009-01-05T19:47:20-04:00 2009-01-05T19:47:20-04:00 Matt Schinckel http://schinckel.net <p>On my OS X machine, it was /etc/ssh_config, not /etc/ssh/ssh_config.</p> <p>And, you can also set it in ~/.ssh/config, if you aren’t an admin on the machine you are working on. Without the # at the start, of course.</p> CakePHP: Recursive Finds tag:robwilkerson.org,2009-01-04:/id/162//comment_4591 2009-01-04T11:12:29-04:00 2009-01-04T11:10:18-04:00 Rob Wilkerson http://robwilkerson.org <p>Seriously? That’s awfully sensitive.</p> <p>Look, this post was about a mistake I made after reading the docs, not a slam-the-docs post. The post outlines:</p> <p>- What I read</p> <p>- What I thought/assumed/understood</p> <p>- Why I was wrong</p> <p>Others new to Cake might make the same mistake and maybe this will help. Or maybe not and that’s okay too.</p> <p>You’re right about my use of the term “misleading”. It was a poor (and inaccurate) choice of words and I’ve adjusted the post accordingly. That said, I stand by my statements that the documentation can be improved and even added one. Here’s why I think that (using this specific scenario):</p> <p>- I was looking to retrieve information from my model</p> <p>- I looked in what I considered (and still consider) to be the obvious place, the section entitled <em>Retrieving Your Data</em>.</p> <p>- I saw an ambiguity (yes, I understand that the type is documented there, but I also explained what lead me to incorrectly read it as a boolean).</p> <p>- I saw no additional information about the ‘recursive’ parameter on that page nor did I see any links to other pages that might contain related information.</p> <p>- I made an assumption and tried it. That assumption turned out to be wrong, so I continued looking via other support channels.</p> <p>Being new to Cake – I’m working on my first Cake project – I don’t want to immediately go digging through the code or the documentation for an <span class="caps">API</span> that I’m not decently versed in just yet so I looked elsewhere. Ultimately I found the answer. Had I not, I certainly would have dug around in the code or searched a little harder, but I was fortunate enough to get my question answered before doing so.</p> <p>Saying that the docs aren’t perfect isn’t a knock on the docs or the fine folks who put in the time to create/update them. It’s a simple statement of where I think there’s room for improvement and supporting that with <em>how</em> I think that they can be improved. </p> <p>Feel free to disagree with that in a reasonable manner, but don’t resort to ad hominem arguments about my laziness.</p> CakePHP: Recursive Finds tag:robwilkerson.org,2009-01-03:/id/162//comment_4516 2009-01-03T17:38:48-04:00 2009-01-03T17:38:48-04:00 ADmad <p>I have no problems with you thinking it to be boolean. People make mistakes. What i didn’t appreciate was you stating like “..provides very little information about the recursive parameter..”, “..but it can be misleading to new CakePHP developers..”.</p> <p>As i pointed out all available sources regarding the recursive property clearly state its an integer. You were just too lazy to dig deeper and conveniently blamed the doc to be ambigious/misleading.</p> CakePHP: Recursive Finds tag:robwilkerson.org,2009-01-03:/id/162//comment_4514 2009-01-03T17:22:54-04:00 2009-01-03T17:22:54-04:00 Rob Wilkerson http://robwilkerson.org <p>@Kevin: Thanks. I’m aware of that behavior, but am still trying to see what the “basics” will do for me before digging into some of the more surgical capabilities.</p> <p>@ADmad: Easy there, sailor, there’s no need to get your knickers in a twist. I said I read it wrong and I explained <em>why</em> I read it wrong. I wrote about it simply because I thought it might be something that others new to Cake may read wrong as well. </p> <p>Because the only examples I’d seen used a “1”, it wasn’t unreasonable in my mind to think of it as a boolean. That said, I clearly didn’t scour the docs for every mention of “recursive” and I should have looked a bit more. I’m still learning the docs, too.</p> CakePHP: Recursive Finds tag:robwilkerson.org,2009-01-03:/id/162//comment_4506 2009-01-03T15:36:14-04:00 2009-01-03T15:36:14-04:00 ADmad <p>Manual:<br /> http://book.cakephp.org/view/71/Model-Attributes#recursive-439</p> <p>Depth: -1, 0, 1, 2<br /> (All so ambiguous let me just assume it to be boolean) </p> CakePHP: Recursive Finds tag:robwilkerson.org,2009-01-03:/id/162//comment_4503 2009-01-03T15:32:09-04:00 2009-01-03T15:32:09-04:00 ADmad <p>The manual/api/code are pretty clear about recursive being integer. You just assumed it to be boolean.</p> <p>Manual:<br /> ‘recursive’ => 1, //int (does int mean integer? No its boolean)</p> <p><span class="caps">API</span>:<br /> http://api.cakephp.org/class_model.html#e60758f27fa8486a063b8cc424bad741<br /> Eg: find(‘all’, array( ‘conditions’ => array(‘name’ => ‘Thomas Anderson’), ‘fields’ => array(‘name’, ‘email’), ‘order’ => ‘field3 <span class="caps">DESC</span>’, ‘recursive’ => 2, ‘group’ => ‘type’));</p> <p>‘recursive’ => 2 (ah even 2 is boolean)</p> <p>Code:<br /> http://api.cakephp.org/libs_2model_2model_8php-source.html#l00253<br /> @var integer (crap.. again that’s boolean)</p> CakePHP: Recursive Finds tag:robwilkerson.org,2009-01-03:/id/162//comment_4501 2009-01-03T15:11:35-04:00 2009-01-03T15:11:35-04:00 Kevin http://dexterthedragon.com <p>You should also look into the containable behavior http://book.cakephp.org/view/474/Containable<br /> You specify which models you want data back from and it handles setting the recursive level itself.</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-30:/id/160//comment_4147 2008-12-30T03:39:03-04:00 2008-12-30T03:39:03-04:00 JIESCH <p>$this->set (‘data’ , $res=compact ( ‘vendor_type’, ‘application_type’, ‘states’ ) );</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-29:/id/160//comment_4106 2008-12-29T18:36:56-04:00 2008-12-29T18:36:56-04:00 Rob Wilkerson http://robwilkerson.org <p>Fair enough, ADmad. And quite true. I’ll take a look and try to figure out the best way to do so this week. Thanks for the, um, encouragement. :-)</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-29:/id/160//comment_4096 2008-12-29T16:14:02-04:00 2008-12-29T16:14:02-04:00 ADmad <p>Anyone can submit updates to the cookbook. And that anyone can be you :)</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-29:/id/160//comment_4076 2008-12-29T11:37:06-04:00 2008-12-29T11:37:06-04:00 dr. Hannibal Lecter http://dsi.vozibrale.com/ <p>That’s strange.. If this is a cake thing, how come it doesn’t happen when you’re not using compact? This is completely absurd. Same method, different output results? Why? If I set my variable as $mega_crap I want $mega_crap and not some other var name.</p> <p>Weird…</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-29:/id/160//comment_4071 2008-12-29T09:21:00-04:00 2008-12-29T09:21:00-04:00 Rob Wilkerson http://robwilkerson.org <p>Thanks for the info, all. I agree that it’s not inconsistent with CakePHP’s conventions, but I do wish its use was documented (or documented more prominently). Renaming variables that were explicitly set is bound to cause confusion among those that, like me, are new to CakePHP. </p> <p>I’d probably go one step further and argue that it’s not a good practice, but if it’s well documented then at least it won’t be a surprise.</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-29:/id/160//comment_4070 2008-12-29T08:14:31-04:00 2008-12-29T08:14:31-04:00 Ferdinant http://www.vtek.nl <p>It’s indeed Cakes Naming Convention that takes care of this. They might take a note on this one at the cakephp book, if it comes to me. :)</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-28:/id/160//comment_4059 2008-12-28T23:47:23-04:00 2008-12-28T23:47:23-04:00 Mike http://www.mikebernat.com <p>Good catch.. I’m sure I’ll get bitten by that sometime. It definitely follows the same sort of conventions cakephp normally enforces so I would have to agree with Adam that it’s not a compact() thing. </p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-28:/id/160//comment_4054 2008-12-28T22:47:03-04:00 2008-12-28T22:47:03-04:00 Brian d. http://realm3.com <p>I’ve been bitten by this same problem before and now I just use $this->set(‘var’, $var) most of the time instead of using compact().</p> CakePHP: Watch Out for the compact() Function tag:robwilkerson.org,2008-12-28:/id/160//comment_4046 2008-12-28T20:55:19-04:00 2008-12-28T20:55:19-04:00 Adam Royle <p>It’s changed by cakephp – nothing to do with the compact() function. Personally I don’t agree with cakephp renaming it without a warning, but I guess they want to standardise variable names.</p>