Questions tagged as 'session'

1
answer

How to display the String value retrieved from the JSF session?

I'm having a problem trying to display a String value retrieved from the session in xhtml. What I want is to show the value of a String attribute (name attribute) of an object of the class I created (User class), which is stored in the session....
asked by 21.12.2016 / 05:21
1
answer

Variables $ _SESSION resets after reloading page in PHP

Hello. I'm trying to run a very simple login system with session and I'm not able to keep the $ _SESSION variables saved, because they get lost every time I have a reload on the page. My index.php <?php session_start(); if(isset...
asked by 03.02.2017 / 13:23
1
answer

Define a session variable by clicking on a link

I have a dropdown list, which allows you to choose the year that will be used in the database search. I would like the user to select one of these dates, set a session variable with the year value, and thus be able to use this variable in future...
asked by 22.01.2017 / 22:57
1
answer

Do I need to use session_generate_id on all pages? [closed]

I recently met this function, I know that it generates another random id for the session, but my question is the following, I can use this function only once in the case after login, and in the other pages I do not need to use ? will my session...
asked by 01.09.2016 / 22:08
1
answer

Flash Session does not work, Laravel 5.1 [closed]

I've done this several times but for some reason now it's not working, I can not grab the flash from the session in the view UsersController: public function login_page(Request $request) { $title = "login"; $dataToView = array(...
asked by 10.12.2015 / 12:04
1
answer

Is it possible to get the name and value of all sessions by javascript?

I'm creating several sessions, and would like to get the name and value of all of them through JavaScript. Home When creating two Sessions in Asp.Net MVC, for example: Session["usuario"] = "user"; Session["tipo"] = "comum"; I'd like to get...
asked by 24.06.2015 / 23:31
1
answer

Session from Config

I have the following case: I want to send an email from cakephp, but since there is more than one user in the database (each containing a different email), I need to send each user's email and password to the / app file /Config/email.php, that i...
asked by 06.04.2015 / 19:58
3
answers

Put an Array in a cookie in PHP

I have a query that returns me the hits of the user who just logged in. I need to turn them into an array and store them in a session and a cookie. Here is the code: //ARMAZENA AS PERMISSOES DO PERFIL DO USUARIO if($sql_permissoes->rowCount...
asked by 06.04.2015 / 14:44
1
answer

PHP Using SESSION with Array

Good night, my goal is when to go back to the products page, and go back to the cart, holding the session variable and also fill the cart page with more products each time the array receives a new one as it is generating one product only. Thank y...
asked by 12.03.2015 / 00:15
1
answer

Best way to provide Sessions for DAO's

I was searching the internet for ways to inject Sessions into DAO's this:    HibernateUtil This form is about implementing a utility class that will configure, instantiate, and make available a org.hibernate.SessionFactory object t...
asked by 09.07.2014 / 05:21