Viewing 1 to 5 of 5 items
Tag Archives: variables

Get the url of the post thumbnail as a variable

One of the improvements in WordPress 2.9 is native support for thumbnail images on posts. The API is pretty good – although it assumes that you want to return the whole IMG tag. In my case I wanted to return the URL of the image (So I could wrap the actual thumbnail in a lightbox-style  Full Article…

0

Get various taxonomy queries and information

Unfortunately (in my eyes)I haven’t found a way inside a post or page to query what taxonomies have beenused to apply terms. This for me would be a bit of a holy grail. Anyeway – these are the bits and pieces I have developed when trying to get various bits and pieces of information from  Full Article…

0

Get Post ID outside the Loop as PHP variable

In the wordpress loop section, each posts displayed on the page with defined format along with such criteria decided by administrator. The Loop template tag the_ID can be used to easily display the post’s ID inside the post. Alternatively, inside the the_content filter, declare $id global and use $id to retrieve the post ID. the_ID  Full Article…

0

Past the current post permalink to a variable

This code is good for use on any page, inside or outside of the loop and in custom queries: This is generally how I would use it to output a link:

0

PHP Echo with html, escapes and variables included

This is a good example of a php echo used to output some html which makes use of some variables – some escapes were also required for the html.

0
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news
news