Page: | 1 |
Topic:

how to remove the redirect to the cart when you click "Add to Cart"

Lelik
See profile of: Lelik
2011-12-27 18:47:40
Votes: 0
Vote answer in plus Vote answer in minus
how to remove the redirect to the cart when you click "Add to Cart"
I found a code that is responsible for this:
templates/pages_default.tpl

<!-- BEGIN PRODUCTS_BASKET -->
<div class="basket"><a href="$aData[sBasketPage]iProductAdd=$aData[iProduct]&amp;iQuantity=1" rel="nofollow">$lang[Basket_add]</a></div>
<!-- END PRODUCTS_BASKET -->

how to convert it?

  » Quick.Cart v4.x
treewood
OpenSolution
See profile of: treewood
2011-12-27 19:22:15
Votes: 0
Vote answer in plus Vote answer in minus
Lelik - then where you want to redirect when product is added to cart/basket ?
baron_jon
See profile of: baron_jon
2011-12-27 19:24:32
Votes: 0
Vote answer in plus Vote answer in minus
http://opensolution.org/Quick.Cart/forum/?p=readTopic&nr=5266
boboo
See profile of: boboo
2011-12-27 19:39:46
Votes: 0
Vote answer in plus Vote answer in minus
http://opensolution.org/Quick.Cart/forum/dodaj-do-koszyka-ale-tam-nie-przeskakuj,6568.html

-------------------------------------------------------
http://qc-plugins.kimla.de
Lelik
See profile of: Lelik
2011-12-27 21:59:48
Votes: 0
Vote answer in plus Vote answer in minus
treenwood, to the client was on the page, select the products

thx 4 all
cachousam
See profile of: cachousam
2012-01-21 07:37:50
Votes: 0
Vote answer in plus Vote answer in minus
hello
boboo, I tried your script on your given link . But the Polish translation of google is not very good and I can be wrong. Could you tell me the procedure in English.
Thanks a lot
cachousam
See profile of: cachousam
2012-01-22 09:31:16
Votes: 0
Vote answer in plus Vote answer in minus
Hello,
I'm sorry to insist, but it would be very nice to translate into English the procedure of post boboo. I do not know Polish,and this language is very difficult for google. This script would please me much.
Thank you all.
boboo
See profile of: boboo
2012-01-22 09:39:27
Votes: 0
Vote answer in plus Vote answer in minus
Do not be nervous :-)
I've improved the procedure, so it is not necessary to use the submit button in the products list. I use the link "as it is" with some changes in executing actions_client files.

Take a contact.

-------------------------------------------------------
qc-plugins.kimla.de
cachousam
See profile of: cachousam
2012-01-23 06:46:13
Votes: 0
Vote answer in plus Vote answer in minus
thank you for your help.
I break my head with these files since a long time
I summarizes:

in templates/pages_defaut.tpl
added at the beginning of the file

<script type="text/javascript">
window.onload = function(){
if(window.name != "")
document.documentElement.scrollTop = window.name;
window.name = 0;
}
</script>

then in the same file find

<!-- BEGIN PRODUCTS_BASKET -->
<div class="basket">
<form method="post" action="" >
<input type="hidden" name="produkt" value="$aData[iProduct]" />
<input type="submit" class="dodaj" name="dodaj" value="$lang[Basket_add]" />
</form>
</div>
<!-- END PRODUCTS_BASKET -->

then replace
<input type="submit" class="dodaj" name="dodaj" value="$lang[Basket_add]" />

with:

<input type="submit" class="dodaj" name="dodaj" value="$lang[Basket_add]" onclick="window.name = document.documentElement.scrollTop;"/>

in the file actions-client/p.php find:

if (isset ($_POST['dodaj'])) {

replace with:

if (isset ($_POST['dodaj'])) {
$oOrder->addToBasket( $_POST['produkt'], 1 );
$oProduct =& Products::getInstance( );
$_SESSION['fOrderSummary'.LANGUAGE] += $oProduct->aProducts[$_POST['produkt']]['fPrice'];
$_SESSION['iOrderQuantity'.LANGUAGE] = $_SESSION['iOrderQuantity'.LANGUAGE] + 1;
}

I do not understand what we have to do with the file defaut.cc as you explained below

W default.css znajdź:
#products li .basket{...

i .basket zmień na: .dodaj
I poformatuj trochę, aby jakoś to wyglądało.

thank you again

My email is cachousam@yahoo.fr
boboo
See profile of: boboo
2012-01-23 08:53:49
Votes: 0
Vote answer in plus Vote answer in minus
The changes in .css are because I have added a button with class: dodaj
So, if You want to make it nice, add this class .dodaj or change #products li .basket{...
to #products li .dodaj{...
and format it a bit.

-------------------------------------------------------
qc-plugins.kimla.de
Page: | 1 |
 


If You want to do this operation, please log in first ».
If You don't have an account please register ».
Valid XHTML 1.0! Valid CSS! version: 2.2.0-alfa | powered by Quick.Forum