Thanks for the reply,.. $url.search solves my problem,.. Now I can easily
customize my search form. But I have enother one with
#showWeblogCategoryLinksList
#set($rootCategory = $model.weblog.getWeblogCategory("nil"))
#showWeblogCategoryLinksList($rootCategory false false)
It returns list of Categories and current category has class name different
from others, and no A tag. Also it add ALL option to the list.
Often many things should be changed in this structure. For example some times I
don't need ALL at all, and some time I want it to be HOME, not ALL.
I can use foreach() but I believe I cannot recognize if Category is current or
not.
Do you have any suggestions?
Thanks
Eu
----- Original Message ----
From: Leon Messerschmidt <[EMAIL PROTECTED]>
To: [email protected]
Sent: Wednesday, July 18, 2007 6:58:32 PM
Subject: Re: How to change form generated by #showWeblogSearchForm
Hi Eu,
You could change the default behaviour of #showWeblogSearchForm in
WEB-INF/velocity/weblog.vm Just be careful, because this macro is
shared by all the themes and you might break something else.
As far as I know the search action URL is available as $url.search So
you could do:
<form id="searchForm" method="get" action="$url.search">
<!-- Some fields go here -->
</form>
~ Leon
On Wed, 2007-07-18 at 11:58 -0700, Evgeniy Strokin wrote:
> Hello
> I use standard #showWeblogSearchForm($model.weblog false) it generates
> this code:
>
> <form id="searchForm" method="get" action="/about/search"
> style="margin: 0; padding: 0" onsubmit="return validateSearch(this)">
> <p>
> <input type="text" id="q" name="q" size="10"
> maxlength="255" value="" />
> <input type="submit" value="Search" />
> </p>
> </form>
>
> I need to remove style="margin: 0; padding: 0" since it totally corrupt my
> CSS.
> Is any way to do this?
> Also,.. it would be very handy to have id distribute not only for input>text
> but for input>submit as well.
> And It would be very usefull to have some varible in $model or somethere else
> to keep action URL there. In this case I could design my own form as I need
> it and not use #showWeblogSearchForm.
>
> Thx
> Eu
>
>
______________________________________________________________________
This email, including attachments, is intended only for the addressee
and may be confidential, privileged and subject to copyright. If you
have received this email in error, please advise the sender and delete
it. If you are not the intended recipient of this email, you must not
use, copy or disclose its content to anyone. You must not copy or
communicate to others content that is confidential or subject to
copyright, unless you have the consent of the content owner.