firefox,cookies , Exact solution to keep cookie after closing firefox

Exact solution to keep cookie after closing firefox


Tag: firefox,cookies

I know this is asked many time but i want exact solution.

Why cookies are deleted after closing firefox?

I want to keep cookies after closing firefox.


From here

To summarize:

In case you are using "Clear history when Firefox closes":

do not clear Cookies
do not clear Site Preferences 

Clearing cookies will remove all specified (selected) cookies including cookies that have an allow exception.

Tools > Options > Privacy: History: [X] Clear history when Firefox closes > Settings 

Note that clearing "Site Preferences" clears all exceptions for cookies, images, pop-up windows, software installation, and passwords.

Let all cookies expire when you close Firefox.

Tools > Options > Privacy > Cookies: "Keep until": "I close Firefox" 

Make an Allow exception for the ones that you want to keep.

Tools > Options > Privacy > Cookies: "Exceptions"


Storing Check Box Selection in Cookies

I have programmed a Remember Me check box to store the username and password in cookies if the box is checked. My problem is, that if they check it and then re-launch the application the username and password auto fill, but the checkbox does not stay checked. I have not...

Javascript Retina / HD display detection and blocking page render during reload

My question is pretty much about page reload rather than retina detection. I'm using the code below in head tag for retina display : <script type="text/javascript"> if( document.cookie.indexOf('device_pixel_ratio') == -1 && 'devicePixelRatio' in window && window.devicePixelRatio == 2 ){ var date = new Date(); date.setTime( date.getTime() + 3600000000 ); document.cookie...

how symfony2 remember me work without any table for token?

I configure symfony2 to add remember me functionality, but how it work without any table in database to save remember me token. I mean some best practice for remember me cookie like what is said in here

Prevent a triggering action using a cookie with JavaScript

In a wordpress site I have a pop up window (for email capture) that is triggered by the "mouseleave" event. The pop up works fine but Once the info is captured or the pop up window closed I dont want to bother the visitor with this pop up anymore. So...

Errors in Firefox Add-on SDK when using cfx xpi whereas cfx run works great

I'm a student at a University Institute of Technology in France and I'm very new to Firefox add-on development since I discovered it at the beginning of my work placement, a few days ago. What I have to do is an add-on that allows employees of the company to organize...

Android Cookies (Reward for Invites)

I am trying to integrate 'reward for invites' logic. What I am trying to do for this is I generate a unique URl for every user. When a friend clicks on the URL he is directed to a page and then to the playstore. On the page, a cookie with...

Google maps not working in Firefox (gray box)

I have a plugin I'm working on that uses the Google Maps API v3. Works like a charm, except in Firefox! I present to you the following URL: [REDACTED BECAUSE SOLVED]. You'll notice that if you're using firefox there is a gray box with google maps stuff available. If you...

How to display red borders on required or invalid value input element in Chrome just like Firefox behaviour for HTML5 validation?

I have to bring red borders around the input element in chrome on HTML5 validation like as that of Firefox. I have search it a lot but unable to find precise answer. Any help of how to do it using css is greatly appreciated. Thank you....

.htacces rewrite by cookie value

I have a website in 2 languages. I'm inserting the text for each language through php constants and I define the user language through a cookie (lang=es or lang=en). Now the base url in each language is but i want to rewrite it depending on the language. If the...

python-requests does not grab JSESSIONID and SessionData cookies

