Small width layout Medium width layout Maximum width layout Small text Medium text Large text
     Search
Downloads Downloads Directory Directory Forums Forums Forge Forge Blogs Blogs        Marketplace Marketplace Careers Program Careers
Community › Forums Register  |  

AspDotNetStoreFront
  Ads  
Iron Speed Designer is a software development tool for building database, reporting, and forms applications for .NET without hand-coding.
 


  Sponsors  

Meet Our Sponsors

R2integrated - formerly bi4ce
Jango Studios - Skins, Modules and Hosting for DotNetNuke
eUKhost.com is commited to offer exceptional UK Windows Web Hosting solutions with quality 24x7 technical support.Our plans support ASP.Net, ASP, ASP.NET Ajax extensions, XML, MSSQL, MySQL, PHP,DNN, multiple domains and Shared SSL as standard.
SmarterTools
The Official Microsoft ASP.NET Website
Portal Webhosting - Hosting For Developers
 


DotNetNuke Forums
 
  Forum  General DotNetN...  Make it Hot! ( ...  Center my Content?
Previous Previous
 
Next Next
New Post 2/22/2008 7:43 AM
Resolved
User is offline BeeMarie
96 posts
10th Ranked


Center my Content? 

Hi,

This is probably such a ridiculously simple question that you'll wonder what I'm even doing trying to make a skin. But it seems that while I can figure out the complicated things like embedding panes and skin objects, I am having alot of trouble figuring out something that ought to be simple.

I can't figure out how to write the html code so that it centers my content on the page.

Imagine that you have an html page and you have one table with one cell that is 800 px wide. How do you get the table to be in the center of the browser window when you maximize the window, instead of being on the left side? I've tried coding it a number of different ways and it just stubbornly stays on the left of the page. I'm sick of trying to figure it out!

Please help!

~Bee

 
New Post 2/22/2008 1:16 PM
User is offline keeperofstars
252 posts
9th Ranked


Re: Center my Content? 

have you tried making a div tag that has 100% width and align set to center, then put your table inside the div tag.

I think that will work.

 

 
New Post 2/22/2008 1:33 PM
User is offline Jan Olsmar
458 posts
www.olsmar.com/
8th Ranked




Re: Center my Content? 

Try align="center" in the first table or div.

 

 
New Post 2/23/2008 3:49 PM
User is offline abecedarian
77 posts
10th Ranked


Re: Center my Content? 

something like this:

<table style="width: 800px; margin-left: auto; margin-right: auto; border: thin black solid;">
 <tr>
  <td style="border: thin black solid;">&nbsp;</td>
 </tr>
</table>

renders a table 800 pixels wide with the left and right margins set to 'auto' which should center it (I've added borders to the table and cell so you can see below):

 
 
New Post 2/25/2008 5:00 AM
User is offline BeeMarie
96 posts
10th Ranked


Re: Center my Content? 

Thank you so much y'all! It works now! I'm so happy!

~Bee

 
Previous Previous
 
Next Next
  Forum  General DotNetN...  Make it Hot! ( ...  Center my Content?
 


Forum Policy

These Discussion Forums are dedicated to the discussion of the DotNetNuke Web Application Framework.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:

1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DotNetNuke.
2. Discussion or promotion of DotNetNuke product releases under a different brand name are strictly prohibited.
3. No Flaming or Trolling.
4. No Profanity, Racism, or Prejudice.
5. Site Moderators have the final word on approving/removing a thread or post or comment.
6. English language posting only, please.

 


Customer Connect
Customer Connect provides cutting edge solutions that deliver sales, marketing and customer service results.
www.customer-connect.com
TechNexxus
Business process and technology sourcing solutions delivering superior people, process and value. We have used, and continue to use, DNN successfully in numerous client projects to deliver exceptional value. We are proud to support the DNN team and community.
www.technexxus.com
PartnerPoint | Community of Microsoft Partners
PartnerPoint is one of the largest and most active online communities of Microsoft Partners worlwide with over 8,000 members.
www.PartnerPoint.com

DotNetNuke Corporation   Terms Of Use  Privacy Statement
DotNetNuke®, DNN®, and the DotNetNuke logo are trademarks of DotNetNuke Corporation
Hosted by MaximumASP