jimfoltz
Forum Replies Created
-
Forum: Plugins
In reply to: Forum for Plugin Authoring?Thank you Michael. Found the Google Groups interface also:
Forum: Plugins
In reply to: require(‘../../../wp-blog-header.php’);Picky, picky. I had to change this line (the submit for the form):
<input type="submit" value="Update" onClick="ei_update_ex(this.form.name);">to a type of button:
<input type="button" value="Update" onClick="my_js_func(this.form.name);">Go me.
Forum: Plugins
In reply to: require(‘../../../wp-blog-header.php’);Ok, so I read and followed the instructions mentioned in the above link. I think I have everything in the right place, but after I submit the form I get the Please Register screen.
Forum: Plugins
In reply to: require(‘../../../wp-blog-header.php’);To answer my own Q’s, the better way appears to be to use viewer-side AJAX.
Forum: Plugins
In reply to: First Post & QuestionOk, so I can just use method=”post” in the action, and point the action to my plugin’s form handler php file.
Next problem is that I can’t use any of the wordpress functions in the form handler file. It’s like the handler file has no idea about wordpress.
Not sure what I need to be doing. Any thoughts appreciated.
I think I understand the wordpress way of doing things – define some functions in the plugin file, call the functions in templates. But it’s not clear how I can get html form values into the database using this model.
Forum: Plugins
In reply to: require(‘../../../wp-blog-header.php’);Thank you. You are right except that I lied – the file is not directly in the plugins folder, but rather a sub-folder of plugins.
What I am doing is sending html form data using the post method to a ‘update.php’ file in my plugin’s folder. Using the ‘require’ was the only way I could get the ‘update.php’ file to know it was running in wordpress. I need to make sure the user who submitted the form data has authorization to use the database by checking if the user is logged in and has the correct role.
Is there a better way?