Gossamer Forum
Home : Products : Gossamer Links : Development, Plugins and Globals :

Links SQL as Auction Site (plug-in ??)

Quote Reply
Links SQL as Auction Site (plug-in ??)
I've started work on a new project, a first step to the shopping system. I find it easier to do things in pieces, rather than try to do it all at once, and an auction program is perfect for that. Different functions are just that, different functions, and it will give a chance to get familiar to the Links SQL new logic.

Right now, I'm using a full copy of links, and modifying from the outset. So, before anyone gets too excited, that means it may require a full Links SQL license to run.

If you analyze Links, it does many things just like an auction program. After all, the big auctions are just a front end to a database. Each item is a unique object, and unrelated to anything but it's parent category. Categories are exactly the same as in links. The only difference is that the Detailed page is a part of the "link" and is the ultimate object.

Detail pages can be built static, and a dynamic header pre-pended to the output, or they can be built completely dynamicly. There are slight benefits to each method. If the static portion is kept in a "user" directory, accessed by 'UserID/ItemID.html' then you 1) over come directory limits on large numbers of files, and 2) you allow the user to keep a certain number of these stock files on their disk, in a workspace, to allow them to re-list common items, with a single click(advanced feature and 3) you take some real-time load off the parser since it just "includes" the item file and you can exempt that field from parsing. As I said, there are benefits to each system -- the dynamic system stores everything in the database, and eliminates any disk storage, but it puts more load on the server and server connections (which if you are on the same machine may not make a difference, but with a remote server, might make a difference).

Anyway, the following is a list of functions I visualize users will need, I added the admin and config options just to show I was thinking about them :) The first clumn is the function name, the "value" is the description of the function, and the stuff behind the ### is what the function expects.

All functions expect a User to be logged on, and will require that before doing anything that requires a User_ID. In most functions the {User_ID} being passed, is the QUERY ID, not the current user, which is always obtained from the logon cookie, never passed in.

Code:
admin => "Admin Menu Options, Board Configuration, etc",
config => "Board configuration Options, admin only",

add_item => "Add an item to the auction" ## form based, multiple
ask_seller => "Ask the seller a question", ## {seller_ID, Item_ID, User_ID}
change_reg => "Change registration information", ##
change_pass => "Change password", ##
change_email => "Change Email address", ## requires re-validation
contact_memb => "Contact another member in the system", ## {User_ID}
display_cat => "Displays a detailed category tree/list", ## {Categor_ID}
display_item => "Display an item", ## {Item_ID}
display_list => "Display items in a category", ## {category_ID, Next}
display_closed => "Display closed items, historical information", ## any search parameters
display_closing => "Display a list of items closing", ## any search parameters
display_going => "Display items closing in x-time", ## {Category, Time, Day}
display_hot => "Display items flagged as "hot"", ##
display_new => "Display New items", ## {Date}
display_seller => "Display a list of a Sellers Items", ## {User_ID}
display_bidder => "Display a list of a bidders Items", ## {User_ID}
edit_item => "Edit an item you have for bid", ## {item_ID}
feedback => "View or add feedback to a user", ## {User_ID}
help => "Help system, context sensitive", ## {Context_Tag}
join => "Join system", ##
lost_pass => "Send a new password to a user", ## or present "question"
place_bid => "Bid on an item", ## {Item_ID, BidAmount, User_ID}
view_seller => "View a sellers profile info", ## {User_ID}
view_bidder => "View a bidders profile info", ## {User_ID}
view_feedback => "view a users feedback", ## {User_ID}
view_bid_hx => "View an items bid history", ## {Item_ID}
view_similar => "View similar items", ## ?? fuzzy search, related keywords?
view_U2U => "View all transactions between two users", ## {User_ID_1, User_ID_2}
.

Distinction between "view" and "display" is very blurry. But, in brief,
display is a non-registered user call, and view requires logon.

As you can see, most of the above calls are a simple "SELECT" statement, wrapped
up in a display routine.

The only routines that are complicated are the place bid, since some calculations
and timing are required. Everything else is a query/response type action.

