How can the explode function in PHP be utilized with a limit parameter to split a string based on a specific delimiter?

When using the explode function in PHP, you can specify a limit parameter to control the number of elements in the resulting array after splitting the string based on a specific delimiter. This can be useful when you only want to split the string up to a certain number of times, rather than splitting it completely.

```php
$string = "apple,banana,orange,grape,pineapple";
$fruits = explode(",", $string, 3);

print_r($fruits);
```

In this example, the string "apple,banana,orange,grape,pineapple" is split into an array using the comma delimiter. However, the limit parameter is set to 3, so only the first 3 elements ("apple", "banana", "orange") are included in the resulting array.