- 別途指定がない限りHTML5又はXHTML1.0を使用してください。
- 文字コード指定がUTF-8の場合、XML宣言は含めないでください。
- 別途指定が無い限りBOMなしのUTF-8を使用してください。
| <?php | |
| $contentTypeXml = '<?xml version="1.0" encoding="UTF-8" standalone="yes"?> | |
| <Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types"> | |
| <Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml"/> | |
| <Default Extension="xml" ContentType="application/xml"/> | |
| <Override PartName="/docProps/core.xml" ContentType="application/vnd.openxmlformats-package.core-properties+xml"/> | |
| <Override PartName="/xl/workbook.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"/> | |
| <Override PartName="/xl/worksheets/sheet1.xml" ContentType="application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"/> | |
| </Types>'; |
| composer create-project bear/skeleton My.NoteApp | |
| cd My.NoteApp | |
| composer install |
| test1 | test2 | test3 | |
|---|---|---|---|
| test4 | test5 | test6 |
| <?php | |
| use Symfony\Component\Form\AbstractType; | |
| use Symfony\Component\Form\FormBuilderInterface; | |
| use Symfony\Component\Form\FormError; | |
| use Symfony\Component\Form\FormEvent; | |
| use Symfony\Component\Form\FormEvents; | |
| class FileUploadType extends AbstractType | |
| { |
| <?php | |
| class opActivityTweetPluginConfiguration extends sfPluginConfiguration | |
| { | |
| public function configure() | |
| { | |
| //hack member config | |
| $this->dispatcher->connect('op_action.pre_execute_member_config', array($this, 'listenToPreMemberConfig')); | |
| //manual post |
| //you may have some more configs here... | |
| providers: | |
| user: | |
| entity: { class: MyAppBundle:User, property: loginEmail } | |
| admin: | |
| entity: { class: MyAppBundle:Admin, property: username } | |
| firewalls: | |
| dev: | |
| pattern: ^/(_(profiler|wdt)|css|images|js)/ | |
| security: false |
| <?php | |
| namespace Acme\DemoBundle\Form\Type; | |
| use Symfony\Component\Form\AbstractType; | |
| use Symfony\Component\Form\FormBuilderInterface; | |
| use Symfony\Component\OptionsResolver\OptionsResolverInterface; | |
| use Acme\DemoBundle\EntityRepository\AbleCharieRepository; |
| <?php | |
| /** | |
| * sfFormのフォームでtwitter bootstrap用のHTMLを出力するformatterクラス | |
| * | |
| * @auther Hiromi Hishida<info@77-web.com> | |
| */ | |
| class sfWidgetFormSchemaFormatterBootstrap extends sfWidgetFormSchemaFormatter | |
| { | |
| protected $rowFormat = '<fieldset class="%status%"><div class="control-group">%label%<div class="controls">%error%%field%%help%%hidden_fields%</div></div></fieldset>'; | |
| protected $errorRowFormat = '%errors%'; |
| <?php | |
| // modules/foo/actions/actions.class.php | |
| class fooActions extends sfActions | |
| { | |
| public function executeBar(sfWebRequest $request) | |
| { | |
| //何かの計算や条件判定 | |
| $this->showNameInTitle = true; | |
| $this->name = 'my name'; | |
| } |