Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


  • dwarakesh 50 posts 69 karma points
    Aug 30, 2011 @ 07:38
    dwarakesh
    0

    Full text search

    I installed Xslt full text search .. its working fine.. but i need to apply css for the search text box and button.. dont know how to apply..  is there any way to apply css..

  • Fuji Kusaka 2203 posts 4220 karma points
    Aug 30, 2011 @ 08:00
    Fuji Kusaka
    0

    Hi,

    Yes this is totally possible to do. In your template you can apply css class to your form like this

    <input type="text" name="search" class="searchField" value="Search" onFocus="this.value=''"/>
     <input type="image" alt="Search" src="img.png" value="Search" class="searhButton" />


    and you can also change the highlighting when you get the results which is the XSLTsearch under settings sections

  • dwarakesh 50 posts 69 karma points
    Aug 30, 2011 @ 08:13
    dwarakesh
    0

    Hi

        xsltsearch  xslt file having search textbox and button .. i need to apply css on that .. not on the search textbox and button in my template.. sorry if i m not clear..

     

  • Fuji Kusaka 2203 posts 4220 karma points
    Aug 30, 2011 @ 08:16
    Fuji Kusaka
    0

    Sorry am not sure what you said earlier, where are you applying your css?

  • dwarakesh 50 posts 69 karma points
    Aug 30, 2011 @ 08:35
    dwarakesh
    0

    in  XSLTsearch.xslt  

      <!-- display search box at the top of the page (the search box is always present even if no search was attempted) -->
           
    <xsl:if test="$searchBoxLocation='TOP' or $searchBoxLocation='BOTH'">

    <div class="xsltsearch_form">

     

    <----------  Dont know from which css they are refering Class=input-->

    <input name="search" type="text" class="input">

    <xsl:attribute name="value">

    <xsl:value-of select="$unescapedSearch"/>

    </xsl:attribute>

    </input>

    <xsl:text>&nbsp;</xsl:text>

    <----------  Dont know from which css they are refering Class=submit -->

    <input type="submit" class="submit">

    <xsl:attribute name="value">

    <xsl:value-of select="$dictionaryButton-Search"/>

    </xsl:attribute>

    </input>
    </div>

    </xsl:if>

    -------------------------------------------------

     

    need to apply  my css class for the above thing..

  • Fuji Kusaka 2203 posts 4220 karma points
    Aug 30, 2011 @ 09:00
    Fuji Kusaka
    0

    Oh so you have 2 Search Box being displayed at the moment right?

    In your template where you are calling your macros have you put searchBoxLocation ="None" you should have something like that

    <form method="get" action="search.aspx?">
    <umbraco:Macro source="-1" searchFields="@nodeName,bodyText" previewFields="bodyText" searchBoxLocation="None" previewType="Beginning" resultsPerPage="5" previewChars="225" showPageRange="1" showOrdinals="1" showScores="0" showStats="0" Alias="XSLTsearch" runat="server"></umbraco:Macro>
    </form>

  • dwarakesh 50 posts 69 karma points
    Aug 30, 2011 @ 09:07
    dwarakesh
    0

    s.. i m displaying search result in a another page  searchresultpage.aspx.. and calling a macro

    on this like

     <form id="searchresult" runat="server">

    <umbraco:Macro source="1256" searchFields="@nodeName,metaKeywords,metaDescription,slider,welcome,meetAbcEvents,meetAbcnews,meetabcfooter" previewFields="bodyText,metaDescription" searchBoxLocation="TOP" previewType="BEGINNING" resultsPerPage="5" previewChars="255" showPageRange="1" showOrdinals="1" showScores="1" showStats="1" Alias="XSLTsearch" runat="server"></umbraco:Macro>


        </form>

     

  • Fuji Kusaka 2203 posts 4220 karma points
    Aug 30, 2011 @ 09:18
    Fuji Kusaka
    0

    Try to change your input text box to

    <form method="post" action="searchresultpage.aspx?">
    <
    inputtype="text"name="search"class="searchField"value="Search"onFocus="this.value=''"/>
     <inputtype="image"alt="Search"src="img.png"value="Search"class="searhButton"/>
    </form>

    And in your template where you want the result to display to

    <form method="get" action="search.aspx?">
    <umbraco:Macro source="1256" searchFields="@nodeName,metaKeywords,metaDescription,slider,welcome,meetAbcEvents,meetAbcnews,meetabcfooter" previewFields="bodyText,metaDescription" searchBoxLocation="None" previewType="BEGINNING" resultsPerPage="5" previewChars="255" showPageRange="1" showOrdinals="1" showScores="1" showStats="1" Alias="XSLTsearch" runat="server"></umbraco:Macro>
    </form>
  • dwarakesh 50 posts 69 karma points
    Aug 30, 2011 @ 09:30
    dwarakesh
    0

    Hi

    I didn't get u...  i m not clear with the above thing ...

    i need to change the css of textbox and button in XSltsearch.xslt file ....

  • Fuji Kusaka 2203 posts 4220 karma points
    Aug 30, 2011 @ 09:42
    Fuji Kusaka
    0

    Hi,

    Then you can just do this in your form post and add your css style for your input type="text" which is your textbox, and for your button you can use an image or css like below

     

    <formmethod="post"action="searchresultpage.aspx?">
    <
    input type="text" name="search" class="searchField" value="Search" onFocus="this.value=''"/>
     <input type="image" alt="Search" src="img.png" value="Search" class="searhButton"/>
    </form>
  • dwarakesh 50 posts 69 karma points
    Sep 05, 2011 @ 08:16
    dwarakesh
    0

    Hi,

       I got ur point.. but in Xsltsearch.xslt... there is a textbox and button with the  css class called input and submit.  i want to know from which css they are refering the class.. so that i can change the css according to my needs.. am i clear..

  • Fuji Kusaka 2203 posts 4220 karma points
    Sep 05, 2011 @ 08:22
    Fuji Kusaka
    0

    To be honest with you am not sure where this class is refering to. You could try asking Doug about it.

    //fuji

  • This forum is in read-only mode while we transition to the new forum.

    You can continue this topic on the new forum by tapping the "Continue discussion" link below.

Please Sign in or register to post replies