File is a reserved word in Cake - there is already a class called
File. Try renaming your model.

On Feb 4, 7:23 pm, "Adam D." <[EMAIL PROTECTED]> wrote:
> I have 3 tables in a database. Properties, Images and Files.
>
> My Property table $hasMany array contains both Images and Files.
>
> Properties has many images. Properties has many Files.
>
> For some reason when I add 'File' to my properties controller.
> Everything stops working, and I get the following errors...
>
> Notice (8): Array to string conversion [CORE/cake/libs/file.php, line
> 90]
> Notice (8): Array to string conversion [CORE/cake/libs/file.php, line
> 91]
> Warning (2): basename() expects parameter 1 to be string, array given
> [CORE/cake/libs/file.php, line 92]
> Notice (8): Undefined property:  table [CORE/cake/libs/model/
> model.php, line 667]
> Notice (8): Undefined property:  alias [CORE/cake/libs/model/
> datasources/dbo_source.php, line 554]
> Notice (8): Undefined property:  useDbConfig [CORE/cake/libs/model/
> datasources/dbo_source.php, line 559]
> Notice (8): Undefined property:  useDbConfig [CORE/cake/libs/model/
> datasources/dbo_source.php, line 586]
> Notice (8): Undefined property:  useDbConfig [CORE/cake/libs/model/
> datasources/dbo_source.php, line 589
>
> ...The odd thing is, Images works fine. Displays all the images. The
> images relationship to Properties is identical to Files, but Files
> just doesn't work. And the real kicker is, I have a separate admin
> site that has already been built, and you can add, edit, delete and
> view Files, Properties and Images perfect. No problems there at all.
>
> ** Also, when I have debug mode on, the query doesn't contain anything
> related to 'File' in the sql at all.
>
> Very confusing.
>
> Any help would be greatly appreciated.
>
> Thanks,
> Adam
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to [email protected]
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to