It would even be possible to provide a "my auctions" feature, simply by extending the user profile to hold a few options, then passing those options to a program that does a few "select" statements and passes them back to the "my_user.html" template.

Granted, I am not talking about a high-traffic system, since it's all PERL and lots of templates, but it should handle a reasonable volume. The biggest improvement would be in how well MySQL caches queries, so that repeated requests for an unchanged record come out of a cache, rather than a disk access (for example, someone hitting the refresh button every 5 seconds). The time update occurs after a record is retrieved, just before output, so that would be unaffected by an unchanged (or even changed) database record. The output always reflects the current time offset.

PUGDOG®
PUGDOG® Enterprises, Inc.
FAQ: http://postcards.com/FAQ


Quote Reply
Re: Links SQL as Auction Site (plug-in ??) In reply to
This may be easier than I thought...

I've been able to modify two scripts I used in the 1.1x version to the Links NG version, and they are _SIGNIFICANTLY_ shorter, with less house keeping code.

Time will tell if any thing will come back to bite, but it looks like it will be much, much easier to do things in the NG version, and what you do will even be more powerful!

I'm getting very, very excited :)

PUGDOG®
PUGDOG® Enterprises, Inc.
FAQ: http://postcards.com/FAQ


Quote Reply
Re: Links SQL as Auction Site (plug-in ??) In reply to
Hi Pugdog,

I wish i could understand it all like you do, I wish you lived a little closer than the other side of the pond so you could show me!

Anyway i like the idea of the plugin for the auction script! Excellent.



Regards

MDJ1
http://www.isee-multimedia.co.uk
Quote Reply
Re: Links SQL as Auction Site (plug-in ??) In reply to
It comes from many late nights, and no "life" <G>

PUGDOG®
PUGDOG® Enterprises, Inc.
FAQ: http://postcards.com/FAQ


Quote Reply
Re: Links SQL as Auction Site (plug-in ??) In reply to
Tell me about it it's 4:09AM here



Regards

MDJ1
http://www.isee-multimedia.co.uk
Quote Reply
Auction Update In reply to
I've got about half of it done. Half the work is in designing the database, the logic flow, and then developing the add_item and place_bid code. 90% of that is done. The templates for that took at least 2x as long as the code! <sigh>

Anyway, I think I may have to yeild to CSS for template design, since basic HTML seems to be lacking the grain to fit so much on the screen as needed. Everything has changed, to where the "style/CSS" tags are preferred over the HTML tags and way things have been done (tables, transparent spacer gifs, etc).

I may have a demo site working in about a week. It depends on numerous factors, including whether the beta comes out (since getting that working is my first priority).

Once that happens, I may need people who are interested in trying it out. Unfortunately, as I indicated before, this incarnation will take a full install of Links SQL to run. Hopefully, as I learn more about the structure and logic flow, this will become an add-on as well. Because this program uses all external scripts, and by nature _must_ be dynamic, it uses the GT libraries, but not the CGI, which makes it an add-on, from what I understand. _BUT_ right now, certain limitations in my understanding of the logic/hierarchy of Links SQL NG are relying on the default behaviour of the triad of Links/CatLinks/Category tables.

Because this is geared to small or medium sites, of a targeted or niche nature, while I worry about efficiency, I'm not worrying about problems due to high-load or multiple "snipes". The default behaviour of the program will be to extend the end-time 5 minutes after the last bid.

Because of this, many, many additional features can be made available, and increase the value and informative nature of the auction site. Virtually _nothing_ is unable to be put into the database, or gotten out of it.

Because of the extended close, and _NO_ATTEMPT_ to play in the big leagues, you can customize the display template to show any type of relations, and allow users to generate any sort of search or display options you would like.

Most of the big places don't let you search and get auctions sold by User1 to User2 or all of User2's auctions from User1. They don't let the user customize their output display or their "my page" to their liking. All this is possible with replacable parameters or targeted scripts. It's _your_ database, and a familiar output, so there are _no_restrictions.

By separating the user-interface development from the underlying engine, you can maintain the same engine, and look/feel across your site, while adding features to it that you or your users may want.

