![]() |
Add Product Actions to Lesane's Store Hack!
Physical Product Hack for Lesane's Store Hack
by ChurchMedia --------------------------------------------------------- NOTE: This hack has not been updated for the latest version of the Store Hack for VB2. I'll write a new hack if and when there is a VB3 version of the Store Hack --------------------------------------------------------- What this hack is for: If you want to sell actual products in your community store, such as books, videos, coffee mugs... whatever. I suggest adding products that promote your site. You can get all sorts of customized merchandise from Cafe Press. Before you ask, this is not a shopping cart to sell things with real money. It's to redeem points for tangible products. If you don't like the idea of giving stuff away for posting, this isn't the hack for you. --------------------------------------------------------- How this hack works/what it does (after initial setup): 1) You add a new action to the database from your admin cp 2) You modify 2 small parts of a code chunk and add it to your store.php 3) When a user purchases an item, they enter their address, etc. 4) You will receive an email with the product info and shipping info 5) The user receives a "receipt" by email as well --------------------------------------------------------- INSTRUCTIONS: 1) Follow the instructions in: initial_hack_instructions.txt You only have to do this once! --------------------------------------------------------- 2) For new actions, follow the instructions in add_action_instructions.txt You have to follow these instructions for each new action/product you add, so keep them handy! --------------------------------------------------------- Modifications: 1 Initial Modification to store.php 1 Modification to index.php in admin Templates: 2 new templates are added Screenshots are included in the zip file. Enjoy! |
Screen shot of admin -- adding a new action to the database
|
Screenshot of admin: after adding a new action
|
Screenshot of store after adding product
|
Screenshot of user buying product and filling out shipping info
|
Screenshot of final screen when user completes the purchase
|
Screenshot of the email that the admin receives
|
Screenshot of the email that the user receives
|
All I can say is that it is ABOUT time! Sheesh. I will be installing this over the weekend! This matches clearly with my request way back when (located here).
Q) Is there a way you can bypass the address part and simply just send an email with the email only? |
Quote:
Let me know if you have any questions.... |
If you downloaded the variations zip (which I deleted now), don't use it. I just realized there still needs to be a verify step. Just follow the instructions in the post above if you want to skip the shipping info...
|
Great job!
One question, is there a way to sort items in price order (from lowerest to highest)? |
Quote:
|
ehm..is this for fun or is it a serious sort of ecommerce kind of thing? Shipments to what and where? Are they pay with points for gizmo's?
|
Quote:
|
Ok :) It looks almost as a miniature itemshop and could act that way if there were icons or mini images to display in the postbit. Very nice CM.
|
Lovely add-on :)
However i wouldn't offer my members something for free for just for posting :D. Any chance you could modify this like so: - When entering the store main you have 2 places you can go. One where you sell actual products and another place where you can buy real products. - then on the real products page you put in your information as such and then it takes you to paypal with some info filled in the form and where you can pay in real money :)? Regards - miSt |
It's really only desinged for redeeming points for product. Like I said, it's kind of a marketing mechanism for my real oline store. I use Miva Merchant with a MySql mod for the database. I've also tried X-Cart, which is an excellent and affordable php-based shopping cart.
Lesane's original store hack was desinged to sell "forum enhancements" redeemable by points. This is just a modification for real product. If you want an actual cart and have people pay real money, check out the carts I mentioned. Also, keep in mind that I am in the "information business", so the more people post to my site, the better. I don't mind paying for a few items to make that happen :). |
Quote:
|
It's not a shopping cart. I suppose you could do a bunch of coding and turn it into one, but that's a whole different ball game and doesn't have anything to do with forum posting. You would be better off with x-cart. You could do some mods to x-cart to access VB's database for login info and look, so in a way it would be integrated with VB.
Just to add some perspective, be sure you understand Leane's original hack, Found Here. |
Just another thought -- if you aren't thrilled with the idea of giving away product for posting, consider adding products that promote your site. Like mousepads, shirts, mugs, etc. with your logo. You can get all sorts of merchandise from Cafe Press.
|
Quote:
But still is there any chance you could do something like i mentionned. People are always asking for a proper store for their vbulletin's with intigrated log-in's etc. Any chance of you doing it :)? I'm sure if you got stuck with anything one of our expert hackers could help you too :) Kindest Regards - miSt |
/me clicks install
|
Hello
sorry i didn't find store.php file in your attachment .. Thanx:) |
Quote:
https://vborg.vbsupport.ru/showthrea...threadid=36991 you need that hack added before you can add this |
got a litle problem
you said in your instruction page Quote:
what's my problem? |
ChurchMedia, THANK you!!!
Will install this as soon as possible. I have magazine subscriptions I give away but this will automate this a lot!!! Thanks! |
Quote:
The code chunk for the store is: PHP Code:
|
I did find one small error in the code. It does not cause an error, but it doesn't update your items sold. I fixed it in the zip file, but if you alrady downloaded it, in store.php, find
PHP Code:
PHP Code:
|
cool thx churchmedia
|
got a question
is it possible when users buy the item the they get a link to download instead of a email. |
Quote:
The only "danger" I can see is that the download link would not be secure -- so once it's bought, the user could share it with someone else.... It might be better to just strip out all of the shipping info stuff from the templates and from the code and then email them a unique download link.... |
ok thx bud
and what about a page that creat a random password and protect the directory of the file or is that to much work? ps i'm a newbi to php |
Believe it or not, I'm a newbi too ;). I'm sure there's a way you could do it. Maybe when I have a few more months of programming under my belt I can write something like that....
|
Church. First of all, thanks again for doing this.
Question: I've installed the hack, added an item and tried testing it out. When I hit submit my order on top it said, "Could not send email" but it did send it and I got it in my email box with all of the pertinent information. |
Strange... Double-check this line of code in the store chunk:
PHP Code:
PHP Code:
Code:
or print "Could NOT send mail" PHP Code:
|
Thank you very much, sir.
|
Another question if I may.
Say I set quantity of 3. Anyway I can make the code say something like, you can't buy anymore once the quantity == to sold#? |
That's a good idea and should be pretty simple. You would need to run a query to find out how many have been sold and then use an "if" statement. Unfortunately, I'm really swamped right now and wouldn't be able to code it for a couple of weeks. I'm actually a little new to PHP, otherwise I bet I could bang it out in a few minutes. If anyone else sees this request, feel free to give us some code. It would have to be hard-coded in the product action sections, otherwise a new field would have to be added and some admin modifications...
If no one comes up with something I'll get to it ASAP. Good luck :) |
Sounds great. I wish I was a decent programmer. Unfortunately, I have a mental block (although I think I would have been very good at this).
|
All times are GMT. The time now is 01:10 PM. |
Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
![]() |
|
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|