2254 posts Digital Artist
  • Had an item featured in a magazine
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $75,000+ on Envato Market and is now an Elite Author
  • Has referred 200+ members
+12 more
crozer says

Eyo,
I am finishing my first WP theme, and I have a doubt that I consider easy to fix (I have tried, and I feel as if I am so close to fixing/getting it, but it just doesn’t happen).

Anyway, the thing is, I’d like to add a sidebar ‘widget’ (not sure if it’s entirely a widget, because I think a few PHP lines should to the trick) that displays the blog’s about-page (and ideally only that that has been written before the

<!-- more -->
tag).

Thank you very much in advance.
I hope a widget isn’t necessary, as I really would like to avoid one for the moment.

Chris

308 posts
  • Has referred 1+ members
  • Has sold $75,000+ on Envato Market and is now an Elite Author
  • Has been a beta tester for an Envato feature
  • Has collected 10+ items on Envato Market
+4 more
brainbuzzmedia says

It would be a lot easier to just make a widget area and put a text widget in with the “About Us” info.

2254 posts Digital Artist
  • Had an item featured in a magazine
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $75,000+ on Envato Market and is now an Elite Author
  • Has referred 200+ members
+12 more
crozer says
It would be a lot easier to just make a widget area and put a text widget in with the “About Us” info.

Hmm.. I suppose. I just wanted to make the theme incredibly customizable/adaptable.

Thanks.

3135 posts
  • Has been part of the Envato Community for over 5 years
  • Has sold $1,000+ on Envato Market
  • Has been a beta tester for an Envato feature
  • Has collected 500+ items on Envato Market
+4 more
Daniel_R says

I need your help pumpkins? that’s a weird title name for a thread, chris…lol

629 posts
  • Has been part of the Envato Community for over 5 years
  • Has referred 10+ members
  • Has collected 10+ items on Envato Market
  • Sells items exclusively on Envato Market
+2 more
VagrantRadio says

I’m fresh out of help pumpkins, but you can have my help squash and zucchini.

374 posts
  • Has been part of the Envato Community for over 5 years
  • Has referred 1+ members
  • Has sold $1,000+ on Envato Market
  • Has collected 10+ items on Envato Market
+3 more
_rohan says
I’m fresh out of help pumpkins, but you can have my help squash and zucchini.

Hahaha, that’s funny :-)

@OP: This isn’t tough.

Step 1: Add an option to your theme options for the user to choose which page.

Step 2: Use the page ID, and use the get_page() function to get the page http://codex.wordpress.org/Function_Reference/get_page

Step 3: Use the post_excerpt from the returned object to show the content.

Step 4: Optionally, use the get_permalink() function to get the permalink. http://codex.wordpress.org/Function_Reference/get_permalink

Good luck :-)

2254 posts Digital Artist
  • Had an item featured in a magazine
  • Elite Author: Sold more than $75,000 on Envato Market
  • Has sold $75,000+ on Envato Market and is now an Elite Author
  • Has referred 200+ members
+12 more
crozer says

Thanks a bunch. Everything is working accordingly now. The only thing bugged, is the fact that post_excerpt does not support page-excerpts (as far as I know), and thus, post_excerpt of a page does not echo anything out, unless I use post_content (but then I have the whole page echoed).

Any ideas?
Thanks again :)

536 posts
  • Has referred 50+ members
  • Has sold $10,000+ on Envato Market
  • Has collected 100+ items on Envato Market
  • Located in Croatia
+2 more
darius9000 says

pumpkiiiiin! it’s meeee, it’s meeeeee! :D

Helpful Information

  • Please read our community guidelines. Self promotion and discussion of piracy is not allowed.
  • Open a support ticket if you would like specific help with your account, deposits or purchases.
  • Item Support by authors is optional and may vary. Please see the Support tab on each item page.

Most of all, enjoy your time here. Thank you for being a valued Envato community member.

Post Reply

Format your entry with some basic HTML. Read the Full Details, or here is a refresher:

<strong></strong> to make things bold
<em></em> to emphasize
<ul><li> or <ol><li> to make lists
<h3> or <h4> to make headings
<pre></pre> for code blocks
<code></code> for a few words of code
<a></a> for links
<img> to paste in an image (it'll need to be hosted somewhere else though)
<blockquote></blockquote> to quote somebody

:grin: :shocked: :cry: Complete List of Smiley Codes

by
by
by
by
by
by