Warning: Unexpected character in input: '' (ASCII=127) state=0 - wordpress

I got this problem
Warning: Unexpected character in input: '' (ASCII=127) state=0 in
/home/penumbr9/public_html/wp-load.php(1) : eval()'d code on line 1
Parse error: in /home/penumbr9/public_html/wp-load.php(1) : eval()'d
code on line 1.
Didn't know when this happen because since 1 month I didn't open the website.
But I think it happened when auto updated wordpress.
Also can open wp-admin or known as dashboard

Related

system2("open","/Users/folder (P)") results in " syntax error near unexpected token `(' " in R

trying to open folder using R by the code
system2("open","/Users/folder (P)")
results in error A below
sh: -c: line 0: syntax error near unexpected token `('
i think it is because the folder name has parentheses. looking forward to help and any comments are welcome
I tried the below code too--
system2("open","/Users/folder \(P\)")
then error B is
Error: '\(' is an unrecognized escape in character string
I also tried hitting Tab button, then successfully selecting the "folder (P)", but it results in the same error A

Unexpected input error when doing subtraction in R

i try to run:
x = (1 / 1 – 2)
And here is the message:
Error: unexpected input in "x=(1 / 1 �"
I have the same issue with these sign : <- and * and minus, none of them are recognised.
You might be confronted to the so-called "zero-width space" which is not interpreted as a space. Check this wiki page:
If the blanks you have in your code example are this kind of character, it will make an error like this:
Error: unexpected input in "x=(1 / 1"
as some comments point out, one must be careful when pasting code from websites.

Error in source() unexpected numeric constant

when I write an R script in a test.R file
nb <- 22
paste("Etudions le nombre: ",nb)
paste("Le logarithme népérien de ce nombre est: ", log(nb))
paste("La racine carrée de ce nombre est: ", sqrt(nb))
paste("Le cosinus de ce nombre est: ", cos(nb))
paste("Si on ajoute 3 au nombre ", nb, " on obtient: ", nb + 3)
q("ask")
I executed using :
source("/Users/shous/Desktop/Master2.0/LanguageR/test.R")
error message :
Error in source("/Users/shous/Desktop/Master2.0/LanguageR/test.R") :
/Users/shous/Desktop/Master2.0/LanguageR/test.R:1:9: unexpected numeric constant
1: nb <- 22
It can be encoding problem: unexpected numeric constant 1: nb <- 22
I guess you don't want to have this character Â.Try to change file encoding or rewrite problematic line (not copy paste).
unexpected numeric constant 1: nb <- 22
This is R telling you that it found the line
nb <- 22
and that isn't valid syntax. You can duplicate this simply on the command line with something like a = a 22, which also isn't valid syntax. You need to correct that line of code - I don't know what you want it to be, perhaps there is a missing line break, or perhaps it should be  + 22 or Â[22], etc...
The line that produces the error does not occur in the code you show, perhaps you should make sure you are running the right file.

Michael Hartl's Railstutorial : Listing 7.32: A template for tests of the error messages

The example code:
assert_select 'div#<CSS id for error explanation>'
assert_select 'div.<CSS class for field with error>'
This generates:
DEPRECATION WARNING: The assertion was not run because of an invalid css selector. ] 16% Time: 00:00:01, ETA: 00:00:06
unexpected '#' after '[#]' (called from block in at /home/ubuntu/workspace/sample_app/test/integration/users_signup_test.rb:25)
DEPRECATION WARNING: The assertion was not run because of an invalid css selector.
unexpected '<' after '.' (called from block in at /home/ubuntu/workspace/sample_app/test/integration/users_signup_test.rb:26)
I read somewhere that versions 4.2+ need an other way to do assert_select. Is that true? And what should be used?
[ I have to say; I am still an absolute beginner ]
substitute a your-class under <CSS class...>, and your-id under <CSS id ...>

Errors when loading ci-merchant library

I'm trying to use http://ci-merchant.org/ for CodeIgniter. But when I load the merchant library, I get these errors:
A PHP Error was encountered
Severity: Warning
Message: stripos() expects parameter 1 to be string, array given
Filename: libraries/merchant.php
Line Number: 97
A PHP Error was encountered
Severity: Warning
Message: strtolower() expects parameter 1 to be string, array given
Filename: libraries/merchant.php
Line Number: 103
Here is my code:
$this->load->library('merchant');
$this->merchant->load('paypal_express');
Looking at the source of that file, the driver name needs to be passed as a string. So I highly doubt the two lines of code you put above is actually what's being called, it looks like you are passing an array as the driver name.
If you aren't sure where it's coming from, try adding some debug_print_backtrace() lines to the merchant.php file to figure out where the array is getting passed from.

Resources