Linked Questions

2
votes
1answer
3k views

Bare minimum to include in PHP file to use WP functions? [duplicate]

I'm finding the documentation on coding WP stuff to be very lacking and can't figure out which files I need to include in my PHP script to get a bare minimum working code environment? Example: I want ...
0
votes
2answers
79 views

Static Page with php echo [duplicate]

I build a static page in my WordPress root folder. Now I'm trying to include a list of my categories with echo clpr_categories_list();. Its not working because I some how have to tell the static page ...
5
votes
1answer
6k views

Call to undefined function add_action()

I created a Theme Options page where the user can edit some of the theme settings. Now I'm trying to save this options asynchronously but it seems I have some problems integrating the handler file ...
0
votes
1answer
9k views

Creating wordpress user registration form

I am having a form page called Test Form with this form : <div id="container"> <form action="wp-content/themes/max-magazine/TestForm.php" method="post" name="myForm"> User <input type="...
3
votes
4answers
2k views

Moving a PHP web-app to Wordpress

I've been running a niche job-search web-site for the past several years. I wrote it from scratch in PHP. Essentially it allows members to search for or post job ads. As you can imagine it has ...
3
votes
2answers
3k views

Admin Bar (Toolbar) not showing on custom PHP file that loads WordPress

I've made my own PHP page and used it as a part of my WordPress website. I'm using some WordPress functions and want to have it fully integrated with WordPress itself. Although I've loaded WordPress,...
1
vote
2answers
3k views

Fatal error: Call to a member function add_rewrite_tag() on a non-object in /wp-includes/taxonomy.php on line 333

I get this error while trying to load wordpress in a smarty template. But when I visit wordpress I dont get that error any where. the code I use to load wordpress is : {php}include $_SERVER['...
0
votes
2answers
328 views

how to invoke wordpress API from other existing PHP system

We have our own php system, now we want to have a blog function. Because wordpress are widely used, so we decided to use it. And now I want to invoke wordpress's function , for example wp_insert_user ,...
1
vote
2answers
776 views

How to display admin bar when using WP_USE_THEMES = false?

So I'm using WordPress in a 'themeless' manner, i.e. not using a "blog" template. My site files are in the root directory (not in the theme folder), and WordPressis installed in its own /wordpress/ ...
1
vote
0answers
324 views

How to use Wordpress methods (themes, plugins, context) with Behat?

My Wordpress project is running with a composer inside my plugin folder, just to test Behat a little bit, i'm not using Bedrock Wordpress yet. I can run Behat to do some behavior tests using the ...
0
votes
1answer
295 views

Fetching wpdb data from a php file seems to break?

So I have an html element where the text reflects a text field in my database, this works normally. I need it to update every so often so I have: <script> setInterval(function(){ $("#...
0
votes
0answers
46 views

I am trying to call external database recieving error

My case is different from the case defined here .. I am calling an external databse in my functional.php file by this method function newdata() { $newdb = new wpdb("onlinedu_newuser","oeb_new%...
1
vote
1answer
34 views

How to add shortcode to HTML file (not showing on website)

Im trying to add a plugin shortcode into an HTML document so that when you clickthe "Music" icon on the site a popup appears with the plugin widget in it. This is the shortcode in the HTML file (...
0
votes
1answer
32 views

Where to put a migration script to switch post information?

I just changed a crucial aspect of my theme, and posts tagged with a particular taxonomy called position are now handled by a custom meta field called cmb_position_name. Posts that have the taxonomy ...
0
votes
1answer
15 views

How to return a record from a custom table by sending an AJAX request

I am trying to return a record from a custom table. On the client side, I am sending an AJAX request. <script> var eventId; var xmlhttp; var xmlhttp = new XMLHttpRequest; ...