Each time I send my register page containing this
[[!Register?
&submitVar=`registerbtn`
&activationResourceId=`470`
&activationEmailTpl=`ActivateEmailTpl`
&activationEmailSubject=`Bedankt voor uw registratie`
&submittedResourceId=`471`
&usergroups=`webusers`
]]
<div class="register">
<div class="registerMessage">[[+error.message]]</div>
<form class="form" action="[[~[[*id]]]]" method="post">
...etc
An error will appear in the log file. No email is sent either. What does this error mean?
[2010-10-19 07:31:09] (ERROR @ /index.php) Could not get table name for class: modAccess
[2010-10-19 07:31:09] (ERROR @ /index.php) Error 42000 executing statement:
Array
(
[0] => 42000
[1] => 1064
[2] => You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ’AS `modAccess` WHERE `modAccess`.`principal` = 9’ at line 1
)
I found out that if I leave out
&usergroups=`webusers`
the error doesn’t appear, but still no mail is sent.
-
MODX Staff
- 10,725 Posts
No, this is an "abstract" object definition in the schema, which the other modAccess* classes define "concrete" implementations of. What is "this error message"? I don’t think you posted the error...
What does it mean abstract class - there is a real table (access_actiondom) in database for this class. Code is trying to getTableName for this class and cannot get it.
I use "$delUser->remove()" to delete a user, it is deleted but with error on screen:
ERROR is:
(ERROR @ /index.php) Could not get table name for class: modAccess
[2010-11-23 17:29:14] (ERROR @ /index.php) Error 42000 executing statement:
Array
(
[0] => 42000
[1] => 1064
[2] => You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ’AS `modAccess` WHERE `modAccess`.`principal` = 86’ at line 1
)
And this is because there is "$accessTable = $this->xpdo->getTableName($target);" in moduser.class.php code which probably gives error as this class does not have table.
Hi OpenGeek, thanks for reply. How come it is not causing troubles when deleting normal modUser? My extended user class simply inherits function remove from modUser. I am not instantiating modAccess in any of my functions. So why am I getting this error and there is no error when you remove user through standard back-end.
Thanks,
Vlad
-
MODX Staff
- 10,725 Posts
I have no idea why yet, thus I asked for the ticket so I (or another core contributor) don’t forget to look into it.
Hi OpenGeek, has this issue been reported as a bug? This error appears even in Error Logs in CMS after deleting a user.