Wordpress Themes - WP Forum at BFA
Click Here To DONATE! Support the theme development, get more attention and additional benefits based on your donation level. Your forum name will be highlighted.

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Sidebars & Widgets »

[SOLVED] Display Page-Title in Sidebar


Build custom WP THEMES, without
coding.
Click here for THEMEFRAME

From the author of Atahualpa, the #1 most
downloaded (700,000+) theme @ wordpress.org
  #1  
Old Aug 25, 2010, 05:23 PM
semperfidelis
 
5 posts · Aug 2010
Hello!

First of all: I'm sorry for my poor English. Furthermore: neither HTML, CSS or PHP are my friends.
I'm using Atahualpa 3.5.3 on a wordpress 3 installation, and that theme is simply great.

my question:
Would it, somehow, be possible to display the page title of the current page within a widget in a sidebar? I dont care if the page title would remain on the top of the page, as usual, too, but I would like to display the current page title in a sidebar, next to the content.

My primitive understanding suggests me to somehow "get" the current page's title, using PHP? Would it be possible to do that in a standard text-widget, using HTML? Are there any plugins available that would do the job? I've tried finding one, but didnt have much success.

I'm sorry if I have posted this thread in a wrong section.

Thanks for any kind of answer or idea!

Cheers
Tom
  #2  
Old Aug 25, 2010, 07:40 PM
lmilesw's Avatar
lmilesw
 
10,099 posts · Jul 2009
Central New York State USA
You could put this code in a php friendly text widget.
HTML Code:
<?php bloginfo('name'); ?>
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.
  #3  
Old Aug 25, 2010, 09:40 PM
semperfidelis
 
5 posts · Aug 2010
Thanks a lot.

But that returns the blog name, and not the name or title of the currently displayed page or post.

Code:
         <!-- Post Headline -->                    
        <div class="post-headline">    
        <h1><?php
if (!is_single() and !is_page()) { ?>
            <a href="<?php the_permalink() ?>" rel="bookmark" title="Permanent Link to <?php
    if (function_exists('the_title_attribute')) {
        the_title_attribute();
    } elseif (function_exists('the_title')) {
        the_title();
    } ?>"><?php
}
the_title();
if (!is_single() and !is_page()) { ?>
            </a><?php
} ?>
        </h1>
        </div>
is what helped me for now.
  #4  
Old Aug 25, 2010, 09:42 PM
lmilesw's Avatar
lmilesw
 
10,099 posts · Jul 2009
Central New York State USA
Sorry about that. I read your question too quickly.
__________________
~Larry (CNY Web Designs)
This site should be a membership site since it so full of good stuff.
Please consider donating which gives you access to even more good stuff.

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Display post title only of a category in a page ladylulu Page & Category Menu Bars 9 Mar 1, 2011 08:02 AM
Don't display page title georgenoise Post-Kicker, -Byline & -Footer 1 Aug 10, 2010 08:58 AM
Help! Page Title Does Not Display Hyphens, Commas, etc.! sfdiaries Page & Category Menu Bars 21 Jul 9, 2010 12:12 PM
Category Page Listing - How to display: Post Title only TotalBalance Excerpts, Read more, Pagination 16 Jan 27, 2010 12:22 PM
[SOLVED] Turning off Page Title display MrCardinal Atahualpa 3 Wordpress theme 4 Jul 23, 2009 04:47 PM


All times are GMT -6. The time now is 11:35 PM.


Powered by vBulletin® Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.