The server-side programming language that the WordPress core, plugins and themes are written in.

learn more… | top users | synonyms (1)

0
votes
1answer
601 views

is_singular won't call my functions?

Hi i'm using this code to call for a different stylesheet for a single post type but the problem is, It won't call the stylesheet. It's in header.php, i also tried placing it in single.php <?php ...
1
vote
1answer
171 views

How do themes render caption texts in extended markup (e.g. “wp-caption” paragraphs)

I've created my own theme based on a very lean template. My theme is not parsing the [caption]...[/caption] markup to the correct html. It's just showing the text without any markup around it. Here ...
0
votes
3answers
199 views

Display a custom field rating system in the front end

I have added a content rating system to my platform where the authors can select which audience their post is appropriate for. Currently, these options are available: Unrated G PG ...
0
votes
1answer
138 views

Hide content from Post Preview

Is it possible to hide content in Post Preview (that is not hidden when the post is published)? I have customised single.php quite extensively and there are a few elements that I do not want my ...
0
votes
1answer
61 views

How can I fix this code [duplicate]

Possible Duplicate: Stackoverflow type of badge plugin giving warnings in Wordpress 3.5 I'm getting an error on my site that says: Warning: Missing argument 2 for wpdb::prepare(), called ...
6
votes
2answers
190 views

How to check if image is already stored in a site's post database? (network)

I currently have configured Wordpress so that a post can be copied to other sites within a Wordpress network. However, a post may be broadcast more than once, and I want to check if the image is ...
1
vote
2answers
478 views

Trying to get property of non-object “ wordpress ”

My WP theme got these notice on description menu function my code : http://www49.zippyshare.com/v/89513423/file.html /* Discription Navigation Menu, Credit to Christian Kriesi */ class ...
-1
votes
1answer
551 views

Open WordPress Page from selected option dropdown

Code/process to get option dropdown menu selection to open page in WordPress with php? Tried all kinds of plug-ins, widgets, but none will make menu that fits requirements of project so far. ...
-1
votes
2answers
95 views

Fix incorrect related posts code snippet

