`
ranfow
  • 浏览: 29705 次
  • 性别: Icon_minigender_1
  • 来自: 广州
最近访客 更多访客>>
社区版块
存档分类
最新评论

25 Excellent Ajax Techniques and Examples

    博客分类:
  • Ajax
阅读更多

Ajax allows for rich-internet applications that mimic the responsiveness and complex user interfaces typically associated with desktop applications. Moving applications to the web browser opens many possibilities, including the ability to save user data, connecting with other users for collaboration and sharing, and making deployment and using the application easier since web browsers are standard-issue with most computers regardless of operating system.

If you’re interested in expanding your understanding of Ajax techniques and practices, check out these 25 hand-picked Ajax articles and tutorials that outline various methods and concepts involved in the development of Ajax-based applications. Though most are geared for budding and intermediate developers, veterans might find a trick or two they haven’t encountered before.

1. Ajax RSS reader

Ajax RSS reader - Screenshot

Build a simple RSS reader that takes remote XML data from RSS feeds using Ajax, PHP, and MySQL. This example allows users to view feed content from multiple sources in one page. At the bottom of the article, you’ll find an animated demonstration of the RSS reader.

 

2. Ajax Desktop Tutorial

Ajax Desktop Tutorial - Screenshot

This tutorial is a step-by-step guide on how to create a desktop/homepage similar to Pageflake and Netvibes . The goal of this tutorial is to showcase some common techiques involved in developing web-based applications like manipulating the Document Object Model (DOM), listening to events (i.e. certain mouse movements), and working with remote data.

3. Ajax for Chat

Learn to build a simple web-based chat client using asynchronous JavaScript, XML, and PHP. The tutorial’s example utilizes the Prototype JS framework, MySQL, and PHP.

4. Create your own information space with Ajax and del.icio.us

This article outlines the basic foundations of using Ajax alongside an API service. It uses the del.icio.us API , but the methods and concepts can be adapted to other popular services such as Digg’s or Flickr’s . It’s an essential resource for those contemplating on creating web applications that use remote XML data - a couple of live examples are popurls and SocialBlade , which obtains information from social media sites using available API services. This tutorial requires you to register (for free).

5. Ultra-lightweight Charts For AJAX

Ultra-lightweight Charts For AJAX - Screenshot

See how to create a super-lightweight (1.78 KB) charting component using Flash with Ajax. The example allows you to generate visual graphs using dynamically-loaded data. The solution involves ActionScript-JavaScript communication, and covers the use of the setData and setStyle ActionScript methods for generating and styling the charts.

6. Quick Calendar Using AJAX and PHP

Quick Calendar Using AJAX and PHP - Screenshot

Learn how to create a calendar component using Ajax and PHP. Ajax is used for navigating through the calendar months without refreshing the page.

7. How to integrate Google Calendar in your website using AJAX

How to integrate Google Calendar in your website using AJAX - Screenshot

This tutorial shows you how to create a web page component that calls a publicly available Google calendar. Google Calendar allows you to easily create, share, and manage events and is an excellent feature for community websites.

8. Edit In Place with AJAX Using jQuery

Edit In Place with AJAX Using jQuery - Screenshot

In this example, users are given the ability to edit the XHTML of the web page they’re currently viewing. The example is a proof-of-concept – presenting how this functionality can be achieved using jQuery. Normally, you’d want to send the user’s edits to server-side code to perform processes such as validation or saving the changes in a database.

9. Creating an AJAX Rating Widget

Creating an AJAX Rating Widget - Screenshot

Learn the concepts of creating a rating system without prompting the user to click a submit button or refreshing the page. The tutorial showcases how you can do this in a variety of ways by including examples for the following four JavaScript frameworks/libraries: Dojo, jQuery, mootools, and Prototype JS.

10. AJAX file upload tutorial

AJAX File Uploader - Screenshot

In this tutorial, you’re shown how to create a file uploader. The tutorial uses JavaScript and PHP.

11. Use AJAX and PHP to Build your Mailing List

This tutorial from SitePoint walks you through the development of a mailing list form that accepts submissions asynchronously. It uses MySQL for storing the data inputted by the user and Prototype JS for simplifying Ajax requests and binding event handlers.

12. Safer Contact Forms Without CAPTCHAs

Safer Contact Forms Without CAPTCHAs - Screenshot

One way to reduce spam from public web forms is to implement a system to verify if the submitter is human by using image CAPTCHAs. Problems arise with accessibility when individuals using visual assistive technologies are presented with the test (and thus cannot continue on). This simple technique uses an Ajax call to a server-side script to drop a cookie on the user’s computer.

13. Using AJAX with CAPTCHA

Using AJAX with CAPTCHA - Screenshot

Avoiding the use of image-based CAPTCHAs is a good idea. With that said, many sites still prefer using this technique to distinguish between humans and computers. If forgoing web accessibility is appropriate for your situation, this article outlines a unique method for administering CAPTCHA tests. The user is presented with a sequence of descriptions (i.e. Animal, Costume, Boy), and asked to click on a set of images in sequential order. The clicks are recorded and validated, returning the appropriate status message. Though probably not an ideal solution to CAPTCHAs, it does outline a fundamental technique for developing responsive user interfaces - use it for inspiration.

14. Ajax-based login form

Ajax-based login form demo - Screenshot

Create a basic login form that asynchronously validates the inputted data. The example uses the jQuery form plugin and PHP to process the request.

15. Nice Ajax effect for message box using Mootools

Nice Ajax Effects for messages - Screenshot

In this example, a message box that fades after a specified duration is displayed when the user clicks on the “save” button. This is a model for supplying users with the status of their request, and an real Ajax request should typically happen when the user clicks on the “save” button.

16. AutoCompleter Tutorial

AutoCompleter Tutorial - Screenshot

The AutoCompleter tutorial teaches you how auto completion of input fields can be accomplished. The example uses jQuery, PHP, and MySQL.

17. Auto-populating Select Boxes using jQuery & AJAX

Auto-populating Select Boxes using jQuery & AJAX - Screenshot

A key technique in Ajax applications is to populate content without a page refresh. In this tutorial, you’ll witness how this is done with a PHP and JavaScript (jQuery to make it easier).

18. Build an Ajax Dropdown Menu

Here’s a basic example of working with external data to load content into a drop-down menu - from our beloved Webmonkey . Though the example uses a text file, you can use your own data source when applying the technique to your own purposes.

19. Ajax/PHP Shoutbox Tutorial

Ajax Shoutbox - Screenshot

Make an Ajax-powered shoutbox using PHP and JavaScript. This tutorial walks you through the server-side and client-side requirements of creating a shoutbox, which can be adapted to other functions such as a commenting system.

20. Building Tabbed Content

Building Tabbed Content - Screenshot

Learn how to build a tabbed content component with the data populated via Ajax. The tutorial uses PHP and Prototype JS.

21. How to Load In and Animate Content with jQuery

Load In and Animate Content - Screenshot

This step-by-step tutorial shows you how to load data into a web page using jQuery to handle the Ajax request and manipulation of the DOM.

Best practices and workaround techniques to common issues

22. The Hows and Whys of Degradable Ajax

The Hows and Whys of Degradable Ajax - Screenshot

This article discusses the concept of creating Ajax-based applications that degrades effectively when JavaScript is not detected, providing increased accessibility and bulletproof-ness . Completely successful degradation means that an application is still usable and information is still accessible without reliance to JavaScript or CSS.

23. Avoid unnecessary Ajax traffic with session state

This article presents a method for minimizing unneeded database/computational processes and avoiding large status updates if no changes have occurred. By using client cookies to keep track of the session’s state, you can cut down on processes that may be redundant. Though the article presents an example using Python for server code – the model remains the same in virtually any language you use.

24. A Better Ajax Back Button Solution

Here’s a workaround to issues pertaining to Ajax-loaded content breaking web browser controls and bookmarking capabilities. The solution involves firing off a function at a set interval that checks the #value of the URL, and then presenting the correct content. It restores the ability to bookmark the content. In Part 2 of the article, you’ll see a working example and additional discussion of this method.

25. Making Ajax Work with Screen Readers

Making Ajax Work with Screen Readers - demonstration Screenshot

One of the biggest drawbacks of loading content via Ajax is that it fails to indicate an update of the content to users who are reliant on screen readers. For people who are not visually-impaired – messages and status indicators can be visual queues that the content is changing; this isn’t effective for users with visual impairments. This article draws out the underlying issues and proposes techniques to make Ajax-based applications work with screen readers.

There we have it… some brilliant Ajax techniques and examples. I hope you’ve found some links of interest that will help you in a future project or in advancing your command of Ajax.

Have you got your own favorite link? Let’s see it by dropping a message in the comments section.

 

http://sixrevisions.com/ajax/ajax_techniques/

分享到:
评论

相关推荐

    Apress.JavaFX.Script.Oct.2007

    - This chapter expands on the topics covered in Chapter 3, introducing advanced UI techniques and 2D graphics capabilities. It includes practical examples of drawing shapes, handling events, and ...

    模具状态监测行业发展趋势:预计到2030年市场规模为5.06亿美元

    模具状态监测市场:6.8%的年复合增长率引领制造业智能化升级 在快速发展的制造业中,模具作为生产过程中的核心部件,其状态直接影响到产品的质量和生产效率。然而,模具的损耗和故障往往难以预测,给企业带来不小的损失。如今,随着模具状态监测技术的兴起,这一切正在发生改变。这项创新技术不仅能够帮助企业提前发现模具的潜在问题,还能显著延长模具的使用寿命,提升生产效率。但你真的了解这个市场的潜力和现状吗?让我们一同揭开模具状态监测市场的神秘面纱。 市场概况: 根据QYR(恒州博智)的统计,2023年全球模具状态监测市场的销售额已经达到了3.2亿美元,预计到2030年,这一数字将攀升至5.06亿美元,年复合增长率高达6.8%。这一显著的增长背后,是制造业对智能化、自动化生产需求的不断提升,以及模具状态监测技术在提高生产效率、降低维护成本方面的显著优势。 技术创新与趋势: 模具状态监测技术主要依赖于传感器、数据分析和处理等技术手段,能够实时采集模具的温度、振动、压力等指标,并通过与预设参数的比对,及时识别模具的异常情况。随着物联网、大数据和人工智能等技术的不断发展,模具状态监测技术将更加智能化,能够提供

    Kubernetes DevOps实践工作坊-从理论到实战操作脚本集(含源码).zip

    Kubernetes DevOps实践工作坊-从理论到实战操作脚本集(含源码).zip [资源说明] 1、该项目是团队成员近期最新开发,代码完整,资料齐全,含设计文档等 2、上传的项目源码经过严格测试,功能完善且能正常运行,请放心下载使用! 3、本项目适合计算机相关专业(人工智能、通信工程、自动化、电子信息、物联网等)的高校学生、教师、科研工作者、行业从业者下载使用,可借鉴学习,也可直接作为毕业设计、课程设计、作业、项目初期立项演示等,也适合小白学习进阶,遇到问题不懂就问,欢迎交流。 4、如果基础还行,可以在此代码基础上进行修改,以实现其他功能,也可直接用于毕设、课设、作业等。 5、不懂配置和运行,可远程教学 欢迎下载,学习使用!

    基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)

    基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设),个人经导师指导并认可通过的毕业设计项目,评审分98分,项目中的源码都是经过本地编译过可运行的,都经过严格调试,确保可以运行!主要针对计算机相关专业的正在做毕业设计的学生和需要项目实战练习的学习者,资源项目的难度比较适中,内容都是经过助教老师审定过的能够满足学习、使用需求,如果有需要的话可以放心下载使用。 基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)基于springboot+vue3+uniapp的点餐小程序源代码+数据库+文档说明(高分毕设)基于springb

    欧姆龙NX1P2系列总线plc程序 自动检测机,plc程序,无触摸屏程序 1.多工位DDR马达转盘控制,多工位同时加工 2.多产品配方功能程序 3.各种实用型自制功能块程序,可重复调用,成熟设备

    欧姆龙NX1P2系列总线plc程序 自动检测机,plc程序,无触摸屏程序 1.多工位DDR马达转盘控制,多工位同时加工。 2.多产品配方功能程序。 3.各种实用型自制功能块程序,可重复调用,成熟设备

    企业微信最全养号、防封、加人机制.pdf

    企业微信最全养号、防封、加人机制.pdf

    LLM 友好的异步爬虫框架

    这是一款用 Python 开发的异步爬虫框架,能够将网站上的数据转化成 Markdown、JSON 等 LLM 友好的输出格式。它完全开源且免费,极大地简化了异步爬虫的编写。相比于付费的 Firecrawl,它具有更快的爬取速度,支持同时抓取多个 URL、页面截图、关键字优化提取(基于 LLM)和复杂的多页面会话管理等功能。

    毕设Python春节电影信息爬取与可视化分析源码+项目说明+全部资料.zip

    毕设Python春节电影信息爬取与可视化分析源码+项目说明+全部资料.zip [资源说明] 1、该项目是团队成员近期最新开发,代码完整,资料齐全,含设计文档等 2、上传的项目源码经过严格测试,功能完善且能正常运行,请放心下载使用! 3、本项目适合计算机相关专业(人工智能、通信工程、自动化、电子信息、物联网等)的高校学生、教师、科研工作者、行业从业者下载使用,可借鉴学习,也可直接作为毕业设计、课程设计、作业、项目初期立项演示等,也适合小白学习进阶,遇到问题不懂就问,欢迎交流。 4、如果基础还行,可以在此代码基础上进行修改,以实现其他功能,也可直接用于毕设、课设、作业等。 5、不懂配置和运行,可远程教学 欢迎下载,学习使用!

    2019厦门国际银行数创金融杯源码+竞赛策略报告文档.zip

    2019厦门国际银行数创金融杯源码+竞赛策略报告文档.zip [资源说明] 1、该项目是团队成员近期最新开发,代码完整,资料齐全,含设计文档等 2、上传的项目源码经过严格测试,功能完善且能正常运行,请放心下载使用! 3、本项目适合计算机相关专业(人工智能、通信工程、自动化、电子信息、物联网等)的高校学生、教师、科研工作者、行业从业者下载使用,可借鉴学习,也可直接作为毕业设计、课程设计、作业、项目初期立项演示等,也适合小白学习进阶,遇到问题不懂就问,欢迎交流。 4、如果基础还行,可以在此代码基础上进行修改,以实现其他功能,也可直接用于毕设、课设、作业等。 5、不懂配置和运行,可远程教学 欢迎下载,学习使用!

    基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)

    基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业),个人经导师指导并认可通过的毕业设计项目,评审分98分,项目中的源码都是经过本地编译过可运行的,都经过严格调试,确保可以运行!主要针对计算机相关专业的正在做毕业设计的学生和需要项目实战练习的学习者,资源项目的难度比较适中,内容都是经过助教老师审定过的能够满足学习、使用需求,如果有需要的话可以放心下载使用。 基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开发的安卓的记事本app项目源码(高分期末大作业)基于Android Studio开

    基于java的小区智能卡管理系统设计与实现.docx

    基于java的小区智能卡管理系统设计与实现.docx

    NLP中文垃圾短信分类系统源码+设计全部资料+文档报告(自然语言处理课设).zip

    NLP中文垃圾短信分类系统源码+设计全部资料+文档报告(自然语言处理课设).zip [资源说明] 1、该项目是团队成员近期最新开发,代码完整,资料齐全,含设计文档等 2、上传的项目源码经过严格测试,功能完善且能正常运行,请放心下载使用! 3、本项目适合计算机相关专业(人工智能、通信工程、自动化、电子信息、物联网等)的高校学生、教师、科研工作者、行业从业者下载使用,可借鉴学习,也可直接作为毕业设计、课程设计、作业、项目初期立项演示等,也适合小白学习进阶,遇到问题不懂就问,欢迎交流。 4、如果基础还行,可以在此代码基础上进行修改,以实现其他功能,也可直接用于毕设、课设、作业等。 5、不懂配置和运行,可远程教学 欢迎下载,学习使用!

    电源滤波器车辆状态估计,扩展卡尔曼滤波EKF,无迹卡尔曼滤波UKF车辆状态估计,扩展卡尔曼滤波EKF,无迹卡尔曼滤波UKF 角阶跃输入+整车7自由度模型+UKF状态估计模型+附送EKF状态估计模型,针

    电源滤波器车辆状态估计,扩展卡尔曼滤波EKF,无迹卡尔曼滤波UKF车辆状态估计,扩展卡尔曼滤波EKF,无迹卡尔曼滤波UKF 角阶跃输入+整车7自由度模型+UKF状态估计模型+附送EKF状态估计模型,针对于轮毂电机分布式驱动车辆,进行车速,质心侧偏角,横摆角速度估计。 模型输入:方向盘转角delta,车辆纵向加速度ax 模型输出:横摆角速度wz,纵向车速vx,质心侧偏角β

Global site tag (gtag.js) - Google Analytics