Cant change a code

Mod Support

Moderators: BNa, Sekuro, 4seven

Cant change a code

Postby pilsner » 07 Nov 2013, 11:29

Im trying to use this: [Snippet] IP-Logging ausschalten (de)

But i cant find the code: $this->ip = (!empty($_SERVER['REMOTE_ADDR'])) ? htmlspecialchars($_SERVER['REMOTE_ADDR']) : ''; in includes/session.php the closest i can find is: $this->ip = (!empty($_SERVER['REMOTE_ADDR'])) ? (string) $_SERVER['REMOTE_ADDR']

I was trying to typing the code $this->ip = '127.0.0.1'; under the first line and what i can se it works, but i dont know if something is wrong anyway?

If i change the second line: 'session_ip' => (string) $this->ip, to 'session_ip' => '127.0.0.1', Everything is just White...

whats wrong?
pilsner

Tiptop

Tiptop
 
Posts: 1
Joined: 06 Nov 2013, 23:08
 
Resolution: 1024x600


Re: Cant change a code

Postby 4seven » 03 Dec 2013, 00:56

pilsner wrote:If i change the second line: 'session_ip' => (string) $this->ip, to 'session_ip' => '127.0.0.1', Everything is just White...

whats wrong?


seems in newer phpbb version the string is casted via (string) ;)

so write 'session_ip' => (string) '127.0.0.1', instead of 'session_ip' => '127.0.0.1',
Current Mods | Mod Base | php(BB) programming | No help via PM
User avatar
4seven

Tiptop

Tiptop
 
Posts: 318
Joined: 20 Jun 2012, 16:55
 
Resolution: 1920x1080



Return to Support Forum

Who is online

Users browsing this forum: No registered users and 1 guest

cron