Content display on Ipad
-
Hi guys
I’m strugling with my theme (BlackPearl) for showing website on Apple products .. nightmare.
One of the problems is related to core WP, for showing content.
Example:
I tested our site https://www.prodive.si with https://ipadpeek.com/ (choose ipad horizontal orientation)When you scroll down, you will se that we use code to show 3 posts from specific category
On Apple they are “small” .. no full width
Code that i use is
<!-- Recent Posts --> <?php if(opt('home_recent_posts')) { $lastposts = get_posts('numberposts=3&category=47'); if(count($lastposts)) { ?> <div class="container"> <div class="row latest_blog_post"> <?php foreach($lastposts as $post) { setup_postdata($post); $postType = get_post_meta(get_the_ID(), 'content_type', true); $hasMedia = false; $vType = get_post_meta(get_the_ID(), 'video_server', true); $vID = get_post_meta(get_the_ID(), 'video_id', true); if($postType == '1' && function_exists('has_post_thumbnail') && has_post_thumbnail()) $hasMedia = true; else if($postType == '2') $hasMedia = true; $boxClass = $hasMedia ? '' : 'no-media'; ?> <div class="span4 box <?php echo $boxClass; ?>"> <a href="<?php the_permalink(); ?>"> <div class="meta1"> HOT </div> <?php if($postType == '1'){ ?> <div class="image"> <?php if ( function_exists('has_post_thumbnail') && has_post_thumbnail() ) the_post_thumbnail('recent-posts'); ?> </div> <?php } elseif($postType == '2') { ?> <div class="post_video"> <?php if($vType == '' || $vType == '1') { ?> <iframe width="560" height="315" src="https://www.youtube.com/embed/<?php echo $vID; ?>" frameborder="0" allowfullscreen></iframe> <?php } else {?> <iframe src="https://player.vimeo.com/video/<?php echo $vID; ?>?color=f0e400" width="500" height="281" frameborder="0" webkitAllowFullScreen mozallowfullscreen allowFullScreen></iframe> <?php } ?> </div> <?php } ?> </a> <h2> <a class="title" href="<?php the_permalink(); ?>"><?php the_title(); ?></a> </h2> <div><hr align="center" width="94%" color="#00579a" size="5"></div> <div class="latest_levo"> <?php $content = get_the_content(); if(strlen($content) <= 200) echo $content; else { $matches = array(); preg_match('/^.{0,200}(?:.*?)\b/iu', strip_tags($content), $matches); echo $matches[0] . '...'; } ?> </div> </div> <?php } ?> </div> </div> <?php }//If recent posts } ?>
any idea what to do, so these three posts will be full width on apple products?
Thank you
Viewing 4 replies - 1 through 4 (of 4 total)
Viewing 4 replies - 1 through 4 (of 4 total)
- The topic ‘Content display on Ipad’ is closed to new replies.