Jump to content
Sign in to follow this  
bmcewan

Purchase Without Account Updated & Admin Functionality

Recommended Posts

Hey Guys and Galls

 

I have PWA installed, and been following this issue about two people being logged in at same time.

 

I have PWA set to false in admin, so its not an option, and when I have two users logged into there accounts, I dont get any bleed over from one to the other.

I used Firefox browser to test, my computers are on the same local network.

but with two usernames logged in at the same time,, and even with items in cart, they dont blend toether, or cant see the others information.

Maybe those having the issue could post what browsers they are using, in case that has something to do with it as well.

or it maybe another mod that is also blended in, that is in common, that may not work together.

 

With PWA set to true, and one customer logged in, and second customer in checkout using pwa, i still get no bleed over of account info or shopping cart items either.

With two customers both in pwa checkout, I still get not blending of account, either in cart items, or in the address info put into the system.

 

So far, I have been unable to re-create this issue on my site.

 

www.hillbillybargains.com

 

There is going to be some common connection somewhere to resolve this issue, but figuring out where.

 

If i can help with anything,, Just ask . I'll try anything i can to help resolve this issue.

 

oh,, i have forced cookie use as well

 

 

Tom

Edited by Qwiz

no bugs in my stuff,,, just random features ;)

Share this post


Link to post
Share on other sites

Could it have anything to do with whether sessions are file-based or SQL-based, or cache files on a shared server?

Share this post


Link to post
Share on other sites

I tested with FF and IE6 and on both the problem appears. I found it is even not neccessary to login PWA on both browsers. If I put something inside the cart on one and login PWA on the second the product from the first will be visible with the second cart also. Logging in as a registered customer on one does not create this problem.

 

I have been trying to follow the process of how PWA created the 'noaccount' user but I have a hard time to follow what is happening. Some help from others would be greatly appreciated to tackle this odd behaviour.

When reading the installation instructions again I noticed that somewhere along the line it is noted that the file order_info_process.php is not used anymore but as it is still provided I do not understand this remark completely.

What I found is that after the login_pwa.php you are going to order_info.php but, and I think this is important, the actual form shown is from order_info_check.php which is also the place where any errors are handled. However when you create an error the page loading is then order_info_process.php ?!

This means that if you do everything right the first time you will never see order_info_process.php but only order_info.php with order_info_check.php.

When you look at the source code of order_info.check.php and order_info_process.php you will see however there is a lot handled inside order_info_process.php which is not replicated within order_info_check.php

If this program flow is indeed the case it might mean the problems are somewhere within the code never executed from order_info_process.php

 

I hope this makes sense and any help/insight from the original contributor(s) will be very welcome !

Share this post


Link to post
Share on other sites

Howard,

 

May I ask if you are using the same pc to do both accounts, just different browser screens? or are you using two different pc?s

 

I used two different pc's and so far, can not re-create the issue.

 

I am not saying its not out there,, just trying to help narrow down where to look.

 

If we can just figure out whats in common,, then we wont have so many files to look at for security issues,, ;)

 

if you would like to go to my page and try it, you are more than welcome.

 

now,, after typing the first part of this, I went back to test some more.

 

If i use the same pc, but two browser windows, and i add something to a guest cart, and click checkout and start into the pwa check out process, and then go to the other browser window, and log into the account, the item is in the cart,, but that is because the page is setting a cookie on this local computer, and any guest cart, is kept and put into a user cart when that user log's into there account.

 

This is due to the fact that you dont want a customer to ad things to there cart, and then log in, and find out they have lost what they had in there cart and have to start over.

 

Now, when i run this same test, on two different pc's, This DOES NOT happen.

So that indicates to me, that it is cookies being placed on the local computer, which is supposed to happen in basic osc.

even though its two different browser screens, there on the same pc,, so it cant tell which browser it came from.

Make sense?

 

if i use one pc to ad something to my cart, and start into the checkout with pwa, and then turn to one of my other pc's, and log into my account, there is no effect between the two,

just if its on the same pc, where it can confuse the cookie being placed.

 

using the same pc is the only time i can re-create this issue

 

