如何在表单配置中达到GET参数?

I'm in the middle of configure() method and I must set a default selected value for a combobox. The value is in the URL, but no request or any object.

How to reach this variable?

Not a good idea to use sfContext in that context.

Better send the parameter in the constructor of the form. Something like this:

$form = new Form(array(), array(‘my_form_param’ => $request->getParameter('my_get_param'));

In the form you can call it with:

$this->getOption('my_form_param')

You can access the request from anywhere like this:

sfContext::getInstance()->getRequest()->getParameter('foo')