If this is your first visit, check our documentation. To post, register or login.
Forums / Templates, Stylesheets, Page Layout / Unable to get an image to show on the home page

Unable to get an image to show on the home page

Started by bhensarl on 13 Apr 2011, 4:27 PM · Views: 893

Results 1 to 9 of 9
13 Apr 2011, 4:27 PM
#1
bhensarl avatar

bhensarl

New Zenner

Join Date:
Feb 2010
Posts:
67
Plugin Contributions:
0

Unable to get an image to show on the home page

Hello,
I'm using a Template Monster template and the way it's currently set up it allows a simplified homepage, by not showing some items on the homepage that then show up on all the other pages. That's not very descriptive, but if you check out the site (http: //2600 strange. com) you will see that on the home page you don't have an image in the upper right hand corner. Then if you click on any of the buttons, "The Goods", top left for example, you will see an image of a boy with the words, "Luke's Local Artists, June 11". I would like that image to show up on the home page but I can't figure out how it's being hidden. Any ideas? Thanks in advance.
Brian

13 Apr 2011, 5:26 PM
#2
stevesh avatar

stevesh

Black Belt

Join Date:
Feb 2005
Location:
Lansing, Michigan USA
Posts:
19,793
Plugin Contributions:
2

Re: Unable to get an image to show on the home page

Check the source of that page and search for col2. You have that whole section commented out.

13 Apr 2011, 7:30 PM
#3
bhensarl avatar

bhensarl

New Zenner

Join Date:
Feb 2010
Posts:
67
Plugin Contributions:
0

Re: Unable to get an image to show on the home page

stevesh,
Thanks for the response. I found the col2 that's commented out, but that doesn't seem to be it because on the pages where col2 is commented out, the picture displays normally. I think the php might be loading a separate header for just the homepage. If that's happening, do you have any idea where I could look to try to find the homepage header, or which php doc would tell me where it would be? Thanks.
Brian

13 Apr 2011, 11:31 PM
#4
celtic avatar

celtic

Zen Follower

Join Date:
Feb 2010
Posts:
154
Plugin Contributions:
0

Re: Unable to get an image to show on the home page

bhensarl,

The 'col2' block that's commented out is not what you need to put back in. In your other pages you'll find another whole chunk of code (between the javascript for the rotating slideshow and the drop-down menu definitions) that just isn't present within the homepage.

You could try a filesystem search through sourcecode for the string 'LLAbutton.jpg' to see where that is used, which might narrow down which files to look in.

14 Apr 2011, 12:31 AM
#5
usr50 avatar

usr50

Zen Follower

Join Date:
Mar 2009
Location:
Niagara Ontario
Posts:
136
Plugin Contributions:
0

Re: Unable to get an image to show on the home page

Image Report - http://2600strange.com/index.php?main_page=page&id=44 ( link to page with boy )

image path for boy =http://2600strange.com/images/events/LLA/LLAbutton.jpg

this image is not on the index.php (main) page

needs to be added.

14 Apr 2011, 9:35 AM
#7
bhensarl avatar

bhensarl

New Zenner

Join Date:
Feb 2010
Posts:
67
Plugin Contributions:
0

Re: Unable to get an image to show on the home page

Guys, the thing that's perplexing me is that part of the header shows up perfectly when I'm on any page other than the home page. I added the image in the header to advertise an event we have coming up, but it's not super helpful for me if I can't get it to show up on the home page. I also added the twitter and facebook buttons to the common/tpl_header.php file in the past, and you can see that they also show up on all the other pages, but not the home page. However, the logo in the top left shows on both the home page and all the other pages as well. How is it doing that? Any ideas? I'm sure there must be some little php string somewhere that determines whether the page is the homepage or not, and if it is the home page it hides certain portions of the header (and the footer for that matter). It's not simply a matter of trying to figure out where to put the image, I don't think. Any ideas? Thanks!
Brian

14 Apr 2011, 10:14 AM
#8
bhensarl avatar

bhensarl

New Zenner

Join Date:
Feb 2010
Posts:
67
Plugin Contributions:
0

Re: Unable to get an image to show on the home page

Alright, I found it. Here's the code in case anyone's interested:

<?php if (!$this_is_home_page) { //switch only nav/search ?>

That string is placed just before the col2 div, and apparently it forces the col2 div to not appear on the homepage. I don't know how it works, I just know THAT it works. I put the image in the col1 div instead and now it works perfectly. Thanks for the help!
Brian

14 Apr 2011, 1:07 PM
#9
usr50 avatar

usr50

Zen Follower

Join Date:
Mar 2009
Location:
Niagara Ontario
Posts:
136
Plugin Contributions:
0

Re: Unable to get an image to show on the home page

bhensarl:

. I put the image in the col1 div instead and now it works perfectly. Thanks for the help!
Brian

  • using MS developer tools found solution in 30 seconds *