direct_mail_subscription throws error under php 7 - typo3

TYPO3 7.6.14, php 7.0.12 throws: Oops, an error occurred! Code: 20170302191205e900dbd4 after sending the form to the server. The user is made but the email is not sent. This happens with both versions, from TER and from git.
When changing to php 5.6 the extension works as expected.
Any ideas?
Thanks!

Problem is caused by a PHP 7 deprecation warning.
I've just encountered this problem a couple of days ago and fixed it:
https://github.com/kartolo/direct_mail_subscription/issues/20
There is no new release yet, but you can use my patch.
Feel free to leave a comment in the GitHub issue if the patch works for you as well.

As a first solution, disable the content exception handler with
config.contentObjectExceptionHandler = 0
See the documentation for some more explanations.
By guessing there is an issue with overriding methods and changing there declarations. Report it to the author, maybe including a patch.

Related

Typo3 8.7: Could not analyse class: maybe not loaded or no autoloader? Keeps coming and going

I have had this problem as seen in the title in the past and I always resolved this issue by adding the psr-4 autoloader in the emconf and simply reactivate my extensions.
Now I'm facing the same problem:
Could not analyse class: maybe not loaded or no autoloader?
but I have set the autoloader correctly as always. This also happens in more than one Extension right now.. After deleting the php cache in the install tool und dump autoload and reactivating my extension, the error was gone for some time, a couple hours later its back again.. Therefore I think it must have something to do with temp files, but I can't figure out what it is exactly..
Does anyone have a solution? I have seen plenty of topics about this issue on stackoverflow, I used them in the past, but unfortunately none is working for me right now.
Important fact: This error is happening on my new server now. On my old server (with the same code in the extensions) this didn't occur and they worked fine.
Thanks in advance.
Edit: Vendornames etc. are set correctly and there are no errors in the syntax whatsoever. As I said, the extensions worked fine.
Edit2: I just found this changelog of Typo3:
https://docs.typo3.org/typo3cms/extensions/core/Changelog/8.4/Breaking-78222-ExtensionAutoloadInformationIsNowInTypo3confautoload.html
But there is no solution for the impact for none composer installations. Can someone provide one for me?
When you use composer installation and you use extensions which are not installed via composer, you need to add the autoload information in the root composer.json of your project and then run composer dump-autoload. (ext_emconf.php dont works in composer mode?)
{
...
"autoload": {
"psr-4": {
"Vendor\\ExtensionNameA\\": "public/typo3conf/ext/extension_name_a/Classes",
"Vendor\\ExtensionNameB\\": "public/typo3conf/ext/extension_name_b/Classes"
}
}
}
A possible explanation for strange timing thing "works and later not". Maybe it has something to do with the red clear cache button in the TYPO3 backend (Clear all caches). Maybe it start not working when u hit this button and cache files get cleared. Then you need to reinstall extensions to get the autoloader "temporarly" working, till the point you hit the clear all caches button again. With the solution i mentioned above, it works permanet.
Have you left any configuration in your ext_tables.php?
As the TCA configuration, which is cached, is expected in Configuration/TCA/[Override/] any code in ext_tables.php might get lost.
If you want some configuration to be executed for each run you need to put it in ext_localconf.php
Thanks for all the help, I found the solution myself now.
Actually it was not really caused by any autoloader configuration, but and old version of fpdf which apparently caused two extensions to not load their classes properly. The exception thrown was simply misleading. I have upgraded the version of fpdf and now it works properly. It is not clear to me why the same code worked a week ago and now it failed, but atleast I have found the solution to my problem.

Oops, an error occurred - after TYPO3 Upgrade 7.6 to 8.7

