473,803 Members | 2,038 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

pass PHPSESSID in FORM-tag

Hello ,

I want to pass some $_SESSION data to another page.

I can pass PHPSESSID along using echo '<br /><a href="page2.php ?' . SID
.. '">page 2</a>';

However, I want to fill in a table with values and include PHPSESSID
with it. This does not work. I tried somethink like this:
<INPUT TYPE="Hidden" NAME="PHPSESSID " VALUE="<?=SID ?>">

and on the next page 'retrieve' the SID
$SID=$_POST["PHPSESSID"];

Now probably SID is not a normal variable , but how to get this right?

How is a call like http://page2.php?PHPSESSID=42ed32d .. processed , is
there a variabele PHPSESSID or a variabele SID that is being used?
Jul 17 '05 #1
3 7328
edward hage <ed**@xs4all.nl > wrote in message news:<3f******* **************@ news.xs4all.nl> ...
Hello ,

I want to pass some $_SESSION data to another page.

I can pass PHPSESSID along using echo '<br /><a href="page2.php ?' . SID
. '">page 2</a>';

However, I want to fill in a table with values and include PHPSESSID
with it. This does not work. I tried somethink like this:
<INPUT TYPE="Hidden" NAME="PHPSESSID " VALUE="<?=SID ?>">

and on the next page 'retrieve' the SID
$SID=$_POST["PHPSESSID"];

Now probably SID is not a normal variable , but how to get this right?

How is a call like http://page2.php?PHPSESSID=42ed32d .. processed , is
there a variabele PHPSESSID or a variabele SID that is being used?


http://in2.php.net/manual/en/install...able-trans-sid

http://in2.php.net/session See session.use_tra ns_sid

--
"There are two kinds of people, those who do the work and those who
take the credit. Try to be in the first group; there is less
competition there." -- Indira Gandhi
Email: rrjanbiah-at-Y!com
Jul 17 '05 #2
R. Rajesh Jeba Anbiah wrote:
edward hage <ed**@xs4all.nl > wrote in message news:<3f******* **************@ news.xs4all.nl> ...
Hello ,

I want to pass some $_SESSION data to another page.

I can pass PHPSESSID along using echo '<br /><a href="page2.php ?' . SID
. '">page 2</a>';

However, I want to fill in a table with values and include PHPSESSID
with it. This does not work. I tried somethink like this:
<INPUT TYPE="Hidden" NAME="PHPSESSID " VALUE="<?=SID ?>">

and on the next page 'retrieve' the SID
$SID=$_POST["PHPSESSID"];

Now probably SID is not a normal variable , but how to get this right?

How is a call like http://page2.php?PHPSESSID=42ed32d .. processed , is
there a variabele PHPSESSID or a variabele SID that is being used?

http://in2.php.net/manual/en/install...able-trans-sid

http://in2.php.net/session See session.use_tra ns_sid


I already read that page but it doesn't say anything about passing SID
in a frame.

I am using PHP 4.3.1 so the --enable-trans-sid is already enabled.Thanks.
Jul 17 '05 #3
edward hage wrote:
R. Rajesh Jeba Anbiah wrote:
edward hage <ed**@xs4all.nl > wrote in message
news:<3f******* **************@ news.xs4all.nl> ...
Hello ,

I want to pass some $_SESSION data to another page.

I can pass PHPSESSID along using echo '<br /><a href="page2.php ?' . SID
. '">page 2</a>';

However, I want to fill in a table with values and include PHPSESSID
with it. This does not work. I tried somethink like this:
<INPUT TYPE="Hidden" NAME="PHPSESSID " VALUE="<?=SID ?>">

and on the next page 'retrieve' the SID
$SID=$_POST["PHPSESSID"];

Now probably SID is not a normal variable , but how to get this right?

How is a call like http://page2.php?PHPSESSID=42ed32d .. processed , is
there a variabele PHPSESSID or a variabele SID that is being used?



http://in2.php.net/manual/en/install...able-trans-sid
http://in2.php.net/session See session.use_tra ns_sid

