Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7627567
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 31, 20262026-05-31T05:28:36+00:00 2026-05-31T05:28:36+00:00

php manual has setcookies syntax like this setcookie ($name, $value, $expire, $path, $domain, $secure,

  • 0

php manual has setcookies syntax like this

setcookie ($name, $value, $expire, $path, $domain, $secure, $httponly) 

It is said that cookies are stored on the remotely in client side. The syntax has path var that if applied cookies will be stored on the server side.

Now suppose if I mention that path var “/”. And on user named denish log in and I create a cookie for username for remember me functionality

setcookie('site_username','denish',time + 3600,'/','.xyz.com')

Now each time the different user logs in. Would it over write the previous cookie or new cookie will be created?

What if I want to create a cookie client side and also want to apply $domain var. Is it possible?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-31T05:28:37+00:00Added an answer on May 31, 2026 at 5:28 am

    You’re incorrect as to the use of the path argument from the manual:

    The path on the server in which the cookie will be available on.

    Cookies are always stored on the client’s machine.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

According to the PHP manual , a class like this: abstract class Example {}
The PHP manual for split() says This function has been DEPRECATED as of PHP
In the PHP manual, to show the syntax for functions with optional parameters, they
I've tried this: http://be.php.net/manual/en/function.mysql-list-fields.php , but there's too much detail here. What I'm looking
I got some legacy code that has this: <?PHP if(isset($_GET['pagina'])==homepage) { ?> HtmlCode1 <?php
Does Java has similar PHP function checkdnsrr ? http://php.net/manual/en/function.checkdnsrr.php
The PHP manual has a section called Handling file uploads . That section has
According to the PHP manual , in order to make code more portable, they
In the PHP manual, the file operations reference an optional context (e.g. for copy
According to php manual nor php://input neither $HTTP_RAW_POST_DATA work with multipart/form-data POST-requests. php://input allows

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.