26

Re: Some issues

Hi Dieter,

I wouldn't recommend downgrading to Drupal 6. I am upgrading iRecord from D6 to D7 at present. D6 will become obsolete before too long. We have plenty of D7 sites working just fine.

When you say you do not get any errors when using the photo upload button you'd probably only know about that if you are using the browser developer tools. Typically if there is a javascript error the browser reports nothing, the script is abandoned and your only clue is that something does not work as expected.

You may have done this already, of course, but with Chrome, use ctrl-shift-J to bring up the JavaScript console, navigate to your recording form (or refresh if you are already there) and click the photo upload button. Any sign of errors now?

Jim Bacon.

27

Re: Some issues

Aha, didn't know this function in Chrome. Is this useful information?

 GET http://localhost/funbel/sites/all/modules/iform/media/js/lang/en.js?ngfj9k 4:90
GET http://localhost/funbel/sites/all/modules/iform/media/js/plupload/js/plupload.full.min.js?ngfj9k 
jquery.uploader.js?ngfj9k:242 
Uncaught ReferenceError: plupload is not definedjquery.uploader.js?ngfj9k:242 (anonymous function)jquery.js?v=1.4.4:34 b.extend.eachjquery.js?v=1.4.4:27 b.fn.b.eachjquery.uploader.js?ngfj9k:188 $.fn.uploaderaddRowToGrid.js?ngfj9k:493 (anonymous function)jquery.js?v=1.4.4:19 Kajquery.js?v=1.4.4:64 c.event.handlejquery.js?v=1.4.4:57 h.handle.o

28

Re: Some issues

Now you're talking!
This tells us that, when line 242 of the uploader.js script is reached, plupload is not defined.
Plupload is used to upload files so, if it is not defined, that would explain why your button is not working.

I can see from the above that there is a GET request for the file plupload.full.min.js. I'm not clear if that is in the console as a success or a failure message. If it is a failure, saying that you don't have that file, then there is your problem. If that is a success message then we have to think again.

So, does sites/all/modules/iform/media/js/plupload/js/plupload.full.min.js exist?

Jim Bacon.

29

Re: Some issues

We're getting closer Jim. It's not there. Where can I find this file? :)

30 (edited by dieter 13-12-2014 17:43:40)

Re: Some issues

Aha!!! The files in the Drupal 7 branche are not up to date. I solved it with copying files I downloaded from the Plupload website. It finally works now!!! Jim, you're my hero. :D Now I can go on testing.

31

Re: Some issues

About the other issue on the my records page, it only appears when refreshing this page. When I stop my apache server and clear my coockie cache it dissappears again until I refresh this page again.

32

Re: Some issues

Hi Dieter

This is very interesting.

First of all, you have discovered a problem in the repository which I see exists for
- drupal/modules/iform/tags/version 0.9.0 (March 5, 2014)
- drupal_7/moudules/iform/tags/version 0.9.0 (March 5, 2014)
- core/tags/version 0.9.0.1 (March 25, 2014)
- core/branches/version 0.9.1 (Still receiving occasional bug fixes relative to version 0.9.0.)
all of which, in client_helpers/helper_base.php, call for the file plupload.full.min.js but do not have it.

I think this error was introduced at the time of creation of the tagged versions as the file existed since February 5 2014.
The tagged versions represent a moment in time so will always be wrong.
The core branch could be corrected although I'm not clear about the extent of the errors it may contain.
The trunk does not suffer this problem.

My apologies for this error and the for the waste of time it has caused you.

However, this may help us solve your other problem. When John wrote

Have you updated your iform module from SVN recently? I think that this is an area I worked on a couple of months back.

he meant updating from the trunk. If you have been getting your code from a tag/branch you will not be getting the changes that he has made. If you would like to switch to the trunk and try again we should all, finally, be working from the same code base.

Jim Bacon.

33

Re: Some issues

Hmmm, it's very confusing with all the seperate files and folders. The trunk should be the latest development, I agree on that. But the trunk doesn't have the client_helpers folder. And overriding the files from the trunk to the tags folder to have the client_helpers folder is not a good idea apparently. I got an error and the form was broken (couldn't do anything anymore). Reinstalling doesn't work either.
Fatal error: Access to undeclared static property: helper_base::$cache_folder in C:\xampp\htdocs\funbel\sites\all\modules\iform\iform.module on line 1097.
So I think something with the drupal 7 files in the client_helpers is not compatible with the files in the trunk. Maybe John should have a look to the drupal 7 files because I have the feeling this is not yet as it should be.

Dieter

34

Re: Some issues

Hi Dieter,

We need to use the client_helpers and the media library both in the warehouse and in the Drupal modules.
Naturally we don't want to have the same code in the repository twice so it is put in the core (i.e. warehouse) trunk.
There is then an import statement (or something like that) which should ensure that, when you checkout the trunk of the iForm module you get the the client_helpers from the trunk of the core automatically.

The problem with the missing plupload file in the tags probably arose when John created the tags. It looks like he has to take a copy of the client_helpers and media libraries, rather than use this linking mechanism, at that point.

Perhaps there is something going wrong with the way you checkout the code. We use Tortoise SVN which seems to work very well at getting the external libraries at the same time as the IForm code.

Jim Bacon.

35

Re: Some issues

Okay, apparently I checked the svn code with the wrong software. Thanks! :)