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

learn more… | top users | synonyms (1)

0
votes
1answer
198 views

Path for contact form file

I have a php contact form that I use with all websites, so ideally I want to avoid using a plug in. The files used include: • contact.php - A file with php/html write up which displays the form ...
0
votes
4answers
949 views

Add additional field to custom post_type

I am trying to add another field (subtitle) to my already created and existing custom post_type: team (code from functions.php in my *child*theme) <?php /** * Custom Post type register framework ...
0
votes
1answer
847 views

reorder a WP_Query, using a dropdown

I have the following loop used to display posts by category & I would like to to re-order them based on a dropdown selector if (!isset($qry)) $qry = new WP_Query(array('category_name'=>$...
0
votes
1answer
887 views

save_post action inside a custom metabox class not working

I am writing a class to create metaboxes and save the form data. The problem is, I keep getting a warning when I click "publish": Warning: call_user_func_array() expects parameter 1 to be a valid ...
3
votes
1answer
6k views

Debugging an error: wp_enqueue_style was called incorrectly

I've just uploaded a new, custom theme to find that the container is a fraction of the intended width, and the sections below the home section(this is one single page, long site utilizing ids/anchors ...
0
votes
1answer
101 views

Wordpress child pages not working

I am creating a wordpress CMS and I have added multiple pages under one parent page. I am generating the links for all the child pages of a page and then when user clicks on the links, they should be ...
0
votes
1answer
4k views

Trying to get property of non-object wordpress error message

I am running the really-simple-facebook-twitter-share-buttons. I have placed the below code on my site as the plug in recommends, which is: <div class="share"><?php echo ...
1
vote
1answer
2k views

How can i create a function to get youtube video time

Tom J Nowell posted this code to help me retrieve the YouTube video time. Functions // function to parse the code from the URL function parse_youtube_video_id_from_url( $video_url ) { $...
0
votes
1answer
169 views

Display Youtube Time Automate from Key

Hy im building the Trailer section, i want to get the time automate from Youtube video's... Custom Fields $key="trailer"; - represents the key of the trailer Ex (http://www.youtube.com/watch?v=...
-1
votes
2answers
125 views

Wordpress menu links with images & class selection

<ul> <li class="selected">Link 1<img src="images/slash.png" /></li> <li>Link 2<img src="images/slash.png" /></li> <li>Link 3<...
0
votes
2answers
446 views

How to reduce the database query-es

Hy, i make a slide for news, the question is how can i reduce the dathabase queries...ore how can i compress this code... http://s16.postimage.org/bswe0vrph/queries.jpg <div id="featured" > &...
0
votes
1answer
101 views

URL prefix to include one PHP page

is it possible to set one URL prefix to include one PHP page every time? Only Wordpress header and this PHP page. I need to include some custom application but HAVE TO include wordpress powered web-...
0
votes
1answer
105 views

custom header text

I am creating a custom website by modifying the twenty-eleven theme. I want to create custom text in the header area that is unique to each page. Is there a way to add a 'description' to each page and ...
-1
votes
1answer
1k views

best way to communicate between php and jquery/javascript

I have a custom post type "pakket", in which I've put all kinds of data in the taxonomy terms. This custom post type has about 50 items, each with their own values for taxonomy terms. For example: ...
1
vote
2answers
4k views

Edit Yoast SEO breadcrumbs output

I want to customise the output of Yoast SEO breadcrumbs, I have this so far which works great: add_filter( 'wpseo_breadcrumb_single_link', 'ss_breadcrumb_single_link', 10, 2 ); function ...
0
votes
1answer
84 views

Wordpress Rewrite Rule

I have a standard page setup at http://mysite.com/mypage/ I'd like to setup a rewrite rule in my theme functions that takes any URLs such as: http://mysite.com/mypage/helloworld/ <-- Currently ...
2
votes
1answer
200 views

I would like to use create a function in my custom plugin to tell WP to use a different header

I am well aware of the use of child themes for this. I know about get_header($name). I already understand the use of conditional tags. I want my plugin to remove the function: function get_header( $...
2
votes
1answer
942 views

Crop image from get_theme_mod Customizer field

I'm using the following code to allow a user to upload a custom image (in addition to header image) through the customizer. Is there a way to crop the image when displaying it? $wp_customize->...
3
votes
2answers
1k views

How to hide get_theme_mod if field empty

I'm using: get_theme_mod to show various pieces of info from the theme customizer, in the following format: <a href=" <?php get_theme_mod( $name, $default ) ?> ">This is the link</a>...
0
votes
1answer
406 views

How to change the menu color

I need to change the menu color of the wordpress 2011 theme to transparent. this is the header <nav id="access" role="navigation"> <h3 class="assistive-text"><?php _e( '...
0
votes
1answer
143 views

Can't remove menu items added by plugin

I am trying to remove menu items from the backend but for some reason I can't remove specific menu items added by plugins. For example, I can use this line to remove the plugins page and it works just ...
0
votes
1answer
3k views

admin-ajax.php loading many times

My site is running slow, because the file "admin-ajax.php" is loaded many times. see screenshot here: http://f.cl.ly/items/2b0O3Q0X27433X2F2j3U/Bildschirmfoto%202013-02-23%20um%2014.13.14.png Here ...
1
vote
2answers
273 views

CSS from textarea in options page to frontend what to do

I have a textarea for small css enhancements on the plugins page i output them directly to the head. My Question is how to sanitize the CSS i have validation function registered for the options with ...
1
vote
1answer
142 views

How do I attach a php file to an arbitrary slug and still have access to the wp-core functions?

Based on an example found here and several others, I am trying to load a non wordpress page from a specific URL while having access to the wordpress core. I have the following code (which seems to ...
-2
votes
1answer
650 views

Why is my footer missing [closed]

Hi for some reason my footer is missing on my site, and i don't know why. I have deactivated all plugins and it's still not there, I have checked the css and all, but the footer is still missing can ...
1
vote
1answer
852 views

Using the echo command adds unwanted br tags to source

I am making a simple HTML form in a plugin I am writing. I was thinking of using echo for all output, but I can't seem to control the formatting of the HTML outputted (for debugging, neat looking HTML,...
0
votes
2answers
116 views

PHP echoes value without the use of echo

I'm building a table with items in it. What I don't understand is the following: When I type <td> <?php custom_get_terms('landschapspakket');?> </td>, it echoes the value of ...
0
votes
3answers
881 views

Creating on-page options for Custom Post Type

I'm creating a plugin for creating Landing Pages. I use custom post type and custom fields for the landing pages, but i need to add some on-page options for each entry. For example i need to have a ...
0
votes
1answer
44 views

feedburner plugin for WP 3.5

I was using FD Feedburner Plugin for feeds redirection to feedburner, but now after updating to WP 3.5 it stops working. Is there any feedburner plugin which forks for WP 3.5 ?
8
votes
3answers
474 views

Make Google index the entire post if it is separated into several pages

While this is a question, it is as well a serious warning to publishers that separate their posts using <!--nextpage-->. Bare with me. I run a highly trafficked multiple author platform that ...
0
votes
1answer
377 views

Kohana Frontend, Wordpress Backend

I love Kohana code, I don't love Wordpress code. I need to upgrade a blog to have a custom theme, very custom with Grid style blog roll (like Pinterest) and Traditional Blog Roll, and fully ...
0
votes
3answers
144 views

Display additional page templates and a sidebar on plugin activation

I'm developing a child-theme off of the Twenty Twelve (1.1), using Wordpress (3.5.1) and the Woocommerce plugin (1.6.6). I've noticed that the problem with creating the online shop, single product ...
1
vote
4answers
743 views

Different background-image by category

I am trying to put different body background-image for each category. body { background-color: #000; background-image: url(img/bg.png); background-repeat: no-repeat; background-position: center ...
0
votes
1answer
114 views

Adding else if conditional statement to purchased theme

I purchased a theme that I want to change a bit. I'm familiar with writing some if/else statements but not this type and not matter what I do, I can't add an else/if without breaking the code. Below ...
0
votes
3answers
82 views

Trying to display ads on only a third of posts in a loop. Keep getting Error 500?

I'm thinking it's just a PHP code error, but for some reason the following code won't work, it just keeps giving me Internal Server Error 500 <?php $ajfl_adLuck = rand(1,3); if ($ajfl_adLuck ==...
0
votes
1answer
353 views

Theme Functions run a function upon activation or preview

My theme currently has the following line in the function.php file: if ( $_GET['activated'] == 'true' || $_GET['preview'] == 1 ) If this statement is true the code runs a function. I am getting a ...
1
vote
1answer
1k views

Recent Posts slider, using WP_Query(), loads duplicate sliders

I have written a small piece of code for Wordpress that will show the most recent top 4 posts in a slider (the Filament Group Responsive Carousel). It works, displaying the posts and sliding them etc, ...
1
vote
1answer
1k views

Error: options page not found

This error is really well known and every where I look its either I am not doing: <form method="post" action="options.php"> or I am not registering my options, which is not the case as seen ...
0
votes
2answers
277 views

Content filter won't work

I'm trying to filter my content and on matches on flow I would like to change my html structure, but my rule doesn't really apply. I have the following filter which searches the first image of posts ...
0
votes
1answer
106 views

posting twice from an array?

I dynamically create iterations of a form field with jquery, but they all carry the name extrakosten[] for the first variable and the other variable vergoeding[]. The php: $postTitle = ''; // save ...
0
votes
2answers
634 views

Display latest 5 posts on homepage

I'm currently using a custom made Twentytwelve child theme and would like to display the last 5 posts on the homepage using a shortcode. I have tried using the code below (added to functions.php) but ...
-1
votes
1answer
379 views

How can a 'scripts' directory be hooked into wp_head();?

So I'm trying to get my head round <?php wp_head(); ?>. I understand that it loads in the stuff needed for plugins etc., but I'm using a theme that seems to be using it to load in scripts for ...
1
vote
1answer
836 views

Notify comment author upon reply

To improve communication between guest commenters and authors, I am fiddling with a script that sends an email to the author of a comment when it receives a reply. Here is how the code looks so far: ...
0
votes
1answer
37 views

How to retrive the text : No movie by this actor

Hy, im building a cinema site, in movie page i have a Custom Field that link's the actor page, when i add a movie and i link the actor, on the actor page i get the movie, now the problem is how can i ...
2
votes
1answer
633 views

Mysterious HTTP 404 header in my own scripts

I have a WordPress 3.5.1 + nginx configuration. Its nginx configuration is this: server { root /mysite/public_html; server_name wp.mysite; location / { try_files $uri $uri/ /index....
0
votes
2answers
365 views

How do I return an image from a script

I have googled but must not be using the correct terms. I am trying to add a script to my WordPress plugin that takes a url and returns a reformatted image. I know this is frowned upon as hotlinking....
0
votes
1answer
879 views

Redirect to current user page upon link click

I hope this problem does not have too complicated of a solution. I also hope it isn't too easy so I don't feel like a fool for not figuring it out :) On my website, (Wordpress), I have Peter's ...
0
votes
1answer
66 views

Older entries link within a category page

I have set up a category called 'blog' and have all of my posts displaying from this category. I have selected to display 4 posts / page therefore there is a link at the bottom that says older entries....
1
vote
2answers
11k views

Why WP_Query('showposts=5') shows only 1 post?

I am trying to do a simple query to get the latest 5 posts into an unordered list, but this is only showing 1 result even though I have several posts. I even did an offset, but it shows the next post ...
0
votes
1answer
147 views

How do I display a full post, not just an excerpt?

I am a newbie, so apologies in advance if my terminology is off. I have purchased a theme (WP SmartStart) and I would like the posts in the blog to display fully, not just as excerpts. I read previous ...