Needs and Problems ( nothing found... )

  • Posts: 11
  • Thank you received: 0
9 years 6 months ago #233541

-- HikaShop version -- : last
-- Joomla version -- : 2.5
-- Error-message(debug-mod must be tuned on) -- : No error.

Hi there.
Sorry for the last request, I did not see the codes you gave in answer, but I had to try out almost all of them before having one working.
In attachment you will find needs and problems in the clearest way I could ask.
For Forum sake, here it is :
1. I need only in the product listings page, the EMPTY CART button ( which then go to a link I have in the joomla menu )
and the GO TO CHECKOUT button , exactly the same on the popup window, as I won't have the popup window.
Selling vegetables and fruit, the user will insert how many Kg of food they want per kind of and will go to checkout.

2. To make the UX faster, it shoul be useful to have a dropdown menu ( in the product listing page ) populated with the category names so that the user can buy 8kg carrots, 2 perfumes and 3 kind of tea and then go to checkout or empty the cart ... or add another product to their cart.

The problems I had are on the picture I am attaching, hope you to help me.
and let me say ... you really rock !

Carlo

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 84307
  • Thank you received: 13701
  • MODERATOR
9 years 5 months ago #233553

Hi,

So to have one quantity field for each product of the listing and a global add to cart button, you can just set the "Display the quantity field on the product page" setting of the HikaShop configuration to "Global on listings".
To have an 'empty cart' and a 'go to checkout' buttons on the listing, I would recommend to simply enable the HikaShop cart module via the Joomla modules manager and configure it with the "mini cart" option activated. It will display automatically the "proceed to checkout" button when needed if you activated the corresponding option in the module, and it will also display an empty cart icon if you activate it. And what's great about it, is that you can display it on other pages to if needed, and that it doesn't display the buttons if there is nothing in the cart, so that will avoid misunderstandings for the customers.

The following user(s) said Thank You: CarloG

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
9 years 5 months ago #233612

Thank you for your hints.
Perfect for the Global on listings, which I already did and also for the mini-cart options, which I activated.
When I use this link :

www.monasterosanbiagio.com/index.php?opt...cle&id=84&Itemid=146
which links to an article with modules activated on ( The category Listing in content-bottom-a and the mini-cart in content-bottom-c )
The two modules are one near the other ( and it can be ok ... )

If I go into a category, ie this link :

www.monasterosanbiagio.com/index.php?opt...cid=12&name=ortaggi&
Itemid=179

I see the cart in the bottom-c position, exactly where I want it.

I cannot see the EMPTY CART button, and I still don't know how I can use the category drop down even I am trying very hard to do this.
Maybe I missed something in the setting up of modules and so on...

Thank you again for your precious help.

Carlo

Please Log in or Create an account to join the conversation.

  • Posts: 4820
  • Thank you received: 654
  • MODERATOR
9 years 5 months ago #233621

Hello,

For me you have your "empty button" or more precisely in your backend configuration your Delete button, see the screenshot on below :



Maybe if his design don't fit your tastes, you can use some Css code to modify his look.

Regards,

Attachments:
Last edit: 9 years 5 months ago by Philip.
The following user(s) said Thank You: CarloG

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
9 years 5 months ago #233806

Thank you for your support.

I already saw that useful button.
What I'd like to have is a violet button like the 'Go to checkout' one, but with 'Empty cart' written on it, which really empty the cart completely and take the user back to the category listing page ( the one from the main menu ).

Is that possible ? I have seen the code on the forum, and it was alright, but I need it ONLY in the product listing pages and I don't know in which view I can insert it ... as it should be in the mini-cart as you suggested before.

This is the last step I need to get what I need...

Thank you again.

Carlo

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
9 years 5 months ago #233912

Ok. On the forum I found this code :

<input type="submit" class="button" name="Empty Cart" value="Empty Cart" onclick="window.location='<?php echo hikashop::completeLink('product&task=cleancart&return_url='. urlencode(base64_encode(hikashop::currentURL('url')))); ?>';return false;"/>

which create a nice button to empty the user cart.
What I cannot find inside the administration and/or inside the docs is

1. How can I redirect, after emptying the cart, to the category listing page ( I have a URL to redirect ).
2. Where is the minicart view, as I want that button to be in the minicart at the bottom of the product pages ?

Thank you.

Please Log in or Create an account to join the conversation.

  • Posts: 4820
  • Thank you received: 654
  • MODERATOR
9 years 5 months ago #233820

Hello,

As a start, follow this link , you will find a tutorial that explain how reach your Css file and create a custom Css.

