开发者

Can we create table for wordpress?

开发者 https://www.devze.com 2023-01-04 08:18 出处:网络
I am very new to wordress. I have a appointment form. While submitting a form i need to save those information from the form to the database. I created a table of my own lets say wp_appointment and sa

I am very new to wordress. I have a appointment form. While submitting a form i need to save those information from the form to the database. I created a table of my own lets say wp_appointment and saved the information to开发者_如何学C this table. Now what i want to know is that is this a good way to do so or is there any solution to this. And i need to display those information in admin section and update. Is it possible? Please do suggest me if i can do or not.

Thanks in advance


Now what i want to know is that is this a good way to do so or is there any solution to this.

Yes, this is the ideal way to doing this. Besides, there is something to consider:

  • For ease of use and compatability, you can use wordpress's built-in database functions. Check this one: wpdb Class

And i need to display those information in admin section and update. Is it possible?

Sure. You can create a custom admin page and show/make editable them in there. As a start point check this link: Adding Administration Menus. You can apply the instructions told there to your function.php file to have custom pages without create an "external plugin".


To answer your questions: Yes, it's possible. And what you described is being done by current calendar plugins.

Here is one: http://wordpress.org/extend/plugins/events-calendar/

I would take a look at their code to see how they implement something similar to your idea.

0

精彩评论

暂无评论...
验证码 换一张
取 消