An application programming interface (API) specifies how some software components should interact with each other. In addition to accessing databases or computer hardware, such as hard disk drives or video cards, an API can be used to ease the work of programming graphical user interface components. ...

learn more… | top users | synonyms

0
votes
2answers
597 views

Displaying the post count of all custom taxonomy terms in a list format

I thought this would have displayed the post counts right next to the clickable links wp_tag_cloud( array( 'taxonomy' => $taxonomy, 'format' => 'list', 'smallest' => 12, 'largest' => ...
0
votes
2answers
79 views

Is Wordpress API visible from PHP file called in htaccess

I'm trying to add some rewriterules in the .htaccess file to deal with hotlinked images - specifically I want to add the URL from the post where the image appeared to the header location information ...
2
votes
2answers
177 views

How to override a function call in functions.php?

In functions.php of a theme makes a call to show_admin_bar(false) which hides admin bar in front end: if (!is_admin()) { wp_deregister_style( 'bp-admin-bar' ); if ( function_exists( ...
2
votes
1answer
213 views

wp_insert_comment error. puzzled by date value

I am trying to programmatically insert comments in a bulk operation as part of migration routine. Comments are in a SQL server table. I receive the date info from the SQL server table field and ...
0
votes
2answers
522 views

Does Wordpress support a shortcode calling itself from within a shortcode call?

I've built a super-crazy Wordpress framework that has a million and one shortcodes, one of those is a columns shortcode which supports a count parameter that allows you to define a column and the ...
0
votes
1answer
204 views

How to create download links based on Custom Fields with Rewrite API

For me this is quite hard to do, but I guess that this could be easily done by an expert. :) Let's suppose I have a post, which is a custom post type resources, with the following data: Post Slug: ...
1
vote
3answers
231 views

Does WordPress's HTTP API use any caching?

I'm working on a plugin to will retrieve data from a remote server and display it on the Dashboard. To do this, I'll be using the WordPress HTTP API but I'm not seeing any information on the HTTP API ...
2
votes
2answers
2k views

How should I use register_setting, add_settings_section, & add_settings_field in my plugin's options page?

I'm working on a settings section for my plugin, and after reading over Wordpress's documentation which is in ROGUH DRAFT status, and also the Creating Options Pages - which is also in "transition", ...
0
votes
1answer
738 views

jQuery Tabs in Shortcode API

Pastebin of the html prototype and my attempt at the wp function -> http://pastebin.com/91zBv8sk I want a simple notation so its easy for new users to use. So something like this: [tabs] [tab ...
4
votes
3answers
4k views

What is the best way to get directory path for wp-config.php?

I am developer of the plugin mapsmarker.com which also offers several APIs which can be accessed directly (eg www.mapsmarker.com/wp-content/plugins/leaflet-maps-marker/leaflet-geojson.php?marker=1) ...
-2
votes
1answer
786 views

How to import data from another website using an API link?

I have an API link ($content bellow), and I need to display the content fetched from this link in the dashboard. I don't have slightest idea how to do this. if( !class_exists( ...
3
votes
1answer
385 views

Authentication/API Questions

We are trying to use S2Member to manage our WP site and memberships for a Flash program that we are launching. We'd like to use S2Member to authenticate the user when they login and remain logged in. ...
2
votes
1answer
2k views

WordPress JSON output

Update: I've changed the code as following $cats = get_categories(); $output = array('categories' => array()); function collect_posts(){ $args = array( 'numberposts=' => 9999, 'category' ...
1
vote
1answer
240 views

How to add an alternative style sheet as a theme option?

I'm trying to create a few extra theme options in the "customise" section of the wp admin menu. I would like to offer an option to load an alternative style sheet. Question: How can I adapt the ...
0
votes
1answer
52 views

Lead form that submits to 2 external APIs

I need to add 2 registration forms to my wp website, each form should submit the information in it to 2 different APIs. I don't know even where to begin. Is there a plugin that can help me handle the ...
-1
votes
1answer
110 views

More Fields WP Plugin

one of my clients use More Fields WP plugin and we want to generate a feed of the data entered using that plugin. http://wordpress.org/support/plugin/more-fields Have installed JSON WP plugin to ...
1
vote
0answers
113 views

permalinks with get variables

I'm trying to create my own permalinks with wordpress rewrite API. I have been registering my get variables as it follows add_filter( 'query_vars','driver_vars' ); function driver_vars( $vars ) { ...
11
votes
2answers
2k views

How to pass variable to add_settings_section() callback?

I am attempting to automate, as much as possible, the Settings API function calls for each setting in a Plugin. Looping through the options array, and outputting add_settings_section() and ...
0
votes
3answers
431 views

Get timestamp of latest post in C#

Is there a way to get the timestamp of the latest post in C#/.net? I am writing a control in ASP.NET for a intranet, which will alert users when a new post is posted in a wordpress blog.
2
votes
1answer
830 views

API integration with WordPress

I'm trying to integrate a 3rd party API with WordPress. I fear this is above my head. I was this code but I'm not exactly sure how to make is work in WordPress. Is it possible? $ch = curl_init(); ...
1
vote
1answer
587 views

How can I add an options page for my class based plugin?

I'm trying to use the new Settings API with a class based plugin to add a settings page. This is the code I have so far: class simple_sample_plugin{ function simple_sample_plugin() { ...
5
votes
2answers
401 views

WordPress.org API - Get plugin authors favorite plugins

There have been some recent additions to the WordPress.org plugin repository. Most notably the changes to the plugin page and the author profile page which now shows an authors favorite plugins. I ...
4
votes
1answer
3k views

[Plugin WPML] : How to create a translation of a post using the WPML API?

I'm trying to figure out how to create a translation for a post using the internal WPML API (inc/wpml-api.php) I simply want to create a translation for post ID xx, set some content and publish it. ...
1
vote
1answer
286 views

Exposing data using a custom Wordpress API

I'm attempting to create an API through Wordpress exposing some of my back-end data. I've come to the conclusion that I cannot have a stand alone page (plugin) exposing this data because Wordpress is ...
0
votes
2answers
426 views

Multiple sub directories for theme template pages

I apologize if this questions has already been answered, I have a feeling I'm just not using the right terminology for my search. I'm in the process of building a base theme for my employer. One of ...
0
votes
1answer
440 views

Plugin options will not save in database

I'm not sure what's happening here, since this has worked in another plugin I've created. I'm simply trying to store data in the options table. Here is the code I'm using: function on_myplugin_start ...
0
votes
1answer
489 views

how do I delete (not exclude) a menu item from navigation bar

I'm building a site's navigation bar programmatically, using the following code: wp_update_nav_menu_item($menu->term_id, 0, array( 'menu-item-title' => $page_data->post_title, ...
0
votes
1answer
439 views

get_pages and get_posts returning different data?

this is driving me crazy... I have an admin plugin page that lists pages for a wordpress website. I'm trying to list all the pages using get_pages() but for some reason once pages are published they ...
1
vote
1answer
2k views

How to create a drop down list with pages to a themes options page?

I'm building a themes options page using settings API. Everything is ok, but i now i want to create a drop down list populated with pages and i don't know how to! For example, i have this piece of ...
2
votes
1answer
353 views

What is the best way to move a plugin´s subdirectory+files to wp-content/uploads-directory?

I am developer of the plugin Leaflet Maps Marker (http://www.mapsmarker.com - "Pin, organize & show your favorite places through OpenStreetMap, OGD Vienna or any custom WMTS-map") and have one ...
0
votes
1answer
245 views

hybridauth (google OAuth integration) and WP problems

I'm trying to implement the script shown here: http://hybridauth.sourceforge.net/userguide/Integrating_HybridAuth_SignIn.html To allow people to sign in with Google to my site. However I am getting ...
1
vote
1answer
143 views

Custom Post-to-Post with multiple parents?

I currently have a custom post type of "Faculty" - each faculty can have zero or many custom post type "Bibliographies," and a bibliography can belong to one or more faculty. What is the best ...
1
vote
1answer
756 views

Use Gravity Forms and a Shopping Cart for output to Freshbooks for an Estimate

I've been asked to develop a website pretty much like (but not the same as): http://www.yoursingapore.com/ basically we need to allow people to add Wordpress posts (custom post types) into a sort of ...
12
votes
2answers
559 views

New WP_Customize API - how does it work under the hood?

I noticed that if you make changes trough the new "customize" feature, when you navigate on a different page within the iframe preview document, your changes still apply, even if they are unsaved. It ...
0
votes
1answer
245 views

Trying to integrate wordpress query on other website - getting redirection to wp-install

i'm trying to replace news system on my website with posts from wordpress site. I have main site in (example) /var/www/site and working Wordpress blog on /var/www/site/blog Tried to do that: ...
0
votes
1answer
274 views

term_exists returns NULL

According to the codex ( http://codex.wordpress.org/Function_Reference/term_exists ), term_exists returns some mixed results but not NULL. In my case, I'm getting NULL, what am I doing wrong? In ...
2
votes
3answers
1k views

How do I create a widget that only allows a single instance?

How do I create a widget that only allows a single instance of a widget to be added through the Wordpress interface? The default behaviour of widgets allows multiple instances to be added. I am ...
1
vote
1answer
112 views

Get the timout value of a saved transient?

Does anyone know if there is a Wordpress function to get the timeout value of a saved transient? I am using a transient with a 5 minute timeout to cache data from a web API call locally. Between ...
1
vote
1answer
1k views

POST to a REST API from a wordpress form

I dont want to use a REST API to publish to wordpress. I want to create a form on a wordpress page which will send a POST to an external REST API. Users will put in their information, and perhaps ...
1
vote
2answers
1k views

wp_localize_script escaping my url - fix or alternative

Here is my wp_enqueue_script and wp_localize_script - which i am using to run an Ajax call. wp_enqueue_script( 'function', plugin_dir_url( __FILE__ ) . 'function.js', array( 'jquery', 'json2' ) ); ...
1
vote
1answer
255 views

Sending WP posts to external API

What's the best method for sending all new Wordpress Posts to an external script on another server? It needs to include the full post information including the post content, so a simple ping is not ...
0
votes
2answers
248 views

Get Wordpress login functions without printing anything

I want to serve a dynamically-generated PDF with a "File Transfer" header header('Content-Description: File Transfer'); However, before I generate the document I need to verify the user's login ...
4
votes
2answers
1k views

How to use WP_Error $data argument?

The Call $error = new WP_Error( $code, $message, $data ); The Output Say I added three messages (msg A, msg B, msg C) to the code my_code and with the last message I added "Data" as $data, which ...
0
votes
2answers
254 views

What to hook into to check a value before a post is published?

My website is set up with pages as categories, meaning that if a user publishes without choosing a category, no one can see the post unless they know the specific address. What do I need to hook ...
0
votes
1answer
67 views

How do I query posts and have their related taxonomies returned in the results?

I have created a custom post type that contains television channel data. Each channel has its own post. I have also created a custom taxonomy of channel groups. What I want to do is query all the data ...
0
votes
1answer
38 views

Including content from legacy app: via plugin or custom content?

I am looking to integrate content that exist in a legacy system to a wordpress blog. The content can be accessed from the legacy system via SOAP. I have some PHP experience and some (limited) ...
0
votes
4answers
556 views

How to query WordPress from another application?

We're building an iOS app for BarbadosPropertyList.com. The iOS app needs to query the website and download recent listings data, including titles, datestamps, thumbnails and custom fields. We would ...
1
vote
1answer
49 views

Include default functions and methods

I'm starting a new service for a customer consisting in adding a input API in their WP website. I started by creating a blank page on the root but then I realized I couldn't access all methods and ...
2
votes
0answers
543 views

Wordpress JSON API Extend to Create Users [closed]

I have the JSON API Plugin installed on my wordpress blog and it works like a charm. However there is one functionality that i really need. A method called create_user which should take parameters ...
0
votes
1answer
433 views

get_option() fails to return binary result

For some reason, get_option() started to fail when returning binary results when I moved my website from localhost to the web server. I migrated my WordPress using an upload of the files on the FTP ...