Fantastico - Phpauction

liunx

Guest
I installed PHPAction...all went well...but... When I created a test item for auction there appears to be an issue with the timestamp. You can see the single item here: <a href="http://auction.johnlathrop.com/index.php" target="_blank">http://auction.johnlathrop.com/index.php</a><br /><br />Look at the date last created auctions...it is messed up. Dates are messed up in other display locations.<br /><br />I'm wondering if anyone has had success with this program...or has seen the problem as well. I thought I would ask before I start digging into it...<!--content-->
It appears that the PHPAuction code has a problem with our version of MySQL...??? In any case these are my observations while looking at the listauctions.php file...<br /><br />The code retrieves the date in typical fashion:<br /><br />$tmp_date = mysql_result($result,$i,"starts");<br /><br />The value of $tmp_date in my example is: 2007-02-21 22:45:33<br /><br />Then the code attempts to parse out the year, month and day parts:<br /><br />$day = substr($tmp_date,6,2);<br />$month = substr($tmp_date,4,2);<br />$year = substr($tmp_date,0,4);<br />$date = "$month/$day/$year";<br /><br />The only problem with this that is it is picking up the dashes. The result is that the value of $date is "-0/2-/2007" as displayed.<br /><br />I found that if I insert this line just before the date parsing the result is as desired:<br /><br />$tmp_date = ereg_replace("/|-|:|\ |\.|,","",$tmp_date);<br /><br />$tmp_date becomes "20070221224533" and $date becomes "02/21/2007"<br /><br />Now I just need to find all of the other places in code where dates are used. This doesn't sound very "Fantastico". <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/wallbash.gif" style="vertical-align:middle" emoid=":wallbash:" border="0" alt="wallbash.gif" /> <br /><br />I'm not a PHP or MySQL expert...is there an easier solution?<!--content-->
A couple of files have code like this:<br /><br />$ends = substr($item[ends],6,2)."/".substr($item[ends],4,2)."/".substr($item[ends],0,4);<br /><br />That I changed to this:<br /><br />$tmp_ends = $item[ends]; //added<br />$tmp_ends = ereg_replace("/|-|:|\ |\.|,","",$tmp_ends); //added<br />$ends = substr($tmp_ends,4,2)."/".substr($tmp_ends,6,2)."/".substr($tmp_ends,0,4); //added<br /><br />The dates seem to work now...I think I found all of the spots that needed a fix. <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/sweatdrop.gif" style="vertical-align:middle" emoid=":sweatdrop:" border="0" alt="sweatdrop.gif" /><!--content-->
This is my last word on this subject of PHPAuction provided by Fantastico. Don't use it! <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/surrender.gif" style="vertical-align:middle" emoid=":surrender:" border="0" alt="surrender.gif" /> <br /><br />After the date parsing fixes I found a few more things I'm still working on:<br /><br />1) Email confirmation when a user registers is not working...no email is sent. (However, an email confirmation is sent when a user submits an item to be sold...so, there's an opportunity for comparison)<br /><br />2) SQL problem is encountered when a bid is entered...it is probably related to the timestamp:<br /><br />Database access error. Please contact the site administrator.<br />update PHPAUCTION_auctions set current_bid=10000,starts=2007-02-22 23:25:28,ends=2007-02-25 23:25:28 where id="3c5d32571e80ee9d33e3d64f918c0755"<br />You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '23:25:28,ends=2007-02-25 23:25:28 where id="3c5d32571e80ee9d33e3d64f918c0755"' at line 1<br /><br />Too many problems with this product <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/thumbdown.gif" style="vertical-align:middle" emoid=":thumbdown:" border="0" alt="thumbdown.gif" /> ...but, I'm a little determined now to get it working. <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/wallbash.gif" style="vertical-align:middle" emoid=":wallbash:" border="0" alt="wallbash.gif" /><!--content-->
I tried it and I did get the register email<br />But I don't care for the script.<br />It would not let me bid?<!--content-->
Well, I got the bidding to work <img src="http://www.totalchoicehosting.com/forums/style_emoticons/default/sweatdrop.gif" style="vertical-align:middle" emoid=":sweatdrop:" border="0" alt="sweatdrop.gif" /> ...more date issues.<br /><br />The registration confirmation email is working too...strange issue...won't even go into it.<br /><br />I just want a cheap site to try to auction off 100s of old early 1900 postcards and other things...drop the bait and see if anyone bites...EBay is too expensive for this kind of thing.<!--content-->
Might be time to look at <a href="http://www.hotscripts.com/PHP/Scripts_and_Programs/Auctions/index.html" target="_blank">hotscripts.com for a better script</a>.<!--content-->
 
Top