Regards

Tom


no bugs in my stuff,,, just random features ;)

Share this post


Link to post
Share on other sites
Howard,

 

May I ask if you are using the same pc to do both accounts, just different browser screens? or are you using two different pc?s

 

I used two different pc's and so far, can not re-create the issue.

 

I am not saying its not out there,, just trying to help narrow down where to look.

 

If we can just figure out whats in common,, then we wont have so many files to look at for security issues,, ;)

 

if you would like to go to my page and try it, you are more than welcome.

 

now,, after typing the first part of this, I went back to test some more.

 

If i use the same pc, but two browser windows, and i add something to a guest cart, and click checkout and start into the pwa check out process, and then go to the other browser window, and  log into the account, the item is in the cart,, but that is because the page is setting a cookie on this local computer, and any guest cart, is kept and put into a user cart when that user log's into there account.

 

This is due to the fact that you dont want a customer to ad things to there cart, and then log in, and find out they have lost what they had in there cart and have to start over.

 

Now, when i run this same test, on two different pc's, This DOES NOT  happen.

So that indicates to me, that it is cookies being placed on the local computer, which is supposed to happen in basic osc.

even though its two different browser screens, there on the same pc,, so it cant tell which browser it came from.

Make sense?

 

if i use one pc to ad something to my cart, and start into the checkout with pwa, and then turn to one of my other pc's, and log into my account, there is no effect between the two,

just if its on the same pc, where it can confuse the cookie being placed.

 

using the same pc is the only time i can re-create this issue

 

Regards

Tom

 

Tom,

 

At first I was also thinking about a cookie issue because I tested on one machine with two browser sessions but reading the other posts already gave an indication it also happened when people were on totally different computers and locations. So I tested this also with someone far away and the same behaviour occured. I find it weird as when I let my browsers accept no cookies the problem does not arise. I tried your option with Force cookie to true (and my browsers back to accept cookies) and the problem is still there. Also i believe IE and FF have different cookie directories so they should not interfere with each other if it were a local cookie problem. After looking at the program flow for PWA I have a feeling this is not a good way but I am not sure it this could really be where the problem comes from. If you are using PWA 0.82 and can not re-create this behaviour on different computers one would think it is a server issue after all but then why not with the normal login procedure and only with the PWA part ?

I saw some specific cookie handling within the order_info_process.php which is totally ignored when going straight through the PWA check-in.

The coding is very hard to follow and with my minimal PHP knowledge it is difficult to tell why, where and how.

I, and I am sure we, very much appreciate your time and help for looking into this !

Share this post


Link to post
Share on other sites

I hope you all excuse me another question about PWA which however makes me wonder if I missed something somewhere or if this is how 0.82 works:

 

What happens is this:

I created manual orders by using the PWA option for orders from this year coming from my old shop. That went all fine but I noticed that in the end I only have order records for these particular customers but no customer record. Only when a PWA customer does not go completely through the checkout I will find a customer record (and no order record of course). I assume the customer record is thrown away as soon as he/she finishes the checkout procedure ?! Looking through the database fields I see however a defined field purchase_without_account within the customer database and also within the order database. The question is why this field is inside the customer database as it gets never filled when the PWA user completes the checkout ? If the PWA customer doesn't complete the checkout I would not be interested in their customer record as now I only have to clean up the mess made by PWA customers not ordering in the end. This would also mean I think you can skip a lot of checks to see if they went PWA already and/or have a normal login ID (if a normal customer likes to use PWA now and then I wouldn't mind and if he/she can live with filling in the address etc. details again I can't complain either).

By deleting the PWA customer record at the end of the checkout process there will be a problem when you want to view the Admin report for Customer Order-Total because PWA orders are not taken into account simply because there is no customer record for them. Personally I like the way it works now despite the problem with the Customer Order-Total report (which must be easily fixable for PWA users by looking at the orders table also).

I am curious how others think about this and if it is indeed by design the PWA customer record gets deleted after a succesful checkout ? And if so, would it not be better to not create a customer record for a PWA user at all so your customer records will not have the chance to get polluted with PWA records from customers not going to the checkout after all ?

