a datatype that can hold a character of the implementation’s character set.
Questions tagged [chars]
208 questions
3
votes
0 answers
Sending an email from Delphi using Indy changes Danish chars
I have made a form that I use to send a mail using Indy. The form can be used to attach files as well.
All this is working very fine when I use the sample in the link below and when I use it in a utility I have made for sending invoices made as PDF…

OZ8HP
- 1,443
- 4
- 31
- 61
3
votes
2 answers
HTML → / ← not displayed on some systems
I'm making heavy use of → / ← arrow symbols in HTML so that i spare myself the pain of having to go with images. This is for an enclosed system, not for a public website.
Now i noticed that my client does not have those symbols in their charsets…

SquareCat
- 5,699
- 9
- 41
- 75
3
votes
3 answers
php true multi-byte string shuffle function?
I have a unique problem with multibyte character strings and need to be able to shuffle, with some fair degree of randomness, a long UTF-8 encoded multibyte string in PHP without dropping or losing or repeating any of the characters.
In the PHP…

Dave
- 117
- 5
3
votes
3 answers
Convert array of int to array of chars - Python
I am trying to convert a set literal of integers into that of chars.
For example, if the array {0,1} is given as an input, I would like to firstly check if the individual elements are chars and if not convert them into chars so that I get {'0',…

Seb
- 481
- 2
- 6
- 18
3
votes
1 answer
Incrementing chars in for loop works, decrementing does not?
So I was doing some exercises and ran across this code (which produces "1. Item A", "2. Item B", etc ):
echo "\n
- ";
for ($x='A'; $x<'G'; $x++){
echo "
- Item $x \n"; } echo "\n

Tim Spencer
- 131
- 7
3
votes
2 answers
C++: Chr() and unichr() equivalent?
I could have sworn I used a chr() function 40 minutes ago but can't find the file. I know it can go up to 256 so I use this:
std::string chars = "";
chars += (char) 42; //etc
So that's alright, but I really want to access unicode characters. Can I…

alex
- 31
- 1
- 2
3
votes
1 answer
Lua Removing first couple characters without add a space
I'm new to Lua and I'm sure this is a silly problem.
I was trying to remove first 3 characters from a string with string.gsub
Here is the code:
string.gsub(m, "/jk", "", 1)
Now "/jk" are the first 3 chars the string, now, string.gsub adds a space…

nuberelo
- 57
- 1
- 2
- 5
3
votes
4 answers
PHP urlencode converting HTML special characters
Ive done a good deal of searching and so far can't find this already answered (though I might not be asking properly).
I have a simple title string on a page thats stored into a php variable
$title
When I print_r it I get back a happy, normal,…

Tey
- 51
- 1
- 1
- 8
2
votes
7 answers
C langugage - "Weird" characters in char[] output
I had to build a C program which convert's infix notation into postfix notation using STACK. That went well and it's working in some way. It was long ago when I used last time C language so I'm probably dont use char[] variables very well.
So…

rjovic
- 1,207
- 2
- 16
- 37
2
votes
1 answer
phpQuery making  of and others
When I have a file that I run through phpQuery that has stuff like or © in it somehow a  is added.
so when I have this file (hello.html):
hello, this is a test ©
and I run this code:
$f = phpQuery::newDocumentFile( 'hello.html'…

patrick
- 11,519
- 8
- 71
- 80
2
votes
3 answers
Problem with string - lenght is not correct - some chars included not displayed
I wanted to upgrade the Magento Ogone module to match the new SHASign calculation.
It's working fine now but there is a problem ...
I have an issue with some strings returned by a Magento method : Mage::getUrl('ogone/api/accept');
It returns me a…

antoineg
- 98
- 6
2
votes
2 answers
Test if two first chars typed in are alphanumeric - no regex
I have following code that needs something smart to deal with typed in chars and detection:
private final MultiWordSuggestOracle mySuggestions = new MultiWordSuggestOracle();
private final Set mySuggestionsData = new…

MatBanik
- 26,356
- 39
- 116
- 178
2
votes
1 answer
Send chars with UDP
I'm trying to send text with UDP, by sending every character separately, but something seems to be wrong.
This is the client:
while(strcmp(sir,"0")!=0)
{
printf("Text number %d:", i);
i++;
scanf("%s",sir);
printf("\n");
…

Vidi
- 183
- 1
- 1
- 9
2
votes
2 answers
Unable to remove invisible chars using Regex
I want to remove any invisible chars from a string, only keep spaces & any chars from 0x20-0x7F,
I use this: Regex.Replace(QueryString, @"[^\s\x20-\x7F]", "");
However it does not work
QueryString has a char 0xA0, after that, the char still exists…

susu
- 73
- 1
- 5
2
votes
2 answers
Two dimensional char array from string using Stream
I am about to create the two dimensional array from string:
char[][] chars;
String alphabet = "abcdefghijklmnopqrstuvwxyz";
So the array will ilustrate this matrix:
But how can I do that using Java 8 Streams, cause I do not want to do this by…

masterofdisaster
- 1,079
- 1
- 12
- 27