What is wrong with < in script ? Hitskin_logo Hitskin.com

This is a Hitskin.com skin preview
Install the skinReturn to the skin page

The forum of the forums
Would you like to react to this message? Create an account in a few clicks or log in to continue.
3 posters

    What is wrong with < in script ?

    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress What is wrong with < in script ?

    Post by TamDonCo August 30th 2016, 4:15 pm

    the script file does not accept less than sign (<) whenever I change to < , script errors


    ERROR
    What is wrong with < in script ? 8uP


    NO ERROR
    What is wrong with < in script ? 8u9
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    In progress Re: What is wrong with < in script ?

    Post by Ange Tuteur August 30th 2016, 4:41 pm

    Hi @TamDonCo,

    I didn't manage to replicate an error on my end. Then again I was doing it in the HTML pages, is that where you were getting the error ? Think

    Try placing the content of your script in a CDATA section :
    Code:
    //<![CDATA[
    // JAVASCRIPT HERE
    //]]>

    Here's my example script using CDATA :
    Code:
    <script type="text/javascript">//<![CDATA[
    (function() {
      var a = 5,
          b = 6;
     
      if (a && b && window.console) {
     
        if (a < b) {
          console.log('Lesser');
        } else {
          console.log('Greater');
        }
     
      }
     
    }());
    //]]></script>

    Here's a topic on CDATA :
    http://stackoverflow.com/questions/7092236/what-is-cdata-in-html
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo August 30th 2016, 5:59 pm

    Thanks Ange Tuteur

    Let me try later
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo August 30th 2016, 10:24 pm

    hi Ange Tuteur

    just update

    it still has error

    when I do

    <script src=.......link here> < / script>

    it works fine but I copy the contents and paste into file to run local and it has error

    SLGray
    SLGray
    Administrator
    Administrator


    Male Posts : 51499
    Reputation : 3523
    Language : English
    Location : United States

    In progress Re: What is wrong with < in script ?

    Post by SLGray August 31st 2016, 2:57 am

    Where are you adding this code?



    What is wrong with < in script ? Slgray10

    When your topic has been solved, ensure you mark the topic solved.
    Never post your email in public.
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo August 31st 2016, 2:34 pm

    SLGray wrote:Where are you adding this code?

    overall_footer_end
    Ange Tuteur
    Ange Tuteur
    Forumaster


    Male Posts : 13207
    Reputation : 3000
    Language : English & 日本語
    Location : Pennsylvania

    In progress Re: What is wrong with < in script ?

    Post by Ange Tuteur August 31st 2016, 5:58 pm

    @TamDonCo would it be possible for you to post the code here so that we may look over it ?
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo August 31st 2016, 6:09 pm

    Ange Tuteur wrote:@TamDonCo would it be possible for you to post the code here so that we may look over it ?

    Yes I can but it 's very long script .. is it OK
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo August 31st 2016, 6:56 pm

    I can not post , it says "The posted message is too long."
    SLGray
    SLGray
    Administrator
    Administrator


    Male Posts : 51499
    Reputation : 3523
    Language : English
    Location : United States

    In progress Re: What is wrong with < in script ?

    Post by SLGray August 31st 2016, 8:59 pm

    You can post it in 2 posts.



    What is wrong with < in script ? Slgray10

    When your topic has been solved, ensure you mark the topic solved.
    Never post your email in public.
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo September 1st 2016, 12:00 am

    SLGray
    SLGray
    Administrator
    Administrator


    Male Posts : 51499
    Reputation : 3523
    Language : English
    Location : United States

    In progress Re: What is wrong with < in script ?

    Post by SLGray September 1st 2016, 3:28 am

    Could you post a screenshot of the error message you get?



    What is wrong with < in script ? Slgray10

    When your topic has been solved, ensure you mark the topic solved.
    Never post your email in public.
    TamDonCo
    TamDonCo
    Forumember


    Posts : 427
    Reputation : 2
    Language : English

    In progress Re: What is wrong with < in script ?

    Post by TamDonCo September 1st 2016, 3:57 am

    This is no screen shot, this works backgroud, it lets user to type in Vietnamese because Vietname has accents such as á , à , ư , ủ ... etc.

    the above link works well when you put in <script scr= ..... > < / script>
    SLGray
    SLGray
    Administrator
    Administrator


    Male Posts : 51499
    Reputation : 3523
    Language : English
    Location : United States

    In progress Re: What is wrong with < in script ?

    Post by SLGray September 1st 2016, 5:25 am

    Maybe I do not understand the purpose of this for your forum. You can set your language in your profiles and forum for Vietnamese.



    What is wrong with < in script ? Slgray10

    When your topic has been solved, ensure you mark the topic solved.
    Never post your email in public.