I already read that page but it doesn't say anything about passing SID
in a frame.

I am using PHP 4.3.1 so the --enable-trans-sid is already enabled.Thanks.

Found out answer for who is interested. Kind of straightforward to use
session-data in next page by using FORM ACTION = "wisme2.php?<?= SID ?> "

This may be usefull for somebody.

<?php
session_start() ;
$_SESSION['data1']= 1 ;
$_SESSION['data2']='hello';
?>
<FORM ACTION="wisme2. php?<?=SID ?> " METHOD=POST>
<INPUT TYPE="SUBMIT" VALUE="Verder">
</FORM>

Jul 17 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
6899
by: JohnS | last post by:
Hi, When I initially start my browser (any of 'm) and point it to my PHP script the $PHPSESSID is always blank. On all subsequent hits or after a refresh the value for $PHPSESSID is fine... why do I have to complete a php file before the $PHPSESSID is set? I tried to do session_start() before anything still blank, what did I miss? (Aix 4.3.3, php 4.2.1,Apache 1.13.26)
4
8265
by: Arnaud | last post by:
Hi ! I would like to propagate data between php pages, in two cases : the pages are read by : 1- Internet Explorer It's ok, data are writen in one page, and read from another. I don't use PHPSESSID 2- from a mobile browser ( mobile i-Mode phone Nec22) After several tests, I understod it's impossible, because the session system tries to write a cookie on the browser...
0
1709
by: Alex Shi | last post by:
Hi, I don't know how php process its session. I just noticed that for the first time a web site is loaded php will insert a PHPSESSID through out the page: it attach this id to links, insert hidden field into form, and even attach the id onto form button if the button is an image. Here are samples what it did: <a href="http://link?PHPSESSID=e2b49283217665659a856cd939f10881>
3
774
by: Quinonez | last post by:
how can i get the PHPSESSID to not show on the results of a form i have created?
2
7754
by: frizzle | last post by:
Hi there I have a site in which all pages ARE php-pages, but they're called/manipulated with htaccess. All files appear as a html-file to surfers. Sometimes i get the PHPSESSID declared in the url. I want to avoid this from caching in the browsers history. is there a way to detect if PHPSESSID is set, and if
0
1762
by: John Smith | last post by:
Googlebot has been picking up numerous PHPSESSID name/value pairs in URIs at my website, and this causes duplicate hits and wasted bandwidth. I've since prevented PHPSESSID generation in my PHP script if Googlebot makes the request; like so: if(preg_match("/googlebot/i", $_SERVER) != 1) //session code here ....but this doesn't stop the PHPSESSID requests from Googlebot because they're already stored in its database, and it continues...
0
3240
by: joseph conrad | last post by:
Hi, I tried to implement my own session handler in order to keep control on the process the drawback I foun it is not creating and storing in my cookie the PHPSESSID variable anymore. reading te documentation it seems it should do it anyway any advice?
29
4877
by: CAH | last post by:
Hi Can you avoid that googlebot indexes PHPSESSID pages? Googlebot is indexing pages with PHPSESSID, which makes it think my page has a infinite number of pages. How can one avoid this? Here is an exsample of url that google register, that might make is more clear what is happening www.winches.dk/winches.php?artnr=500735&PHPSESSID=d22126f0d46334659ff...
1
2585
by: Leszek | last post by:
Hi. How should I configure Apache2.2 with php5 so that PHPSESSID would be sent as a cookie ? Now I'm not getting any messages even if I set IE to ask about incoming cookies... So what is the default way of sending PHPSESSID if not as a cookie? What is the best way to send PHPSESSID? thanks,
1
2605
by: zorro | last post by:
Greetings, I want users to select the duration time of their sessions. I'm able to do it by setting the PHPSESSID cookie duration. Is this reliable, or is it not recommended for some reason? This is the test : open browser, close browser, reopen browser if( ! $_COOKIE) // opened browser first time - no session
0
9562
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
10542
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
10309
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
10289
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
10068
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
7600
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6840
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
1
4274
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
2
3795
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.