Share this post


Link to post
Share on other sites
No it is not safe to assume anything, my tests showed that a user can not only see the name, address but change the details, certainly with PWA turned on.

 

When I tested this with PWA turned off in the admin, I believe the results were exactly the same but I want to recheck this just to be sure. Certainly, users saw each other's cart contents in this case also (i.e. with PWA switched off in the admin). I can't check re access to users details now with PWA off as I'm on my way out, but will return with the results later today.

When I try this with two different computers on the same network, I cannot recreate the problem. I use two different user names and email addresses for the PWA accounts. You aren't using the same UN on both computers when you see the problem, are you?

Share this post


Link to post
Share on other sites
When I try this with two different computers on the same network, I cannot recreate the problem.  I use two different user names and email addresses for the PWA accounts.  You aren't using the same UN on both computers when you see the problem, are you?

 

I don't think he does and neither did I. What are your settings which could affect this ? And for that, you never answered my question about the setting of your customer details considering the State field which I am still curious for as related to some missing shipping options when using PWA and this set to false.

Share this post


Link to post
Share on other sites
I don't think he does and neither did I. What are your settings which could affect this ? And for that, you never answered my question about the setting of your customer details considering the State field which I am still curious for as related to some missing shipping options when using PWA and this set to false.

I've got State set to True under Customer Details.

Share this post


Link to post
Share on other sites
I've got State set to True under Customer Details.

 

Thanks, thought so...

Any ideas why this seems to happen to some but not all (appearantly) ?! You also have PWA 0.82 installed or by chance an earlier version ?

Do you recognize the things I wrote in my last message ?

I know, a lot of questions but there is some odd behaviour and glitches with PWA which would be nice to get straigthened for all of us.

Share this post


Link to post
Share on other sites
Could it have anything to do with whether sessions are file-based or SQL-based, or cache files on a shared server?

 

I am running sql based sessions, and on a shared server.

 

I can only re-create this issue if it is done on one pc at the same time.

 

Regards

Tom


no bugs in my stuff,,, just random features ;)

Share this post


Link to post
Share on other sites

Hi -

