Quantcast

JQuery Error Lasso 9.3

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

JQuery Error Lasso 9.3

John Torres-3
New to integraty JQuery into a .lasso page. I'm not understanding the following error that Lasso server is sending back on the following code. The jquery works just fine on its own, but inside of a lasso page not so much. Any ideas why the CARET "^" error?
Error:

An unhandled failure during a web request

Error Code: -1

Error Message: Parser error. //Library/FileMaker Server/HTTPServer/htdocs//lasso/central/hot/New_index.lasso: Error while parsing. Unexpected: CARET line: 110, col: 16



<script type="text/javascript" src="/lasso/js/jquery-3.2.1.min.js"></script>

<script>
       
        $('input[class^="Day"]').click(function() {
                var $this = $(this);
                if ($this.is(".Day0")) {
                        if ($(".Day0:checked").length > 0) {
                                $(".Day1").prop({ disabled: true, checked: false });
                                $(".Day2").prop({ disabled: true, checked: false });
                                $(".Day3").prop({ disabled: true, checked: false });
                        } else {
                                $(".Day1").prop("disabled", false);
                                $(".Day2").prop("disabled", false);
                                $(".Day3").prop("disabled", false);
                        }
                } else if ($this.is(".class2")) {
       
       
                }
        });

</script>

#############################################################

This message is sent to you because you are subscribed to
  the mailing list Lasso [hidden email]
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <[hidden email]>
Send administrative queries to  <[hidden email]>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JQuery Error Lasso 9.3

Steffan Cline
Lasso sees the [ and ] in the JavaScript as Lasso code. If you use the proper JavaScript comment syntax it will be fine. That tells the lasso parser to ignore anything within.

<script ...><!--
...
--></script>


Thanks,
Steffan Cline
[hidden email]
602-793-0014

> On Apr 29, 2017, at 8:31 PM, John Torres <[hidden email]> wrote:
>
> New to integraty JQuery into a .lasso page. I'm not understanding the following error that Lasso server is sending back on the following code. The jquery works just fine on its own, but inside of a lasso page not so much. Any ideas why the CARET "^" error?
> Error:
>
> An unhandled failure during a web request
>
> Error Code: -1
>
> Error Message: Parser error. //Library/FileMaker Server/HTTPServer/htdocs//lasso/central/hot/New_index.lasso: Error while parsing. Unexpected: CARET line: 110, col: 16
>
>
>
> <script type="text/javascript" src="/lasso/js/jquery-3.2.1.min.js"></script>
>
> <script>
>    
>    $('input[class^="Day"]').click(function() {
>        var $this = $(this);
>        if ($this.is(".Day0")) {
>            if ($(".Day0:checked").length > 0) {
>                $(".Day1").prop({ disabled: true, checked: false });
>                $(".Day2").prop({ disabled: true, checked: false });
>                $(".Day3").prop({ disabled: true, checked: false });
>            } else {
>                $(".Day1").prop("disabled", false);
>                $(".Day2").prop("disabled", false);
>                $(".Day3").prop("disabled", false);
>            }
>        } else if ($this.is(".class2")) {
>    
>    
>        }
>    });
>
> </script>
>
> #############################################################
>
> This message is sent to you because you are subscribed to
>  the mailing list Lasso [hidden email]
> Official list archives available at http://www.lassotalk.com
> To unsubscribe, E-mail to: <[hidden email]>
> Send administrative queries to  <[hidden email]>
>


#############################################################

This message is sent to you because you are subscribed to
  the mailing list Lasso [hidden email]
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <[hidden email]>
Send administrative queries to  <[hidden email]>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JQuery Error Lasso 9.3

stevepiercy
In reply to this post by John Torres-3
Lasso parses [ and ].  Either:

