• in the template im trying i can’t get it to do what i want.

    the site is : http://kubestudio.com/web/wordpress

    when you click the 2nd button portfolio a sub menu opens, and what i want is that on those sub menus the “MainWrapper” is 0px wide instead of the 500 or whatever of the other pages.

    Now those sub-menus ( the sports one for example ) Answer to a file called : single-portfolio.php

    with this code:

    <?php 
    
    get_header(2); 
    
    $gallery_id = (get_post_meta($post->ID, THEME_METABOX . 'gallery_id', true) == "") ? null : get_post_meta($post->ID, THEME_METABOX . 'gallery_id', true);
    $gallery_columns = (get_post_meta($post->ID, THEME_METABOX . 'gallery_columns', true) == "") ? 3 : get_post_meta($post->ID, THEME_METABOX . 'gallery_columns', true);
    
    $heading_text = (get_post_meta($post->ID, THEME_METABOX . "heading_text", true) == "") ? get_the_title() : get_post_meta($post->ID, THEME_METABOX . "heading_text", true);
    ?>
    
    <!-- start mainWrapper -->
    <div id="mainWrapper">
    	<h1 id="pageHeading"><?php echo $heading_text;?></h1>
    	<!-- start content -->
    	<div id="content">
    		<!--start single post-->
    		<div id="singlePost">
    			<!-- start post -->
    			<div <?php post_class("last"); ?>>
    			<?php 
    
    			if (have_posts()) : while (have_posts()) : the_post();
    
    			$image_url_big = wp_get_attachment_image_src( get_post_thumbnail_id($post->ID), 'full');
    
    			?>
    
    			<div class="postContent">
    
    				<?php //get_template_part('templates/entrymeta'); ?>
    
    				<?php 
    
    				the_content(); 
    
    				?>   
    
    			</div>
    
    			<?php 
    
    			endwhile; endif;
    			?>
    
    			<?php
    			if ( !post_password_required() ) :
    
    				comments_template();
    			endif;
    			?>
    			</div>
    			<!-- end post -->
    		</div>
    		<!-- end single post-->
    	</div>
    	<!-- end content -->
    </div>
    <!-- end mainWrapper -->
    
    <?php get_template_part('templates/sidewrapper'); ?>
    
    <?php get_footer(); ?>

    I tryed changing that PHP to not load the MainWrapper but can’t get it to work, so im thinking on an alternative way changing the style of this specific page.

    Now i guess this page gets the Style from the Get_header , so i thought about creating a new header that calls a new style.css ( style2.css for example ) and in this style2.css i will change the width of the Mainwrapper wich works because i tried on the style.css

    Now how do i do this?

    i mean getting the single-portfolio.php to load style2.css instead of style.css ?

    thanks a lot!

    i have another post open to try to correct the issue with php but not finding a solution so maybe CSS works easier.

    [please do not bump – allow more time to get a reply]

  • The topic ‘Is it possible to Change the style on one specific page’ is closed to new replies.