• My site has a fixed width, 2 column design. The second column constains several widgets which show up on all pages. I want to add another page and embed an amazon store which has its own 2 column design and so I want to eliminate the second column on my page and devote the full width to the embedded store.

    I have the code to embed the store but the presents of the second column does not leave enough width for the embedded store to display properly.

    Can I get rid of the second column and its widgets in only a single page of the site?

    I don’t want the other pages to change.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Yeah, you can make a page template that will be used for just that page.

    Check Here

    Thread Starter jmdougla

    (@jmdougla)

    Another option for the layout is to use a frameset instead of an inline frame. If I could elininate the body of the site and replace it with the frame with the amazon store, that may work. But I don’t know what to add into the frameset coding to get the right result.

    Here is the frameset code:

    <frameset rows="80,*" border="0">
      <frame src="INSERT_YOUR_PAGE_HERE" name="topFrame" frameborder="no" scrolling="no" noresize="noresize" />
      <frame src="http://astore.amazon.com/jmdouglasscom-20" name="mainFrame" frameborder="no" />
    </frameset>

    Any help is appreciated

    Just thinking right off, I would duplicate the “page.php” file and rename it something like “products.php” or store.php

    Then using the same files and div setup on page.php, right after the content div, i would take out the files in there, ie the sidebars request and the thumbnails and entry code and then throw in your frameset code and see how it looks.
    You may have to edit the CSS a little bit and/or create a little bit of CSS to control the way it flows on your page.

    Thread Starter jmdougla

    (@jmdougla)

    Ok, if I understood you right, I have added a new php file named astore.php and uploaded it to my themes folder. Then modified by copying the contents of the page.php file. I added a “!” to the get sidebar code and added the frameset code above.

    I also selected the astore template to run that page.

    In the preview window, the only content I get is the name of the page. The sidebar content is gone but the sidebar is actually still there only empty and no store data shows up at all.

    Here is the astore.php coding:

    <?php
    /*
    Template Name: astore
    */
    ?>
    
    <?php get_header(); ?>
    
    	<div id="content" class="narrowcolumn">
    
    		<?php if (have_posts()) : while (have_posts()) : the_post(); ?>
    		<div class="post" id="post-<?php the_ID(); ?>">
    		<h2><?php the_title(); ?></h2>
    			<div class="entry">
    				<?php the_content('<p class="serif">Read the rest of this page &raquo;</p>'); ?>
    
    				<?php wp_link_pages(array('before' => '<p><strong>Pages:</strong> ', 'after' => '</p>', 'next_or_number' => 'number')); ?>
    
    			</div>
    		</div>
    		<?php endwhile; endif; ?>
    	<?php edit_post_link('Edit this entry.', '<p>', '</p>'); ?>
    	</div>
    
    <frameset rows="80,*" border="0">
      <frame src="INSERT_YOUR_PAGE_HERE" name="topFrame" frameborder="no" scrolling="no" noresize="noresize" />
      <frame src="http://astore.amazon.com/jmdouglasscom-20" name="mainFrame" frameborder="no" />
    </frameset>
    
    <!?php get_sidebar(); ?>
    
    <?php get_footer(); ?>

    You can see the page contents at:
    http://jmdouglass.com/forex_review/a-store/

    Thanks for your help

    Thread Starter jmdougla

    (@jmdougla)

    Anyone out there that can help me out?
    thx
    jmd

    Try taking out the whole php get_sidebar call

    Then take out the stuff between your div id content and the closing /div and throw in your frameset in between the div id content and the /div and see if that works?

    Thread Starter jmdougla

    (@jmdougla)

    Thanks for your help. I did get it to work. Here what I did–

    1. Uploaded a new php file named astore.php to my themes folder using my ftp program.
    2. Went to the editor in the WP dashboard and brought up page.php and copied the contents.
    3. Opened astore.php and pasted previously copied contents from page.php
    4. In astore.php I added the following contents at the top of the existing code:

    <?php
    /*
    Template Name: astore
    */
    ?>

    Then I deleted the following line:
    <?php get_sidebar(); ?>

    Then found the line containing <div id="content"> and changed it to `<div id=”content” style=”width:100% !important;”>

    Finally saved astore.php

    5. Went to page editor and brought up page I wanted to change. On the right side of the screen there is a dropdown menu listing the template assigned to the page. It needed to be changed to astore.

    6 copy the astore code from amazon and paste it into the page you are editing. Be sure it has HTML picked in the tabs at the top of the editor.

    7 Preview and publish.

    8. So far it looked pretty good but it still was a little too wide. So I search on amazon for a narrower theme in the astore editor, chose it, and copied the code, and pasted it into the page editor on WP. Preview. It fit but wasn’t centered the way I wanted it so I went back to the code pasted from amazon and started experimneting with changing the width="100% to smaller percentages until it appeared to look like I wanted. Then published again.

    Hope this will help others who are having this problem. The theme I ended up using was bluebirdhost2. It is much narrower that the default theme and still looks good. It did need a little tweeking with the colors. Here are the results:
    http://jmdouglass.com/forex_review/a-store/

    Please let me know what you think.

    Thanks

Viewing 7 replies - 1 through 7 (of 7 total)

The topic ‘Delete columns’ is closed to new replies.