PHP str_repeat() Function
The str_repeat()
function is used torepeats a string a specified number of times.
Syntax
str_pad(string,length,pad_string,pad_type)
- string - (Required) Specify the string to repeat.
- repeat - (Required) Specify the number of times for string repeated..
Example
<?php echo str_repeat("Hello",10); ?>
Output
HelloHelloHelloHelloHelloHelloHelloHelloHelloHello