TYPO3 EXT:webkitpdf does not render PDF file - typo3

Using EXT:webkitpdf with TYPO3 7.6 worked very well. But "suddenly" the PDFs were corrupted or no PDF file was written (just empty temp-files). There is also no entry in the EXT:webkitpdf-Log.

After some investitgation I found this in my TYPO3-error-Log:
10-02-17 12:49 - core: Core: Error handler (FE): PHP Warning: Cannot modify header information - headers already sent in /is/htdocs/wpXXXXXXXXX/www/typo3_sources/typo3_src-7.6.13/typo3/sysext/frontend/Classes/Utility/CompressionUtility.php line 54
Okay, it's the FE:compression!
After turning off [FE][compressionLevel]=0 in InstallTool, all works fine again!

Related

TYPO3 Form Multicheckbox Partial

I tried to edit the core file form\Resources\Private\Frontend\Partials\Field\Field.html to change the html output in the frontend. If I change that file, it has not effetcs. If I change the core file form\Resources\Private\Frontend\Partials\Textarea.html it effects the output in the frontend.
I've tried to set a custom partial, layout and templates folder like this:
I've set the following in the setup part of the page template:
plugin.tx_form {
settings {
yamlConfigurations {
# register your own additional configuration
# choose a number higher than 30 (below is reserved)
100 = fileadmin/my_site_package/Configuration/Form/CustomFormSetup.yaml
}
}
}
In fileadmin/my_site_package/Configuration/Form/CustomFormSetup.yaml I have
TYPO3:
CMS:
Form:
prototypes:
standard:
formElementsDefinition:
Form:
renderingOptions:
templateRootPaths:
20:'fileadmin/my_site_package/Resources/Private/Templates/Form/Frontend/'
partialRootPaths:
20: 'fileadmin/my_site_package/Resources/Private/Partials/Form/Frontend/'
In the folder fileadmin/my_site_package/Resources/Private/Partials/Form/Frontend/ I have the copied Multicheckbox.html and the other copied partial files from the form core folder. I have edited the Multicheckbox.html, but it has not effects to the frontend.
Thank you so much for your input. The problem was because of the bootstrap package. There was a file Multicheckbox.html in the folder "typo3conf/ext/bootstrap_package/Resources/Private/Partials/Form". This one overrided the core file Multicheckbox.html
But what am I doing wrong in my steps? I'm getting now the following error in the frontend:
Oops, an error occurred!
Tried resolving a template file for controller action "FormFrontend->form" in format ".html", but none of the paths contained the expected template file (FormFrontend/Form.html). No paths configured.
More information regarding this error might be available online.
Did I set the paths in CustomFormSetup.yaml wrong?
I've also tried
TYPO3:
CMS:
Form:
prototypes:
standard:
formElementsDefinition:
Form:
renderingOptions:
templateRootPaths:
1:'/my_site_package/Resources/Private/Templates/Form/Frontend/'
partialRootPaths:
1:'/my_site_package/Resources/Private/Partials/Form/Frontend/'
with the same error.

Error when trying to use custom tessdata file

