Wrox Programmer Forums

Need to download code?

View our list of code downloads.

Go Back   Wrox Programmer Forums > ASP.NET and ASP > ASP.NET 3.5 > ASP.NET 3.5 Basics
Password Reminder
Register
Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read
ASP.NET 3.5 Basics If you are new to ASP or ASP.NET programming with version 3.5, this is the forum to begin asking questions. Please also see the Visual Web Developer 2008 forum.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the ASP.NET 3.5 Basics section of the Wrox Programmer to Programmer discussions. This is a community of tens of thousands of software programmers and website developers including Wrox book authors and readers. As a guest, you can read any forum posting. By joining today you can post your own programming questions, respond to other developersí questions, and eliminate the ads that are displayed to guests. Registration is fast, simple and absolutely free .
DRM-free e-books 300x50
 
 
Thread Tools Display Modes
  #1 (permalink)  
Old April 19th, 2009, 10:21 PM
Authorized User
 
Join Date: Jan 2009
Posts: 51
Thanks: 0
Thanked 0 Times in 0 Posts
Default Change <div> content

I have three images on my webpage that comprise an small interface. When the page loads, the first picture is in focus and to the right is an explaination. When the user clicks on a different picture, I would like to change the text of the div. I have tried adding code to the code behind page, but I can't figure out how to make that work. I am new to this and am getting my hands around the VB coding. Any direction would greatly help.
  #2 (permalink)  
Old April 20th, 2009, 07:53 AM
Friend of Wrox
Points: 7,395, Level: 36
Points: 7,395, Level: 36 Points: 7,395, Level: 36 Points: 7,395, Level: 36
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Capital Federal, , Argentina.
Posts: 2,190
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

Hello, Unless you show us something, I don't know how we can help you...
__________________
HTH

Gonzalo


================================================== =========
Read this if you want to know how to get a correct reply for your question.
(Took that from Doug signature and he Took that from Peter profile)
================================================== =========
My programs achieved a new certification :
WORKS ON MY MACHINE
================================================== =========
I know that CVS was evil, and now i got the
proof.
================================================== =========
  #3 (permalink)  
Old April 20th, 2009, 09:49 PM
Authorized User
 
Join Date: Jan 2009
Posts: 51
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Sorry, this is what I have so far

Code:
<div id="Nav">
              <asp:HyperLink ID="HyperLink1" runat="server" NavigateUrl="about.aspx" 
              <img alt="" src="Images/about.jpg" style="width: 171px; height: 28px" />
              </asp:HyperLink> 
              <asp:HyperLink ID="HyperLink2" runat="server" NavigateUrl="prices.aspx" 
              <img alt="" src="Images/prices.jpg" style="width: 171px; height: 28px" />
              </asp:HyperLink> 
              <asp:HyperLink ID="HyperLink3" runat="server" NavigateUrl="contact.aspx" 
              <img alt="" src="Images/contact.jpg" style="width: 171px; height: 28px" />
              </asp:HyperLink>               

</div>
<div id="ContentArea">
               <cc1:CollapsiblePanelExtender ID="CollapsiblePanelExtender1" runat="server"                
                TargetControlID="MoreInfo" 
                CollapseControlID="Less" 
                Collapsed="True"
                TextLabelID="More"
                SuppressPostBack="true" Enabled="True" 
                ExpandedImage="Images/blank.gif" 
                ExpandControlID="Image1" CollapsedImage="Images/more.gif" 
                ImageControlID="Image1">
                </cc1:CollapsiblePanelExtender>
            
               <div class="contentInfo1" runat="server">
     
             <p> This is all about us.
  </p>
      
                <asp:Image ID="Image1" runat="server" ImageUrl="~/Images/more.gif" />
               </div>
              <div class="contentInfo2">    
              
  <asp:Panel ID="MoreInfo" runat="server" Class="moreInfo"> 
  
              <p> This is more about us. 
   <asp:Label ID="Less" runat="server" Text="[Less]" CssClass="link"></asp:Label>
       </p>
                </asp:Panel>
</div>
I would like to add the functionality that when the user clicks on the hyperlinks, the Content Area information changes depending on which Hyperlink they click. This is a small interface within the main page.
  #4 (permalink)  
Old April 20th, 2009, 09:59 PM
Friend of Wrox
Points: 7,395, Level: 36
Points: 7,395, Level: 36 Points: 7,395, Level: 36 Points: 7,395, Level: 36
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Capital Federal, , Argentina.
Posts: 2,190
Thanks: 5
Thanked 59 Times in 57 Posts
Send a message via MSN to gbianchi
Default

Unless I'm missing something, your hyperlinks navigates to other pages, maybe you need a standard button??

Also, if you are using ajax (like I think because you have a collapsible panel), then the solution is at code behind, setting the image to the new link. (or you can do it with js at client side, but I don't know how).
__________________
HTH

Gonzalo


================================================== =========
Read this if you want to know how to get a correct reply for your question.
(Took that from Doug signature and he Took that from Peter profile)
================================================== =========
My programs achieved a new certification :
WORKS ON MY MACHINE
================================================== =========
I know that CVS was evil, and now i got the
proof.
================================================== =========
 


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
hide the <div> crmpicco Javascript How-To 1 August 22nd, 2005 09:43 PM
disable <div> content (everything inside it!) crmpicco Javascript How-To 2 April 12th, 2005 09:35 AM
<style> tags in a <body> vs. <div> bcat BOOK: Beginning CSS: Cascading Style Sheets for Web Design ISBN: 978-0-7645-7642-3 1 March 27th, 2005 07:50 AM
sizeable <div> johnjohn Javascript How-To 1 December 8th, 2004 07:28 PM
<A><DIV><TABLE></DIV></A> anshul HTML Code Clinic 2 July 17th, 2004 02:17 PM



All times are GMT -4. The time now is 07:39 PM.


Powered by vBulletin®
Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.
© 2013 John Wiley & Sons, Inc.