[wp-trac] Re: [WordPress Trac] #3874: add returns in functions:
the_time the_content the_permalink
WordPress Trac
wp-trac at lists.automattic.com
Mon Feb 26 12:55:26 GMT 2007
#3874: add returns in functions: the_time the_content the_permalink
----------------------------------------------------+-----------------------
Reporter: pampfelimetten | Owner: anonymous
Type: enhancement | Status: new
Priority: low | Milestone: 2.1.2
Component: General | Version: 2.1
Severity: minor | Resolution:
Keywords: return function time content permalink |
----------------------------------------------------+-----------------------
Comment (by majelbstoat):
Why? As you note, there are already functions to get_the_time(),
get_the_permalink() etc. You can do what you want with them, including
echoing out the results...
This isn't really necessary, except if you're desperate to manipulate the
value after the filter but before it is echoed... But even if you wanted
to do that, you could just use the 'post_link' filter instead and work
with the return value of get_the_permalink.
Even if something like this was applied, it should be either/or,
controlled by an argument, $return = false, the same as all the other
template functions. Plus, you're applying the same filter twice, when you
could just assign it to a variable.
--
Ticket URL: <http://trac.wordpress.org/ticket/3874#comment:1>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list