 | |  | | | Classifieds Bug Reports Post any problems you may be having with Classifieds here. |
August 10th, 2006, 06:03 PM
|
#1 (permalink)
| | Member Verified Customer
Join Date: Jun 2005
Posts: 179
| possible sendnotice.php bug?
One of our users has complained that he's getting notices about his auction ending continually after it's ended. Is this because finished aucitons are listed for 7 days on our site?
|
| |
August 10th, 2006, 08:03 PM
|
#2 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,945
|
I do not see how this would be possible. Here is the query in sendnotice.php to grab the expiring auctions Code: Content visible to verified customers only.
Now once the email is sent we issue this query Code: Content visible to verified customers only.
Therefore status is no longer 0 and thus will not be found when sendnotice is ran again.
|
| |
August 10th, 2006, 08:34 PM
|
#3 (permalink)
| | Member Verified Customer
Join Date: Jun 2005
Posts: 179
|
As I read it:
So if we've gone past the auction end send out an email:
SELECT id,user,userid,title,enddate,highbidder,price FROM {$Globals['pp_db_prefix']}products WHERE enddate < $today
Then we set the end date to today? ($newend):
UPDATE {$Globals['pp_db_prefix']}products SET status='$today',enddate='$newend' WHERE id=$id
As I see it, enddate is always set to localtime(); on the loop? Isn't that always going to be less than the time in a few minutes? I can't see a flag in the code that's ever checked to say "has_ended". It just seems to be filtered on the timestamp.
I can't see how an auction is actually closed down. I'm looking at the SQL for the advert for the affected user and his auction is sending out an email telling him the result of his auction every 10 minutes.
edit: Ah I see the status is set to a date when it's finished ? ...ahh
I'm going to get a copy of the emails this uyser has received so I can compare them to the code and the SQL to find out the issue.
Last edited by Arnie; August 10th, 2006 at 08:48 PM.
|
| |
August 11th, 2006, 08:06 AM
|
#4 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,945
|
We set status to the time which means its not 0 anymore hense the next time you run sendnotice the ad which has already been processed can not be found in the query results when sendnotice is ran again. Code: Content visible to verified customers only.
|
| |
August 15th, 2006, 04:15 PM
|
#6 (permalink)
| | Member Verified Customer
Join Date: Jun 2005
Posts: 179
|
Hello?
As I mentioned the symtoms appear after a user flags their auction as closed before the listing's end date. They then seem to get reminders every 10 minutes (each time the cron task is run).
Any ideas?
|
| |
August 15th, 2006, 04:22 PM
|
#7 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,945
|
A user can not stop an auction only an admin can furthermore if an auction is closed by admin status is set to that time and hense it is not able to be pulled up in this query in sendnotice.php Code: Content visible to verified customers only.
|
| |
August 16th, 2006, 09:35 PM
|
#8 (permalink)
| | Member Verified Customer
Join Date: Jun 2005
Posts: 179
|
I spoke to one of the users concerned. He ran this auction: http://www.arniesairsoft.co.uk/class....php?product=4
It ended automatically. As you can see though it's listed as "SOLD" but at present going to end on "Tue August 22, 2006 22:13, 5 day(s), 18 Hours, 40 Minutes, 34 Seconds". He received multiple emails that said:
"There were no bids on your item. You may want to review your
auction and make adjustments before relisting.
"
..and listed the auction URL.
They received about 160 messages like that after the auction ended, they arrived once every ten minutes, then the emails stopped.
|
| |
August 16th, 2006, 09:54 PM
|
#9 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,945
|
You see the dilema here though in what I am trying to say though. The only way I see looking at the default unhacked code to mark an auction sold is by the admin which would be you. A user does not have a close an auction link. Then in the sendnotice.php script that auction would never be pulled up in the mysql results. You can even try running this query here yourself and verify. But from what I am seeing two things here
For that auction status is not 0 and the enddate since it ends in the future is greated then todays date so lets look at the sendnotice.php query and you will see where I am coming from. I would be glad to assist if I saw something out of the ordinary but based on the query below that ad would never be pulled into the sendnotice script because there are those two items which would not match the criteria for grabbing it and emailing and those I marked in bold. Code: Content visible to verified customers only.
|
| |
August 17th, 2006, 09:23 AM
|
#10 (permalink)
| | Member Verified Customer
Join Date: Jun 2005
Posts: 179
|
I am using the latest download from yourselves, and unhacked code.
Here's another auction that's ended: http://www.arniesairsoft.co.uk/class...hp?product=114
You see that somehow it's reset the end date to in the future? Any idea why that is?
|
| |
August 17th, 2006, 09:38 AM
|
#11 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,945
|
thats easy it is set to an enddate higher than today based on your enddate in admin settings for how long you want to show expired auctions ads Code: Content visible to verified customers only.
As stated this is fine and my prior post explains there is nowhere I can see that a user would get emailed more than once since the query would never meet the requirements to be pulled by the query. Did you try running the specific query in sendnotice.php I posted to confirm that what I am seeing is indeed correct.
|
| |
August 17th, 2006, 10:13 AM
|
#12 (permalink)
| | Member Verified Customer
Join Date: Jun 2005
Posts: 179
|
Yeah next time a user complains of multiple emails I'm going to be keeping a direct eye on the sendnotice script to see if I can spot it.
|
| |
August 17th, 2006, 10:29 AM
|
#13 (permalink)
| | Photopost Developer Verified Customer
Join Date: Jun 2002 Location: Abingdon,MD
Posts: 71,945
|
Yeah I would love to help but everything I am seeing points to no issues with the code as the query is pretty specific in what it looks for to be able to send not an email and with status not being 0 on those auctions there is no way it would be sent out via sendnotice that I can see.
|
| | |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | | | | Thread Tools | | | | Display Modes | Rate This Thread | Linear Mode | |
Posting Rules
| You may not post new threads You may not post replies You may not post attachments You may not edit your posts HTML code is Off | | | All times are GMT -5. The time now is 06:36 PM. | |