I don't see what could explain the fatal error in the entity explorer. Could you maybe tell a bit more about the exception?
I did not see what caused it either. As I mentioned the database entries looked fine and a SQL query pulled things as expected. I discovered the problem when I tried to pull the entity for a view. the view was creating a blank object for all objects of the custom class type. The class was (is) registered in elgg-plugin.php. The same view could pull any other object as expected. The entity explore did not give a lot of info in the error *well not a lot of useful info) It essentially said the object was empty.
I took the two lines from the initialize attributes function and put them in the action and from that point, all object created using the same class work as expected.
RvR
//If you'll insult me (and you're doing it now), you'll be banned here.//
You are right and I am sorry I came in hot. Yes I should have included code but I was posting from my iPad away from my development box, Also I had already deleted/changed the code to make the project work and was simply hoping for some general ideas as to why a class might cause such errors so didn't think code was relevant. My bad
I will make sure to include code in future posts.
I was wrong in my statements to you and I really do appreciate your efforts. that said please try to remember that not all of us are at your level. This is a beginner forum. It is not alwasy easy to ask for help and being told the RTFM and figure it out ourselves is not what we are hoping for.
I did not see what caused it either. As I mentioned the database entries looked fine and a SQL query pulled things as expected. I discovered the problem when I tried to pull the entity for a view. the view was creating a blank object for all objects of the custom class type. The class was (is) registered in elgg-plugin.php. The same view could pull any other object as expected. The entity explore did not give a lot of info in the error *well not a lot of useful info) It essentially said the object was empty.
So if you did :
var_dump(get_entity($guid_of_your_custom_class));
Does it result in YourCustomClass or in an ElggObject? If it's an ElggObject than your class registration is wrong (it should still be able to show all information stored in the database for this object however).
Works but when I substituted my class in instead of EllgFile it threw errors in the symfonly libraries
without seeing a backtrace of the errors, it's hard for me to guess what happened.
Like i said all looks fine, there must be one (dumb/stupid) thing that is wrong. But finding that one thing is almost always the hardest part ;)
info@elgg.org
Security issues should be reported to security@elgg.org!
©2014 the Elgg Foundation
Elgg is a registered trademark of Thematic Networks.
Cover image by Raül Utrera is used under Creative Commons license.
Icons by Flaticon and FontAwesome.