I figured I’d jump back into the conversation here, since this is the ‘hacks’ section, while the other thread was in ‘requests and feedback’. ??
I’m still not ready to package it up for public consumption, but if you check out my site later today, you’ll see a lot of the revisions. Though, some are under the covers.
– I now can show ‘optional extra data’, configurable outside of the module. Basically, a list of product data fields and titles to show for each.
– I now track history of products being shown on the page, and won’t double-show a product. This could be made optional, but went with the next feature…
– I now track when I have ‘inlined’ amazon links within the body of a post, and when on a list/search/cat page, I now ‘pre-cache’ the products that would be show, and show them in the sidebar. (It’s the “Gear on This Page” block on the left…)
– When you go into a post with an amazon link showing, because of history tracking, it’ll no longer show up in a sidebar that has it as part of the group.
– Also when you go into a post with shown amazon product, I show extended data there (and not on sidebar), showing same underlying code setup, different display. I have the rank listed, and also the MSRP, when they’re in the product data.
– Also in post, you’ll see the first sidebar shows “similar product” search results. I’ve added Similar, UPC, and Search queries, though I’ve only used/tested Asin and Similar queries so far (UPC and Search aren’t of much use to me right now).
– It would be easy to add hard-coded lookups, like the ‘best sellers’ stuff — I think that’s an accessible list to as for, for a given Category of product.
PHEW.
That’s not all the changes, but a lot of it. I think I’m starting to head back toward a stable state, and will look to cleaning up the code so that you can call functions rather than setting global variables, to make things happen.
I’ve also thought about ‘random’ listings — that is, query results return a dozen, show a random selection of 5 every time it outputs…
Lastly, been considering adding an admin page for what products are in what cache-file, managing this stuff… but when you start accessing all the more powerful features (Similar, Search, automatic tracking, etc.), it’s just easier to put an array in PHP directly.
One last Q: I know there are a lot of ‘amazon SDKs’ out there. This originated from an Amazon sample, as they all do (hah!), but has months of work put into building up a ‘package’ that does more for you up front. I’ve seen some developers with SDKs do something like “I substitute in my Associates ID randomly 10% of the time a link is generated, to help offset the cost of development, and keep the package itself free.” Would people be ‘open’ to that (I don’t HAVE to do that, but it’d be nice if this thing becomes more widespread to actually cover a little of the upkeep costs… ?? ).
Interested in seeing denyerec’s system when it’s together. I assume that’s a more ‘static’ system — ie., build up the product database and links ahead of time? Sounds like a cool approach for people who just want an immense product database to select from for display (i.e., random book-link on ever page generation).
-d
https://www.chait.net