I have a string in php formatted like this:

```
http://aaaaaaaaaa/*http://bbbbbbbbbbbbbbb

```

where aaa... and bbb.... represent random characters and are random in length.

I would like to parse the string so that I am left with this:

```
http://bbbbbbbbbbbbbbb

```
['https://Stackoverflow.com/questions/8737854', 'https://Stackoverflow.com', 'https://Stackoverflow.com/users/657818/']
In this case I wouldn't recommend regex but a simple substring or explode

```
$data = "http://aaaaaaaaaa/*http://bbbbbbbbbbb"
$parts = explode('*', $data);
echo $parts[1];

```

fin :)
Here is the regular expression way:

```
$str = 'http://aaaaaaaaaa/*http://bbbbbbbbbbbbbbb';
$url = preg_replace("/^.*(http:\/\/.*[^(http:\/\/)+])$/", "$1", $str);
echo $url;

```