How To Use SAJAX (AJAX Framework) from HTML 를 사용하는 방법에 sajax (ajax 프레임 워크)를 html
Sajax is an useful ajax framework to simplify ajax based development for languages like PHP, Ruby etc. Not many realize Sajax can be used equally well from plain old html pages (as in .html or .htm). ajax sajax가 유용합니다 ajax 기반 개발 프레임 워크를 단순화하기위한 언어처럼 php, 루비 등 sajax 많지 않습니다 실현에서 동일하게 사용할 수있습니다 평범하고 오래된 페이지 (예 :합니다. html 또는합니다. htm). Their website doesn’t mention it anywhere so I can guess it was not one of their use cases. 자신의 웹사이트 어디 볼 수 있도록 그것을 언급하지 않습니다 것 같네요 중 하나는 그들의 유스 케이스. However sajax is based upon ajax which is plain old Javascript. 그러나이 평범하고 오래된 sajax ajax는 자바 스크립트 기반으로합니다. Let’s find out how we can use trusty old sajax to liven up your static pages. 믿을 만함 찾아보자 오래된 sajax 사용할 수있는 방법이 귀하의 정적 페이지를 활기 차게합니다.
To use sajax from html you need to get the javascript code it generates and include it in your html pages. html을 사용해야합니다 sajax에서 자바 스크립트 코드를 생성하여 귀하의 페이지 안에 그것을 포함합니다.
Sajax doesn’t tell you how you can create a javascript file to include (in your html pages), thereby allowing you to call php (for example) function calls from client side javascript. sajax하지 않습니다 자바 스크립트 파일을 말씀을 포함하는 방법을 만들 수있습니다 (여러분의 페이지), 그것에 전화하실 수있습니다 php (예를 들어) 함수를 호출 클라이언트 측 자바 스크립트합니다. This can however be remedied with a simple call: 이것은 그러나 조치를 취했고,이있는 간단한 전화 번호 :
This generates the required javascript file (change filename to your liking). 이것을 생성에 필요한 자바 스크립트 파일 (파일 이름을 변경 당신의 마음에 드는). Include this file in your html pages and you are good to go. 귀하의 페이지에서이 파일을 포함하고 당신이 돼있다. Now you can call your exported php function from javascript. 지금 당신의 수출 php 기능을 자바 스크립트를 호출할 수있습니다. Remember to append the function names with x_ . 이 함수 이름을 잊지 말고 끝에 x_합니다.
How can you use it? 어떻게 사용됩니까?
Check my 체크 내 Annotated wordPress source code cross-reference 주석 wordpress 소스 코드를 크로스 - 레퍼런스 site for an example. 사이트에 대한 예입니다. Check out the sajax based commenting system. sajax 기반 코멘트 시스템을 확인하십시오.
PS. ps. As a side tip you should know sajax_init() function call is not required and can be eliminated with current versions of Sajax. 쪽 끝로서 당신이 알아야 할 sajax_init () 함수를 호출은 필요하지 않습니다과 현재 버전의 제거와 sajax 수있습니다. It does nothing. 그것은 아무것도합니다.
Filed under 밑에 CMS Software cms 소프트웨어를 , Headline News 헤드 라인 뉴스 , How To 하는 방법을 , Open Source Software 오픈 소스 소프트웨어 , PHP php , Pro Blogging 직업적인 블로깅 , Tech Note 기술 참고 사항 , Web 웹 , Web Services 웹 서비스 , WordPress wordpress | |
| |
RSS 2.0 rss 2.0 | |
Trackback 트랙백 this Article | 이 문서 |
Email this Article 전자 우편이 문서
You may also like to read 같은를 읽을 수있습니다 |




January 14th, 2007 at 3:55 am 1 월 14 일 오전 3시 55분
[...] There is a third and even simpler way to execute programs and display the results using AJAX. [...] 제 3도가 프로그램을 실행하고 표시하는 간단한 방법을 사용하여 그 결과 ajax합니다. You can use any popular AJAX framework like Sajax or Prototype to make calls to the server and then display the results dynamically. 어떤 인기있는 ajax 프레임 워크를 사용할 수있습니다 sajax이나 프로토 타입을 같이하고 다음을 표시하는 검색 결과를 서버로 전화를 동적으로합니다. This had the added advantage of being able to repeatedly update page contents. 이것이 추가된 이점이 페이지의 내용을 반복적으로 업데이 트합니다. [...]
September 9th, 2007 at 9:50 am 2007년 9월 9일에서 오전 9시 50분
Your site says “Remember to append the function names with x_.” In fact, in my experience the “x_” needs to be prepended, not appended. 귀하의 사이트는 "이름을 기억 x_의 기능을 추가합니다."사실, 내 경험은 "x_"해야합니다 전,되지 않습니다.