special-characters

Prevent PHPExcel to calculate values when writing to file

*爱你&永不变心* 提交于 2019-12-01 17:19:19
When writing my data in an Excel file with class PHPExcel. This is happening when the writer works, not when adding data to the cells $this->sheet->setCellValue() Fatal error: Uncaught exception 'PHPExcel_Calculation_Exception' with message 'Adressen!AF20955 -> Formula Error: Unexpected operator '>'' in \Cell.php:300 Stack trace: #0 \PHPExcel\Worksheet.php(754): PHPExcel_Cell->getCalculatedValue() #1 \PHPExcel\Writer\Excel2007\Worksheet.php(373): PHPExcel_Worksheet->calculateColumnWidths() #2 \PHPExcel\Writer\Excel2007\Worksheet.php(80): PHPExcel_Writer_Excel2007_Worksheet->_writeCols(Object

Brew and knit one PDF report split by variable with special characters (å æ ø) - encoding issue

不打扰是莪最后的温柔 提交于 2019-12-01 17:04:15
I try to produce one PDF report split on sections based on a grouping variable, using brew and knitr . My grouping variable may contain special characters (umlauts), such as å æ ø. Umlauts in the document title only are handled fine with \usepackage[utf8]{inputenc} (see examples below). However, umlauts in the grouping variable generate an error with \usepackage[utf8]{inputenc} . On the other hand, when I tried \usepackage[T1]{fontenc} , umlauts in the grouping variable are handled properly. But now the title is not correctly encoded. I am struggling to get encoding right in both title and

Using columns with special characters in formulae in R

爷,独闯天下 提交于 2019-12-01 16:41:19
问题 I'm trying to make a decision tree using rpart using a data frame that has ~200 columns. Some of these columns have numbers in their names, some have special characters (e.g. "/"). When I try to generate the tree I get error such as the ones below: R> gg.rpart <- rpart(nospecialchar ~ Special/char, data=temp, method="class") Error in eval(expr, envir, enclos) : object 'Special' not found R> gg.rpart <- rpart(nospecialchar ~ "Special/char", data=temp, method="class") Error in terms.formula

Brew and knit one PDF report split by variable with special characters (å æ ø) - encoding issue

风流意气都作罢 提交于 2019-12-01 16:23:47
问题 I try to produce one PDF report split on sections based on a grouping variable, using brew and knitr . My grouping variable may contain special characters (umlauts), such as å æ ø. Umlauts in the document title only are handled fine with \usepackage[utf8]{inputenc} (see examples below). However, umlauts in the grouping variable generate an error with \usepackage[utf8]{inputenc} . On the other hand, when I tried \usepackage[T1]{fontenc} , umlauts in the grouping variable are handled properly.

Unicode class names in C# - why do some work, when others don't?

女生的网名这么多〃 提交于 2019-12-01 16:13:53
I'm wondering why this is. I have two unicode characters from the same group Ll, which is allowed according to the specs: http://msdn.microsoft.com/en-us/library/aa664670%28VS.71%29.aspx One of them works, the other gives a compile error, and I can't find any documentation on why this is: This works: U+0467 CYRILLIC SMALL LETTER LITTLE YUS ѧ This don't: U+04FF CYRILLIC SMALL LETTER HA WITH STROKE ӿ Can you help me find the pattern? U+0467 is from Unicode 1.1, whereas U+04FF is from Unicode 5.0. The page you refer to mentions Unicode 3.0. So the compiler's Unicode databases are just not new

How should I echo a PHP string variable that contains special characters?

自古美人都是妖i 提交于 2019-12-01 13:39:23
问题 I'm trying to populate a form with some data that contains special characters (e.g. single quote, double quote,<,>,?,","".~,,!@#$%^&*()_+}{":?<<>,./;'[.] etc) : <input type="text" name="message" size="200" maxlength="200" value =<?php echo $message;?>> However, $message , which comes from a MySQL table, isn't displayed correctly - any HTML output that should be in $message is broken. How do I do this properly? 回答1: This will prevent your tags from being broken by the echo: <?php echo

Connect to FTP with PHP with a password that has @

谁说我不能喝 提交于 2019-12-01 13:18:49
I have the following problem: I need connect to FTP and read one CSV file. The main problem it's password has @, $, %... How can I connect with especials characters? I tried the following ways to connect: FILE OPEN $filename = 'ftp://user:p@s($word@ftp.myftp.url/file.csv'; $handle = fopen($filename, "r") or die("Error"); FTP LOGIN $ftp_server = "ftp.myftp.url/file.csv"; $ftp_user = "user"; $ftp_pass = "p@s($word"; $conn_id = ftp_connect($ftp_server) or die("Could not connect to $ftp_server"); $login_result = ftp_login($ftp_server, $ftp_user, $ftp_pass) or die("Could not connect to 2"); $data =

“. was unexpected at this time” generated from batch script line 'if exist [file] (…

China☆狼群 提交于 2019-12-01 12:09:27
问题 relevant code looks like this: cd /d %~dp0 if exist filename.txt ( echo %date% %time% *** text... >> filename2.txt echo ============================== echo === text....... === echo === text....... === echo === text....... (text...) === echo === text (text... echo === text...). :loop set /p "varx= text: " if "%varx%" neq "xxxx" goto loop ... more script... ) Have searched high and low for solutions... was pointed in direction of If statement groupings here: https://www.petri.com/forums/forum

Connect to FTP with PHP with a password that has @

非 Y 不嫁゛ 提交于 2019-12-01 11:52:54
问题 I have the following problem: I need connect to FTP and read one CSV file. The main problem it's password has @, $, %... How can I connect with especials characters? I tried the following ways to connect: FILE OPEN $filename = 'ftp://user:p@s($word@ftp.myftp.url/file.csv'; $handle = fopen($filename, "r") or die("Error"); FTP LOGIN $ftp_server = "ftp.myftp.url/file.csv"; $ftp_user = "user"; $ftp_pass = "p@s($word"; $conn_id = ftp_connect($ftp_server) or die("Could not connect to $ftp_server");

Remove special characters in the string in java?

泄露秘密 提交于 2019-12-01 11:29:41
How to remove special characters in the string except "- _". Now I use: replaceAll("[^\\w\\s]", "") it remove all special character but i want to keep "- _" . Can anyone tell me how should I do? Use replaceAll("[^\\w\\s\\-_]", ""); What I did was add the underscore and hyphen to the regular expression. I added a \\ before the hyphen because it also serves for specifying ranges: a-z means all letters between a and z. Escaping it with \\ makes sure it is treated as an hyphen. This might help: replaceAll("[^a-zA-Z0-9_-]", ""); I suspect that you need to assign the result (in case you're not doing