Announcement

Collapse
No announcement yet.

Global variable truncated if the value contains "&" character

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Global variable truncated if the value contains "&" character

    This happened when I linked html image with any control app or blank app then in the control/blank the global variable got truncated.

    E.g., [customer]='H&M' then the value becoming 'H' in the blank.

    Is there any way to resolve this?

    Thanks & Regards
    Rajibul
    __________________
    S. M. Rajibul Huda
    CEO & Founder
    www.efficienterp.com

  • #2
    Originally posted by rajibul View Post
    This happened when I linked html image with any control app or blank app then in the control/blank the global variable got truncated.

    E.g., [customer]='H&M' then the value becoming 'H' in the blank.

    Is there any way to resolve this?

    Thanks & Regards
    Rajibul
    Use 'H\&M'
    Dave Prue
    Code Whisperer
    Lahar International Corp
    www.lahar.net

    Comment


    • #3
      Hi Dave Prue,

      Thank you, but it won't work!.
      __________________
      S. M. Rajibul Huda
      CEO & Founder
      www.efficienterp.com

      Comment


      • #4
        Originally posted by rajibul View Post
        Hi Dave Prue,

        Thank you, but it won't work!.
        Just curious. Try...
        PHP Code:
        $cust "H&M";
        [
        customer] = "'".$cust."'"
        /Giuseppe

        Professional Scriptcase Services
        Some Customers opinions

        Comment


        • #5
          Hi Giu,

          Now it becomes 'H !
          __________________
          S. M. Rajibul Huda
          CEO & Founder
          www.efficienterp.com

          Comment


          • #6
            Originally posted by rajibul View Post
            Hi Giu,

            Now it becomes 'H !
            Try replacing the & with &
            EDIT: Actually assuming that works for showing it but I'm not completely certain what you're wanting to do with the variable.
            In case it's not just for showing it on a page somewhere you might want to make a small converter function to convert all &'s to 'something', then one to convert all 'something' back to &'s

            EDIT2: Actually just starting thinking it might be because your global is being get through GET or POST and I think the syntax for those might use the & for something, so maybe setting the global to a SESSION global would work out better.

            EDIT3: Nevermind, I'm unable to reproduce te problem, would you mind giving some more detail as to what all you're doing with the global variable and maybe what SC version you're running?
            Last edited by hoihoi661; 04-15-2015, 06:07 AM.

            Comment


            • #7
              Hi,

              Please, explain more how you did.

              How you link the application? you use the macro sc_redir or you created a link in side menu Link?

              How are you using this global variable?
              how you passed and how get the variable?
              We wait your reply.

              --
              best regard
              Netmake Team

              Comment


              • #8
                Any news about this problem?
                Best Regards,
                John L. Santos

                Bug Tracker Team
                NetMake - IT Solutions

                Comment


                • #9
                  John, what should we say ?

                  Tihs is a character setting problem through all applications

                  Comment


                  • #10
                    Originally posted by Gerd Dietrich View Post
                    John, what should we say ?

                    Tihs is a character setting problem through all applications

                    In my view, Arthur called for more information about this problem, but no one answered yet.
                    So I asked if there was any news, because I'm working to solve all the problems of the forum and thus help all of you.
                    Best Regards,
                    John L. Santos

                    Bug Tracker Team
                    NetMake - IT Solutions

                    Comment


                    • #11
                      Hi,

                      We can't simulate this problem.

                      can you explain more?

                      I created two application, a form and other control.
                      In control application I used in onLoad event echo [variable];
                      just to see the value.
                      in form application I use in onLoad [x] = 'H&M';

                      So,I created in the form application a Image HTML field and linked to control application. in parameters, I set that [variable] will get [x] value.

                      see images:

                      onloadControl.png

                      OnloadForm.png

                      variable.png

                      result.png


                      did you make this way?

                      --
                      Best regard
                      Netmake team

                      Comment

                      Working...
                      X