Author Topic: Edit search Block  (Read 3162 times)

Offline sliverin

  • Newbie
  • *
  • Posts: 4
  • Karma: +1/-0
    • View Profile
Edit search Block
« on: September 14, 2016, 07:47:10 PM »
I would like to essentially make the Search criteria page, the one that lists search + categories + search model a permanent HTML block that will replace the little search block. Can this be done as I cannot find were the search criteria form is located.

Offline abolabo

  • core-developer
  • Administrator
  • Hero Member
  • *****
  • Posts: 1788
  • Karma: +251/-11
  • web for all, all for web!
    • View Profile
    • AbanteCart
Re: Edit search Block
« Reply #1 on: September 16, 2016, 03:35:35 AM »
What exactly do you mean?
Search block at the top goes to pages/product/search.php controller.
« Last Edit: September 16, 2016, 07:40:44 AM by eCommerce Core »
“No one is useless in this world who lightens the burdens of another.”
― Charles Dickens

Offline sliverin

  • Newbie
  • *
  • Posts: 4
  • Karma: +1/-0
    • View Profile
Re: Edit search Block
« Reply #2 on: September 21, 2016, 11:50:08 PM »
Sorry, after looking at what I wrote, even I am confused by what I wanted :D. Essentially I want the search block in the corner to also search models as well as names.

Offline VE3SLO

  • Newbie
  • *
  • Posts: 10
  • Karma: +1/-0
    • View Profile
Re: Edit search Block
« Reply #3 on: December 12, 2016, 12:19:32 AM »
Was there ever an answer to this?  I have the exact same request.

I am trying to change the default search behaviour to search whatever it's current default is and to include  "Search in product descriptions" and "Search in product model" from the "search key words" box.

Reason for this is the search system finds almost nothing on my site unless one knows exactly what to search for.

Offline eCommerce Core

  • Administrator
  • Hero Member
  • *****
  • Posts: 1599
  • Karma: +93/-1
    • View Profile
Re: Edit search Block
« Reply #4 on: December 12, 2016, 08:06:09 AM »
Just FYI, model is already part of the standard search.
To give you an idea where to start, you need to look into these files:

Template file for search block
public_html/storefront/view/default/template/blocks/search_top.tpl

Search result controller:
public_html/storefront/controller/pages/product/search.php

Model:
public_html/storefront/model/catalog/product.php

The rest is pure PHP. Please share what you achieve or post questions.
“If you’re in the luckiest one per cent of humanity, you owe it to the rest of humanity to think about the other 99 per cent.”
― Warren Buffett

Offline jsitges

  • Newbie
  • *
  • Posts: 8
  • Karma: +3/-0
    • View Profile
Re: Edit search Block
« Reply #5 on: August 19, 2017, 06:21:42 PM »
I have the same question,

I have already ticked search product descriptions by default, in search block.

But I need the search top to search through product descriptions as a default.  any help is gratly appreciated.  I supose i will fiddle around some more to see if I can achieve this, but i am no programmer.

thanks again.
« Last Edit: August 20, 2017, 01:04:42 PM by jsitges »

Offline jsitges

  • Newbie
  • *
  • Posts: 8
  • Karma: +3/-0
    • View Profile
Re: Edit search Block
« Reply #6 on: August 20, 2017, 01:43:40 PM »
Sorry, after looking at what I wrote, even I am confused by what I wanted :D. Essentially I want the search block in the corner to also search models as well as names.


FOUND SOLUTION YAY

in the product.php file in the public_html/storefront/model/catalog/ directory edit 504 where it says
if (!$model){
and take away the '!'

that's it.

I did it for the descriptions and it worked.

 

Powered by SMFPacks Social Login Mod