Forums

tooltip and required fields not working

GaVrA 12 Feb, 2010
Hello!

I have created new form, which is online here:

http://registrujauto.com/index.php?option=com_chronocontact&chronoformname=info_za_registraciju

I have selected several fields to be required.

My validation settings:

[attachment=0]2010-02-12_180400.png[/attachment]

Also tooltips are not working.

"Load Chronoforms CSS/JS Files?" is set to "Yes". I have tried to put this to no, and i can than see tooltip element, so clearly some tooltip javascript is working because it changes "display" value to none on that tooltip element.

I have read that it could be some js issue if jquery is also loaded(or any other js lib), but i cant find in source code any other js lib(i am just working on this page, not the entire site).

Any idea what to do?


Best regards,
GaVrA
GreyHead 12 Feb, 2010
Hi GaVrA,

Your theme is loading MooTools 1.2 - Joomla and ChronoForms use MooTools 1.1 and the two aren't completely compatible.

If you look at the form without the template then MooTools 1.12 is being loaded and the validation and tooltips work correctly.

I have had a site running validation under MooTools 1.2 with the upgrade helper. I've attached the two validation files that I edited, I'm afraid the site didn't use ToolTips so I didn't get that far (but they may be OK).

Bob

PS The file need to be unzipped and go into the com_chronocontact/js folder. Keep the old ones in case you need to go back.
GreyHead 12 Feb, 2010
Hi Romuba,

Same problem - slightly different cause. You have the JQuery Library loading. It needs to be put into noConflict mode. There are threads about how to do that here and more documentation on the JQuery site.

Again if you view the form without the template the tooltips are fine.

Bob
GreyHead 12 Feb, 2010
Hi Ross,

I don't see any sign that the plugin is installed on your page. I think that all you need is to have this at the beginning of your form html
<?php
$doc =& JFactory::getDocument();
$doc->addScriptDeclaration('jQuery.noConflict();');
?>


I resolved the conflict on one site but I'm no expert in this area.

Bob
GaVrA 13 Feb, 2010
Problem is that i dont have FTP access, im just here to do this page and that's it.

Is there any specific reason why you didnt update ChronoForms to work with mootools 1.2? :? I really dont follow mootools or joomla, but it's weird that i have issue because backend system and module for it are using outdated(i think?) version of mootools. 😲

Last resort for me is to disable CF javascript and to try make my own or find some other, but that is really too much to do, i was just hired to do forms page and exit page where i can echo everything from post.🙂

Maybe i can try to make theme load mootools 1.1? Really dont know what to do here.
GreyHead 13 Feb, 2010
Hi GaVrA,

Because Joomla 1.5 doesn't use MooTools 1.2 - simple as that really. It's planned for Joomla 1.6 I believe and the bridging library I posted the link too is an excellent help (but only available since the end of the year).

I'm afraid my view is thst if your client uses a template that isn't Joomla consistent then they should sort out the problem with the template designer. I know that isn't very sympathetic . . . sorry.

There are ways of forcing the page to load MooTools 1.1 but that would probably break things in the template.

Your best bet might be to add native LiveValidation without using the ChronoForms loaders; and may to find some MooTools 1.2 compatible tooltip code (that may be in the template?).

Bob
GaVrA 13 Feb, 2010
Like i said, im not that into joomla and mootools.

But let's see if understand:

latest version of joomla is 1.5
latest version of mootools is 1.2

joomla 1.5 uses mootools 1.1 and hence you guys use it also.

This theme my client have uses mootools 1.2 so it is theme designer that pretty much screwed things?

I will tell this to my client, and i will ask him to try to contact theme designer for downgrade to mootools 1.1 or something like that...

Anyhow thanks for really good and fast answers!
GreyHead 13 Feb, 2010
Hi GaVrA,

That's it in a nutshell :-)

When I have time I'll look at converting other parts of the code that ChronoForms uses. It's tedious rather than difficult and the demand isn't that high :-(

But you'd still need FTP access to make the changes (or a special ChronoForms installer I guess).

Bob
nml375 13 Feb, 2010
Hi Josh,
I did notice that the URL http://www.joshuawest.co.za/files/components/com_chronocontact/js/jsvalidation2.js does not work - instead returns a "404 Not Found" error-page. Also, directory contents listing is enabled (generally not advisable) - which does reveal that the jsvalidation.js file has been renamed to jsvalidation_old.js

The jQuery library is running in no-conflict mode, though there are two other errors in the javascript console:
elementExtend not defined - this is related to the missing jsvalidation2.js.
el.set is not a function - originates from mootools.js, not sure about the cause though. A guess would be there's something overriding mootools' Element class...

I do notice there's two different jQuery scripts being loaded, the last one is loaded from ajax.googleapis.com, and has no following jQuery.noconflict() call - this could possibly be an issue.

/Fredrik
This topic is locked and no more replies can be posted.