使用php和jquery从mysql中检索数据

时间:2022-09-25 21:24:27

I have a menu, it contains multiple items, each menu item will retrieve data from the database. I want to do it without the page refresh, I want like an area that will change when the user clicks on the menu link. How should I send data to the php script and how should I get it from there and preview it on the page? If you can send me any information, references or examples that will be great. Thanks in advance.

我有一个菜单,它包含多个项目,每个菜单项将从数据库中检索数据。我想在没有页面刷新的情况下这样做,我想要一个在用户点击菜单链接时会改变的区域。我应该如何将数据发送到PHP脚本,我应该如何从那里获取并在页面上预览?如果您能向我发送任何信息,参考或示例,那将是很棒的。提前致谢。

1 个解决方案

#1


1  

I would start by reading some of the documentation from the jQuery website: http://api.jquery.com/category/ajax/

我将首先阅读jQuery网站上的一些文档:http://api.jquery.com/category/ajax/

This might also be of interest to you: http://articles.sitepoint.com/article/ajax-jquery

您可能也对此感兴趣:http://articles.sitepoint.com/article/ajax-jquery

#1


1  

I would start by reading some of the documentation from the jQuery website: http://api.jquery.com/category/ajax/

我将首先阅读jQuery网站上的一些文档:http://api.jquery.com/category/ajax/

This might also be of interest to you: http://articles.sitepoint.com/article/ajax-jquery

您可能也对此感兴趣:http://articles.sitepoint.com/article/ajax-jquery