- Joined
- Oct 19, 2007
- Messages
- 491
- Reaction score
- 159
Hi there, I'm getting an error when I try to install WordPress and it's PHP.
Function.php:
Help please !
Code:
Warning: Invalid argument supplied for foreach() in /Applications/XAMPP/xamppfiles/htdocs/myvps/wp-content/themes/ActiveHost/functions.php on line 363
Function.php:
Code:
if(function_exists("get_field") && is_page_template("page-homepage.php") ){
$upload_dir = wp_upload_dir();
// load all slide css
$slides = get_field("slides", get_the_id());
foreach($slides as $slide){
$args = array('p' => $slide,'post_type' => 'slide','posts_per_page' => 1);
query_posts( $args );
while ( have_posts() ) :
the_post();
wp_enqueue_style( 'ftl-build-'.get_the_id().'', $upload_dir['baseurl'].'/bb-plugin/cache/'.get_the_id().'-layout.css',array('main'));
endwhile;
wp_reset_query();
}
Help please !