• Forum
  • Doc
  • Screenshots
  • Download
  • Donate
  • Contributors
  • Contact
  • Follow @phpfreechat
  • DEMO
  • Board index ‹ Version 2.x Branch ‹ General Support (v2.x)
  • Change font size
  • FAQ
  • Register
  • Login

problem with $_SESSION $_COOKIE

Moderators: OldWolf, re*s.t.a.r.s.*2

Post a reply
1 post • Page 1 of 1

problem with $_SESSION $_COOKIE

Postby shneeble » Wed Feb 05, 2014 3:17 pm

Hello Guys,

I try to integrate phpFreeChat into my environment, and want to get the nickname for the chat from either the session or a cookie (both is ok)

$GLOBALS['pfc_hooks']['pfc.before.auth'][5] = function ($app, $req, $res) {
return function () use ($app, $req, $res) {

return $_COOKIE['Adlerchat-name']; // TODO: replace this code with a real example
};
};

in server/config.php

but the cookie seems to be empty (if i append e.g. a "001" the nick is "001")

the cookie exists and contains the desired username. (i.e. it is visible in firecookie, a test simple script outside the context of the site shows the value, and within the page it seems to be available too, but not within the hook)
du i have to activate / configure / set / ... something somewhere?
shneeble
New member
 
Posts: 1
Joined: Wed Feb 05, 2014 3:12 pm
Top

Post a reply
1 post • Page 1 of 1

Return to General Support (v2.x)

Who is online

Users browsing this forum: No registered users and 2 guests

  • Board index
  • The team • Delete all board cookies • All times are UTC + 1 hour
Powered by phpBB® Forum Software © phpBB Group
Sign in
Wrong credentials
Sign up I forgot my password
.
jeu-gratuit.net | more partners
Fork me on GitHub