When I say I'm targeting this at smaller sites, the auction program has essentially unlimited capability to hold categories or items, but it will suffer from system performance issues related to it's pure-perl nature and high-level design. It will not perform in milli-second type situations, but I'm not designing it for that. Brick and morter auction houses never ended bidding at "3:05:33". As long as there was a hand raised, the bidding continued.

Basically, this disclaimer is the "dose of reality". Don't expect to run an eBay off this. An Amazon... maybe. :) It's a high-content, medium traffic type of solution -- for the rest of us :)



PUGDOG®
PUGDOG® Enterprises, Inc.
FAQ: http://postcards.com/FAQ


Quote Reply
Re: [pugdog] Links SQL as Auction Site (plug-in ??) In reply to
I'm bumping this up since I've started working on it again, and should have a site running in a few days.

A lot of factors prompted this, but the short of it is that I hope to have a working alpha very soon.

How this is released is also up in the air. It will most likely require a full Link SQL license, and there is really no reason to not go that way. The amount of time to try to bypass that is not worth the effort. It would mean rewriting many of the core functions of links, and that defeats the whole purpose. Right now it uses the Links categories, custom templates, search engine, etc, *and* should be able to use the standard links plugins to expand capabilities -- advanced search loggers, user tracking, etc.

Right now I'm converting it from a Links 2.0 beta format, to the current 2.12 community-enabled version.

Don't expect any code release for several weeks, but the demo should be up and running as soon as I get the domains pointed over.

I'm open to suggestions, the list of things that are going to be in it, as time allows (or are already in it):
  1. basic ebay-like, amazon-like, etc functionality
  2. • Unlimited categories and items (per links sql)
    • Suggest a new category
    • Number of open items per category listed in the Category listing lists (per links sql, template configurable)
    • Automated e-mail validation registration (per links sql)
    • All outgoing e-mails configurable and customizable by the administrator (per links sql - template easy to edit tags)
    • Lost password look up (per links sql)
    • Lost user handle look up
    • purge inactive users after x-time.
    • Encrypt user passwords (per links sql)
    • Non-registration mode to allow posting/bidding by anyone (not supported, but may be possible in later version)
    • Editable User Contact information
    • Buy It Now feature for auction items with no bids placed yet! (on/off)
    • Dutch fixed price auctions for Multiple items (on/off)
    • Dutch variable price auctions for Multiple items (on/off)
    • Item preview before an item is actually posted (bid/post confirmations, quick forms)
    • "Reserve" prices supported which allow a seller to set a minimum amount that he/she will accept (configurable display)
    • Seller determines minimum bid increment and length of the auction (configurable in setup)
    • Each item is given a unique ID number and URL, so sellers can advertise their auctions in newsgroups or via a link (per links sql)
    • Item display lists bidding history and product information (templates can be edited to show what info you want)
    • Easy bidding with a configurable quick bid form
    • Current server time displayed above closing time
    • Bid and Outbid notice sent to buyer and seller (selectable, customizable)
    • Closing E-Mail sent to buyer and seller (configurable)
    • sniper protection: auctions can close a configurable time after the last bid and the designated closing time
    • Integrated search engine allows search by any fields, (per links sql)
    • Users can view closed auction history and contact information - bidder, seller, loser, winner, etc (configurable via templates)
    • Auction items may be deleted by the system administrator/editors (per links sql)
    • E-mail sent to both high-bidder and seller on auction close
    • Fast re-posting of items that were not sold
    • Potential for quick import of off-line text files for "power listers"
    • Featured picture gallery (extra cost options and automatic)
    • Main page featured auctions (extra cost options and automatic)
    • Category featured auctions (extra cost options and automatic)
    • Standard, Bold, and Bold Background Listings (extra cost options)
    • Listing attention grabber icons (if people want to make some)
    • improved Ebay like auction item display (editable templates, customize look/feel you want)
    • Auction bidding confirmation display (configurable quick/confirm)
    • Payment / Condition / Shipping / Display
    • Ask the seller a question Q&A Forum Style
    • Seller and Buyer FeedBack, planned advanced "reviews" system (per links sql)
    • Seller can ban a user from bidding on their auction items (configurable)
    • Sellers can edit their auction item description (configurable)
    • Mail To A friend
    • View sellers other auction items
    • Billing receipt and info sent for new items posted (on/off)
    • Auto Delete Closed Auctions after X days (configurable)
    • Report Fraud
    • Problem seller form & censoring
    • Problem bidder form & censoring
    • New user registration credit (configurable, credit system and/or cash system)
    • Registration referral credit to the referring registered user (configurable).
    • And Much More!
  3. Planned
    - Gallery Listings with thumbnail generation -- (almost ready)
    - WYSIWYG HTML Editor for item descriptions (??)
    - Users can watch items without bidding
    - A "My Auction" page, summary page for all activity on the user, favorites, etc.


