How do I pass a message that shows only once?

Source: Internet
Author: User
such as logging in,

You can produce errors (such as password errors) on the current page when the login error occurred.

Login successfully jump to the first page. Want to display a row on the home page (login success prompt message), how to pass this?

A cookie? Does it feel weird to delete it immediately after the display?

And this information is only displayed once

Reply content:

such as logging in,

You can produce errors (such as password errors) on the current page when the login error occurred.

Login successfully jump to the first page. Want to display a row on the home page (login success prompt message), how to pass this?

A cookie? Does it feel weird to delete it immediately after the display?

And this information is only displayed once

In web development, it is a mature practice to put information into a flash domain, which will return or jump or display
In the page, usually based on the session, will automatically complete the display after emptying

PS: Do not understand the PHP following is the search out do not know how to use NOT (keywords: php flash message )
http://mikeeverhart.net/php/session-based-flash-messages/

The front end is displayed directly on the page, usually under head navigation, main-content above.
Similar to
Add content to it when it needs to be displayed.

The backend uses the session in the Controller and view between the pass, the use of attention to empty.

It is possible to use flash or use Localstorage.

  • Contact Us

    The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

    If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

    A Free Trial That Lets You Build Big!

    Start building with 50+ products and up to 12 months usage for Elastic Compute Service

    • Sales Support

      1 on 1 presale consultation

    • After-Sales Support

      24/7 Technical Support 6 Free Tickets per Quarter Faster Response

    • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.