Articles of database

Array: What is this value based on?

I need to do an import of an array of checkboxes, but there is a value that I don’t how it is determined. The array is based on a user meta option that I created that shows a list of category checkbox options. It grabs all of the categories and creates a checkbox option that […]

How to edit a published post?

I’m writing a plugin. Can anyone please show me how to edit the content of a published post? I’ve tried using this: function edit( $post_ID ) { $content = “Hello. This is a test.”; $post_info = get_post($post_ID); $post_info->post_content = “$content”; } add_action(‘publish_post’, ‘edit’); Although I’m having no luck. Can anyone suggest how to get it […]

Remove “%” from strings in serialized arrays in wp_postmeta

In the course of converting a blog from Blogger to WP and running a script to grab hot-linked images for hosting, I ended up with some funky images names like act%252Bapandas-210×290.png These image names prevent the image from displaying on a webpage, due the url encoding ending up in the file name itself (don’t ask!). […]

How to display content from external db with relevant urls

I am working on a website that needs to display information about electronic resources which is stored in an external database. This information will be presented three different ways (alphabetical by letter, by category, and a detail view of a specific resource) and needs to have a unique url that a user could bookmark or […]

Add some fileds to the wp_posts table

I need to extend some wp tables (wp_posts, wp_comments, wp_users) to store some additional fields. I can’t use metadata because I need to query those values directly via MySQL. I need an help to choose if it’s better to extend the original table or to define an additional one with those fields, with a 1-1 […]

Change the default data installed when setting up WordPress

Is there documentation somewhere on how to change the default data that is entered into the WordPress database when setting up a new database? I want to change the default category and add a couple others. Change the default post. Set a different theme, activate a couple plugins all by default. All of this to […]

Allow front end users to add data to a custom post type

Hay Guys , I’m currently making a plugin so that the administrator can manage “Subscriptions” to the website. I have made a custom post type and activated it within WordPress and only allowed the title field. This works perfectly on the backend, but now i need a way for front end users to add their […]

Share users across multiple sites on same database, but with different domains

I am trying to implement a single sign-on solution between a WordPress and a non-WP site, under different domains. I am aiming to setup a ghost WP install on the non_WP site domain, to be able to load WP in the background, and facilitate cross-domain cookie sharing and authentication Basically I have setup a fresh […]

Using the same database on another Subdomain

Hi i am currently replacing my blog run on wordpress with another neat theme. I tried the preview template feature and everything is fine, just that i don’t trust everything so easily when it comes to web-applications. So i want to use the same database currently used[meaning not to use same database for both sites, […]

Importer fails to import every post

I’m trying to move the content of a blog to a self-hosted one. Right now I’m just trying to set things up on my local environment. I exported the content using the built-in WordPress exporter from the original blog and the file is a little bigger than 2 megabytes. Anyway I managed to increase […]