user2133342
user2133342

Reputation: 161

page keeps reloading fast

I have the following index file, but when load, it seems too keep reloading very fast like there is some kind of loop going on?
It makes it hard to click something, but i cannot find the problem.
Can anyone see why this happens? I removed the session _destroy and all in the common file for selecting the language seems fine too me?

These are the 2 files I use:
File 1
File 2

Upvotes: 0

Views: 106

Answers (2)

Appleshell
Appleshell

Reputation: 7388

else
{
  $lang = 'nl';
  echo "<meta http-equiv=\"refresh\" content=\"0;URL=index.php\">";
}

I think what you want is to set $_SESSION["lang"] at this point.

Upvotes: 1

Kirill Kulakov
Kirill Kulakov

Reputation: 10245

There is a meta tag which might refresh your page under some conditions, try comment it

<meta http-equiv="refresh" content="0;URL=index.php">

Upvotes: 0

Related Questions