1
kaotik
Tiny store using tiny content
  • 2004/9/21 15:34

  • kaotik

  • Just can't stay away

  • Posts: 861

  • Since: 2004/2/19


Hi. I used to have xosc oscommerce module instaled but my site only has 3 products to sell so it was overkill.
Now i'm tring to setup tiny content to wrap a simple php form that will email the info to me.
I have a couple of issues that I hope someone can help me with:
1- There is a submenu page in tiny content called ORDER, this will be the php form. How can I make it verify if the user is logged in? If not I would like it to redirect to the page that say's you don't have permission.
2- I would like to add the username of the logged in user to the info that will be emailed. Could someone point me in the right direction in doing this?

Thank You

2
beerMe
Re: Tiny store using tiny content
  • 2004/9/23 14:07

  • beerMe

  • Not too shy to talk

  • Posts: 133

  • Since: 2004/9/13


I would also be interested in something like this.

3
kaotik
Re: Tiny store using tiny content
  • 2004/9/23 15:08

  • kaotik

  • Just can't stay away

  • Posts: 861

  • Since: 2004/2/19


Here's how I solved this:
- I was already using tiny content for another block, so I had to install the duplicatable hack by chapi so I could have 2 instances of tiny content. Great Hack chapi!
- The first page I created was a simple products.html. This is the homepage for the 'store'. It's just a simple html wrapped into tiny content.
--- For the order part I wrapped formmail.v50 which can be found
here

- The second page is the ORDER submenu item. This is also a html page that's been wrapped into tiny content. Here's mine
- This html links to a php script that's in the same directory. Here's mine
This php file doesn't have to be wrapped in tiny content.
- The way I set it up, it will report the XOOPS username in the emails it sends.
- If the order was correctly placed it will redirect to a page I called sucesso.html, which basicly says the order was sucessfull. Here's mine
I made this module only acessible by registered users. I then created a block for the top page viewable by all users anouncing a new store and that you have to register to see it.
- There are a couple of options you will need to custimize on order page (encomendas.html if your using my file):
line 19- REQUIRE this makes certain text fields mandatory
line 20- REDIRECT this redirects your users if the order was sucessfull
line 21- EMAIL the email to which you want the order sent
line 22- SORT this sorts the order on the email.
- on formmail.php there is something which you might also want to change:
line 389- You should change the text to 'Registered User'. Below this will show the name of the registered user on the email.
For me it works great, but then again I only have 3 products

4
jfernau
Re: Tiny store using tiny content
  • 2004/9/23 16:00

  • jfernau

  • Just popping in

  • Posts: 95

  • Since: 2003/12/29


Just for the sake of accuracy -

Chapi wrote the original TinyContent

GIJoe hacked it to created TinyD (TinyContent Duplicatable)

TinyD is the first module I load after a new install. I don't think I could live without it.

Thanks Chapi and GIJoe!

John

5
kaotik
Re: Tiny store using tiny content
  • 2004/9/23 16:10

  • kaotik

  • Just can't stay away

  • Posts: 861

  • Since: 2004/2/19


I stand corrected
Thanks to Chapi and GIJoe!

Login

Who's Online

118 user(s) are online (70 user(s) are browsing Support Forums)


Members: 0


Guests: 118


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: May 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits