0 like 0 dislike
9 views
asked Apr 27 in Education & Reference by Neha (730 points) | 9 views
    

1 Answer

0 like 0 dislike
$a = preg_replace('/[^a-zA-Z0-9]+/', '', "my" );
if(strlen($a)>8){
  $name_alter = substr($a,0,8);
}else{
  $name_alter = str_pad($a,8,"Z");
} 
echo $name_alter;
answered Apr 27 by Krish (920 points)

Related questions

0 like 0 dislike
1 answer
0 like 0 dislike
1 answer
asked Aug 1, 2017 in Education & Reference by Krish (920 points) | 15 views
0 like 0 dislike
2 answers
1 like 0 dislike
1 answer
1 like 0 dislike
1 answer
1 like 0 dislike
1 answer
1 like 0 dislike
1 answer
0 like 0 dislike
1 answer
1 like 0 dislike
1 answer

Where your donation goes
Technology: We will utilize your donation for development, server maintenance and bandwidth management, etc for our site.

Employee and Projects: We have only 15 employees. They are involved in a wide sort of project works. Your valuable donation will definitely boost their work efficiency.

How can I earn points?
Awarded a Best Answer 10 points
Answer questions 10 points
Asking Question -20 points

Mathe Forum Schule und Studenten
1,151 questions
1,281 answers
263 comments
1,506 users