Error
Notice: Undefined variable: workshop in C:\wamp\www\MBL\index.php on line 273
Line 273
$workshop .= '<div class="workshopAddon col-xs-4 text-center no-padding" style="display:none;">';
Cut out of coding
</script>
<!-- Server Workshop Collection -->
<div class="col-xs-12" style="overflow:hidden;position:absolute!important;bottom:25px;">
<?php
include 'simple_html_dom.php';
$url = 'http://steamcommunity.com/sharedfiles/filedetails/?&format=json&id=124102726';
$html = file_get_html($url);
foreach($html->find('.collectionItem') as $element) {
$workshop .= '<div class="workshopAddon col-xs-4 text-center no-padding" style="display:none;">';
foreach($element->find('.workshopItemPreviewHolder') as $previewImg) {
$img = '<div class="col-xs-3 no-padding text-center circular">'.$previewImg->innertext.'</div>';
}
foreach($element->find('.workshopItemTitle') as $displayName) {
$title = '<p class="workshopItemTitle">'.$displayName->innertext.'</p>';
}
foreach($element->find('.workshopItemAuthor') as $displayName) {
$author = '<p class="workshopItemAuthor">'.$displayName->innertext.'</p>';
}
$workshop .= $img.'
<div class="col-xs-9 no-padding">
'.$title.$author.'
</div>
</div>';
}
echo $workshop;
?>
<script>