Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
Flat form calls with console browser error [Solved]
I activated the “Advanced Preferences”; I removed all comment lines into the default config for JS support; I associated my js code to the new form type; I exported the form to the server; finaly I called this form by the following tag (I don’t need some magic TXP dynamic processes for this js code 😜):
<txp:output_form form="footer_js" format="flat.script" />
Unfortunatly, the ressource isn’t loaded and the browser imform me an error occurs:
The resource from “https://domain.tdl/?f=footer_js” was blocked due to MIME type (“text/html”) mismatch (X-Content-Type-Options: nosniff).
Could you tell me, please, where I’m fail? I’m lost… 😕
(I got the same error even with this: <txp::footer_js format="flat.script" />
)
Last edited by Pat64 (2019-10-02 09:27:44)
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline
Re: Flat form calls with console browser error [Solved]
Did you try using <txp:output_form form="footer_js.js" format="flat.script" />
. Notice the .js
at the end of the form name which actually should be included.
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: Flat form calls with console browser error [Solved]
Absolutely, you’re right Yannis! Thank you lot! 😃
The form name need a .js
file extension, too.
Are-you a master in Textpattern? I’m sure you are. 👌
Last edited by Pat64 (2019-10-02 09:28:56)
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline
Re: Flat form calls with console browser error [Solved]
Yep, I think Yiannis (hi) is right master. Flat scripts are served by Apache, txp is only creating links. And footer_js
is certainly served as text/html
. So, either give your form .js
extension (better) or use format="script"
attribute.
We should probably allow .
(period) in txp tags, currently <txp::footer.js />
form will not work.
Offline
Re: Flat form calls with console browser error [Solved]
Sure you are a master, too. Oleg (but just after Yannis) 😃
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline
Offline
Re: Flat form calls with console browser error [Solved]
Pat64 wrote #319482:
Are-you a master in Textpattern? I’m sure you are. 👌
Not really. I just have an undergraduate degree in it:)
Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.
Offline
Re: Flat form calls with console browser error [Solved]
😃
That’s why I’m falling in love with Textpattern and its great community!
Thanks lot you, mates.
Patrick.
Github | CodePen | Codier | Simplr theme | Wait Me: a maintenance theme | [\a mi.ni.ma]: a “Low Tech” simple Blog theme.
Offline