Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GlobalNav Search Broken #73

Closed
PsukheDelos opened this issue Apr 9, 2018 · 2 comments
Closed

GlobalNav Search Broken #73

PsukheDelos opened this issue Apr 9, 2018 · 2 comments

Comments

@PsukheDelos
Copy link

Recently we updated the SilverStripe.com and SilverStripe.org search from Google Custom Search to Swiftype. The CSS now references a Swiftype specific search input and the JS for Google has been replaced with Swiftype JS. This has broken the GlobalNav search (the search bar that is displayed when you click the search icon in the nav in the top right).

I believe the fix may be to replace the following lines:
https://github.com/silverstripe/api.silverstripe.org/blob/master/conf/themes/silverstripe/layout/layout.twig#L48-L51

With:

        <div id="swiftype-search">
            <div class="swiftype-control-searchbox-only" dir="ltr">
                <form class="swiftype-search-box" accept-charset="utf-8">
                    <table cellspacing="0" cellpadding="0" class="swiftype-search-box">
                        <tbody><tr><td class="swiftype-input">
                            <input autocomplete="off" type="text" size="10" class="swiftype-input" name="search" title="search" dir="ltr" spellcheck="false" style="outline: none;" placeholder="Search SilverStripe...">
                        </td>
                            <td class="swiftype-search-button"><input type="submit" value="Search" class="swiftype-search-button" title="search"></td>
                            <td class="swiftype-clear-button"><div class="swiftype-clear-button" title="clear results">&nbsp;</div></td>
                        </tr></tbody>
                    </table>
                </form>
            </div>
        </div>
@clarkepaul
Copy link

As this doesn't seem to be a docs/api/user-help issue, but rather a ss.org global toolbar issue I'll try to get this prioritised through the right team.

image

Not sure if this is the reason for the break but might be the case... Swiftype code needs to be included in the header which is shared across all the sites rather than being placed within ss.org site.

@robbieaverill
Copy link
Contributor

Search is no longer broken. We can track content configuration tweaking here: silverstripe/doc.silverstripe.org#176

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants