Storing link text to a Cookie or Session Variable

Ask a Question related to Dreamweaver AppDev, Design and Development.

  1. #1

    Default Storing link text to a Cookie or Session Variable

    Another one of those "It sounds easy enough to do, but...."

    I need to store the value/text displayed as a hyperlink to either a Cookie or
    Session Variable, when the user clicks the link.

    Any quick code samples or advise would be much appreciated!

    Thanks

    PA Guest

  2. Similar Questions and Discussions

    1. Storing additional data in the session cookie
      yes of course u can either use setcookie or session_register "Ladana Spak" <tz@x-over.com> wrote in message...
    2. #25629 [Opn->Bgs]: session cookie being set to deleted when deleting a session
      ID: 25629 Updated by: sniper@php.net Reported By: john at tarot dot com -Status: Open +Status: Bogus...
    3. #25465 [Opn]: Session lost, session.cookie.lifetime
      ID: 25465 User updated by: sam dot houlder at teleperfomance dot no Reported By: sam dot houlder at teleperfomance dot no...
    4. #25465 [NEW]: Session lost, session.cookie.lifetime
      From: sam dot houlder at teleperfomance dot no Operating system: Linux PHP version: 4.3.3 PHP Bug Type: Session related Bug...
    5. authentication cookie vs session cookie
      Hi, What are the differences between authentication and session cookies? In my web.config file, I set the cookieless attribute for the...
  3. #2

    Default Re: Storing link text to a Cookie or Session Variable

    You can use the A tag to link to other pages. The HREF attribute is then
    used to specify the page togo to. eg

    <a href="<%=Session("foo")%>">

    --
    Jules
    [url]http://www.charon.co.uk/charoncart[/url]
    Charon Cart 3
    Shopping Cart Extension for Dreamweaver MX/MX 2004


    Julian Roberts Guest

  4. #3

    Default Re: Storing link text to a Cookie or Session Variable

    Thanks Jules,

    I forgot to mention that the link is based on dynamic data. Here's a sample of
    the code:

    <a href="details.asp?<%= Server.HTMLEncode(MM_keepNone) &
    MM_joinChar(MM_keepNone) & "id=" & rsRecentWork.Fields.Item("recordID").Value
    %>" target="_blank">

    <%=LEFT((rsRecentWork.Fields.Item("details").Value ),100)%>

    I need to store the recordID value to a session after link is clicked - what
    do I need to change to accomplish this?

    Thanks again!


    PA Guest

  5. #4

    Default Re: Storing link text to a Cookie or Session Variable

    PA wrote:
    > Thanks Jules,
    >
    > I forgot to mention that the link is based on dynamic data. Here's a
    > sample of the code:
    >
    > <a href="details.asp?<%= Server.HTMLEncode(MM_keepNone) &
    > MM_joinChar(MM_keepNone) & "id=" &
    > rsRecentWork.Fields.Item("recordID").Value %>" target="_blank">
    >
    > <%=LEFT((rsRecentWork.Fields.Item("details").Value ),100)%>
    >
    > I need to store the recordID value to a session after link is
    > clicked - what do I need to change to accomplish this?
    You need to request the recordID on the next page. It's not uncommon to send
    a page to a "silent" page that records an ID into a DB, session, cookie,
    etc... and then redirect the user to the appropriate page; the process is
    silent and the user is unaware of being redirected.

    --
    kindler chase
    [url]http://www.ncubed.com[/url]
    Home of SuperInvoice: The Online Invoicing Application.
    Organize your billing process and impress your clients.

    [url]news://news.ncubed.com/support[/url]
    n3 Support Group


    Kindler Chase Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139