Thank you Aicha for the details,
Made the changes. now concerned portion of default.php looks like this ...
Code:
var validator = jQuery(document).ready(function() {
jQuery('#visform<?php echo $this->visforms->id; ?>').validate({
submitHandler: function(form) {
<?php if (JFactory::getUser()->guest)
{ ?>
alert('Please login in submit the form);
<?php } else { ?>
form.submit();
<?php } ?>
},
wrapper: "p",
But for some unknown reason it appears that there is no change in behavior of submit button. It works just as beofre as if no changes has been made in the code.
Workarounds ...
1. Created a folder html/mod_visforms/ in my root template folder and copied default.php from modules/mod_visforms/tmpl in it. Changed the code as described in your last message.
2. Put the form on test on my live site. When it did not work as intended, additionally, made the following changes...
3. Created a folder html/com_visforms/visforms in my root template folder and copied default.php from components/com_visforms/views/visforms/tmpl in it. Changed the code as described in your last message. It did not work either.
What am I doing wrong here ?
Here
is the said form on my site. You can check if you wish.
Thank you again