I want to scrape a pdf file from but it wants me to accept Terms and Conditions. While downloading from browser I found out that JSTOR saves my acceptance in 2 cookies with names JSESSIONID and SessionData but python-requests does not grab these two cookie( It grab two other...

When is the cookie set by AJAX available in javascript?

I'm doing an AJAX call and setting a cookie in the user browser in the response (the server code sets the cookie). I noticed in the success callback from the ajax, the cookie is not available. When I look in document.cookie the new cookie is not there. My question, when...

Check if a cookie array element exists

How can I check that an array element already exists within cookie? Here is my code: var cookieList = function (cookieName) { var cookie = Cookies.get(cookieName); var items = cookie ? cookie.split(/,/) : new Array(); return { "add": function (val) { items.push(val); Cookies.set(cookieName, items.join(','), { path: '/' }); } }...

Exact solution to keep cookie after closing firefox

I know this is asked many time but i want exact solution. Why cookies are deleted after closing firefox? I want to keep cookies after closing firefox....

PHP Cookie to Track/Limit Website Joins (Preventing Automated Account Creation)

I want to implement a solution to limit the number of Website Joins can be made by one user. I thought of tracking IP address but these are to generic now. I'm now looking to set a cookie and increment for each join and then block joins at say 5...

cookie not setting as expected

When I set a cookie like this, it works: var now = new Date(); now.setDate(now.getDate() + 30); document.cookie='bla=cats; expires=' + now + ';path=/;' But when I do this it does not: var now = new Date(); now.setMinutes(now.getMinutes() + 30); document.cookie='bla=cats; expires=' + now + ';path=/;' So I want to set...

XUL iframe firefox addon, how to change the src within the iframe?

I am developing a firefox addon, in my settings page dialog.xul i have an iframe where i load different settings pages page1.xul page2.xul page3.xul Iframe : <vbox flex="1"> <iframe id="iframe" src="chrome://xxx/content/page1.xul" flex="1"></iframe> </vbox> Within the iframe i need to navigate from page2.xul to page3.xul with the code in page2.xul My...

Can CSS identifiers begin with two hyphens?

CSS 2.1 defines identifiers as In CSS, identifiers can contain only the characters [a-zA-Z0-9] and ISO 10646 characters U+00A0 and higher, plus the hyphen (-) and the underscore (_); they cannot start with a digit, two hyphens, or a hyphen followed by a digit. Identifiers can also contain escaped characters...

How do i add a cookie to my popup form? Built only with css and html [closed]

I have a popup form that shows up onpage load... but i have only used html and css for this... I want to be able to add a cookie that makes the popup only show once onpage load how can i do this? Also how can i put a delay...

How to get web page source from a cookie drived web site using Java

It is easy to get web page source if it has a regular url with it. Here is an answer for it: How to get a web page's source code from Java But some websites, like Sobeys. they are asking you to input your location first then you can get...

$(this).val() not working in FireFox but works in Chrome

This is my problem. When I try to set the value of an input field in FireFox nothing happens. I don't get any errors. It simply just doesn't work. It is supposed to add two decimal places after the number. It works perfectly in Chrome. Here's my jQuery code... $('input.drawer').on('blur',...

Retaining scope value from the cookie store on page refresh

I have the following code in one of my controllers. $scope.artistId = $cookies.artistId; $scope.artistName = $cookies.artistName; $scope.switchArtist = function(artist) { $scope.artistName = ''; $scope.artistId = ''; $scope.artist = artist; $cookies.artistName =; $cookies.artistId =; $scope.artistName =; $scope.artistId =; $rootScope.$broadcast(ARTIST_EVENTS.switchedArtist); }; Then in my view I have {{...

Inconsistent display on IE & Firefox

I'm using Bootstrap on my website project. I'm through with the design but the items are displayed out of place on IE & Firefox. The same page renders great on Chrome. I used developer tools on the three browsers to make sure there was no difference in the CSS properties....

Setting a cookie to only show popup once

I'm trying to setup a cookie to only show a popup once, here's my code so far: jQuery(window).load(function(){ // Load pop up within parent-page section only if (window.location.href.indexOf('parent-page') > -1) { alert("your url contains the parent-page in the URL"); ${ items: [ { src: '#disclaimer', // CSS selector of an...

i have developed website and the issue is that same version of firefox shows different design on different computers while other browsers were fine?

i have developed this website the website tests on my laptop are correct and same design over IE, Chrome, FF and Opera the problem i have found that same version of firefox shows the design different on different computers. FF on my laptop shows correct design while same version...

multiple SESSION cookies being set?

My site is sending two different session id cookies (PHPSESSID), one under "" and the other "". I read this answer here which says to specify the domain used in the 5th parameter, but what about SESSION cookies which are created automatically? I think the issue is that the facebook...

With @csrf_exempt still have Set-Cookie: csrftoken

With Django 1.8, I do not want to have a cookie set on the homepage of my site when the users are not logged in. So I decorate my view with @csrf_exempt like from django.views.decorators.csrf import csrf_exempt @csrf_exempt def mainhome(request): When I look at the query I can see the...

Please explain this code to me [closed]

We hit an unexpected error during our school project. Someone took the time and figured out what it was. But when he fixed it he couldn't explain what he did. I hope someone can explain the following line of code: public string aantalVoorArtikel(object id) { int artikel_id = (int)id; if...

Dart Polymer: Creating PaperDialog with CoreAnimatedPages displayed incorrectly in Firefox

I use Dart Polymer PaperDialogs containing CoreAnimatedPages. The idea is to have popups in which you can click through multiple option views. Example repository available at: DialogView: view.html <link rel="import" href="packages/polymer/polymer.html"> <link rel="import" href="packages/paper_elements/paper_button.html"> <link rel="import" href="packages/paper_elements/paper_dialog.html"> <link rel="import"...

Cookie values consistently returning null

I'm attempting to use a prompt to have someone enter a value, make that value into a cookie, then have a link that will redirect that person to a second page where their cookie value would be displayed. The issue I'm running into is that the cookie in question continues...

Requests dict from cookiejar issue with escaped chars

I'm running into some issues getting a cookie into a dictionary with python. It seems to be all escaped somehow even after running the command provided by requests. resp = requests.get(geturl, cookies=cookies) cookies = requests.utils.dict_from_cookiejar(resp.cookies) and this is what cookies looks like {'P-fa9d887b1fe1a997d543493080644610':...

slideToggle state not working with multiple boxes

I'm trying to save the toggle state of collapsable boxes using cookies. Here's my code: HTML: <div class="box_container"> <div class="box_handle"> Title </div> <div class="box" data-title="admin_actions"> Content </div> </div> Javascript: $('div.box_container div.box_handle').click(function() { $(this).next('.box').slideToggle('fast'); }); $.each($('div.box_container div.box_handle'), function(index,value){ if ($.cookie('show_box_' + $(value).next('.box').attr('data-title')) != 'closed'){...

Firefox dropdown menu click

I have a dropdown menu for languages in my website and it works fine in Google Chrome, Safari and Internet Explorer, but it is bugged in Firefox. This is the code: <a href=""> <select id="languageSelector" style="background-color: transparent" onchange="location = this.options[this.selectedIndex].value;"> <option value=".">ESPAÑOL</option> <option value="./en/index.html">ENGLISH</option> <option value="./de/index.html">DEUTSCH</option> <option...

CSS flexbox wraps content in FireFox (not Chrome)

I have a button that consists of an <i> and an <span> element (an icon and some text). Now both have different sizes so I'm applying a flexbox to my button that should center my items nicely. In Chrome everything works as I expected but using the page in a...

Javascript Not deleting all cookies

I am using following code to delete a cookie: document.cookie = "CookieName=; expires=Thu, 01 Jan 1970 00:00:00 UTC"; There are two cookies, one in on domain and other is on When I am on page the cookie having domain address gets deleted but other one is...

Using a cookie to save the state of a toggled division

While I've found essentially the same question asked a number of times here and on other sites, I've spent hours and hours trying to get those answers to work on my site to no avail; I'm just plain stumped. Possibly because I'm fairly new to Javascript, self-taught, and I'm doing...

Get value from cookies in database Codeigniter PHP

Actually i don't know what is this case name, i save/insert cart cookies php codeigniter to database, and it successful, but i cannot get the specific value from that database string. This is data from my DB a:1:{s:32:"1679091c5a880faf6fb5e6087eb1b2dc";a:6:{s:5:"rowid";s:32:"1679091c5a880faf6fb5e6087eb1b2dc";s:2:"id";s:1:"6";s:3:"qty";s:1:"1";s:5:"price";s:6:"275000";s:4:"name";s:10:"Vinly True";s:8:"subtotal";i:275000;}} And how can i get specific value in that string? for...

Why is position of html button in tablecell different in Firefox

Why is the position of a button element different in Firefox vs Chrome/IE when nested inside a li with display: table-cell? In Chrome and IE the button is aligned to the top of the cell while in Firefox it is aligned to the bottom. Can this be influenced in Firefox...

Dgrid - Firefox breaks while trying to load large data set in dgrid

I have a dgrid connected to a store with a very large data set. (Currently over 137,000 rows). I expect there to be a delay. When I first connected the store - the data populated the dgrid. However I keep getting a pipe break now. I didn't change anything between...

Magnific Popup position bug

There is a strange bug happening when you have got a link triggering Magnific Popup and that link is contained inside an absolute positioned element, which is positioned inside a relative positioned element with overflow:hidden. To reproduce the bug, checkout this example in Chrome or Firefox: HTML <div class="hover-container">...

Can I put a button on the tab header using Firefox Add-on?

In a Firefox browser window, I would like to put a button on the tab header next to the web page title. Is this possible with a Firefox add-on? So far I am still unsure what to call this part of a tab. Sorry for duplicates! Edit: I didn't have...

xul overlay for new menu in TB/Firefox main menubar

I'd like to add a new menu at the end of the main menu bar (file, edit, ...) after the Help menu via an extension i wrote. I already know how to add a new item to one of the menus by something like: <menupopup id="menu_HelpPopup"> <menuitem id="example-item" oncommand="alert('Hello!');" label="TEST"...

Jquery not working while browsing with Firefox

Hello I'm using this code: $("#cart").click(function () { if ($('.content').length > 0) return false; $('#cart').load('index.php?route=module/cart #cart > *'); var e = window.event || e; $("#cart").toggleClass("active"); e.stopPropagation(); $(document).click(function (e) { $("#cart").removeClass("active"); $('#cart').live('mouseleave', function () { // Code Here }); }); }); It works just fine in Chrome but when testing it...

Secure Cookie Attribute in WebSphere

We are trying to secure our JSESSIONID in our WebSphere Full Profile I have followed the URL provided: Our server configuration: Server11_was: I have Recycled my node - servers and runtimes. However, The JSESSIONID still coming as not secure. Am I missing something? WebSphere version:

Adobe DTM Custom rule conditions check for cookies

I have some problems to get a specific rule to fire in DTM. And the documentation on custom rule conditions from Adobe is very basic. What is should do: Check if a specific cookie exists (values of the cookie are irrelevant). When this cookies does not exist fire the rule....

Show Firefox OS devtools on Firefox Developer Edition 'desktop'

I've an iMac with OS X Yosemite v.10.10.3. I use Firefox Developer Edition 40.0a2. I've a ZTE Open C (FR version) with Firefox OS; Boot2Gecko (B2G OS). What I'd like to do is the following: I've a basic webpage (mostyl HTML, CSS and JS) opened in my browser on...

Serializing a java bean into a cookie: Is it bad?

In the organization that i work for, there was a serious debate about the following. Scenario: There is a POJO with 6 different properties all are of type Strings. These values need to be persisted as cookies so that it can be picked back when someone does a booking on...

Implementing cookies with JS to recognize returning visitors

I have a blog with locked content. User needs to enter their email address into a form in order to see the full content. Problem now is that the same user has to enter their email on every post. How do I implement cookies so that: 1) on a form...

Check if cookies are enabled without redirect

I need on each page check if cookies are enabled.And use this code. <?php setcookie('COOK_CHK',uniqid(),time()+60*60*24); if(!isset($_COOKIE['COOK_CHK'])){ echo"Cookies are disabled!"; exit; } session_start(); ?> However on the first check it gives me false until i don't refresh the page.I include this code in each page so can not redirect every time...

Django CSRF cookie not set error if there is cookie value starting with square brackets '['

I have a django site that is hosted on Parent site which I do not own or control sets up a cookie with value [XX]v3|[XXX]. This causes my site to return the error CSRF cookie not set. This happened because django/middleware/ csrf_token value is set to none when...