1
extbase의 독립 실행 형보기에 문제가 있습니다.Typo3 독립 실행 형보기 양식
보기가 독립 실행 형보기와 함께 생성 될 때 양식이 올바르지 않습니다. 나는 기본 생성기를 사용하는 경우 형식은 다음과 같습니다
<form role="form" name="user" id="validateEmailForm" action="index.php?id=2&tx_registration_userregistration%5Buser%5D=&tx_registration_userregistration%5Baction%5D=validateEmail&tx_registration_userregistration%5Bcontroller%5D=User&cHash=b608ba14aff3a034be5e58a0402b96c0" method="post">
<div>
<input name="tx_registration_userregistration[__referrer][@extension]" value="Registration" type="hidden">
<input name="tx_registration_userregistration[__referrer][@vendor]" value="Whmcs" type="hidden">
<input name="tx_registration_userregistration[__referrer][@controller]" value="User" type="hidden">
<input name="tx_registration_userregistration[__referrer][@action]" value="test" type="hidden">
<input name="tx_registration_userregistration[__referrer][arguments]" value="YToyOntzOjY6ImFjdGlvbiI7czo0OiJ0ZXN0IjtzOjEwOiJjb250cm9sbGVyIjtzOjQ6IlVzZXIiO30=0fea5b97636b178cebbb4da9ed487d5e77f205ae" type="hidden">
<input name="tx_registration_userregistration[__trustedProperties]" value="a:1:{s:4:"user";a:2:{s:12:"eMailAddress";i:1;s:13:"eMailVerified";i:1;}}bbc1e3377150a6976a7dbec4197d034951d29ef0" type="hidden">
</div>
<div class="form-group">
<label>E-Mail Adresse</label>
<input class="form-control" name="tx_registration_userregistration[user][eMailAddress]" type="text">
</div>
<div class="form-group">
<label>Verifizierungs Code</label>
<input class="form-control" name="tx_registration_userregistration[user][eMailVerified]" type="text">
</div>
<button type="button" class="btn btn-primary" onclick="validateEmailForm();">Bestätigen</button>
<input class="small button" name="" value="Bestaetigen!" type="submit">
<a class="small button" href="index.php?id=2&tx_registration_userregistration%5Baction%5D=resendValidationCodeForm&tx_registration_userregistration%5Bcontroller%5D=User&cHash=89f3a9885d968a1cc58b78afeb462156">Code erneut anfordern</a>
</form>
내가 독립 뷰 생성기를 사용하는 경우, 형태가 다음과 같습니다
<form role="form" name="user" id="validateEmailForm" action="index.php?id=2&tx_registration_%5Buser%5D=&tx_registration_%5Baction%5D=validateEmail&tx_registration_%5Bcontroller%5D=Standard&cHash=1342195ecb09bfaa3eaaed53b5b6ca94" method="post">
<div>
<input name="__referrer[@extension]" value="Registration" type="hidden">
<input name="__referrer[@controller]" value="Standard" type="hidden">
<input name="__referrer[@action]" value="index" type="hidden">
<input name="__referrer[arguments]" value="YTowOnt932be2d0043f353815075d39b8a8dcae00ef10469" type="hidden">
<input name="__trustedProperties" value="a:2:{s:4:"user";a:2:{s:12:"eMailAddress";i:1;s:13:"eMailVerified";i:1;}i:0;i:1;}34e733be32be90328d34d6e089e19ec1e4f4a54a" type="hidden">
</div>
<div class="form-group">
<label>E-Mail Adresse</label>
<input class="form-control" name="user[eMailAddress]" type="text">
</div>
<div class="form-group">
<label>Verifizierungs Code</label>
<input class="form-control" name="user[eMailVerified]" type="text">
</div>
<button type="button" class="btn btn-primary" onclick="validateEmailForm();">Bestätigen</button>
<input class="small button" name="" value="Bestaetigen!" type="submit">
<a class="small button" href="index.php?id=2&tx_registration_%5Baction%5D=resendValidationCodeForm&tx_registration_%5Bcontroller%5D=Standard&cHash=0d47678ecec458d7283b92e15bd9d1d4">Code erneut anfordern</a>
</form>
당신이 볼 수 있듯이, 예를 들어, 입력에서 이름 태그 "tx_registration_userregistration"의 요소가 누락되어 컨트롤러가이를 처리 할 수 없습니다.
내가 독립보기 발생기 코드를 생성하는 방법은 다음과 같습니다
는$View = $this->objectManager->get('TYPO3\\CMS\\Fluid\\View\\StandaloneView');
$extbaseFrameworkConfiguration = $this->configurationManager->getConfiguration(\TYPO3\CMS\Extbase\Configuration\ConfigurationManagerInterface::CONFIGURATION_TYPE_FRAMEWORK);
$templateRootPath = \TYPO3\CMS\Core\Utility\GeneralUtility::getFileAbsFileName($extbaseFrameworkConfiguration['view']['templateRootPath']);
$templatePathAndFilename = $templateRootPath . 'tabControl/' . $templateName . '.html';
$View->setTemplatePathAndFilename($templatePathAndFilename);
$View->assignMultiple($variables);
$renderedView = $View->render();
return $renderedView;
사람은 문제를 알고 있나요 나는이 문제를 해결할 수있는 방법을 알 수있다?
Perfect! 고맙습니다! – Marcel