Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

A game I found on the internet

Name: Anonymous 2009-06-15 4:22

I found this game on some site about programming.

Create a website shopping script in a fake language. Here mine:



create checkOutStart:
    localize item
    do.math(itemCost) = @itemTotal + @itemTax
    if userCurrency(do.math) @itemCost > @userTotal
        say "Sorry. You do not have sufficient funds to make this transaction."
    else do checkOutEnd
    end;
end;

create checkOutEnd:
    say "Are you sure you want to make this transaction?" .function. "checkOutOption"
    checkOutOption(userDefine) "Yes" . "No" # Creates two links: Yes(http://site.com/shop.ext?checkout=yes), and opposite.
        if userDefine(yes)
        do transactionScript
            else return(url_referer)
    end;
end;
   
create transactionScript
    grab itemCost
    if coupons = true
    itemcost (substract(itemCost(couponAmount))) = new itemCost
    else #1# too lazy to finish script
end;

There is a lot of shit missing from it, I know. Please refer to #1.

Name: Anonymous 2009-06-17 9:39

check the price of what the shopper has selected;
if he wants to checkout, check card balance and write "not enough dollas" if checkout sum is greater than the balance, else write "purchased"; afterwards update the database with changed quatity numbers

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List