Skip to content

Instantly share code, notes, and snippets.

@khepin
Created October 17, 2012 02:38
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save khepin/3903414 to your computer and use it in GitHub Desktop.
Save khepin/3903414 to your computer and use it in GitHub Desktop.
<?php
namespace Acme\MessageBundle\FormType;
use Symfony\Component\Form\AbstractType;
use Symfony\Component\Form\FormBuilderInterface;
use Symfony\Component\OptionsResolver\OptionsResolverInterface;
use Symfony\Component\Security\Core\SecurityContext;
use Doctrine\ODM\MongoDB\DocumentRepository;
class FriendMessageWithAttachmentFormType extends AbstractType
{
public function buildForm(FormBuilderInterface $builder, array $options)
{
$builder
->add('message', 'acme_friend_message')
->add('attachment', 'file')
;
}
public function getName()
{
return 'acme_friend_message_with_attachment';
}
public function setDefaultOptions(OptionsResolverInterface $resolver)
{
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment