473,398 Members | 2,389 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,398 software developers and data experts.

Getting session id of ASP pages from PHP.

I want to develop some code in PHP that is part of an ASP application.

I am wondering if there is anyway to get the session ID of an ASP page
(or any other scripting language) from PHP.

I assume that session id's are kept as cookies on the user's desktop.
If that's the case there should be some way of retrieving them.

Has anyone ever accomplished such a linkage?

Thanks

Jul 1 '06 #1
3 2140
In article <11**********************@m79g2000cwm.googlegroups .com>,
j_********@yahoo.com (ImOk) wrote:
I am wondering if there is anyway to get the session ID of an ASP page
(or any other scripting language) from PHP.

I assume that session id's are kept as cookies on the user's desktop.
If that's the case there should be some way of retrieving them.

Has anyone ever accomplished such a linkage?


The following worked in perl for ASP 1 - they might have changed the
cookie format since then.

foreach $_ (split /; /, $ENV{'HTTP_COOKIE'}) {
$session_id = $1 if /ASPSESSIONID.{8}=(.{24})/;
}

--
To reply email rafe, at the address cix co uk
Jul 1 '06 #2
Looks reasonable (except for that perl gunk :)

Care to translate.

Thanks

Rafe Culpin wrote:
In article <11**********************@m79g2000cwm.googlegroups .com>,
j_********@yahoo.com (ImOk) wrote:
I am wondering if there is anyway to get the session ID of an ASP page
(or any other scripting language) from PHP.

I assume that session id's are kept as cookies on the user's desktop.
If that's the case there should be some way of retrieving them.

Has anyone ever accomplished such a linkage?

The following worked in perl for ASP 1 - they might have changed the
cookie format since then.

foreach $_ (split /; /, $ENV{'HTTP_COOKIE'}) {
$session_id = $1 if /ASPSESSIONID.{8}=(.{24})/;
}

--
To reply email rafe, at the address cix co uk
Jul 2 '06 #3
In article <11*********************@j8g2000cwa.googlegroups.c om>,
j_********@yahoo.com (ImOk) wrote:

Looks reasonable (except for that perl gunk :)

Care to translate.
I wrote it years back, so I'd have to work through it all again, and I
don't have that set-up at the moment. You should be able to translate into
PHP's perl compatible regexps, but you'll need to check the current cookie
format.

--
To reply email rafe, at the address cix co uk
Jul 2 '06 #4

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

Similar topics

3
by: Steve Mauldin | last post by:
This is a standard ASP application that has several pages at the root withthe global.asa. I set a session variable session("accountid") = "123456" within an asp page and then response.redirect to...
0
by: Jim | last post by:
I need some help getting started with a .NET web project for a commercial site. I am new to .NET and my understanding of some (but not all) of its concepts is a little sparse. I apologize for the...
0
by: Jim | last post by:
This si a repost, I apologize but perhaps my original inquiry got buried under all the usenet spam... I need some help getting started with a .NET web project for a commercial site. I am new to...
4
by: Rahul Chatterjee | last post by:
Hello All I have 2 websites both using different style sheets (.css). The stylesheets are stored in a session variable and get set at the time the site gets invoked. What is happening is...
10
by: darrel | last post by:
I have this structure: mypage.aspx (class = mypage) myusercontro.ascx On the mypage.aspx I can declare a variable: animal = "monkey" I can read this from the UC by simply doing this:...
4
by: abcd | last post by:
I have an ASP application. It instantiaties some COM components and we put those COM components in Session variables...COM components have license restrictions...We have written new ASPX page ( for...
9
by: McGeeky | last post by:
Is there a way to get a user control to remember its state across pages? I have a standard page layout I use with a header and footer as user controls. Each page uses the same layout by means of...
0
by: tharika_c | last post by:
Hi, We have a simple ASP.NET web application where one of the Session variables, called Session("SSO_ID") gets created and assigned a value (equal to the HTTP_HRID request variable value),...
1
by: michael | last post by:
I have a series of pages I want to put a link on that will allow them to go back to the page they entered from (the referring URL). The problem is that to return to the previous page correctly I...
13
by: SAL | last post by:
Okay, don't bash me to hard for my design on this app, it's my first web app and it's in production. My basic design is using Datatables created via the designer with a business logic class in...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
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...
0
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...
0
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...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...

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.