I installed this the other day, and I'm not 100% positive that it is the culprit, but ever since installing this, I'm getting replies back from customers saying that the "Order Update" email they get (when I add the tracking info and change the order status from "Pending" to "Delivered" is BLANK.

 

I've never gotten complaints about this until I installed this contribution. Any thoughts?

 

Thanks,

Fred

Share this post


Link to post
Share on other sites
Hi -

I installed this the other day, and I'm not 100% positive that it is the culprit, but ever since installing this, I'm getting replies back from customers saying that the "Order Update" email they get (when I add the tracking info and change the order status from "Pending" to "Delivered" is BLANK.

 

I've never gotten complaints about this until I installed this contribution.  Any thoughts?

 

Thanks,

Fred

 

 

This is resolved - the answer was found here:

http://forums.oscommerce.com/index.php?act=ST&f=11&t=132582

Share this post


Link to post
Share on other sites
Yes, I saw the code that checks for failure and redirects, but it did not seem to work for me. It gave some error text, but rather than the actual text it gave something akin to /catalog/this+email+address+is+already+registered+.....php file cannot be found.

 

Hi Erin (and anyone else with this problem),

 

This appears to have something to do with having the search engine safe urls option turned on. I turned off search engine safe urls and now it redirects to the login page without error 404 and displays the error message fine.

 

The piece of code that causes this is in Order_Info_Process.php (line 209 in my file)

 

if ($check_customer['purchased_without_account'] != 1) {

tep_redirect(tep_href_link(FILENAME_LOGIN,

'login=fail&reason=' . urlencode(

str_replace('{EMAIL_ADDRESS}',$check_customer['customers_email_address'],PWA_FAIL_ACCOUNT_EXISTS)), 'SSL'));

 

There should be a way to rewirte this so it works with search engine safe URLS and I will post the fix here if I come up with one.

Edited by aschmuck

Share this post


Link to post
Share on other sites

anyone figure anything out on the problem with two ppl being logged in?

 

I am not having that problem myself, but would like to know if it was resolved or not?

 

Regards

Tom


no bugs in my stuff,,, just random features ;)

Share this post


Link to post
Share on other sites

Hi again,

 

The error 404 problem appears to be caused by the definition of PWA_FAIL_ACCOUNT_EXISTS and using search engine safe urls.

 

The definition is (line 29 in /catalog/includes/languages/english/login.php)

 

define('PWA_FAIL_ACCOUNT_EXISTS', 'An account already exists for the email address <i>{EMAIL_ADDRESS}</i>. You must login here with the password for that account before proceeding to checkout.');

 

Apperanltey if you have search engine safe urls enabled the italic tags don't get encoded correctly and cause the problem. If you remove them by changing the definition to the one below it should fix the problem

 

define('PWA_FAIL_ACCOUNT_EXISTS', 'An account already exists for the email address {EMAIL_ADDRESS}. You must login here with the password for that account before proceeding to checkout.');

Edited by aschmuck

Share this post


Link to post
Share on other sites

Im also wondering about the issue with two customers seeing each others content.

 

I've so far only installed this on a test shop and can't reproduce that error but im still interested

in knowing the cause of that error.

Share this post


Link to post
Share on other sites

For me it is reproducable and it still worries me but testing this on my own is not enough to find the possible culprit. I suppose it would be nice to have someone, Tom ?, who doesn't suffer from it to test on my shop and I on his/her shop which has PWA 0.82 also but not the problem. I wrote something about how PWA seems to work and got no reply/confirmation on it but I am still curious how others feel about that.

Share this post


Link to post
Share on other sites

Howard.

 

Check your PM's I did some testing...

 

Tom


no bugs in my stuff,,, just random features ;)

Share this post


Link to post
Share on other sites
Howard.

 

Check your PM's  I did some testing...

 

Tom

 

Yep, got those. You still can't reproduce it through my site and I couldn't reproduce it on your site. So it must be something local and/or one or more osC settings I suppose.

 

I'll get back to you later.

Share this post


Link to post
Share on other sites
Howard.

 

Check your PM's  I did some testing...

 

Tom

 

This is silly but I can't reproduce it on my one or more computers anymore :'(

I can not recollect to have changed anything related to this so unfortunately I can't explain it.

I'll PM you later with some things I found on your site in progress while testing the PWA thingie.

 

Thanks a bunch for your help !

 

Grtz.

Howard

Share this post


Link to post
Share on other sites
Anyway, Fredrik, if you have any thoughts or come up with a solution, please post here, as I think there are quite a few of us with the print order contribution that need a solution.

 

Peace,

Erin :)

 

Thanks for the respond Erin.

I'm not a wizz on php, but I will try to pull the order number from the database so the invoice can be viewed.

 

I have some other stuff I need to do first, but if I get it to work I will post it.

 

// Fredrik

Share this post


Link to post
Share on other sites

Having an issue when clicking continue on Order_Info.php page following entering customer details - the system just then hangs.

 

Any ideas why this is happening ?

 

TIA.

Share this post


Link to post
Share on other sites
Scarlet: I had that problem as well (in 0.7 actually)... it happened when the customer entered something wrong and PWA took them to the "change the error" page... the delivery address would then be entered as blank.

 

installing .82 fixed the issue

 

Ok, well, it was working fine for a while once I upgraded the purchase without account, now once again, I got an order where the shipping address is totally blank, so no shipping was configured. So the upgrade didn't fix the issue.

 

I guess what is really needed is something that tells it if the shipping address is blank, to use the billing address.

 

Once again, I have tried and can not recreate the error.

 

www.californiababestuff.com


Tara Lang

Share this post


Link to post
Share on other sites

Is there a way to hide the "Log Off" and "My Account" options after someone selects the pay without account option? As a customer, if I chose this option I wouldn't expect see that an account was created.

 

Also, regarding the multiple PWA customers seeing each others cart contents: I haven't been able to reproduce the symptom testing on two windows machines-one running firefox and the other IE, and a mac running safari. All machines on the same network with cookies enabled.


Quidquid latine dictum sit, profundum viditur.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×