I want to be able to turn certain parts of a string to bold using a regular expression in PHP.
When the string contains text \*\*surrounded by two asterisks\*\*, it should turn bold.

I'm using three examples:

```
**The quick brown fox jumps over the lazy dog.**

The **quick** brown fox **jumps over** the lazy dog.

**The quick* brown fox jumps over the lazy dog**.

```

I've tried:

```
$string = preg_replace('/\*\*(.+)\*\*/' , "<b>$1</b>" , $string);

```

Which fails on the second one because it gives:

```
The <b>quick** brown fox **jumps over</b> the lazy dog.

```

It should have stopped after quick and matched again at jumps.

I also tried:

```
$string = preg_replace('/\*\*([^*]+)\*\*/' , "<b>$1</b>" , $string);

```

Which works on the second one but fails on the third, matching nothing at all.

What I really want is something like this:

```
$string = preg_replace('/\*\*([^*{2}]+)\*\*/' , "<b>$1</b>" , $string);

```

But I know that's know right. I think I should be using negative lookahead somehow but I don't know how.

Thanks in advance.