Support » Theme: Storefront » Modify Header Cart and Search sections

  • Resolved billy-boy

    (@billy-boy-1)


    Howdy,

    I am tinkering with my storefront header using powerpack and cant figure a few things out.

    1) I was surprised to find no easy way to modify the placeholder text in the header search box. My site is multilingual using polypro and, since the placeholder text translated based on current language, I assumed there would be a way to set change the placeholder text under string translations….. but there wasn’t. And not in widgets either. So, I researched and apparently only way was to do a translation via function which worked fine but seemed like an odd way to go about it imo.

    2) I would really like to have a simple and sleek section on the right side of header with #1) a simple search icon that, when selected, opens up a search field (like in the handheld footer!) and #2) a simplified cart section with ONLY the Cart symbol (also just like in the handheld footer!) that when hovered on still displays the wider cart info dropdown and #3) a “my account” icon (again, just like in the handheld footer!) plus, ideally, #4) the language selector.

    I have of course looked around for how i could duplicate/modify the handheld footer into the larger mediascreen header but just am not finding it… ie where in the functions and how to tweak it like this. Anyone done this or have ideas? Seems like a nice, more compact and elegant way to present this stuff in the header imo….

Viewing 4 replies - 1 through 4 (of 4 total)
  • Hey @billy-boy-1

    1) For changing text strings, we usually recommend using a translation plugin such as Loco Translate (you can find a step-by-step guide on how to do that right here), but if you already have Polypro for translations, it’s best to reach out to their own support team for any assistance with that.

    2) This will require some additional custom code. I’m leaving this thread open so that others might be able to help with that.

    Thread Starter billy-boy

    (@billy-boy-1)

    hi Senff and thanks for the quick reply!

    regarding #1, IS there any place within storefront /woocommmerce / wordpress for that matter to actually DEFINE the default placeholder text for the default search field in the header? I looked everywhere I could think of and, like I said, since it was automatically translating based on my selected language, I assumed it must be set within the string translations under languages but it is not….. so I looked everywhere else and coudnt find anywhere that set that text blurb…. and my research online yielded only changes via a function. Is that REALLY the only way to define/change something as “standard” as the placeholder text for a default search field? I found that surprising so hoped I had indeed missed a built in way to change it via admin….

    regarding #2, thanks, I hope someone else more skilled than me has already done similar and can point me in the right direction.

    Hi @billy-boy-1,

    I’m sorry we missed your last post. Have you been able to resolve this issue?

    If not, as your post involves a development topic, I’m going to leave it open for a bit longer to see if anyone is able to chime in and help you out.

    I can also recommend the WooCommerce Developer Resources Portal for resources about WooCommerce development.

    You can also visit the WooCommerce Facebook group or the #developers channel of the WooCommerce Community Slack. We’re lucky to have a great community of open-source developers for WooCommerce, and many of our developers hang out there too.`

    As for #1, there is no setting you can use to change the default placeholder text for the search field in the header or elsewhere. The best way to change that is using a translation plugin, or else you will need custom code to make the change.

    Hi there,

    We haven’t heard back from you in a while, so I’m going to mark this as resolved – if you have any further questions, you can start a new thread.

    Cheers!

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Modify Header Cart and Search sections’ is closed to new replies.