Wordpress-Thesis Theme Help

Discussion in 'HTML & Website Design' started by alkantenik, Jul 24, 2010.

  1. #1
    Hello

    I have created a website but I have a problem. In my home page I have a div which display images and text. ( under the featured content slider)

    I used "thesis open hooks" to create this div.

    But I do not want to display for post page or another pages. Can you help me?

    www.fitdietplans.com
     
    alkantenik, Jul 24, 2010 IP
  2. Johnta

    Johnta Peon

    Messages:
    101
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    0
    #2
    You can use IF to check is it the home page or not
     
    Johnta, Jul 25, 2010 IP
  3. EatingEmoKids

    EatingEmoKids Member

    Messages:
    111
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    28
    #3
    Johnta is correct. you will need to add an if statement to your function. it will look some thing like this:

    
    function your_function_name() {
        if (is_home()) {
            <div>your images and text</div>
        }
    }
    
    add_action('thesis_hook_name', 'your_function_name');
    
    PHP:
    hope that helps :)

    edit: I noticed a css issue you might not have seen.

    add this to your custom style sheet to remove the bullet points from your added menu:
    
    ul#topnav_menu { list-style: none; }
    
    Code (markup):
     
    Last edited: Jul 25, 2010
    EatingEmoKids, Jul 25, 2010 IP
  4. alkantenik

    alkantenik Well-Known Member

    Messages:
    190
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    138
    #4
    Thank you very much but my code is does not work. What is the wrong?

    function before_postbox_bottom() {
    if (is_home()) {

    <div id="text2">
    <div id="text2a">
    <div id="headerright">Rapid Weight Loss Techniques</div>
    <div id="headerleft">The Best 20 Minute Workout Plan</div>
    </div>
    <div id="text2b">
    <div id="text2b1">
    <div id="thesis1">
    <div id="thesis1main">
    <div id="thesisimage1"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/5-no-fail-tips-to-motivate-yourself-to-diet.jpg" align="center" alt="Digg it!"/></a></div>
    <div id="thesistext1">Other than physical appearance weight affects a person in many ways. This could be the overall quality of life, self-esteem, depression..</div>
    </div>
    <div id="thesis1b">There are a lot of positive changes once a person experience weight loss. It is for this reason why a lot of people are searching for a weight loss technique that will surely trim down those fats and get a super slim head turner body...</div>
    </div>
    <div id="thesis1a"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/ReadMore.jpg" align="center" alt="Digg it!"/></a></div>
    </div>
    <div id="image"><div id="thesis1">
    <div id="thesis1main">
    <div id="thesisimage1"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/exercise_078.jpg" align="right" alt="Digg it!"/></a></div>
    <div id="thesistext1">If you are busy, not able to get up early morning or have no time for gym just follow this 20 minute home workout plan to stay
    </div>
    </div>
    <div id="thesis1b"><ul>
    <li>1) Jog : in one place for 3 minutes</li>
    <li>2) Jumping jacks: 25 repeats
    When landing, bend your knees slightly to reduce the impact on knee joints.</li>
    <li>3) Crunches : 15 repeats
    Lie flat on your back with your knees bent...</li>
    </ul>
    </div>
    </div>
    <div id="thesis1a"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/ReadMore.jpg" align="center" alt="Digg it!"/></a></div></div>
    </div>
    </div>

    <!-- bottom boxes start -->

    <div id="text2">
    <div id="text2a">
    <div id="headerright">Free Weight Loss Programs</div>
    <div id="headerleft">Losing Weight the Healthy Way</div>
    </div>
    <div id="text2b">
    <div id="text2b1">
    <div id="thesis1">
    <div id="thesis1main">
    <div id="thesisimage1"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/epilepsy-ketogenic-diet.jpg" align="center" alt="Digg it!"/></a></div>
    <div id="thesistext1">The race to fitness is on and a lot of people are getting into the band wagon.Some people do it to achieve a sexy body, </div>
    </div>
    <div id="thesis1b">some people just do it because they are embarrassed with the body they have now, while others do it simply to remain fit and heatlthy. As such, many fitness programs are out in the internet, in gyms, spas and fitness centers all over. </div>
    </div>
    <div id="thesis1a"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/ReadMore.jpg" align="center" alt="Digg it!"/></a></div>
    </div>
    <div id="image"><div id="thesis1">
    <div id="thesis1main">
    <div id="thesisimage1"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/weight-loss-food.jpg" align="center" alt="Digg it!"/></a></div>
    <div id="thesistext1">Almost 108 million Americans were overweight or obese in 1999. Until now, obesity continues to be a serious problem and is predicted to</div>
    </div>
    <div id="thesis1b">reach epidemic levels by the year 2020.

    One way to prevent this scenario is to make people aware of the risks of being overweight or obese.

    Here are some diseases that you are putting yourself in risk of if you are carrying a lot of extra pounds:
    </div>
    </div>
    <div id="thesis1a"><a href="CLICKABLE-LINK"><img src="http://fitdietplans.com/wp-content/uploads/2010/07/ReadMore.jpg" align="center" alt="Digg it!"/></a></div>
    </div>
    </div>
    </div>

    }
    }
    add_action('thesis_hook_before_postbox', 'before_postbox_bottom');
     
    alkantenik, Jul 25, 2010 IP
  5. EatingEmoKids

    EatingEmoKids Member

    Messages:
    111
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    28
    #5
    Change your add action line, you missed an underscore.

    Change this:
    add_action('thesis_hook_before_postbox', 'before_postbox_bottom'); 
    PHP:
    to this:

    add_action('thesis_hook_before_post_box', 'before_postbox_bottom'); 
    PHP:
    should work after that :)
     
    EatingEmoKids, Jul 25, 2010 IP
  6. dcristo

    dcristo Illustrious Member

    Messages:
    19,797
    Likes Received:
    1,201
    Best Answers:
    7
    Trophy Points:
    470
    Articles:
    5
    #6
    Use the Thesis OpenHook plugin so you don't have to insert the add action code.
     
    dcristo, Jul 25, 2010 IP
  7. alkantenik

    alkantenik Well-Known Member

    Messages:
    190
    Likes Received:
    6
    Best Answers:
    0
    Trophy Points:
    138
    #7
    Thanks for replies...
     
    alkantenik, Jul 27, 2010 IP
  8. bob1685

    bob1685 Peon

    Messages:
    1
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    0
    #8
    Hi i was wondering if some 1 can help me? i have the thesis theme installed on this site www.nikonmonarchbinoculars-blog.com how do i add the black border at the top like this guys website www.choppertattoo-reviews.com ?
     
    bob1685, Jul 27, 2010 IP