Home › Forums › SKT Full Width Forum › Limit the width of the theme?
- This topic has 11 replies, 2 voices, and was last updated 9 years, 10 months ago by Sonl Sinha.
-
AuthorPosts
-
December 26, 2014 at 8:07 pm #3064
Is there any way to limit the width of the theme so it doesn’t stretch on larger screens?
December 29, 2014 at 5:27 am #3101Hi,
Is it the theme stretch or the slider stretch you are worried about? Let us know.
Theme width managed by #wrapper within css and slider stretch different area.
Let us know which one.
Regards,
ShriDecember 29, 2014 at 8:26 pm #3117Its the width of the pages that stretch, i am going to be using it with tables for photos and depending on the size of the screen, it stretches from 2 to 3 o 4 columns wide. This is what i would like to stop and give it a fixed width.
Regards
December 29, 2014 at 8:27 pm #3118The main theme mage is perfect, just the individual pages that i create.
December 30, 2014 at 2:00 pm #3139Okay kindly show us the website url. Then i can quickly send the instructions based on that.
Regards,
ShriJanuary 4, 2015 at 10:06 am #3230Morning, sorry for the delay in posting back.
http://octaviolr.dhtech.es/?page_id=2
I would like to limit the width of the page so that i can put photos on it and it will not change for different screens.
Thanks!
January 5, 2015 at 9:05 am #3246Hi Daniel,
For this you need to have a separate page template for this page with different header.
Basically there is a code in header:
January 7, 2015 at 9:11 pm #3298Hi Shri,
I have been looking at the header.php and am trying to find the code that needs to be changed to adjust the width of the page, would you be able to show me the lines that i need to change?
Thanks
Dani
<?php
/**
* The Header for our theme.
*
* Displays all of the <head> section and everything up till <div id=”content”>
*
* @package SKT Full Width
*/
?><!DOCTYPE html>
<html <?php language_attributes(); ?>>
<head>
<meta charset=”<?php bloginfo( ‘charset’ ); ?>”>
<meta name=”viewport” content=”width=device-width, initial-scale=1″>
<title><?php wp_title( ‘|’, true, ‘right’ ); ?></title>
<link rel=”profile” href=”http://gmpg.org/xfn/11″>
<link rel=”pingback” href=”<?php bloginfo( ‘pingback_url’ ); ?>”>
<link rel=”icon” type=”image/x-icon” href=”<?php echo esc_url( of_get_option(‘favicon’, true) ); ?>” />
<?php
$slAr = array();
for ($i=1;$i<16;$i++) {
if ( of_get_option(‘slide’.$i, true) != “” ) {
$imgUrl = of_get_option(‘slide’.$i, true);
if ( strlen($imgUrl) > 3 ) $slAr[] = of_get_option(‘slide’.$i, true);
}
}
?>
<?php wp_head(); ?>
<link rel=”stylesheet” type=”text/css” href=”<?php echo get_template_directory_uri();?>/css/style_base.css”>
</head>
<body <?php body_class(); ?>>
<?php
$front_page = get_option(‘page_on_front’);
$post_page = get_option(‘page_for_posts’);
?>
<div id=”page” class=”hfeed site”>
<?php do_action( ‘before’ ); ?>
<?php if( (is_front_page() || is_home() ) && ($front_page == 0 && $post_page == 0) ){ ?>
<?php if( count($slAr) > 0 ){ ?>
<div class=”slider-parent”>
<div class=”slider-wrapper theme-default container <?php if( is_front_page() || is_home() ){ echo ‘home_front_wrap_main’; } ?>”>
<!–Thumbnail Navigation–>
<div id=”prevthumb”></div>
<div id=”nextthumb”></div>
<div id=”thumb-tray” class=”load-item”>
<div id=”thumb-back”></div>
<div id=”thumb-forward”></div>
</div>
<div id=”progress-back” class=”load-item”>
<div id=”progress-bar”></div>
</div><!–Time Bar–>
<div id=”slidecaption”></div><!–Slide captions displayed here–>
<div id=”controls-wrapper” class=”load-item”>
<div id=”controls”>
<a id=”play-button”><img id=”pauseplay” src=”<?php echo get_template_directory_uri();?>/images/img/pause.png”/></a>
<!–Arrow Navigation–>
<a id=”prevslide” class=”load-item”></a>
<a id=”nextslide” class=”load-item”></a>
<div id=”slidecounter”>
<span class=”slidenumber”></span> / <span class=”totalslides”></span>
</div><!–Slide counter–>
</div>
</div><!–Control Bar–>
</div><!–.container–>
</div><!–.slider-parent–>
<?php } //if( count($slAr) > 0 ){ ?>
<?php } ?>
<div id=”wrapper”>
<div id=”secondary” class=”widget-area <?php if( is_front_page() || is_home() ){ echo ‘home_front_wrap’; } ?>” role=”complementary”>
<div class=”header”>
<div class=”logo”>
<h1 class=”site-title”><a href=”<?php echo esc_url( home_url( ‘/’ ) ); ?>” rel=”home”>
<?php if( of_get_option(‘logo’, true) != ” ) { ?>
<img src=”<?php echo esc_url( of_get_option(‘logo’, true) ); ?>” />
<?php } else { ?>
<?php bloginfo( ‘name’ ); ?>
<?php } ?>
</a></h1>
<p class=”site-description”><?php bloginfo( ‘description’ ); ?></p><br />
</div>
<div class=”show_hide_header”>
<div id=”site-nav”>
<h1 class=”menu-toggle”></h1>
<div class=”screen-reader-text skip-link”><a href=”#content”><?php _e( ‘Skip to content’, ‘skt-full-width’ ); ?></a></div>
<?php wp_nav_menu( array(‘theme_location’ => ‘primary’, ‘container’ => ”, ‘menu_class’ => ‘nav’) ); ?>
</div><!– site-nav –>
<?php if ( is_active_sidebar( ‘sidebar-2’ ) ) : ?>
<?php dynamic_sidebar( ‘sidebar-2’ ); ?>
<?php endif; ?>
</div>
<div class=”header-bottom”>
<div id=”header-bottom-shape”>
</div><!– header-bottom-shape2 –>
</div><!– header-bottom –>
<div class=”clear”></div>
</div><!– header –>
</div><!– secondary –>
January 8, 2015 at 10:10 am #3302Hi Daniel,
This code you need to neglect when using in the new page template:
From the header then the page won’t resize for mobile and tablet. I guess that is what you are asking.
Regards,
ShriJanuary 18, 2015 at 12:50 pm #3450Good afternoon Shri,
Im not sure if you have understood what i am trying to do hehehe.
Its not that i dont want it to resize on mobile devices or tablets. I would like to be able to make the size of the theme contant, so that when i open it on different size pc screens, its does not expand.
Thanks
Daniel
January 18, 2015 at 1:50 pm #3451For example, here is a screenshot of the page:
https://www.dropbox.com/s/6laddq9sqslv47i/Captura-de-pantalla-2015-01-18-a-las-14.45.19.jpg?dl=0
I would like to makes the size marked with the red line, the size of the dotted line.
Regards
Daniel
January 20, 2015 at 12:46 pm #3491That is quite difficult Daniel.
Its like playing with the whole css. It might result in problems in responsive view as well.
Customization request sort of.
Regards,
Shri -
AuthorPosts
- You must be logged in to reply to this topic.