Wordpress Themes - WP Forum at BFA
There will be no more development for Atahualpa (or any other theme), and no support. Also no new registrations. I turned off the donation system. I may turn the forum to read only if it gets abused for spam. Unfortunately I have no time for the forum or the themes. Thanks a lot to the people who helped in all these years, especially Larry and of course: Paul. Take care and stay healthy -- Flynn, Atahualpa developer, Sep 2021

Wordpress Themes - WP Forum at BFA » WordPress Themes » Atahualpa 3 Wordpress theme » Center area post/pages » Comments, trackbacks & pings »

[SOLVED] Post info items with icons as parameter


  #1  
Old Dec 16, 2009, 01:56 PM
dextor
 
19 posts · Sep 2009
Hi there,

I am trying to get some icon inserted in a post info item as a parameter like that:

%edit(' | ' <image(icon_page_edit.gif)>, 'Edit', '')%

or

%edit(<image(icon_page_edit.gif)>, 'Edit', '')%

while non of this works.

The icon should only be displayed in the footer, if the user is logged in or has the
rights to edit a post. If I put it outside the info item it is being displayed all the
time and thats confusing...

Can anybody give me a hint how that works?

The documentation says:

"HTML and icons can be used, inside of parameters, too, just not inside the date item: "

But is does not explain how to use it...

Thanks for this great theme, hope somebody can help me out!

Regards

dextor
  #2  
Old Dec 18, 2009, 04:46 AM
juggledad's Avatar
juggledad
 
23,765 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
You need to put it all inside some PHP. here is how you could get some text and an icon to appear it the user is logged in. Add theis to the end of the FOOTER options at ATO->Edit->POST/PAGE INFO ITEMS
HTML Code:
<?php if ( is_user_logged_in() ) { echo 'Hello world! <img src="http://yourdomain.com/wp-content/themes/atahualpa344/images/icons/key.gif" alt="The Key" /> '; } ?>
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #3  
Old Dec 18, 2009, 08:05 AM
dextor
 
19 posts · Sep 2009
Hi Juggledad!

Thanks for the hint, that helped me working out how I can also change icons e.g. for comments open/closed posts like that:


-----
%date('F jS, Y')% | <image(icon_folder.gif)> %categories-linked(', ')% |

<?php if ( comments_open() ) { ?> <image(icon_comment_new.gif)> <?php }
else { ?> <image(comment.gif)> <?php } ?>

%comments('Kommentieren', 'Ein Kommentar', '% Kommentare', 'Kommentare geschlossen')% %edit(<image(icon_page_edit.gif)> . ' | ', 'Bearbeiten', '')%
-----

Atahualpa is the greates theme out there!!!

Regards

dextor

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
exclude certain tags/categories from post info items jankph Post-Kicker, -Byline & -Footer 1 Nov 11, 2009 06:35 AM
Sociable, NextPage, and Post/Page Info Items ... A Thank You. fromtheranks Plugins & Atahualpa 0 Jun 26, 2009 09:40 PM
Post/Page Info Items - Trackbacks Andrea Post-Kicker, -Byline & -Footer 2 Feb 27, 2009 05:13 AM
Post Info Items and new plugins technstuff Plugins & Atahualpa 9 Feb 26, 2009 07:30 PM
Post / Page Info Items - Button crashes comp, how do I add to post-footer? Image help everygirlssecret Post-Kicker, -Byline & -Footer 1 Jan 5, 2009 01:12 PM


All times are GMT -6. The time now is 10:47 AM.


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