I tried manually upgrade TYPO3 from 7.6.6 to 8.7.16 and received: Oops, an error occurred! I can't login to TYPO3.
I apologize for the brief description but I was very tired after a many hours trying to remove the errorenter image description here. The error looks just like the image, but at the beginning there was a white screen ...
Over the years I have not had problems installing TYPO3 (still Versions 3 and 4), but I had a break in use. I do not have access to SSH. I also assume Symlink was mistakenly set by the admin, and that's why I had to do it manually.
https://docs.typo3.org/typo3cms/InstallationGuide/QuickInstall/GetAndUnpack/Index.html
Similarly, because I did not have access and I did it manually... I noticed that there are also changes in installation, perhaps a problem.
First step to do after an upgrade is to open the install-tool primary to alter tables for new requirements:
example.com/typo3/install.php
There you have to open the upgrade-wizard and follow the shown steps.
You also get the option shown to install compatibility-7, an extension that adds a compatibility-layer for older extensions. You can enter that step and afterwards still decide if to install it or not. In the wizard the logic is that the option will be shown and no matter about your decision it will be marked as done, so that it won't be shown another time again usually.
In your case it's better to follow the update-instructions rather than the install-instructions: https://docs.typo3.org/typo3cms/InstallationGuide/Upgrade/Index.html

'Parse/ParseClientConfiguration.h' file not found

I am trying to make a project using Parse. My project used to work before Swift 3.0 update. Yesterday I decided to upgrade my project code to Swift 3.0. I also updated Parse to its latest version which I used pods to do it. I get these 2 errors which I couldn't find a solution to. I deleted Parse and then reinstalled again using Pods but that didn't fix the problem.
(Can't post pictures because I don't have enough reputation :/)
(Can't post more than 2 links too :/)
Error #1:
http://i.imgur.com/oeGeU2V.png
Error #2:
http://i.imgur.com/urYEWxk.png
Proof of having the required file:
These are the 2 errors that I am encountering right now. When I remove the ParseClientConfiguration.h I also get the same error twice.
Error #1 twice:
While answering keep in mind that I am not a very experienced programmer. You may have to explain some parts more detailed. If you need more information I would gladly provide them.
Deleting "Derived Data" solved my problem.
How to delete "Derived Data":
https://stackoverflow.com/a/39495772/7188022
Most likely you ran into this, because you ignored
"From now on you’ll open the workspace file instead of the project file"
like I did.
A single line, which can easily bee overseen at the Install Guide

Warning: DOMXPath::query(): Invalid expression in /opt/lampp/htdocs/magento/vendor/magento/framework/Config/Dom.php on line 273

I am using Magento latest release 2.x.
Everything works fine, except when saving a product with an image Magento 2.x throws an error
Warning: DOMXPath::query(): Invalid expression in /opt/lampp/htdocs/magento/vendor/magento/framework/Config/Dom.php on line 273
I have just started learning Magento. any help would be appreciated.
Though it is old question, there is no answer in 5 months. I got similar issue and found the cause for my case.
This issue might be generated due to wrong XML configuration. If you would add more code related to this issue, I probably could isolate the exact reason behind this issue.
At my end, I wrote di.xml wrongly, I didn't write root tag in di.xml. For that reason, this error would generate.
If anybody gets this issue, you should check your configuration files.
The Main Problem Is your command line Is not Working...
And A Firstly Check Your Configuration File Before Not working any Idea Then Do this
This is Create an issue in Di.Xml File If you are only changing a Di.xml File Name Then Problem Solved
change current mode to developer and see the file which generating the error.

Typo3 plugin not working in draft-workspace

I have a selfmade T3-plugin that actually works fine.
Unless I try to look at it in the draft-workspace - then I get an error saying «Template could not be found at "typo3/sysext/workspaces/Resources/Private/Templates/Preview/Preview.html"» (of course, the template is there).
We're working with T3 6.1.8
There were some rollbacks made recently that might have caused this, but that's just a wild guess...
Any ideas what could cause this?
The solution to this was actually quite trivial.
The person who wrote the extension used chdir() in the extension's header to write a PDF file. This confused the workspaces plugin so it didn't find it's own directory anymore.