View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

Problem with ending a session

Thread began 11/05/2009 12:05 pm by Roxana | Last modified 11/06/2009 6:38 pm by Roxana | 1100 views | 6 replies

Roxana

Problem with ending a session

Hi,

I have set up the checkout_success page to sent a confirmation mail.

When I place a new order, the order number on the success page increases by one, however the order number of the confirmation mail does not. For example the new order no. shown in the browser is 130. The order number shown in the confirmation mail is 125. If I order three items, the confirmation mail shows three lines, but the item displayed is from order no. 125. Yesterday the numbers for the confirmation mail stayed at the same number, this morning, the number was correct, but now stays at the first order number of today.

I suspect, that the session is somewhat ended, but not entirely (if that is possible).

After the html tag this code is added:
<?php
mysql_free_result($rsorders);

// Initialize the session.
// If you are using session_name("something"), don't forget it now!
session_start();

// Unset all of the session variables.
$_SESSION = array();

// If it's desired to kill the session, also delete the session cookie.
// Note: This will destroy the session, and not just the session data!
if (isset($_COOKIE[session_name()])) {
@setcookie(session_name(), '', time()-42000, '/');
}

// Finally, destroy the session.
session_destroy();
?>

Do I need to make a change to this code? Or what else could be wrong?

Any help would be very much appreciated.

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...