Results 1 to 3 of 3

Thread: Featured Content Slider Cookie

  1. #1
    Join Date
    Jul 2006
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Featured Content Slider Cookie

    1) Script Title: Featured Content Slider

    2) Script URL (http://www.dynamicdrive.com/dynamici...tentslider.htm)

    How to Cookie in add life time expires date

    As like
    Code:
    function createCookie(name,value,days)
    {
    if (days)
    {
    var date = new Date();
    date.setTime(date.getTime()+(days*24*60*60*1000));
    var expires = "; expires="+date.toGMTString();
    }
    else var expires = "";
    document.cookie = name+"="+value+expires+"; path=/";
    }

  2. #2
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    Hmm not sure I understand. You wish the cookie to never expire, instead of the current browser session duration?

  3. #3
    Join Date
    Jul 2006
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    I mean how to I am Cookie in 1 month or 1 year expires date add.

Bookmarks

Posting Permissions

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