Session Variable gets truncated and drives me crazy

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • doltharz

    Session Variable gets truncated and drives me crazy

    Please Help me

    i'm doing something i though was to be REALLY EASY but it drives me
    crazy

    The complete code is at the end of the email
    (i mean newsgroup article),

    i always use Option Explicit
    and Response.Expire s=-1,
    there is NO INCLUDE at all,
    no side effect from any other asp page,
    no global.asa of nothing like that.
    It's on MY IIS 5 server
    hosted on a Win2000 server SP3.
    I'm using IE6-SP1

    Here it goes for step by step explanation:

    I call http://192.168.0.102/Page.asp&driving=me&crazy=true

    I write down session variable content

    Response.Write Session("Doltha rzURL") & "<BR>"
    <!-- THE NEXT LINE IS REALLY BLANK -->

    (( Till it's the first time, there is nothing here ))

    <!-- THE PREVIOUS LINE IS REALLY BLANK -->
    i put the current page address with its querystring in a session
    variable

    Dim tmp
    tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
    Request.ServerV ariables("QUERY _STRING") & ""
    Session("Doltha rzURL") = tmp & ""

    The & "" at the end is to be sure the data is really a string and not
    a reference to an object even if it's not necessary till it's already
    a concatenation of something else... too much can't hurt.

    Then i write down session variable content, just to be sure it's realy
    in the session variable and it's really there.

    Response.Write Session("Doltha rzURL") & "<BR>"

    /Page.asp?drivin g=me&crazy=true

    Then i REOPEN the SAME page which does write down the session variable
    content

    Response.Write Session("Doltha rzURL") & "<BR>"

    /Page.asp?

    Why is the querystring gone??????????? ?

    Even stranger, if i set the Session Variable content this way
    Session("Doltha rzURL") = "BEGIN" & tmp & "END"
    I'll end up with
    BEGIN/Page.asp?END
    Even if all the time Response.Write folling the Session Variable
    content definition gives me the right content

    Going even further, i manually set the content to
    "/Page.asp?drivin g=me&crazy=true "
    without calling any other function (ServerVariable s) and here it's
    working fine.

    So i said to myself, there is a {BEEP} \0 at the end of that {BEEP}
    Request.ServerV ariables("")^so i've type a function that write down
    the content of the string byte by byte giving all ascii code...

    <%
    For i = 1 to len(arg)
    Response.Write i & ", " & mid(arg,i,1) & ", " & asc(mid(arg,i,1 ))
    & "<BR>"
    next
    %>

    it gives me (fake one)

    1, /, 47
    2, p, 99
    3, a, 115
    4, g, 115
    5, e, 116
    6, .
    7, a
    8, s
    9, p
    10, ?
    11, d
    12, r
    13, i
    14, v
    15, i
    16, n
    17, g
    18, =
    19, m
    20, e
    21, &
    22, c
    23, r
    24, a
    25, z
    26, y
    27, =
    28, t
    29, r
    30, u
    31, e

    with no gap in the char count 1..2..3..4..5.. ... ..31..32
    there is no \o between "/page.asp?" and "Drime=me&Crazy =true"
    So i though it was the "?" so i replace it by "XYZ" to end up with
    /Page.aspXYZ

    The variable is called DoltharzURL which i assumed isn't a reserved
    keyword, if it is... i'm a very lucky guy.

    Please Help me

    <%
    'Rem * * * CALL THIS PAGE TWICE WITH TWO ARGs ON THE QUERYSTRING
    'Rem * * * e.g.: Page.asp?arg1=v alue1&arg2=valu e2

    Dim tmp
    tmp = Session("Doltha rzURL")
    Response.Write "tmp=" & tmp & "<BR>"
    Response.Write Session("Doltha rzURL") & "<BR>"
    Response.Write Session.Session ID & "<BR>"

    tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
    Request.ServerV ariables("QUERY _STRING") & ""

    Session("Doltha rzURL") = tmp & ""
    Response.Write "tmp=" & tmp & "<BR>"
    Response.Write Session("Doltha rzURL") & "<BR>"
    Response.Write Session.Session ID & "<BR>"

    %>


    Reply to both my personnal email and this group...

    doltharz at hotmail dot com

    I'm not a GURU nor an EXPERT or something like that.
    I'm just a passionnate programmer.

    Doltharz
  • Julian

    #2
    Re: Session Variable gets truncated and drives me crazy

    Hi

    It seems we have the same problem, read my post (4 posting below you) "the
    value of session variables gets lost". It is a strange problem.

    "doltharz" <doltharz@hotma il.com> wrote in message
    news:n88kivoh3d 1pk3ipnt6in47hp ura1pll3l@4ax.c om...[color=blue]
    > Please Help me
    >
    > i'm doing something i though was to be REALLY EASY but it drives me
    > crazy
    >
    > The complete code is at the end of the email
    > (i mean newsgroup article),
    >
    > i always use Option Explicit
    > and Response.Expire s=-1,
    > there is NO INCLUDE at all,
    > no side effect from any other asp page,
    > no global.asa of nothing like that.
    > It's on MY IIS 5 server
    > hosted on a Win2000 server SP3.
    > I'm using IE6-SP1
    >
    > Here it goes for step by step explanation:
    >
    > I call http://192.168.0.102/Page.asp&driving=me&crazy=true
    >
    > I write down session variable content
    >
    > Response.Write Session("Doltha rzURL") & "<BR>"
    > <!-- THE NEXT LINE IS REALLY BLANK -->
    >
    > (( Till it's the first time, there is nothing here ))
    >
    > <!-- THE PREVIOUS LINE IS REALLY BLANK -->
    > i put the current page address with its querystring in a session
    > variable
    >
    > Dim tmp
    > tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
    > Request.ServerV ariables("QUERY _STRING") & ""
    > Session("Doltha rzURL") = tmp & ""
    >
    > The & "" at the end is to be sure the data is really a string and not
    > a reference to an object even if it's not necessary till it's already
    > a concatenation of something else... too much can't hurt.
    >
    > Then i write down session variable content, just to be sure it's realy
    > in the session variable and it's really there.
    >
    > Response.Write Session("Doltha rzURL") & "<BR>"
    >
    > /Page.asp?drivin g=me&crazy=true
    >
    > Then i REOPEN the SAME page which does write down the session variable
    > content
    >
    > Response.Write Session("Doltha rzURL") & "<BR>"
    >
    > /Page.asp?
    >
    > Why is the querystring gone??????????? ?
    >
    > Even stranger, if i set the Session Variable content this way
    > Session("Doltha rzURL") = "BEGIN" & tmp & "END"
    > I'll end up with
    > BEGIN/Page.asp?END
    > Even if all the time Response.Write folling the Session Variable
    > content definition gives me the right content
    >
    > Going even further, i manually set the content to
    > "/Page.asp?drivin g=me&crazy=true "
    > without calling any other function (ServerVariable s) and here it's
    > working fine.
    >
    > So i said to myself, there is a {BEEP} \0 at the end of that {BEEP}
    > Request.ServerV ariables("")^so i've type a function that write down
    > the content of the string byte by byte giving all ascii code...
    >
    > <%
    > For i = 1 to len(arg)
    > Response.Write i & ", " & mid(arg,i,1) & ", " & asc(mid(arg,i,1 ))
    > & "<BR>"
    > next
    > %>
    >
    > it gives me (fake one)
    >
    > 1, /, 47
    > 2, p, 99
    > 3, a, 115
    > 4, g, 115
    > 5, e, 116
    > 6, .
    > 7, a
    > 8, s
    > 9, p
    > 10, ?
    > 11, d
    > 12, r
    > 13, i
    > 14, v
    > 15, i
    > 16, n
    > 17, g
    > 18, =
    > 19, m
    > 20, e
    > 21, &
    > 22, c
    > 23, r
    > 24, a
    > 25, z
    > 26, y
    > 27, =
    > 28, t
    > 29, r
    > 30, u
    > 31, e
    >
    > with no gap in the char count 1..2..3..4..5.. ... ..31..32
    > there is no \o between "/page.asp?" and "Drime=me&Crazy =true"
    > So i though it was the "?" so i replace it by "XYZ" to end up with
    > /Page.aspXYZ
    >
    > The variable is called DoltharzURL which i assumed isn't a reserved
    > keyword, if it is... i'm a very lucky guy.
    >
    > Please Help me
    >
    > <%
    > 'Rem * * * CALL THIS PAGE TWICE WITH TWO ARGs ON THE QUERYSTRING
    > 'Rem * * * e.g.: Page.asp?arg1=v alue1&arg2=valu e2
    >
    > Dim tmp
    > tmp = Session("Doltha rzURL")
    > Response.Write "tmp=" & tmp & "<BR>"
    > Response.Write Session("Doltha rzURL") & "<BR>"
    > Response.Write Session.Session ID & "<BR>"
    >
    > tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
    > Request.ServerV ariables("QUERY _STRING") & ""
    >
    > Session("Doltha rzURL") = tmp & ""
    > Response.Write "tmp=" & tmp & "<BR>"
    > Response.Write Session("Doltha rzURL") & "<BR>"
    > Response.Write Session.Session ID & "<BR>"
    >
    > %>
    >
    >
    > Reply to both my personnal email and this group...
    >
    > doltharz at hotmail dot com
    >
    > I'm not a GURU nor an EXPERT or something like that.
    > I'm just a passionnate programmer.
    >
    > Doltharz[/color]


    Comment

    • Bob Barrows

      #3
      Re: Session Variable gets truncated and drives me crazy

      Julian wrote:[color=blue]
      > Hi
      >
      > It seems we have the same problem, read my post (4 posting below you)
      > "the value of session variables gets lost". It is a strange problem.
      >
      > "doltharz" <doltharz@hotma il.com> wrote in message
      > news:n88kivoh3d 1pk3ipnt6in47hp ura1pll3l@4ax.c om...[color=green]
      >> Please Help me
      >>
      >> i'm doing something i though was to be REALLY EASY but it drives me
      >> crazy
      >>
      >> The complete code is at the end of the email
      >> (i mean newsgroup article),
      >>
      >> i always use Option Explicit
      >> and Response.Expire s=-1,
      >> there is NO INCLUDE at all,
      >> no side effect from any other asp page,
      >> no global.asa of nothing like that.
      >> It's on MY IIS 5 server
      >> hosted on a Win2000 server SP3.
      >> I'm using IE6-SP1
      >>
      >> Here it goes for step by step explanation:
      >>
      >> I call http://192.168.0.102/Page.asp&driving=me&crazy=true[/color][/color]

      Is this a typo? It should be:


      Bob Barrows



      Comment

      • doltharz

        #4
        Re: Session Variable gets truncated and drives me crazy

        To drive me a little bit more craze but maybe to help some of you to
        pin point the problem:

        Remember that those are not scientific bullet proof copy/pasted code
        but human typed article... dont flame if a typo makes it way to you.




        This one works when not using the QUERY_STRING
        "/page.asp?80" makes it way
        <%
        Dim tmp
        tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
        Request.ServerV ariables("SERVE R_PORT") & ""
        Session("Doltha rzURL") = tmp & ""
        %>

        This one doesn't work when using the QUERY_STRING
        Only a "/Page.asp?" makes it way
        <%
        Dim tmp
        tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
        Request.ServerV ariables("QUERY _STRING") & ""
        Session("Doltha rzURL") = tmp & ""
        %>

        This one doesn't work when using the QUERY_STRING
        Only a "?" makes it way
        <%
        Dim tmp
        tmp = "?" & Request.ServerV ariables("QUERY _STRING") & ""
        Session("Doltha rzURL") = tmp & ""
        %>

        Maybe the problem is the QUERY_STRING server variable and not the
        Session Variable.

        Hope that helps those who are tring to help us ;)

        Doltharz

        On Fri, 01 Aug 2003 05:04:40 -0400, doltharz <doltharz@hotma il.com>
        wrote:
        [color=blue]
        >Please Help me
        >
        >i'm doing something i though was to be REALLY EASY but it drives me
        >crazy
        >
        >The complete code is at the end of the email
        >(i mean newsgroup article),
        >
        >i always use Option Explicit
        >and Response.Expire s=-1,
        >there is NO INCLUDE at all,
        >no side effect from any other asp page,
        >no global.asa of nothing like that.
        >It's on MY IIS 5 server
        >hosted on a Win2000 server SP3.
        >I'm using IE6-SP1
        >
        >Here it goes for step by step explanation:
        >
        >I call http://192.168.0.102/Page.asp&driving=me&crazy=true
        >
        >I write down session variable content
        >
        >Response.Wri te Session("Doltha rzURL") & "<BR>"
        ><!-- THE NEXT LINE IS REALLY BLANK -->
        >
        > (( Till it's the first time, there is nothing here ))
        >
        ><!-- THE PREVIOUS LINE IS REALLY BLANK -->
        >i put the current page address with its querystring in a session
        >variable
        >
        >Dim tmp
        >tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
        >Request.Server Variables("QUER Y_STRING") & ""
        >Session("Dolth arzURL") = tmp & ""
        >
        >The & "" at the end is to be sure the data is really a string and not
        >a reference to an object even if it's not necessary till it's already
        >a concatenation of something else... too much can't hurt.
        >
        >Then i write down session variable content, just to be sure it's realy
        >in the session variable and it's really there.
        >
        >Response.Wri te Session("Doltha rzURL") & "<BR>"
        >
        >/Page.asp?drivin g=me&crazy=true
        >
        >Then i REOPEN the SAME page which does write down the session variable
        >content
        >
        >Response.Wri te Session("Doltha rzURL") & "<BR>"
        >
        >/Page.asp?
        >
        >Why is the querystring gone??????????? ?
        >
        >Even stranger, if i set the Session Variable content this way
        >Session("Dolth arzURL") = "BEGIN" & tmp & "END"
        >I'll end up with
        >BEGIN/Page.asp?END
        >Even if all the time Response.Write folling the Session Variable
        >content definition gives me the right content
        >
        >Going even further, i manually set the content to
        >"/Page.asp?drivin g=me&crazy=true "
        >without calling any other function (ServerVariable s) and here it's
        >working fine.
        >
        >So i said to myself, there is a {BEEP} \0 at the end of that {BEEP}
        >Request.Server Variables("")^s o i've type a function that write down
        >the content of the string byte by byte giving all ascii code...
        >
        ><%
        > For i = 1 to len(arg)
        > Response.Write i & ", " & mid(arg,i,1) & ", " & asc(mid(arg,i,1 ))
        >& "<BR>"
        > next
        >%>
        >
        >it gives me (fake one)
        >
        >1, /, 47
        >2, p, 99
        >3, a, 115
        >4, g, 115
        >5, e, 116
        >6, .
        >7, a
        >8, s
        >9, p
        >10, ?
        >11, d
        >12, r
        >13, i
        >14, v
        >15, i
        >16, n
        >17, g
        >18, =
        >19, m
        >20, e
        >21, &
        >22, c
        >23, r
        >24, a
        >25, z
        >26, y
        >27, =
        >28, t
        >29, r
        >30, u
        >31, e
        >
        >with no gap in the char count 1..2..3..4..5.. ... ..31..32
        >there is no \o between "/page.asp?" and "Drime=me&Crazy =true"
        >So i though it was the "?" so i replace it by "XYZ" to end up with
        >/Page.aspXYZ
        >
        >The variable is called DoltharzURL which i assumed isn't a reserved
        >keyword, if it is... i'm a very lucky guy.
        >
        >Please Help me
        >
        ><%
        > 'Rem * * * CALL THIS PAGE TWICE WITH TWO ARGs ON THE QUERYSTRING
        > 'Rem * * * e.g.: Page.asp?arg1=v alue1&arg2=valu e2
        >
        > Dim tmp
        > tmp = Session("Doltha rzURL")
        > Response.Write "tmp=" & tmp & "<BR>"
        > Response.Write Session("Doltha rzURL") & "<BR>"
        > Response.Write Session.Session ID & "<BR>"
        >
        > tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
        >Request.Server Variables("QUER Y_STRING") & ""
        >
        > Session("Doltha rzURL") = tmp & ""
        > Response.Write "tmp=" & tmp & "<BR>"
        > Response.Write Session("Doltha rzURL") & "<BR>"
        > Response.Write Session.Session ID & "<BR>"
        >
        >%>
        >
        >
        >Reply to both my personnal email and this group...
        >
        >doltharz at hotmail dot com
        >
        >I'm not a GURU nor an EXPERT or something like that.
        >I'm just a passionnate programmer.
        >
        >Doltharz[/color]


        I'm not a GURU nor an EXPERT or something like that.
        I'm just a passionnate programmer.

        Doltharz

        Comment

        • Michael D. Kersey

          #5
          Re: Session Variable gets truncated and drives me crazy

          Have you tried "View Source" in the browser? Sometimes, because of HTML
          formatting issues, the output of an ASP page differs from what the
          browser presents.

          Good Luck,
          Michael D. Kersey

          Comment

          • Bob Barrows

            #6
            Re: Session Variable gets truncated and drives me crazy

            I called it 5 times - no difference.
            doltharz wrote:[color=blue]
            > You need to call the page TWICE.
            > The second time, the session variable content is not what it is
            > expected (for me)
            >
            > it's not a formatting issue but really a "NON EXISTANCE" issue
            > it's a wise guess till & is an escape code but... already checked that
            > one... thanks...
            >
            > &param2=somethi ng produces something like
            > ¶m2=something
            >
            > It seems that only ServerVariables ("QUERY_STRING" ) produces that ,
            > i've tried with some others like SERVER_PORT or SCRIPT_NAME
            >
            > Doltharz
            >
            > On Sat, 2 Aug 2003 17:15:45 -0400, "Bob Barrows" <reb_01501@yaho o.com>
            > wrote:
            >[color=green]
            >> I don't know what to tell you. The following code seemed to work
            >> perfectly for me:
            >>
            >> <%
            >> option explicit
            >> Response.Expire s=-1
            >> 'Rem * * * CALL THIS PAGE TWICE WITH TWO ARGs ON THE QUERYSTRING
            >> 'Rem * * * e.g.: Page.asp?arg1=v alue1&arg2=valu e2
            >>
            >> Dim tmp
            >> tmp = Session("Doltha rzURL")
            >> Response.Write "tmp=" & tmp & "<BR>"
            >> Response.Write Session("Doltha rzURL") & "<BR>"
            >> Response.Write Session.Session ID & "<BR>"
            >>
            >> tmp = Request.ServerV ariables("SCRIP T_NAME") & _
            >> "?" & Request.ServerV ariables("QUERY _STRING") & ""
            >>
            >> Session("Doltha rzURL") = tmp & ""
            >> Response.Write "tmp=" & tmp & "<BR>"
            >> Response.Write Session("Doltha rzURL") & "<BR>"
            >> Response.Write Session.Session ID & "<BR>"
            >> 'Response.End
            >> %>
            >> <HTML><BODY>
            >> <A href="<%=Sessio n("DoltharzURL" )%>">Click Here</A>
            >> </BODY></HTML>
            >>[/color]
            >
            >
            > I'm not a GURU nor an EXPERT or something like that.
            > I'm just a passionnate programmer.
            >
            > Doltharz[/color]



            Comment

            • doltharz

              #7
              Re: Session Variable gets truncated and drives me crazy

              Can you give me your IIS, OS Version and SP info?

              On Sat, 2 Aug 2003 20:18:18 -0400, "Bob Barrows" <reb_01501@yaho o.com>
              wrote:
              [color=blue]
              >I called it 5 times - no difference.
              >doltharz wrote:[color=green]
              >> You need to call the page TWICE.
              >> The second time, the session variable content is not what it is
              >> expected (for me)
              >>
              >> it's not a formatting issue but really a "NON EXISTANCE" issue
              >> it's a wise guess till & is an escape code but... already checked that
              >> one... thanks...
              >>
              >> &param2=somethi ng produces something like
              >> ¶m2=something
              >>
              >> It seems that only ServerVariables ("QUERY_STRING" ) produces that ,
              >> i've tried with some others like SERVER_PORT or SCRIPT_NAME
              >>
              >> Doltharz
              >>
              >> On Sat, 2 Aug 2003 17:15:45 -0400, "Bob Barrows" <reb_01501@yaho o.com>
              >> wrote:
              >>[color=darkred]
              >>> I don't know what to tell you. The following code seemed to work
              >>> perfectly for me:
              >>>
              >>> <%
              >>> option explicit
              >>> Response.Expire s=-1
              >>> 'Rem * * * CALL THIS PAGE TWICE WITH TWO ARGs ON THE QUERYSTRING
              >>> 'Rem * * * e.g.: Page.asp?arg1=v alue1&arg2=valu e2
              >>>
              >>> Dim tmp
              >>> tmp = Session("Doltha rzURL")
              >>> Response.Write "tmp=" & tmp & "<BR>"
              >>> Response.Write Session("Doltha rzURL") & "<BR>"
              >>> Response.Write Session.Session ID & "<BR>"
              >>>
              >>> tmp = Request.ServerV ariables("SCRIP T_NAME") & _
              >>> "?" & Request.ServerV ariables("QUERY _STRING") & ""
              >>>
              >>> Session("Doltha rzURL") = tmp & ""
              >>> Response.Write "tmp=" & tmp & "<BR>"
              >>> Response.Write Session("Doltha rzURL") & "<BR>"
              >>> Response.Write Session.Session ID & "<BR>"
              >>> 'Response.End
              >>> %>
              >>> <HTML><BODY>
              >>> <A href="<%=Sessio n("DoltharzURL" )%>">Click Here</A>
              >>> </BODY></HTML>
              >>>[/color]
              >>
              >>
              >> I'm not a GURU nor an EXPERT or something like that.
              >> I'm just a passionnate programmer.
              >>
              >> Doltharz[/color]
              >
              >[/color]


              I'm not a GURU nor an EXPERT or something like that.
              I'm just a passionnate programmer.

              Doltharz

              Comment

              • doltharz

                #8
                Re: Session Variable gets truncated and drives me crazy

                after more tests
                i realised the probleme only occured when there is some HTML code
                before the critical code and only with ServerVariables ("query_string" )

                take a look at this sample

                try it with and without the HTML code

                %>
                <!DOCTYPE>
                ....
                <BODY BGCOL...>
                <%

                = Code goes here = = = = = = = = = = = = = = = = = = = = = = = = = = =

                <%
                Option Explicit
                Response.Expire s=-1
                %>
                <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
                <HTML>
                <HEAD>
                <TITLE></TITLE>
                <META NAME="Generator " CONTENT="TextPa d 4.6">
                <META NAME="Author" CONTENT="?">
                <META NAME="Keywords" CONTENT="?">
                <META NAME="Descripti on" CONTENT="?">
                </HEAD>

                <BODY BGCOLOR="#FFFFF F" TEXT="#000000" LINK="#FF0000" VLINK="#800000"
                ALINK="#FF00FF" BACKGROUND="?">

                <%

                Dim tmp
                tmp = Session("Doltha rzURL")
                Response.Write "tmp=" & tmp & "<BR>"
                Response.Write Session("Doltha rzURL") & "<BR>"
                Response.Write Session.Session ID & "<BR>"

                'tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
                Request.ServerV ariables("QUERY _STRING") & ""
                tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" _
                & Request.ServerV ariables("QUERY _STRING") & ""

                Session("Doltha rzURL") = tmp & ""
                Response.Write "tmp=" & tmp & "<BR>"
                Response.Write Session("Doltha rzURL") & "<BR>"
                Response.Write Session.Session ID & "<BR>"

                %>

                </BODY>
                </HTML>

                = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =



                I'm not a GURU nor an EXPERT or something like that.
                I'm just a passionnate programmer.

                Doltharz

                Comment

                • Bob Barrows

                  #9
                  Re: Session Variable gets truncated and drives me crazy

                  I'm not sure what you mean by "HTML code". Show us the version that works,
                  followed by the version that doesn't work. I know that will make the post
                  much longer, but it will eliminate the guesswork.

                  Bob


                  doltharz wrote:[color=blue]
                  > after more tests
                  > i realised the probleme only occured when there is some HTML code
                  > before the critical code and only with ServerVariables ("query_string" )
                  >
                  > take a look at this sample
                  >
                  > try it with and without the HTML code
                  >
                  > %>
                  > <!DOCTYPE>
                  > ...
                  > <BODY BGCOL...>
                  > <%
                  >
                  > = Code goes here = = = = = = = = = = = = = = = = = = = = = = = = = = =
                  >
                  > <%
                  > Option Explicit
                  > Response.Expire s=-1
                  > %>
                  > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
                  > <HTML>
                  > <HEAD>
                  > <TITLE></TITLE>
                  > <META NAME="Generator " CONTENT="TextPa d 4.6">
                  > <META NAME="Author" CONTENT="?">
                  > <META NAME="Keywords" CONTENT="?">
                  > <META NAME="Descripti on" CONTENT="?">
                  > </HEAD>
                  >
                  > <BODY BGCOLOR="#FFFFF F" TEXT="#000000" LINK="#FF0000" VLINK="#800000"
                  > ALINK="#FF00FF" BACKGROUND="?">
                  >
                  > <%
                  >
                  > Dim tmp
                  > tmp = Session("Doltha rzURL")
                  > Response.Write "tmp=" & tmp & "<BR>"
                  > Response.Write Session("Doltha rzURL") & "<BR>"
                  > Response.Write Session.Session ID & "<BR>"
                  >
                  > 'tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" &
                  > Request.ServerV ariables("QUERY _STRING") & ""
                  > tmp = Request.ServerV ariables("SCRIP T_NAME") & "?" _
                  > & Request.ServerV ariables("QUERY _STRING") & ""
                  >
                  > Session("Doltha rzURL") = tmp & ""
                  > Response.Write "tmp=" & tmp & "<BR>"
                  > Response.Write Session("Doltha rzURL") & "<BR>"
                  > Response.Write Session.Session ID & "<BR>"
                  >
                  > %>
                  >
                  > </BODY>
                  > </HTML>
                  >
                  > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                  >
                  >
                  >
                  > I'm not a GURU nor an EXPERT or something like that.
                  > I'm just a passionnate programmer.
                  >
                  > Doltharz[/color]



                  Comment

                  • Bob Barrows

                    #10
                    Re: Session Variable gets truncated and drives me crazy

                    OK - this got to me too late for me to do anything with it today. What I
                    would suggest is that you remove lines one-by-one from the page that does
                    not work until you discover exactly which line is causeing it to fail. I
                    suspect that it's that DOCTYPE line, myself. Any idea why you need that one?

                    Bob Barrows

                    doltharz wrote:[color=blue]
                    > Remember to call each page at least twice to affect and see the
                    > session variable on another instance of the same page.
                    >
                    > /Page.asp?query= string&contains =something
                    >
                    > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                    > = This one works
                    > = /Page.asp?query= string&contains =something
                    > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                    >
                    > <%
                    > Option Explicit
                    > Response.Expire s=-1
                    >
                    > Dim tmp
                    > tmp = Session("Doltha rzURL")
                    > Response.Write "tmp=" & tmp & "<BR>"
                    > Response.Write Session("Doltha rzURL") & "<BR>"
                    > Response.Write Session.Session ID & "<BR>"
                    >
                    > tmp = Request.ServerV ariables("SCRIP T_NAME") & _
                    > "?" & Request.ServerV ariables("QUERY _STRING") & ""
                    >
                    > Session("Doltha rzURL") = tmp & ""
                    > Response.Write "tmp=" & tmp & "<BR>"
                    > Response.Write Session("Doltha rzURL") & "<BR>"
                    > Response.Write Session.Session ID & "<BR>"
                    > %>
                    >
                    > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                    > = And this one doesn't
                    > = /Page2.asp?query =string&contain s=something
                    > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                    >
                    >
                    > <%
                    > Option Explicit
                    > Response.Expire s=-1
                    > %>
                    >
                    > <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
                    > <HTML>
                    > <HEAD>
                    > <TITLE></TITLE>
                    > <META NAME="Generator " CONTENT="TextPa d 4.6">
                    > <META NAME="Author" CONTENT="?">
                    > <META NAME="Keywords" CONTENT="?">
                    > <META NAME="Descripti on" CONTENT="?">
                    > </HEAD>
                    >
                    > <BODY BGCOLOR="#FFFFF F" TEXT="#000000" LINK="#FF0000" VLINK="#800000"
                    > ALINK="#FF00FF" BACKGROUND="?">
                    >
                    > <%
                    > Dim tmp
                    > tmp = Session("Doltha rzURL")
                    > Response.Write "tmp=" & tmp & "<BR>"
                    > Response.Write Session("Doltha rzURL") & "<BR>"
                    > Response.Write Session.Session ID & "<BR>"
                    >
                    > tmp = Request.ServerV ariables("SCRIP T_NAME") & _
                    > "?" & Request.ServerV ariables("QUERY _STRING") & ""
                    >
                    > Session("Doltha rzURL") = tmp & ""
                    > Response.Write "tmp=" & tmp & "<BR>"
                    > Response.Write Session("Doltha rzURL") & "<BR>"
                    > Response.Write Session.Session ID & "<BR>"
                    > %>
                    >
                    > </BODY>
                    > </HTML>
                    >
                    > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                    > = I'm not a GURU nor an EXPERT or something like that.
                    > = I'm just a passionnate programmer.
                    > =
                    > = Doltharz
                    > = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =[/color]



                    Comment

                    • doltharz

                      #11
                      Re: Session Variable gets truncated and drives me crazy

                      it's included in the TextPad blank page pattern and i was also willing
                      to create a CSS/W3C Validated Page.


                      On Sun, 3 Aug 2003 17:19:16 -0400, "Bob Barrows" <reb_01501@yaho o.com>
                      wrote:
                      [color=blue]
                      >OK - this got to me too late for me to do anything with it today. What I
                      >would suggest is that you remove lines one-by-one from the page that does
                      >not work until you discover exactly which line is causeing it to fail. I
                      >suspect that it's that DOCTYPE line, myself. Any idea why you need that one?
                      >
                      >Bob Barrows
                      >
                      >doltharz wrote:[color=green]
                      >> Remember to call each page at least twice to affect and see the
                      >> session variable on another instance of the same page.
                      >>
                      >> /Page.asp?query= string&contains =something
                      >>
                      >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                      >> = This one works
                      >> = /Page.asp?query= string&contains =something
                      >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                      >>
                      >> <%
                      >> Option Explicit
                      >> Response.Expire s=-1
                      >>
                      >> Dim tmp
                      >> tmp = Session("Doltha rzURL")
                      >> Response.Write "tmp=" & tmp & "<BR>"
                      >> Response.Write Session("Doltha rzURL") & "<BR>"
                      >> Response.Write Session.Session ID & "<BR>"
                      >>
                      >> tmp = Request.ServerV ariables("SCRIP T_NAME") & _
                      >> "?" & Request.ServerV ariables("QUERY _STRING") & ""
                      >>
                      >> Session("Doltha rzURL") = tmp & ""
                      >> Response.Write "tmp=" & tmp & "<BR>"
                      >> Response.Write Session("Doltha rzURL") & "<BR>"
                      >> Response.Write Session.Session ID & "<BR>"
                      >> %>
                      >>
                      >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                      >> = And this one doesn't
                      >> = /Page2.asp?query =string&contain s=something
                      >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                      >>
                      >>
                      >> <%
                      >> Option Explicit
                      >> Response.Expire s=-1
                      >> %>
                      >>
                      >> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
                      >> <HTML>
                      >> <HEAD>
                      >> <TITLE></TITLE>
                      >> <META NAME="Generator " CONTENT="TextPa d 4.6">
                      >> <META NAME="Author" CONTENT="?">
                      >> <META NAME="Keywords" CONTENT="?">
                      >> <META NAME="Descripti on" CONTENT="?">
                      >> </HEAD>
                      >>
                      >> <BODY BGCOLOR="#FFFFF F" TEXT="#000000" LINK="#FF0000" VLINK="#800000"
                      >> ALINK="#FF00FF" BACKGROUND="?">
                      >>
                      >> <%
                      >> Dim tmp
                      >> tmp = Session("Doltha rzURL")
                      >> Response.Write "tmp=" & tmp & "<BR>"
                      >> Response.Write Session("Doltha rzURL") & "<BR>"
                      >> Response.Write Session.Session ID & "<BR>"
                      >>
                      >> tmp = Request.ServerV ariables("SCRIP T_NAME") & _
                      >> "?" & Request.ServerV ariables("QUERY _STRING") & ""
                      >>
                      >> Session("Doltha rzURL") = tmp & ""
                      >> Response.Write "tmp=" & tmp & "<BR>"
                      >> Response.Write Session("Doltha rzURL") & "<BR>"
                      >> Response.Write Session.Session ID & "<BR>"
                      >> %>
                      >>
                      >> </BODY>
                      >> </HTML>
                      >>
                      >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                      >> = I'm not a GURU nor an EXPERT or something like that.
                      >> = I'm just a passionnate programmer.
                      >> =
                      >> = Doltharz
                      >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =[/color]
                      >
                      >[/color]


                      I'm not a GURU nor an EXPERT or something like that.
                      I'm just a passionnate programmer.

                      Doltharz

                      Comment

                      • doltharz

                        #12
                        Re: Session Variable gets truncated and drives me crazy

                        I think i got it...

                        <BODY BGCOLOR="#FFFFF F" TEXT="#000000" LINK="#FF0000" VLINK="#800000"
                        ALINK="#FF00FF" BACKGROUND="?">

                        BACKGROUND="?" seems to cause the problem
                        BACKGROUND="" works just fine


                        On Sun, 3 Aug 2003 17:19:16 -0400, "Bob Barrows" <reb_01501@yaho o.com>
                        wrote:
                        [color=blue]
                        >OK - this got to me too late for me to do anything with it today. What I
                        >would suggest is that you remove lines one-by-one from the page that does
                        >not work until you discover exactly which line is causeing it to fail. I
                        >suspect that it's that DOCTYPE line, myself. Any idea why you need that one?
                        >
                        >Bob Barrows
                        >
                        >doltharz wrote:[color=green]
                        >> Remember to call each page at least twice to affect and see the
                        >> session variable on another instance of the same page.
                        >>
                        >> /Page.asp?query= string&contains =something
                        >>
                        >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                        >> = This one works
                        >> = /Page.asp?query= string&contains =something
                        >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                        >>
                        >> <%
                        >> Option Explicit
                        >> Response.Expire s=-1
                        >>
                        >> Dim tmp
                        >> tmp = Session("Doltha rzURL")
                        >> Response.Write "tmp=" & tmp & "<BR>"
                        >> Response.Write Session("Doltha rzURL") & "<BR>"
                        >> Response.Write Session.Session ID & "<BR>"
                        >>
                        >> tmp = Request.ServerV ariables("SCRIP T_NAME") & _
                        >> "?" & Request.ServerV ariables("QUERY _STRING") & ""
                        >>
                        >> Session("Doltha rzURL") = tmp & ""
                        >> Response.Write "tmp=" & tmp & "<BR>"
                        >> Response.Write Session("Doltha rzURL") & "<BR>"
                        >> Response.Write Session.Session ID & "<BR>"
                        >> %>
                        >>
                        >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                        >> = And this one doesn't
                        >> = /Page2.asp?query =string&contain s=something
                        >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                        >>
                        >>
                        >> <%
                        >> Option Explicit
                        >> Response.Expire s=-1
                        >> %>
                        >>
                        >> <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
                        >> <HTML>
                        >> <HEAD>
                        >> <TITLE></TITLE>
                        >> <META NAME="Generator " CONTENT="TextPa d 4.6">
                        >> <META NAME="Author" CONTENT="?">
                        >> <META NAME="Keywords" CONTENT="?">
                        >> <META NAME="Descripti on" CONTENT="?">
                        >> </HEAD>
                        >>
                        >> <BODY BGCOLOR="#FFFFF F" TEXT="#000000" LINK="#FF0000" VLINK="#800000"
                        >> ALINK="#FF00FF" BACKGROUND="?">
                        >>
                        >> <%
                        >> Dim tmp
                        >> tmp = Session("Doltha rzURL")
                        >> Response.Write "tmp=" & tmp & "<BR>"
                        >> Response.Write Session("Doltha rzURL") & "<BR>"
                        >> Response.Write Session.Session ID & "<BR>"
                        >>
                        >> tmp = Request.ServerV ariables("SCRIP T_NAME") & _
                        >> "?" & Request.ServerV ariables("QUERY _STRING") & ""
                        >>
                        >> Session("Doltha rzURL") = tmp & ""
                        >> Response.Write "tmp=" & tmp & "<BR>"
                        >> Response.Write Session("Doltha rzURL") & "<BR>"
                        >> Response.Write Session.Session ID & "<BR>"
                        >> %>
                        >>
                        >> </BODY>
                        >> </HTML>
                        >>
                        >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
                        >> = I'm not a GURU nor an EXPERT or something like that.
                        >> = I'm just a passionnate programmer.
                        >> =
                        >> = Doltharz
                        >> = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =[/color]
                        >
                        >[/color]


                        I'm not a GURU nor an EXPERT or something like that.
                        I'm just a passionnate programmer.

                        Doltharz

                        Comment

                        Working...