* move your javascript to an external file with an extension
that is not processed by Lasso (preferred)
* write [ and ] inline.  (ugly, difficult to maintain)  For example:

     $('input['[']class^="Day"[']']').click(function() {

* wrap your inline javascripts with [noprocess][/noprocess]
(easier to maintain)

--steve


On 4/29/17 at 11:31 PM, [hidden email] (John Torres) pronounced:

>New to integraty JQuery into a .lasso page. I'm not
>understanding the following error that Lasso server is sending
>back on the following code. The jquery works just fine on its
>own, but inside of a lasso page not so much. Any ideas why the
>CARET "^" error?
>Error:
>
>An unhandled failure during a web request
>
>Error Code: -1
>
>Error Message: Parser error. //Library/FileMaker
>Server/HTTPServer/htdocs//lasso/central/hot/New_index.lasso:
>Error while parsing. Unexpected: CARET line: 110, col: 16
>
>
>
><script type="text/javascript" src="/lasso/js/jquery-3.2.1.min.js"></script>
>
><script>
>
>$('input[class^="Day"]').click(function() {
>var $this = $(this);
>if ($this.is(".Day0")) {
>if ($(".Day0:checked").length > 0) {
>$(".Day1").prop({ disabled: true, checked: false });
>$(".Day2").prop({ disabled: true, checked: false });
>$(".Day3").prop({ disabled: true, checked: false });
>} else {
>$(".Day1").prop("disabled", false);
>$(".Day2").prop("disabled", false);
>$(".Day3").prop("disabled", false);
>}
>} else if ($this.is(".class2")) {
>
>
>}
>});
>
></script>
>
>#############################################################
>
>This message is sent to you because you are subscribed to
>the mailing list Lasso [hidden email]
>Official list archives available at http://www.lassotalk.com
>To unsubscribe, E-mail to: <[hidden email]>
>Send administrative queries to  <[hidden email]>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Steve Piercy              Website Builder              Soquel, CA
<[hidden email]>               <http://www.stevepiercy.com/>


#############################################################

This message is sent to you because you are subscribed to
  the mailing list Lasso [hidden email]
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <[hidden email]>
Send administrative queries to  <[hidden email]>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JQuery Error Lasso 9.3

John Torres-3
Perfect. Thanks, Steve!

John

On Apr 29, 2017, at 11:53 PM, Steve Piercy - Website Builder <[hidden email]> wrote:

> Lasso parses [ and ].  Either:
>
> * move your javascript to an external file with an extension that is not processed by Lasso (preferred)
> * write [ and ] inline.  (ugly, difficult to maintain)  For example:
>
>    $('input['[']class^="Day"[']']').click(function() {
>
> * wrap your inline javascripts with [noprocess][/noprocess] (easier to maintain)
>
> --steve
>
>
> On 4/29/17 at 11:31 PM, [hidden email] (John Torres) pronounced:
>
>> New to integraty JQuery into a .lasso page. I'm not understanding the following error that Lasso server is sending back on the following code. The jquery works just fine on its own, but inside of a lasso page not so much. Any ideas why the CARET "^" error?
>> Error:
>>
>> An unhandled failure during a web request
>>
>> Error Code: -1
>>
>> Error Message: Parser error. //Library/FileMaker Server/HTTPServer/htdocs//lasso/central/hot/New_index.lasso: Error while parsing. Unexpected: CARET line: 110, col: 16
>>
>>
>>
>> <script type="text/javascript" src="/lasso/js/jquery-3.2.1.min.js"></script>
>>
>> <script>
>>
>> $('input[class^="Day"]').click(function() {
>> var $this = $(this);
>> if ($this.is(".Day0")) {
>> if ($(".Day0:checked").length > 0) {
>> $(".Day1").prop({ disabled: true, checked: false });
>> $(".Day2").prop({ disabled: true, checked: false });
>> $(".Day3").prop({ disabled: true, checked: false });
>> } else {
>> $(".Day1").prop("disabled", false);
>> $(".Day2").prop("disabled", false);
>> $(".Day3").prop("disabled", false);
>> }
>> } else if ($this.is(".class2")) {
>>
>>
>> }
>> });
>>
>> </script>
>>
>> #############################################################
>>
>> This message is sent to you because you are subscribed to
>> the mailing list Lasso [hidden email]
>> Official list archives available at http://www.lassotalk.com
>> To unsubscribe, E-mail to: <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy              Website Builder              Soquel, CA
> <[hidden email]>               <http://www.stevepiercy.com/>
>
>
> #############################################################
>
> This message is sent to you because you are subscribed to
> the mailing list Lasso [hidden email]
> Official list archives available at http://www.lassotalk.com
> To unsubscribe, E-mail to: <[hidden email]>
> Send administrative queries to  <[hidden email]>


#############################################################

This message is sent to you because you are subscribed to
  the mailing list Lasso [hidden email]
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <[hidden email]>
Send administrative queries to  <[hidden email]>
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: JQuery Error Lasso 9.3

Jolle Carlestam-2
In reply to this post by stevepiercy
Actually, Also 9+ has an even better technique targeted for this very purpose.

Put this on top:

[no_square_brackets]

And, yes, it has to be within square brackets…

HDB
Jolle

> 30 apr. 2017 kl. 05:53 skrev Steve Piercy - Website Builder <[hidden email]>:
>
> Lasso parses [ and ].  Either:
>
> * move your javascript to an external file with an extension that is not processed by Lasso (preferred)
> * write [ and ] inline.  (ugly, difficult to maintain)  For example:
>
>    $('input['[']class^="Day"[']']').click(function() {
>
> * wrap your inline javascripts with [noprocess][/noprocess] (easier to maintain)
>
> --steve
>
>
> On 4/29/17 at 11:31 PM, [hidden email] (John Torres) pronounced:
>
>> New to integraty JQuery into a .lasso page. I'm not understanding the following error that Lasso server is sending back on the following code. The jquery works just fine on its own, but inside of a lasso page not so much. Any ideas why the CARET "^" error?
>> Error:
>>
>> An unhandled failure during a web request
>>
>> Error Code: -1
>>
>> Error Message: Parser error. //Library/FileMaker Server/HTTPServer/htdocs//lasso/central/hot/New_index.lasso: Error while parsing. Unexpected: CARET line: 110, col: 16
>>
>>
>>
>> <script type="text/javascript" src="/lasso/js/jquery-3.2.1.min.js"></script>
>>
>> <script>
>>
>> $('input[class^="Day"]').click(function() {
>> var $this = $(this);
>> if ($this.is(".Day0")) {
>> if ($(".Day0:checked").length > 0) {
>> $(".Day1").prop({ disabled: true, checked: false });
>> $(".Day2").prop({ disabled: true, checked: false });
>> $(".Day3").prop({ disabled: true, checked: false });
>> } else {
>> $(".Day1").prop("disabled", false);
>> $(".Day2").prop("disabled", false);
>> $(".Day3").prop("disabled", false);
>> }
>> } else if ($this.is(".class2")) {
>>
>>
>> }
>> });
>>
>> </script>
>>
>> #############################################################
>>
>> This message is sent to you because you are subscribed to
>> the mailing list Lasso [hidden email]
>> Official list archives available at http://www.lassotalk.com
>> To unsubscribe, E-mail to: <[hidden email]>
>> Send administrative queries to  <[hidden email]>
>
> -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
> Steve Piercy              Website Builder              Soquel, CA
> <[hidden email]>               <http://www.stevepiercy.com/>
>
>
> #############################################################
>
> This message is sent to you because you are subscribed to
> the mailing list Lasso [hidden email]
> Official list archives available at http://www.lassotalk.com
> To unsubscribe, E-mail to: <[hidden email]>
> Send administrative queries to  <[hidden email]>


#############################################################

This message is sent to you because you are subscribed to
  the mailing list Lasso [hidden email]
Official list archives available at http://www.lassotalk.com
To unsubscribe, E-mail to: <[hidden email]>
Send administrative queries to  <[hidden email]>
Loading...