PHP Code:
    $pattern=Array();
    
$pattern[0] = "<a(\s+(title=(\"[^\"]*\")|href=(\"[^\"]*\")|\w+=(\"[^\"]*\"|\S+)))+>";
    
$pattern[1] = "#<a.*>(.+)</a#Ui"//preg_match pattern in a for loop to get the href, title and innerhtml and exclude the book title in brackets
    
preg_match_all($pattern[0], $file$file_1);
    for(
$i=0$i<count($file_1[4]); $i++){
        
$href=str_replace("\""""$file_1[4]);
    }
    for(
$i=0$i<count($file_1[3]); $i++){
        
$title=str_replace(" """str_replace("\""""$file_1[3]));
    }
    
preg_match_all($pattern[1], $file$file_2);
    
print_r($file_2[1]);
    for(
$i=0$i<count($file_2[1]); $i++){
        
$heb=explode(")"$file_2[1][$i]);
    }
//var_dump($heb); 
I realize that I don't need to declare $heb as an array $heb=Array(); but I need to gather $file_2[1][$i][1] into one array. How would that be possible?