Yii Framework Forum: SEF - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

SEF http://domain.nl/daytrip/list.html?q=test Rate Topic: -----

#1 User is offline   bas_vdl 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 215
  • Joined: 01-April 09

Posted 17 November 2009 - 11:25 AM

Hi guys,

to make my items searchable i build a simple search form. But when i hit enter my action will put ?q=test behind my url.

i want to change this to http://domain.nl/day...ist/q/test.html

all my url are SEF but not when i use the search form, is there a solution inside Yii?

Thank you!

<form method="get" action="/daytrip/list.html?q=test"><fieldset>
    <legend>Search</legend>
    <ol>
        <li>
            <input type="text" id="q" name="q" value=""/>
        </li>
    </ol>
</fieldset>
</form>

0

#2 User is offline   Sander 

  • Standard Member
  • PipPip
  • Yii
  • Group: Members
  • Posts: 169
  • Joined: 03-November 09
  • Location:Amsterdam, Netherlands

Posted 17 November 2009 - 04:13 PM

Use the path-format of CUrlManager together with a fake URL suffix. For a good explanation see http://www.yiiframew...uide/topics.url
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users