Page 1 of 1

Undefined method

PostPosted: Thu Sep 27, 2012 11:17 pm
by zmmaj
I have recently errors on almost all plugins who need command getModuleURL()
This is from apache2 error log:
Code: Select all
[error] [client 127.0.0.1] PHP Fatal error:  Call to undefined method Dataface_ModuleTool::getModuleURL()


So, where is defined this command, what I need to load before I put in "conf.ini" file line such is
Code: Select all
modules_ckeditor=modules/ckeditor/ckeditor.php

or ajax_upload call or Email call

tnx in advance.

P.S.
I must say that I have same error with command IsAdmin() :(

Re: Undefined method

PostPosted: Fri Sep 28, 2012 10:21 am
by shannah
Looks like you're using a version of Xataface that doesn't support the modules in question. Many of the modules in SVN require Xataface 2.0 (or at least 1.5.x). The latest release is 1.3.2 (i.e. 2.0 isn't released yet).

The isAdmin() function that you see in many examples doesn't exist. It is assumed that you would define such a function for yourself. You can find an example of this function at http://weblite.ca/svn/dataface/core/tru ... ns.inc.php

-Steve

Re: Undefined method

PostPosted: Fri Sep 28, 2012 11:37 am
by zmmaj
OK..
where to download version of Xataface that support the modules in question?
I am bad for php... :(
there is several command's like that...
tnx

Re: Undefined method

PostPosted: Fri Sep 28, 2012 11:45 am
by shannah

Re: Undefined method

PostPosted: Fri Sep 28, 2012 1:52 pm
by zmmaj
OK... I was download 1.9 version...

1: CKEDITOR
First I was try CKEditor... and I have error....
Code: Select all
[Fri Sep 28 22:44:04 2012] [error] [client 127.0.0.1] PHP Parse error:  syntax error, unexpected '(', expecting ')' in /var/www/xatam/lib/HTML/QuickForm/date.php on line 77, referer: http://127.0.1.1/medika/index.ph ............


Line 77 on the file date.php is:
Code: Select all
        'maxYear'          => intval(date('Y'))+5,


I was write here
Code: Select all
maxYear'          => 2020,
.. and now CKEditor works...

2: DATEPICKER

won't work . I have next from error.log
Code: Select all
[Fri Sep 28 23:00:45 2012] [error] [client 127.0.0.1] PHP Fatal error:  Uncaught exception 'Exception' with message 'Server-side Javascript directive failed in script "xataface/widgets/datepicker.js"' in /var/www/xatam/Dataface/JavascriptTool.php:565\nStack trace:\n#0 /var/www/xatam/Dataface/JavascriptTool.php(421): Dataface_JavascriptTool->_compile(Array)\n#1 /var/www/xatam/Dataface/JavascriptTool.php(274): Dataface_JavascriptTool->compile()\n#2 /var/www/medika/modules/XataJax/XataJax.php(30): Dataface_JavascriptTool->getHtml()\n#3 [internal function]: modules_XataJax->block__after_global_footer(Array)\n#4 /var/www/xatam/Dataface/ModuleTool.php(185): call_user_func(Array, Array)\n#5 /var/www/xatam/Dataface/Table.php(5215): Dataface_ModuleTool->displayBlock('after_global_fo...', Array)\n#6 /var/www/xatam/public-api.php(569): Dataface_Table->displayBlock('after_global_fo...', Array)\n#7 /var/www/xatam/Dataface/SkinTool.php(1046): df_block(Array)\n#8 /var/www/medika/templates_c/dataface/%%08^08F^08FE976E%%Dataface_Main_Template.html.php(438): Dataface_SkinTool->block(Array, Object(Dataface_S in /var/www/xatam/Dataface/JavascriptTool.php on line 565, referer: http://127.0.1.1/medika/index.php?


I am stupid for errors like this :)



I will try now and other previous problematic modules

Tnx for tip ( Version 1.9)

Re: Undefined method

PostPosted: Fri Sep 28, 2012 2:13 pm
by shannah
Looks like there was a problem with your downloading of the files. If you're getting syntax errors in the PEAR class HTML/QuickForm/date.php, that's a good indicator that the files are corrupted.

Re: Undefined method

PostPosted: Fri Sep 28, 2012 2:25 pm
by zmmaj
hah.. well.... WHAT files?
OK, I will try to download again that module...
BUt I was try and ajax_upload...
this is from error.og
Code: Select all
[Fri Sep 28 23:20:10 2012] [error] [client 127.0.0.1] PHP Fatal error:  Uncaught exception 'Exception' with message 'Server-side Javascript directive failed in script "xataface/modules/ajax_upload/ajax_upload.js"' in /var/www/xatam/Dataface/JavascriptTool.php:565\nStack trace:\n#0 /var/www/xatam/Dataface/JavascriptTool.php(421): Dataface_JavascriptTool->_compile(Array)\n#1 /var/www/xatam/Dataface/JavascriptTool.php(274): Dataface_JavascriptTool->compile()\n#2 /var/www/medika/modules/XataJax/XataJax.php(30): Dataface_JavascriptTool->getHtml()\n#3 [internal function]: modules_XataJax->block__after_global_footer(Array)\n#4 /var/www/xatam/Dataface/ModuleTool.php(185): call_user_func(Array, Array)\n#5 /var/www/xatam/Dataface/Table.php(5215): Dataface_ModuleTool->displayBlock('after_global_fo...', Array)\n#6 /var/www/xatam/public-api.php(569): Dataface_Table->displayBlock('after_global_fo...', Array)\n#7 /var/www/xatam/Dataface/SkinTool.php(1046): df_block(Array)\n#8 /var/www/medika/templates_c/dataface/%%08^08F^08FE976E%%Dataface_Main_Template.html.php(438): Dataface_SkinTool->block(Array, Obje in /var/www/xatam/Dataface/JavascriptTool.php on line 565, referer: http://127.0.1.1/medika/index.php?


Tnx for help

Re: Undefined method

PostPosted: Fri Sep 28, 2012 3:39 pm
by shannah
hah.. well.... WHAT files?

The the source files that you downloaded from SVN. That would be the actual Xataface distribution and/or the plugins. If it is saying that there is a syntax error in a well tested library - then clearly there was a problem with the files.

You may also need to clear out your templates_c directory after updating to a new version as some of the template files may be cached and overriding the newer versions. Clearing out this directory will force the new templates to be cached.

One good strategy is to get your app working without any modules before you start adding modules. That way you can narrow down the problem.

_Steve

Re: Undefined method

PostPosted: Fri Sep 28, 2012 10:35 pm
by zmmaj
yes yes,,, I am redownload related module... You are right now I haven't that error, and module works well,

Can you help me with datepicker error and ajax_upload?

Tnx