The above is in no major order, but pulled from old notes, other programs, feature lists, requests, etc.

Currently the program does the basics, and everything Links can do, which is far more than most auction programs out there at any price.

Most features can be added in as templates, and a few globals, or a back-end .pm file.

Most "additions" to listings are simply a database field.

Different categories can have different listings using the custom templates option, for example a trading cards area can have fields for year, series, manufacturer, card number, signature, etc. Beads can have a size, color, shape and materials field.

For now, all these features are stored in the Links table (yes it could get large) but once this is on it's way, the "arbitrary tables" feature will allow linking to an associated table for the "extra" data in each link, beyond the basic system needs (post time, end time, open price, close price, bids, etc).

Major features, like accounting, invoicing, user tracking, etc, will probably end up being plugins, as I doubt I'll ever get around to all that.


PUGDOG� Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.
Quote Reply
Re: [pugdog] Links SQL as Auction Site (plug-in ??) In reply to
We had a robbery at the store last week, and my portable/nightime machine was one of the casualties.

Large chunks of the auction code were stolen, and so was the backup disk that was in the machine at the time. Fortunately, it was a copy of the backup disk, I had made the day before, and that is the *only* good thing about the whole event. I made the back up because I was afraid of damaging the disk (I've been having a lot of old CDR's (including original "gold" disks) made in the past 10 or so years start to go bad on me).

Obviously, this has delayed deployment of anything until I can take care of the problems with having a machine like that stolen (passwords, etc).

Deployment will be delayed at least 2 weeks, but I'm also working out the logic for a new feature: "Swap clubs".

Code:
What this is, is part of the "Swap only" set up, where you run a swap site.
You can set up a monthly (or other time period) swap, and enter certain rules.
People sign up, to join in, and send you (the swap host) their swap items.
You distribute the swap items according to the rules of the swap.
(Usually, you send in x items, you get x items back).

This was an unplanned addition, but should be part of the first release, as it's something I want to set up my self.

Just an update as to why the site didn't deploy this week.


PUGDOG� Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.
Quote Reply
Re: [pugdog] Links SQL as Auction Site (plug-in ??) In reply to
Quote:
We had a robbery at the store last week, and my portable/nightime machine was one of the casualties.
Sorry to hear that. Frown
Losting something precious or important is always a bad thing. Especially that you lost a part of your, work, too. No matter how data loss happens, it's always difficult to suffer.
Keep up your head! (hopefully this is the correct expression in English)

Best regards,
Webmaster33


Paid Support
from Webmaster33. Expert in Perl programming & Gossamer Threads applications. (click here for prices)
Webmaster33's products (upd.2004.09.26) | Private message | Contact me | Was my post helpful? Donate my help...
Quote Reply
Re: [webmaster33] Links SQL as Auction Site (plug-in ??) In reply to
Thanks :)

I'm trying to break in the new computer now, but ... Dells are chinzy. It was the only one with a track stick (IBM had some too, but longer lead time). Toshiba seems to have gotten rid of them, at least from the ones in the stores (not that I like toshiba... I still remember them selling to the russians via a scandanavian company during the cold war).


PUGDOG� Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.
Quote Reply
Re: [pugdog] Links SQL as Auction Site (plug-in ??) In reply to
I'm not quite back where I was, with this, but any ideas, or suggestions, now is the time.


PUGDOG� Enterprises, Inc.

The best way to contact me is to NOT use Email.
Please leave a PM here.