Can anybody fix this incorrect related posts codes snippet? function related_posts() { if (is_single()) { global $post; $current_post = $post->ID; $categories = get_the_category(); ...
0
votes
1answer
182 views

Changing Link Attributes for Wp_Link_Pages

I'm wondering if there is any way to change the actual link itself for wp_link_pages. So right now, I have a simple code to display the pagination for a post, it looks like this: <?php ...
0
votes
2answers
34 views

Custom PHP-coding in MU installs

I have a WPMU install with a couple of sites on it. I'd like to add some subdirectories that are not wordpress blog pages but do contain working PHP code. They do not use any of wordpress's ...
0
votes
1answer
162 views

Post from one loop in different containers?

Is there a way to output posts from a single loop in multiple containers? Ideally I'd like to have the posts title/meta/content etc alternate between first-container and second-container, but I can't ...
0
votes
1answer
126 views

Taxonomy term description with style, only if the description exists?

I am attempting to add a conditional function to my index.php that will return the description of a term in my custom taxonomy on the page for that term above the list of posts only if the description ...
0
votes
1answer
121 views

Link blogname and blogdescription to the Options Framework

I'm putting together a Theme Options page, where the user(s) I'm building this for would like to be able to edit a few settings directly from this page, including of which - the Site Title and ...
0
votes
1answer
191 views

WordPress Pages into Sections edit.php PHP hack

Im currently working on a Theme for a WordPress website. The theme affectively splits the website up into three sections. http://url.com/section1 http://url.com/section2 http://url.com/section3 ...
4
votes
2answers
334 views

Wordpress the_content() return only one image from a specific category

I am working on a Wordpress website and I am using a loop to get all the posts that have title and body contain an image. But the problem is that it returns me all the titles but not all the images. ...
2
votes
1answer
382 views

Site Title and Tagline in Theme Options Page

I'm using the Options Framework Theme to put together an options page. The user(s) I'm building this for would like to be able to edit a few settings directly from this page, including of which - the ...
1
vote
1answer
432 views

Choose To Display Post Views With An Options Panel

I have post views enabled and I'm attempting to make an options panel option to allow users to choose if they would like to display post views in each post. If they choose 'Yes," then they will be ...
0
votes
2answers
276 views

iframe not showing in post (with “allow php in posts” plugin activated)

$width = 560; $height = 315; $code = "I8M_uCnxhwY"; $homepage = "/"; $currentpage = $_SERVER['REQUEST_URI']; if($homepage!=$currentpage) { echo '<iframe width=".$width." height=".$height." ...
0
votes
3answers
346 views

How to store accumulate multiple option values in a single array using Options_API

I have created an option array that stores a series of options, along with their values. The problem is that I want to ACCUMULATE these options and store them in the options database. Meaning I would ...
3
votes
2answers
811 views

Shortcode to insert <!--nextpage-->

Since wordpress does not have a menu icon (aka "user friendly) way to add the command to a post or page, I'm trying to create a shortcode to do it. However, as logic would have it, its not that ...
0
votes
2answers
69 views

Liking a facebook page from wordpress website?

I have added a button that links to a facebook page at the left of my website, I would like to be able to let people like the page directly from my website. How can I do that? Right now I added the ...
0
votes
1answer
101 views

Using custom tables for old posts

I have a site with about 24,000 posts and 200 posts daily and the database will get huge soon. So I plan to transfer the old posts to custom tables to reduce the database load. There's no need to show ...
0
votes
1answer
234 views

Include a specific post to the query_posts and remove it if it is already in the returned list

Bare with me. Firstly, here is my whole script for my featured slider articles: <div id="featured" class="<?php if ( $responsive ) echo 'flexslider' . $featured_auto_class; else echo ...
-1
votes
1answer
1k views

Isotope Drop Down Categories Filter Function

I have a code in my functions file that I am using to generate a list of categories so that I can use isotope to filter the current page. However I need to know how to - How to make it a drop down ...
0
votes
1answer
33 views

Dynamically pull the correct email address from a match

Here's my current function, class emailer { function notifyHeart($post_ID) { $interests = get_user_meta(get_current_user_id(), 'interests'); $post = get_post($post_ID); ...
0
votes
2answers
141 views

WordPress theme options error

I am building a theme and I need to call theme options But I do get errors like white screen and 500 internal server error when I call theme options here In WP query (newbie in PHP) ...
0
votes
2answers
89 views

page 1 is not paged

I have rules that only work on paginated pages (is_paged). However, they don't work on page number one (/page/1). This one is behaving exactly like the homepage (!is_paged), but unlike pages 2,3,4 ...
2
votes
2answers
92 views

Categories Template Assistance

I have found a tutorial online for creating a custom categories template for my archived posts within a particular category. This however is targetting a specific category ID (see below), is there ...
-1
votes
1answer
91 views

WPMU - How to echo only one URL

I have this code that I am using on a site to check if the current user has a blog on the our wp network and as of now it is echoing the URL for both the main site and their blog. I would like to ...
1
vote
1answer
498 views

Row actions not showing? Why?

I have constructed a WP_List_Table that displays on a custom theme page that I have built. I am having some trouble getting the row actions to display, despite me reviewing all the possible info on ...
0
votes
1answer
259 views

Stackoverflow type of badge plugin giving warnings in Wordpress 3.5

I modified an abandoned Stackoverflow form of badge plugin to work with Wordpress 3.4.2 and it does indeed. The full script for it is here: http://pastebin.com/Ta91zXiL When upgrading to Wordpress ...
0
votes
1answer
73 views

Make Database query only when option is updated

Below is a DB query I am using to retrieve values and place them in a WP_List_Table. Values are currently being added by add_option, then those values are converted into a custom database table ...
0
votes
1answer
209 views

ISOTOPE - Missing/Invalid Arguement Get Terms

I am trying to use the isotope plugin for sorting on my taxonomy page and even though I don't know much about how to set it up, I tried using some advice found on here. Wordpress and isotope ...
0
votes
1answer
120 views

Filtering a Database Query

In a WP_List_Table example I'm using, I am seeing how to make a general query to the wp_options table in the Wordpress database. For example, $query = "SELECT * FROM $wpdb->options"; I also see ...
1
vote
0answers
117 views

How to store options in an array

I am creating a custom table to display selected options for a page called "Testimonials". The user will enter their options on a "manage testimonial settings" page, and then those options will ...
0
votes
1answer
214 views

Exclude function from running on a certain page

I'm working on modifying the Keyboard Shortcut Navigation plugin to fit my site. Here's the plugin: http://wordpress.org/extend/plugins/easy-keyboard-shortcut-navigation/ I don't want this plugin to ...
5
votes
1answer
2k views

How do I use WP_query with multiple post IDs?

I want to query multiple posts with an array of IDs (note: I am querying a custom post type). Here's what I have, which isn't working: $myarray = array('144', '246'); $args = array( 'post_type' ...
1
vote
1answer
571 views

Enqueue Javascript Correctly for 3.5

I am trying to create tabs for admin settings page in wp, but I think I'm doing it wrong. The example below shows how I did it but I don't know how to change this to use it correctly with no conflict ...
0
votes
1answer
520 views

Ajax URLs without #!, how to prevent falling into single.php on load or reload?

I'm trying to make things properly with a single page ajax powered portfolio. I've read that there is no need of #! to make it crawlable by google. So I have clean URLs that updates with .pushState ...
11
votes
2answers
733 views

How to make a image-size selected by default in Media upload - WP v3.5

Bare with me. I want to have a custom image size selected by default in the Media upload popup page. In Wordpress v3.4.2 and prior, this elegant code worked fine: function ...
6
votes
1answer
1k views

Set media upload attachment link to none and hide it in WP v3.5

In the Media upload popup page, how do I set the attachment link to none and hide it in Wordpress version 3.5? The following filter worked fine in earlier versions of WP: function ...
7
votes
2answers
1k views

Remove “Insert from URL” link in Media upload - WP 3.5

How do I remove the Insert from URL link in the new Wordpress 3.5 Add Media popup page? In earlier versions of Wordpress, this worked fine: // removes URL tab in image upload for post function ...
0
votes
1answer
96 views

WP-DBManager Plugin Can't Find Mysql Path

I support a WordPress 3.4.2 site, lifering.org, running on a GoDaddy Virtual Server. Recently I chose to upgrade the underlying O/S from CentOS 5 to CentOS 6. The rebuild was entirely automated and ...
1
vote
1answer
1k views

How to scale image with equal width and height without distortion?

I have a section on my frontpage that querys through recent posts and grabs the title and thumbnail of each. In my functions.php, I've specified a width and height for the thumbnail using: ...
2
votes
1answer
170 views

What is <# code #> in media-template.php, and how does it work?

I'm checking /wp-includes/media-template.php and just found this: <# if ( data.compat && data.compat.meta ) { #> {{{ data.compat.meta }}} <# } #> Never seen <# #> or ...
0
votes
1answer
102 views

Custom PHP App with a wordpress site

I have created a new 'page template' and (this is probably not the right way to do this, but this is the way I have got it working), and created a new page using that template. Within the page ...
0
votes
1answer
249 views

Dynamic Sidebars & Echo

I can sucesfully get my dynamic sidebar to work like so: <div class="sidebar sidebar-first"> <ul class="widget-area first"> <?php dynamic_sidebar( 'pop-photos-sidebar' ); ...
1
vote
0answers
358 views

Security - Ajax and Nonce use [closed]

I'm developing a site which posts a number of ajax calls from jquery to PHP and returns data from PhP to jquery. Everything is working, but i'd to know if my approach to handling the calls is ok, in ...
0
votes
1answer
50 views

why php notice is not getting ignored?

I have been adding at the top of my wp-config.php the following to switch off php logger but won't take any effect on it. Is there something else what I should do? error_reporting(0); ...