I have generated a box file from a png image then I followed this tutorial:
https://pretius.com/how-to-prepare-training-files-for-tesseract-ocr-and-improve-characters-recognition/ to generate custom traineddata file.
I encountered an error when I tried to use the generated traineddata alongside with Pytesseract.
and i got this kind of error:
raise TesseractError(proc.returncode, get_errors(error_string))
pytesseract.pytesseract.TesseractError: (-4, "read_params_file:
Can't open txt read_params_file: Can't open txt read_params_file: Can't open txt read_params_file: Can't open txt Error: LSTM requested, but not present!! Loading tesseract. mgr->GetComponent(TESSDATA_NORMPROTO, &fp)
:Error:Assert failed:in file adaptmatch.cpp, line 552")
I'm using Tesseract version 5.0
This is my config options
traineddata = f'+eng+lav+lav2'
config = f'-l {traineddata} --oem 1 --psm 3 {tessdata_dir}'
I followed the same tutorial and encountered the exact same error. At my first tries the ***.traineddata didn't generated well, and I findout that one file was missing (normproto). So I just cleaned all the generated files (except the corrected .box files) and rerun the train process, and everything worked fine on the second attempt.

PHP Warning: Module 'imagick' already loaded in Unknown on line 0, need some assistance

So I checked my spam folder today and had 122 messages send through the server stating:
PHP Warning: Module 'imagick' already loaded in Unknown on line 0
Non stop it keeps sending me this.
Googled it and still have no clue on how to fix it as I need a step by step answer.
Found a similar question on stack but it's too complicated for me to understand.
I'm on the latest Plesk Onyx and OS=Ubuntu 16.04.6 LTS‬.
As I'm running php 7.3 I hoped when I uninstalled php 7.0 in plesk it would go away but unfortunately it didn't.
It's send from here
Cron <root#server> [ -x /usr/lib/php/sessionclean ] && /usr/lib/php/sessionclean
And after php --ini (read about it on a forum) this was the result:
PHP Warning: Module 'imagick' already loaded in Unknown on line 0
Configuration File (php.ini) Path: /etc/php/7.0/cli
Loaded Configuration File: /etc/php/7.0/cli/php.ini
Scan for additional .ini files in: /etc/php/7.0/cli/conf.d
Additional .ini files parsed: /etc/php/7.0/cli/conf.d/00-ioncube-loader-7.0.ini,
/etc/php/7.0/cli/conf.d/10-mysqlnd.ini,
/etc/php/7.0/cli/conf.d/10-opcache.ini,
/etc/php/7.0/cli/conf.d/10-pdo.ini,
/etc/php/7.0/cli/conf.d/15-xml.ini,
/etc/php/7.0/cli/conf.d/20-calendar.ini,
/etc/php/7.0/cli/conf.d/20-ctype.ini,
/etc/php/7.0/cli/conf.d/20-curl.ini,
/etc/php/7.0/cli/conf.d/20-dom.ini,
/etc/php/7.0/cli/conf.d/20-exif.ini,
/etc/php/7.0/cli/conf.d/20-fileinfo.ini,
/etc/php/7.0/cli/conf.d/20-ftp.ini,
/etc/php/7.0/cli/conf.d/20-gd.ini,
/etc/php/7.0/cli/conf.d/20-gettext.ini,
/etc/php/7.0/cli/conf.d/20-iconv.ini,
/etc/php/7.0/cli/conf.d/20-imagick.ini,
/etc/php/7.0/cli/conf.d/20-imap.ini,
/etc/php/7.0/cli/conf.d/20-json.ini,
/etc/php/7.0/cli/conf.d/20-mbstring.ini,
/etc/php/7.0/cli/conf.d/20-mysqli.ini,
/etc/php/7.0/cli/conf.d/20-pdo_mysql.ini,
/etc/php/7.0/cli/conf.d/20-pdo_sqlite.ini,
/etc/php/7.0/cli/conf.d/20-phar.ini,
/etc/php/7.0/cli/conf.d/20-posix.ini,
/etc/php/7.0/cli/conf.d/20-readline.ini,
/etc/php/7.0/cli/conf.d/20-shmop.ini,
/etc/php/7.0/cli/conf.d/20-simplexml.ini,
/etc/php/7.0/cli/conf.d/20-sockets.ini,
/etc/php/7.0/cli/conf.d/20-sqlite3.ini,
/etc/php/7.0/cli/conf.d/20-sysvmsg.ini,
/etc/php/7.0/cli/conf.d/20-sysvsem.ini,
/etc/php/7.0/cli/conf.d/20-sysvshm.ini,
/etc/php/7.0/cli/conf.d/20-tokenizer.ini,
/etc/php/7.0/cli/conf.d/20-wddx.ini,
/etc/php/7.0/cli/conf.d/20-xmlreader.ini,
/etc/php/7.0/cli/conf.d/20-xmlwriter.ini,
/etc/php/7.0/cli/conf.d/20-xsl.ini,
/etc/php/7.0/cli/conf.d/20-zip.ini,
/etc/php/7.0/cli/conf.d/zend_extensions_psa.ini
I already know it's probably easily fixed when you know linux but I'm learning on the go and posses very little knowledge yet.
Could anyone assist me with the right commands?
Cheers
Locate where is your php.ini file by:
php -i | grep Configuration
Configuration File (php.ini) Path => /usr/local/etc/php/7.4
Loaded Configuration File => /usr/local/etc/php/7.4/php.ini
Open the php.ini file and remove the line:
extension=imagick.so
or change the line to a comment:
; extension=imagick.so

Emacs Elnode can't show html pages

I have installed Emacs elnode by Marmalade, and everything looks OK. And I have read the manual carefully.
Now elnode has started, and I can view the folder public_html under .emacs.d\elnode folder.
If I input url http://localhost:8000 in my Chrome, it will show following content:
/
.
..
default-webserver-image.png
test.html
But when I click the test.html file, chrome just can't get the response from elnode. I check my Emacs, the Message file provides two errors:
elnode-error: elnode--sentinel 'open from 127.0.0.1.' for process elnode-webserver-proc 127.0.0.1:2224 with buffer nil
elnode-error: Elnode status: elnode-webserver-proc 127.0.0.1:2224 open from 127.0.0.1
elnode-error: filter: calling handler on elnode-webserver-proc 127.0.0.1:2224
elnode-error: starting HTTP response on elnode-webserver-proc 127.0.0.1:2224
error in process filter: apply: Spawning child process: invalid argument
error in process filter: Spawning child process: invalid argument
I just don't know how to debug it. I also tried elnode-send-file function, it also doesn't work.
But If I run the Hello World example, it works:
(defun my-status-page (httpcon)
(elnode-http-start httpcon 200 '("Content-type" . "text/html"))
(elnode-http-return httpcon "<html><b>HELLO!</b></html>"))
(elnode-start 'my-status-page :port 8010)
The core problem is that Emacs can't send html page!
Is it necessary to do some basic configuration after installing elnode?
Thanks
Water Lin
The newest edition has solved the problem. If you meet the same problem as me, please download the newest edition.
My test environment is Windows7 & Emacs 24.2.1.

wurfl2 integration in TYPO3

everytime i try to install the wurfl2 extension in TYPO3 i get the following error message:
Fatal error: require_once() [function.require]: Failed opening required '' (include_path='.:/usr/local/php/lib/php:/usr/local/php/lib/php/PEAR') in /html/typo3conf/temp_CACHED_ps9b8e_ext_localconf.php on line 501
is anyone familiar with this error and knows how to fix it?
I get the same error message with TYPO3 4.4.4. I had to remove the extension folder and to delete all ./typo3conf/temp* files to get Typo3 running again afterwards.
(You might not see the error message if you don't have something like $TYPO3_CONF_VARS['SYS']['displayErrors'] = '1' in your localconf.php. You can set this with the installtool.
As already mentioned by the other answer first you have to get your system running again: set $TYPO3_CONF_VARS['SYS']['displayErrors'] = '1' in your localconf.php in order to see all error messages. Afterwards remove the extension folder.
I think the error is caused by a missing config file. The extension constant wurflConfig has to be set with the absolute path to the file /YOUR/PATH/TO/WEB_DIR/typo3conf/ext/wurfl2/res1/li/wurfl_config.php and might have to adjust the settings there.