Cannot get mPdf working - mpdf

I use composer require mpdf/mpdf to install it.
when trying example I got error:
Parse error: syntax error, unexpected '.', expecting '&' or variable
(T_VARIABLE) in /var/www/randomizer/library/mpdf/src/functions-dev.php
on line 4
hope someone can help me with this issue.

Ensure you are running PHP5.6 or higher when attempting to run the examples. Your CLI might be a different version which is why it didn't complain when you installed Mpdf via composer.

Related

When I update vuejs3 to v3.2.40 why am I getting the error "An index signature parameter type must be either string or number"?

I am trying to simply upgrade the version of vue3 we are running at work from v3.2.31 to v3.2.40. However, when I do, I am now getting an error in the runtime-dom.d.ts
Below is a screen shot from the file with vue v3.2.31 installed.
Once I've run the "npm update vue --save" command, the file looks like this (v3.2.40)...
...and VS 2022 throws the following error when trying to build...
If I delete the line from my local copy of runtime-dom.d.ts, all works as before. My problem comes when deploying the solution to the development environment etc. The npm install step puts a version of the runtime-dom.d.ts that does still have this line.
I'd like to fix this without having to resort to hacking the runtime-dom.d.ts file if at all possible.
Many thanks in advance.

Uploading manifest file failing

After making some changes in a JSON manifest file, I was trying to update it following the Amazon documentation:
ask smapi update-skill-manifest -g development -s amzn1.ask.skill.xxxx --manifest "skillManifest.json" --debug
I kept getting this error:
The error was not pointing to what the error was but my guess was that it was related to the parameters, but that was strange as I was following the documentation to letter.
I then tried, instead of passing the json file, to cat the content of the file, which would be either:
For Powershell: --manifest "$(type skillmanifest.json)"
For Linux: --manifest "$(cat skillmanifest.json)"
I still kept getting the same error.
Firstly, for debugging and getting a more accurate error, I checked my ASK-CLi version, which was outdated.
After updating ASK to the latest version I was still getting the same error.
At that point it started including an error object, which was saying:
When looking into Parsing error due to invalid body. and INVALID_REQUEST_PARAMETER through the error codes, it just said the body of the request cannot be parsed.
After research and playing around, the problem was the manifest parameter, changing it to "file:FILENAME" solved the issue:
--manifest "file:skillmanifest.json"
The documentation is not stating this but it seems necessary for it to go through.
I hope this helps someone out there avoid spending a full day troubleshooting.

Shinyloadtest: Error: Please upgrade your pandoc version to be at least v2.2

I am trying to run results from recording.log, as instructed from https://rstudio.github.io/shinyloadtest/ I am running below command to see in browser view:
shinyloadtest::shinyloadtest_report(df, "run1.html")
but throwing an error :
to resolve this, when I am trying install pandoc, throwing below error
what I am doing wrong in this?
can any one please help me on this!
My Issue was resolved, I have used one command in R Studio that can overpass pandoc issue:
shinyloadtest_report(df,"run1.html",self_contained=F)

syntax error, unexpected T_USE, expecting T_FUNCTION in my SauceLabs test case

I tried following the SauceLabs PHP tutorial: https://docs.saucelabs.com/tutorials/php/
I tried to make it run on Windows. So I followed every step until I have to run this command:
vendor\bin\phpunit.bat WebDriverDemo.php
This generates an error: Parse error: syntax error, unexpected T_USE, expecting T_FUNCTION in C:\xampp\htdocs\sauce-tutorial\vendor\sauce\sausage\src\Sauce\Sausage\WebDriverTestCase.php
on line 6
So I tried looking at WebDriverTestCase.php on line 6 and this is the code:
namespace Sauce\Sausage;
abstract class WebDriverTestCase extends \PHPUnit_Extensions_Selenium2TestCase
{
use TestCase; // this is line 6
}
Whats wrong with this code? I changed nothing, I only tried to run what the tutorial suggests. Any ideas?
I don't use PHP but on the basis of what I found with a Google search, I'd suggest making sure you are running the code with PHP 5.4 or later. In the cases I found on the web using an older version of PHP seemed to be the cause of that error.

Meteor Jade Handlebars on Windows 8 - Jade compiler error: Cannot read property 'length' of undefined

I'm attempting to use jade in meteor with this package https://github.com/SimonDegraeve/meteor-jade-handlebars
I'm on a windows machine. I've so far managed to use most meteorite packages by following the instructions here (www.discovermeteor.com/2013/03/20/using-meteor-and-atmopshere-on-windows/)
When i run 'meteor' on my project with .jade files, I'm getting this error:
While building the application:
client\todos.jade: Jade compiler error: Cannot read property 'length' of undefin
ed
=> Your application has errors. Waiting for file change.
Terminate batch job (Y/N)?
I tried to use this new fork too -> https://github.com/kynan/meteor-jade-handlebars/tree/refactor-for-meteor-0.6.5
Same problem.
I further tested this in a Linux machine and it works perfectly. I have no idea why this is failing with the above mention error on windows.
Try adding a blank extra line to the end of your file. For example, an extra line would be needed here.
template(name="name")
h1 Hello!
I've been dealing with a lot of problems getting jade-templating to work with meteor, but finally got it to work.. Here's how:
Add this to smart.json, belt-jade-handlebars is jade for newer versions of meteor:
"packages": {
"belt-jade-handlebars": {}
}
Add this to .meteor/packages:
belt-jade-handlebars
And finally add the extra blank line to all *.jade files. ( suggested by user3064375 )
Start the app by using:
$ meteor run --release template-engine-preview-3
This will use the latest template engine and start meteor.

Resources