Want to win a PS4? Go Premium and enter to win our High-Tech Treats giveaway. Enter to Win

x
?
Solved

Rendering Page with Panel

Posted on 2011-03-21
9
Medium Priority
?
316 Views
Last Modified: 2012-06-21
I have a asp.net website that is in a format that has header, left panel, main, right panel, and footer like image on left. I am wanting to render the page  to look like image on right using java script to essentially remove left panel and place right panel below main.  Any help with code to do this is greatly appreciated.

Panel Image Result
0
Comment
Question by:zrazak
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
9 Comments
 
LVL 7

Expert Comment

by:nbove
ID: 35182962
Set widths on the panels and set the style property on them to "display:inline"

Here is an example of some code:
<div>Header</div>
<div style="display:inline">Left</div><div style="display:inline; border:1px solid">Main</div><div style="display:inline">Right</div>
<div>Footer</div>
0
 
LVL 60

Expert Comment

by:HainKurt
ID: 35183079
post the current structure of divs (with code & style)
0
 
LVL 60

Expert Comment

by:HainKurt
ID: 35183135
check this one

<style>div {border:1px solid gray} </style>

<div>Header</div>
<div style="display:inline" id=divLeft>Left</div>
<div style="display:inline" id=divMain>Main</div>
<div style="display:inline" id=divRight>Right</div>
<div>Footer</div>

and the one below
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></script>

<script>
$(document).ready(function() {
	$("#divLeft").hide();
	$("#divMain").css("display","");
	$("#divRight").css("display","");
});
</script>

<style>div {border:1px solid gray} </style>

<div>Header</div>
<div style="display:inline" id=divLeft>Left</div>
<div style="display:inline" id=divMain>Main</div>
<div style="display:inline" id=divRight>Right</div>
<div>Footer</div>

Open in new window

0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 

Author Comment

by:zrazak
ID: 35183337
The code sent does not create diagram as on left
0
 

Author Comment

by:zrazak
ID: 35183462
I like the help that you provided.  I have set the div tags to panel tags and wanted to know if a width can be set to the panel left, panel main, and panel right to add up to 100% of screen?
0
 
LVL 60

Expert Comment

by:HainKurt
ID: 35183515
you can use this syntax

$("#divMain").css("width","300");
0
 

Author Comment

by:zrazak
ID: 35183608
i did that and didnt notice any render in screen?
0
 
LVL 60

Accepted Solution

by:
HainKurt earned 2000 total points
ID: 35189511
this should be working fine...
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></script>

<script>
$(document).ready(function() {
	$("#divLeft").hide();
	$("#divMain").css("display","");
	$("#divMain").css("width","300"); 
	$("#divRight").css("display","");
});
</script>

<style>div {border:1px solid gray} </style>

<div>Header</div>
<div style="display:inline" id=divLeft>Left</div>
<div style="display:inline" id=divMain>Main</div>
<div style="display:inline" id=divRight>Right</div>
<div>Footer</div>

Open in new window

0
 

Author Closing Comment

by:zrazak
ID: 35198406
Sorry for late response thanks
0

Featured Post

Tech or Treat!

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Today, the web development industry is booming, and many people consider it to be their vocation. The question you may be asking yourself is – how do I become a web developer?
When crafting your “Why Us” page, there are a plethora of pitfalls to avoid. Follow these five tips, and you’ll be well on your way to creating an effective page.
In this tutorial viewers will learn how to style a corner ribbon overlay for an image using CSS Create a new class by typing ".Ribbon":  Define the class' "display:" as "inline-block": Define its "position:" as "relative": Define its "overflow:" as …
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

636 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question