473,386 Members | 1,803 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

How can I add images on my page and how to put text on the center vertically?

Please help. I am really having a hard time adding images on my pages. Im using CSS to implement design on my aspx pages. I want to add a background but the codes I am getting are not working.

I also have problems on aligning text vertically. All the text are on the bottom of a division, I want to put it into the center... Any suggestion?
Feb 26 '10 #1
7 1985
sashi
1,754 Expert 1GB
Post your code, will try to edit it for you :)
Feb 26 '10 #2
ThatThatGuy
449 Expert 256MB
Show some part of your code.. which is not working :>
Feb 26 '10 #3
<-- This is the aspx page -->
Expand|Select|Wrap|Line Numbers
  1. <body>
  2.     <form id="form1" runat="server">
  3.     <div class = "pageheader">
  4.     <div class = "titleholder">
  5.     LA LEYTENIAS MINIMART
  6.     </div>
  7.     <div class = "navigatorholder">
  8.         <asp:LinkButton ID="HomePageLinkButton" runat="server" style ="color:#59483f; text-decoration:none; size:12px" height="100%" Width = "65px">Home</asp:LinkButton>
  9.         <asp:LinkButton ID="SupplierLinkButton" runat="server" style ="color:#59483f; text-decoration:none; size:12px" height="100%" Width = "65px">Suppliers</asp:LinkButton>
  10.     <asp:LinkButton ID="CategoriesLinkButton" runat="server" style ="color:#59483f; text-decoration:none; size:12px" height="100%" Width = "65px">Product Categories</asp:LinkButton>
  11.     <asp:LinkButton ID="TransactionTypesLinkButton" runat="server" style ="color:#59483f; text-decoration:none; size:12px" height="100%" Width = "65px">Transaction Types</asp:LinkButton>
  12.     </div>
  13.  
  14.     </div>
  15.     </form>
  16. </body>
<-- The CSS that I used-->

Expand|Select|Wrap|Line Numbers
  1. body 
  2. {
  3. }
  4. div.pageheader
  5. {
  6.     border-right-style: solid;
  7.     border-right-width: 1px;
  8.     border-right-color: #ad9e87;
  9.     border-bottom-style: solid;
  10.     border-bottom-width: 2px;
  11.     border-bottom-color: #ad9e87;
  12.     background: #e1d6c7 url(App_Themes/Homepage/Images/headbackgrnd.gif)  repeat-x;
  13.     height:40px;
  14.     width:98.5%;
  15.     margin:5px 5px 5px 5px; 
  16. }
  17.  
  18. div.titleholder
  19. {    
  20.     float:left;
  21.     text-align:center;
  22.     width:30%;    
  23. }
  24.  
  25. div.navigatorholder
  26. {
  27.     float:left;
  28.     width:50%;
  29. }
<-- -->

The home, transaction types are not align center vertically. I want to align it to the center.
Then I also want to put an image background on my page.
Feb 26 '10 #4
sashi
1,754 Expert 1GB
Expand|Select|Wrap|Line Numbers
  1.  background-image: url (location of the image);
  2.  
Feb 26 '10 #5
tlhintoq
3,525 Expert 2GB
TIP: When you are writing your question, there is a button on the tool bar that wraps the [code] tags around your copy/pasted code. It helps a bunch. Its the button with a '#' on it. More on tags. They're cool. Check'em out.
#
Feb 26 '10 #6
I already tried that code. Don't work for me. The image just don't display. Is there any limitations to what images I could use? And also the sizes?
Feb 26 '10 #7
Frinavale
9,735 Expert Mod 8TB
No, the limitations that you think are there are not.
It's most likely that you haven't linked to the images correctly.

Try using this instead (not the single quotes in the url(' '):
Expand|Select|Wrap|Line Numbers
  1.    background: #e1d6c7 url('App_Themes/Homepage/Images/headbackgrnd.gif')  repeat-x;
If you want a background for the entire page then you should place this in the body{} portion.

If you're still having problems with this post back here and I'll give you a hand...If your site is publicly available it will be easier to help you if you posted a link to your site.

-Frinny
Mar 1 '10 #8

Sign in to post your reply or Sign up for a free account.

Similar topics

8
by: Keith Thompson | last post by:
I checked the FAQ, but didn't find an answer to this question. I also checked the O'Reilly HTML and CSS books, with a similar lack of results, though I could have missed something in the CSS book....
5
by: Fred | last post by:
I've written a number of "image gallery" pages before, but I'm trying to do something a little different. All the images are rectangular (these are just pictures from my camera), and the...
19
by: George Ziniewicz | last post by:
.. I try to use CSS when possible, though I am still learning and don't maximize its use. In particular, I still use a table to provide for a centered image in a few slideshows (though table...
3
by: Grytpype-Thynne | last post by:
Is it possible to give a width to a floated div which is greater than the width of the image it contains? What I want to do is display some images which will be of different sizes so that they...
5
by: Peter Lapic | last post by:
I have to create a image web service that when it receives an imageid parameter it will return a gif image from a file that has been stored on the server. The client will be an asp.net web page...
13
by: Egil Helland | last post by:
I am trying to create a breadcrumb with both icons and text, looking like: Home > Trail > Trail Now, how on earth do I get the images and text to vertically align so that the vertical...
8
by: Woodchuck | last post by:
Hi:) I've been trying to position some element's on my page and I can't come up with a way to equally position 4 DIV's in another DIV without explicitly setting the width of the "child" DIV's....
4
riccom
by: riccom | last post by:
Hello, I have a very big dilemma here, for me that is. I am using three images as BG's within a wrapper. See link. The top image is fine. But the center shows okay in design view. However, when I...
1
by: ttamilvanan81 | last post by:
Hai everyone, I need to provide the slideshow for the images. I have upload the images into database. Then i will retrive all the images from the database and provide the slideshow for those...
4
by: harryusa | last post by:
I am trying to center 2 images concentrically which are z-indexed to lay on top of each other making an image with a border from another image that has a transparent center. I need the images to be...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.