Here’s a short list of things to try. First, use the External JavaScript Action to attach the cookiejar.js and cart.js files to your page. Be sure that they are added in that order. Next, use the Protaculous Action to add prototype-packed to your page. Finally, you need some carefully-constructed styles and box names.
Draw an HTML box where you want your cart to appear. In the Inspector, be sure that the Title field reads ‘cart’. Put some text in that box – anything at all – so that it doesn’t publish with a 1px font-size. It’s actually a good idea to put something like “You must have JavaScript enabled to use this cart”, since the only people who will see that text are those with JavaScript disabled for some reason.
Draw another HTML box where you want your list of available items to appear. Put each item on a separate line, with a full return after it.
Create a new style, with the Name set to ‘fake_link’ (without the quotes). In this style, use the Extended dialog to add the following attributes:
cursor: pointer
color: blue
text-decoration: underline
float: right
(For each of these attributes, click New, then put the part to the left of the colon in the Name field, and the part to the right of the colon in the Value field. Don’t enter the colon or anything else.)
Now click right after the name of your first product, type the words “Add to Cart”, then highlight just those three words and click on your new fake_link style in the Styles palette. While the three words are still selected, copy them and paste them at the end of each of the other product names.
At this point, if you preview in a browser, you should be able to add things to your cart.
If you duplicate these steps on each of the other pages in your multi-page cart, you should be able to carry a collection of items from one page to another. Finally, if you are on the checkout page (with the form) you’ll need to do a little more magic to get the order to submit. Depending on how you have set up your form, you may need to add an ID to the page or to the table that holds your form. When you get to that part, upload the site so far on a server where we can see it and post a link back to the list.
Walter
http://scripty.walterdavisstudio.com/catalog/cart.js
http://scripty.walterdavisstudio.com/catalog/cookiejar.js
On Apr 29, 2012, at 2:46 PM, RuiSantos wrote:
Walter
Sorry to bother you again with the question about the shopping-list javascript on freeway.
I’ve download an action from Freeway to place a JS, but after that I can´t figure what to do next to start personalizing this JS and start using it on the website.
I don’t have knowledge about programing.
Can you help me again?
Rui Santos
freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options
freewaytalk mailing list
email@hidden
Update your subscriptions at:
http://freewaytalk.net/person/options