Once, you have understand where you can add your Css code, use this kind of code.

A little advice, put your custom code at the end of your frontend_custom.css, that will be more easy later to find and maybe correct it

.hikashop_subcontainer {
order: value;
}

You can learn more about Css code on this link

Here your Css code to create a button as you asked for it :

a.hikashop_small_cart_clean_link img {
    display: none;
}

a.hikashop_small_cart_clean_link::after {
    content: "Empty cart";
	content: "Empty cart";
    background-color: #9a92cb;
    font-weight: bold;
}

a.hikashop_small_cart_clean_link {
    width: 100px;
    height: 23px;
    transition: all 0.2s ease-out;
    padding: 10px;
    background-color: #9a92cb;
    border-radius: 3px;
    display: block;
    padding-left: 23px;
}

a.hikaa.hikashop_small_cart_clean_link img {
    display: none;
}

a.hikashop_small_cart_clean_link::after {
    content: "Empty cart";
    background-color: #9a92cb;
    font-weight: bold;
}

a.hikashop_small_cart_clean_link {
    width: 100px;
    height: 23px;
    transition: all 0.2s ease-out;
    padding: 10px;
    background-color: #9a92cb;
    border-radius: 3px;
    display: block;
    padding-left: 23px;
}

a.hikashop_small_cart_clean_link:hover {
    background-color: #6a5eb2;
}

Note : among this order the display: block aim is to display first above the second, delete it if this order isn't required for you.

Hope this will help you.

Regards,

Last edit: 9 years 5 months ago by Philip.
The following user(s) said Thank You: CarloG

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
9 years 5 months ago #233954

Thank you Philip for your help.

What I need to know is not how to code a CSS ...
I need to know some internal hikashop coding.

I want to put the button near the 'Go to checkout' in the MINI CART who Nicolas suggested to activate, and which I like a lot...
But I don't know where to insert the code !!

Thank you for the hints on CSS.

I am working on them.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 84307
  • Thank you received: 13701
  • MODERATOR
9 years 5 months ago #233955

Hi,

1. Change hikashop::currentURL('url') to ' mywebsite.com/my/category/listing/page '

2. It's the file "cart" of the view "product" that you can edit via the menu Display>Views.

Please Log in or Create an account to join the conversation.

  • Posts: 11
  • Thank you received: 0
9 years 5 months ago #233984

Thank you and GREAT suggestions.

First of all, I think to be 'code-correct', the button to empty the cart should be among these lines :

<?php
}
if($this->params->get('show_cart_proceed', 1) && $this->cart_type == 'cart' && $this->params->get('from','display') == 'module') {
echo $this->cartHelper->displayButton(JText::_('PROCEED_TO_CHECKOUT'),'checkout',$this->params,$this->url_checkout,'this.disabled=true; window.location=\''.$this->url_checkout.'\';return false;');
}
} else {
?>

as it seems to me that THIS is the code which in the minicart displays the 'Go To Checkout', but this syntax is a little unknown to me...

Anyway, I put the module in content-top-a position, and everything is really really fine.
Now I have another interesting problem.
I'd like the cart to be on only in the Category Listing page AND in the Product listing page ...
but when I go on to checkout, in EVERY PAGE there's the module on.

In the module options, I checked 'Only on selected pages' and the only checked is the 'SHOP' page, which is the 'category listing'.
But I don't see anywhere neither other options to avoid being there on ALL THE PAGES of the checkout procedure.



Another question is ... can I put a dropdown populated with the categories in the shop near the ' Go to Checkout ' button in the minicart module ?

Which should be the code ? And where to put it to make it work ?

I gues I have to create a Category Listing in List Style and then modify the view to have the dropdown, right ?
Can you help with some code hint ?

Thank you again.

Please Log in or Create an account to join the conversation.

  • Posts: 84307
  • Thank you received: 13701
  • MODERATOR
9 years 5 months ago #233995

Hi,

1. Use the "force menu on checkout" setting of the HikaShop configuration to select a menu item of the type HikaShop checkout (you might have to create it first via the Joomla menu manager). Then, don't select that menu item in your module and the module won't display on the checkout.

2. Yes. The best is to configure a HikaShop content module as a category listing with the list layout. Then, just edit the file "listing_list" of the view "category" via the menu Display>Views. You can replace the whole code with a select HTML tag with a foreach on $this->rows to display each option. You'll want to also add an onchange attribute to it with a bit of javascript to redirect to the page of the category selected in the select.

Please Log in or Create an account to join the conversation.

Time to create page: 0.082 seconds
Powered by Kunena Forum