SlideShare una empresa de Scribd logo
1 de 7
Descargar para leer sin conexión
SESSIONS AND FLASH
What goes in a hash?
REVIEW: WHAT IS A SESSION?
A session is a hash that will store information on the client’s
server until the session times out or is deleted.
Ex: creating a new session at login to remember a user until they log out or
exit the application.
FUN FACTS
➤ Sessions are “lazily loaded”, meaning they will only load if
you use them. If you choose not to use sessions, you don’t
have to disable them.
➤ You can use the reset_session method to reset the entire
session hash.
➤ To store data that persists from session to session, you can
store a session in the CookieStore.
WHAT IS THE FLASH HASH?
Much like a session, a flash is a bit of information that is
stored on the client’s server. A flash will only last from one
request to the next.
MORE ABOUT FLASH
➤ You can create different types of messages, such as :notice or
:alert.
➤ You can also create custom alerts such as:
➤ To display multiple flash messages, iterate through the hash
using each.
OTHER WAYS TO USE FLASH
flash.now
flash.keep
FUN FACT
➤ Bootstrap has alert classes that can be used to display flash
messages.

Más contenido relacionado

Similar a Sessions and Flash

10 Cache Implementation
10  Cache Implementation10  Cache Implementation
10 Cache Implementation
Ranjan Kumar
 
Authentication and Single Sing on
Authentication and Single Sing onAuthentication and Single Sing on
Authentication and Single Sing on
guest648519
 

Similar a Sessions and Flash (20)

Php sessions
Php sessionsPhp sessions
Php sessions
 
season management in php (WT)
season management in php (WT)season management in php (WT)
season management in php (WT)
 
Cache
CacheCache
Cache
 
Sas manager-s-guide v50-03052012
Sas manager-s-guide v50-03052012Sas manager-s-guide v50-03052012
Sas manager-s-guide v50-03052012
 
asp.net session management example | using session in asp.net C# | what is se...
asp.net session management example | using session in asp.net C# | what is se...asp.net session management example | using session in asp.net C# | what is se...
asp.net session management example | using session in asp.net C# | what is se...
 
Ph
PhPh
Ph
 
7. Sessions.pptx
7. Sessions.pptx7. Sessions.pptx
7. Sessions.pptx
 
Php 07-cookies-sessions
Php 07-cookies-sessionsPhp 07-cookies-sessions
Php 07-cookies-sessions
 
Sessions in php
Sessions in php Sessions in php
Sessions in php
 
Examen
ExamenExamen
Examen
 
PHP tutorials , php tutorials for beginners , tutorials for php
PHP tutorials , php tutorials for beginners , tutorials for phpPHP tutorials , php tutorials for beginners , tutorials for php
PHP tutorials , php tutorials for beginners , tutorials for php
 
How to Clear Cache in a Symfony Cross Application
How to Clear Cache in a Symfony Cross ApplicationHow to Clear Cache in a Symfony Cross Application
How to Clear Cache in a Symfony Cross Application
 
10 Cache Implementation
10  Cache Implementation10  Cache Implementation
10 Cache Implementation
 
Ahsay Backup Software v7 - Datasheet
Ahsay Backup Software v7 - DatasheetAhsay Backup Software v7 - Datasheet
Ahsay Backup Software v7 - Datasheet
 
lecture 13.pptx
lecture 13.pptxlecture 13.pptx
lecture 13.pptx
 
Authentication and Single Sing on
Authentication and Single Sing onAuthentication and Single Sing on
Authentication and Single Sing on
 
bl_26
bl_26bl_26
bl_26
 
Ahsay Backup Software version 7
Ahsay Backup Software version 7Ahsay Backup Software version 7
Ahsay Backup Software version 7
 
Cookies and Session
Cookies and SessionCookies and Session
Cookies and Session
 
SugarCE For Small And Medium Enterprises
SugarCE For Small And Medium EnterprisesSugarCE For Small And Medium Enterprises
SugarCE For Small And Medium Enterprises
 

Último

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
Joaquim Jorge
 

Último (20)

A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Advantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your BusinessAdvantages of Hiring UIUX Design Service Providers for Your Business
Advantages of Hiring UIUX Design Service Providers for Your Business
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 

Sessions and Flash

  • 1. SESSIONS AND FLASH What goes in a hash?
  • 2. REVIEW: WHAT IS A SESSION? A session is a hash that will store information on the client’s server until the session times out or is deleted. Ex: creating a new session at login to remember a user until they log out or exit the application.
  • 3. FUN FACTS ➤ Sessions are “lazily loaded”, meaning they will only load if you use them. If you choose not to use sessions, you don’t have to disable them. ➤ You can use the reset_session method to reset the entire session hash. ➤ To store data that persists from session to session, you can store a session in the CookieStore.
  • 4. WHAT IS THE FLASH HASH? Much like a session, a flash is a bit of information that is stored on the client’s server. A flash will only last from one request to the next.
  • 5. MORE ABOUT FLASH ➤ You can create different types of messages, such as :notice or :alert. ➤ You can also create custom alerts such as: ➤ To display multiple flash messages, iterate through the hash using each.
  • 6. OTHER WAYS TO USE FLASH flash.now flash.keep
  • 7. FUN FACT ➤ Bootstrap has alert classes that can be used to display flash messages.