Reply to simple thing on session

Your name:

Reply:


Posted by Jean Pierre Daviau on 10/15/12 11:33

Hi all and every one

Eassy php 1.7 does not seem to keep session information between pages.


======== page 1 ===================

<?
session_start();
session_register("sess_var");
$sess_var = "Hello world!";

echo "The content of \$sess_var is $sess_var <br>";

?>
It prints
The content of \$sess_var is Hello world!"


<a href = "page2.php">page 2</a>

======== page 2 ===================

<?
session_start();
$sess = $_SESSION ["sess_var"];

if($_SESSION ["sess_var"])
echo "The content of \$sess_var is $sess_var <br>";

if (!session_is_registered('compteur'))
echo "!session_is_registered <br>";


?>
prints on page 2 !session_is_registered

============= php.ini ============
session.save_handler = files
session.use_cookies = 0
session.name = PHPSESSID
session.auto_start = 0
session.cookie_lifetime = 180
session.cookie_path = /
session.cookie_domain =
session.serialize_handler = php

session.gc_probability = 1
session.gc_divisor = 1000
session.gc_maxlifetime = 1440
session.bug_compat_42 = 0
session.bug_compat_warn = 1
--

X trκme newbe
.......
masm32
windows Xp
asus p4 s533/333/133
Intel(R) Celeron (R) CPU 2.00 GHz

[Back to original message]


УдалСнная Ρ€Π°Π±ΠΎΡ‚Π° для программистов  •  Как Π·Π°Ρ€Π°Π±ΠΎΡ‚Π°Ρ‚ΡŒ Π½Π° Google AdSense  •  England, UK  •  ΡΡ‚Π°Ρ‚ΡŒΠΈ Π½Π° английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Π‘Π°ΠΉΡ‚ ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ Π² Π‘Ρ‚ΡƒΠ΄ΠΈΠΈ Π’Π°Π»Π΅Π½Ρ‚ΠΈΠ½Π° ΠŸΠ΅Ρ‚Ρ€ΡƒΡ‡Π΅ΠΊΠ°
ΠΈΠ·Π³ΠΎΡ‚ΠΎΠ²Π»Π΅Π½ΠΈΠ΅ ΠΈ ΠΏΠΎΠ΄Π΄Π΅Ρ€ΠΆΠΊΠ° Π²Π΅Π±-сайтов, Ρ€Π°Π·Ρ€Π°Π±ΠΎΡ‚ΠΊΠ° ΠΏΡ€ΠΎΠ³Ρ€Π°ΠΌΠΌΠ½ΠΎΠ³ΠΎ обСспСчСния, поисковая оптимизация