This is a duplicate of my question asked on StackOverflow here:
http://stackoverflow.com/questions/17875143/model-habtm-model-referencing-original-model
If you could answer the question there, or let me know if it is a bug or
not, it would be greatly appreciated.
I have a Team model that is HABT
Replace the element method in /DebugKit/View/DebugView.php with the
following:
/**
* Element method, adds comment injection to the features View offers.
*
* @return void
*/
public function element($name, $data = array(), $options = array()) {
$out = '';
$isHtml = (!isset($this->request->param
It also seems that scripts added in the default layout or through elements
that are included in the default layout don't have their scripts added to
the queue at all.
I was going to try adding all the default scripts in via an element, but
they just get ignored.
--
Our newest site for the com
One issue that I'm having, is that if a script is included in the default
layout in the HEAD tag above the $scripts_for_layout, with the default 'inline'
=> true, and then again in a view (or element, or whatever) with 'inline'
=> false, The HtmlHelper does not recognize that the script in quest
I am building a RememberMe Component using the AuthComponent and would like
to get the BaseAuthenticate::$settings data (userModel and fields) data out
of the XxxxAuthenticate object so I can know what model and fields I should
be dealing with, but I can't seem to figure out how to get that data
I ran into a fatal error on my home page.
Fatal error: Call to a member function here() on a non-object in C:
\Development\cake_files\cake_2.0.0-rc3\lib\Cake\Error
\ExceptionRenderer.php on line 182
Not sure what to do about it as it's a core issue.
Is there something I'm missing?
Cake2.0.0-rc3
A similar question was asked previously (about two years ago) and I
was just looking for some further clarification but didn't want to
revive a dead thread...
I was trying to do a find('list') on a model and trying to pull
information from another model (for grouping purposes) via the
containable
odel (MotionFile or SeeFile), or attach-detach
> > behavior manually. I think all will be fine if you remove 'MeioUpload'
> > from $actsAs in all models and will attach it just before save: $this-
>
> > >MotionFile->Behaviors->attach('MeioUploa
I'm currently using the MeioUpload Behavior from
http://github.com/josegonzalez/MeioUpload/tree/master in a couple of
my models on a project of mine and am running into an issue.
When I try to upload a file in one of my models (MotionFile), it says
the index cannot be found "SeeFile".
SeeFile is
I have encountered what might be a bug in Cake.
I have an ACO tree that looks like the following:
controllers
- Events
-- admin_index
- Newsletters
-- events
When I try to access the admin index page for the Events controller, I
get an error stating that the ACL check failed.
After digging a bi
I have a site that uses ACL and Auth to control access to the admin
portion of the site, as well as one other non-admin page.
When I have debug set to 2, I can log in and access the admin fine,
and when I'm logged off, it blocks everything as it should.
When I turn debugging off, and try to acce
Seems to work great. I removed the 'Parent', and 'Child' relationship
from Page, and refactored it to use the Tree behavior methods instead.
Thanks.
On Feb 16, 5:06 pm, benjam wrote:
> I had thought of that (the Parent Child thing on multiple models) but
> was
I had thought of that (the Parent Child thing on multiple models) but
was hoping that Cake was smart enough to know which was which.
Thanks for the info, I'll fiddle with it and post the outcome here...
On Feb 16, 12:43 pm, AD7six wrote:
> On Feb 16, 9:21 am, benjam wrote:
>
&
Here are some (hopefully) relevant code snippits:
http://pastebin.com/f7426e0c4
On Feb 16, 8:55 am, benjam wrote:
> I have just com across a very strange issue with Cake. I have ACL
> installed in my app, and I havre a self-referencing table in that app
> as well (Parent-Child).
I have just com across a very strange issue with Cake. I have ACL
installed in my app, and I havre a self-referencing table in that app
as well (Parent-Child).
In my app_controller, I pull data for the self-referencing model for
every page load (it runs the menu), and it works fine for all the
p
One thing I've noticed that has always kinda bothered me...
Why, when baking a view, does Cake get the names for multi-word models
correct, except for the one you're on.
For instance:
I have a table product_categories, and another table product_families
which is related.
When I bake the view fo
Anybody have any suggestions?
Or should I just submit a ticket?
--~--~-~--~~~---~--~~
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
I'm trying to run cake schema run update from within my APP dir to
update my database schema and I get the following errors:
C:\Development\app>cake schema run update
Welcome to CakePHP v1.2.0.7692 RC3 Console
On Oct 22, 4:07 pm, Gwoo <[EMAIL PROTECTED]> wrote:
> If you
> think your changes are that great, you should really think again.
really? damn, I didn't know that the Cake devs were the only ones
who could write decent code.
Maybe the Cake devs should hop down off the Cake pedestal and g
Seconded again.
On Sep 30, 2:52 am, "dr. Hannibal Lecter" <[EMAIL PROTECTED]> wrote:
> I second that, doesn't work for me either.
>
> On Sep 30, 10:30 am, Kanten <[EMAIL PROTECTED]> wrote:
>
> > Hi,
>
> > I'm afraid there is something wrong with the add comment function in
> > thebakery:http://ba
I apologize in advance for using the group for this, but I can't seem
to log into the bakery.
I tried resetting my password, I also tried creating a new account,
both to no avail.
I would like for someone with admin rights to the bakery to get into
there and get me my original login data, and po
You should probably take a look at why you want to keep people from
viewing certain URLs.
If it's from a security standpoint, you should probably have some
server side scripting that blocks the URL, not just a "If there's no
link, then I hope they can't guess my URL" security system.
And if you
;d choose a different name.
>
> -Jonathan
>
> On 7/9/08, benjam <[EMAIL PROTECTED]> wrote:
>
>
>
> > Apparently the problem was that I had a table called 'files', which
> > isn't allowed.
>
> > WTF?
>
> > On Jul 9, 10:0
Apparently the problem was that I had a table called 'files', which
isn't allowed.
WTF?
On Jul 9, 10:05 am, benjam <[EMAIL PROTECTED]> wrote:
> While trying to bake a view I received the following error:
>
> Fatal error: Call to undefined method File::schema()
While trying to bake a view I received the following error:
Fatal error: Call to undefined method File::schema() in \cake\cake
\console\libs\tasks\view.php on line 383
Any suggestions?
I was also receiving several notices and warnings when baking my
controllers, if this has anything to do with
I have a question about a custom route and was wondering if it's
possible, and if it is, how?
I have some controllers for a game match site named the following:
foos_teams
foos_matches
chess_matches
ping_teams
ping_matches
catan_matches
and I would like to be able to access them by going to the
I have the following tables with the following fields
territories
-
id
zip_start
zip_end
offices
-
id
zipcode
and I want to associate via hasMany and belongsTo on the following
conditions
(territories hasMany offices) and (offices belongsTo terr
I don't think beforeSave would work, because it gets hashed even
before the method that calls Save( ).
I think I may have found a cheater (read: non-cake) way of doing it...
I run the following test:
if ($this->Auth->password('') == $this->data['User']['password']) {
unset($this->data['
d to find a way to
delete it even before that.
On Jun 6, 2:38 pm, "Chris Hartjes" <[EMAIL PROTECTED]> wrote:
> On Fri, Jun 6, 2008 at 4:33 PM, benjam <[EMAIL PROTECTED]> wrote:
> > I was wondering if there was a way to prevent it from hashing the
> > password
I have an admin section to my site, which is protected by Auth and
using a Users table.
The trouble I'm having is, when I set up a user, everything works just
fine.
When I go in to edit that user, the password field gets corrupted
because instead of re-hashing the original password (which would
But I'd still like to know the proper cake way of getting it to work.
Thanks, and sorry for the multiple posts.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to ca
I found a workaround...
by adding 'training' => true to all my cake links parameter arrays, it
works.
e.g-
link($lesson['title'], array('controller' =>
'lessons', 'action' => 'view', $lesson['id'])); ?> -- doesn't work,
but should
link($lesson['title'], array('training' => true,
'controller' =>
I'm having troubles getting this working the way I want it to.
I am using the prefix method (although I also tried the array method
with equally false results) an I have my router set up like this:
$params = array(
'prefix' => 'training' ,
'controller' =>
Both of those options seem like they would work perfectly.
I think I will implement the array version for my needs right now, and
look at the prefixing as a cleaner, more 'Cake' way in the future (I'm
on a deadline right now, and need something quick).
Thanks to you both.
--~--~-~--~
I'm having a menu problem, I have a section of my site which 'wraps'
several controllers and models, therefore, while doing things in this
section, the menu I have created with $menu->menu breaks (the current
menu tab highlighting is incorrect) because my URL keeps changing,
although I am in the s
works now, and thanks for everybody's help.
On May 15, 2:06 pm, "Jonathan Snook" <[EMAIL PROTECTED]> wrote:
> On Thu, May 15, 2008 at 4:00 PM, benjam <[EMAIL PROTECTED]> wrote:
>
> > That's a big help, but not enough to fix the issue. In fact just the
>
where the main site script is not in the root directory of the server.
Thanks for the info though.
On May 15, 10:23 am, Joel Perras <[EMAIL PROTECTED]> wrote:
> http://book.cakephp.org/view/39/configuration#routes-configuration-46
>
> -Joel.
>
> On May 15, 11:18 am, benjam <[E
I have a section of my site called 'Ask Vinny' and I would like the
URL to look something like mysite.com/vinny (not mysite.com/vinnies)
so I renamed the controller and moved the views into the vinny/ dir,
and it works fine, except that when submitting the 'ask question' form
( @ vinny/ask), it tr
Exactly what I was looking for.
Thanks.
On May 14, 11:56 am, Kyle Decot <[EMAIL PROTECTED]> wrote:
> create a file called menu.ctp in your views/elements folder. then you
> can include the menu by using:
>
> echo $this->renderElement("menu");
--~--~-~--~~~---~--~~
I apologize if this has been asked before, I looked but did not find
the answer I was looking for.
I know how to include a file in PHP, and here is what I am looking to
do:
in view.ctp:
-
Other view content here
-
What is
The main reason for the post was not trolling, but to merely open some
eyes to the state of the group.
It seems it worked, and I'm glad to see that there are a lot of people
here who care about the community.
I will be around for quite a while, asking questions (some probably
pretty stupid ones)
> I think this guy is just looking for 5 minutes of fame and fortune :P
yes please.
everybody who has posted a response please send me $5.
mbavio gets to send me $10.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google Groups
> I do find it interesting to compare Cake responses with, say, the
> JQuery group- where someone titles their post "it's not working" and
> still get loads of polite and helpful responses!
Maybe I've just been around the jQuery group too long...
--~--~-~--~~~---~--~-
;] = null;
> }
> return true;
> }
>
> 2) The Tree behaviour has generatetreelist() however it display likes
> this:
>
> Parent 1
> _Child 1-1
> _Child 1-2
> Parent 2
> _Child 2-1
> _Child 2-2
> __Subchild 2-2-1
>
>
> How is calling the documentation horrendous polite? You have any idea
> the amount of hours people take to write that, not to mention that is
> a community effort? I tell you, with the likes of you, I don't doubt
> anyone would call you names, disrespecting other's people valuable
> time like th
Seriously, why does everybody in the CakePHP community got their
finger on the trigger to just rip any person that has a question a new
one?
I mean, I have seen some pretty stupid questions in my time, and the
ones here are nowhere near as bad as the ones that I've seen
elsewhere. The thing that
I have a location table with the following fields:
---
id
name
location_id -- this is a parent location id
---
I have a couple of questions about getting this to work the way I want
it to using scaffolding.
1- How can I set it up so the location_id select box on the form has a
default va
Because it is still an issue, and has not been fixed yet.
On May 5, 2:59 pm, AD7six <[EMAIL PROTECTED]> wrote:
> benjam wrote:
> > My thinking is that it's a cake problem.
>
> Why are you resurrecting this old thread.
--~--~-~--~~~---~
My thinking is that it's a cake problem.
If there is a way of doing things (INSERT NULL) that works everywhere,
regardless of server settings, and a way of doing things (INSERT '')
that works _almost_ everywhere, then you should use the way of doing
things that works everywhere.
If you don't, yo
49 matches
Mail list logo