New AJAX/PHP framework - My-BIC is LIGHT and TASTY!

February 19, 2006

After trying a bunch of bloated ajax frameworks I decided to write one that is lightweight and just takes care of the bare essentials to get things rolling. It supports XML, JSON, and TEXT formats.

http://litfuel.net/mybic

I'm looking for some volunteers to try it out and voice their opinions. The basic concept is:
one xmlhttp class that takes care of sending and receiving data and a php script on the server that acts as a front controller that all ajax requests go through.

2 lines of javascript and one php class are all you need to get an ajax setup going! So far it's for PHP5 however if there is interest in PHP4 I will create a quick version for that as well.

  1.  
  2. <script type="text/javascript" src="js/class_xmlhttp.js"></script>
  3.  
  4. <script>
  5.  
  6. var ajaxObj = new XMLHTTP("/ajax_server.php");
  7.  
  8. function postComment(comment) {
  9. ajaxObj.call("action=postComment&comment="+comment, ComResp);
  10.  
  11. }
  12.  
  13. function ComResp(resp) {
  14. if(resp) {
  15. document.getElementByID("status").innerHTML = resp;
  16. } else {
  17. // handle error here
  18. }
  19. }
  20.  
  21. </script>


thats all the javascript you need! you want xml? just add ajaxObj.format = "XML" before your call statement

I look forward to hearing back from you! Feel free to email me directly at jiminoc AT gmail.com



Comments

RSS feed for comments on this post.

  1. Eddie Peloke says:
    February 25, 2006 @ 17:23 — Reply

    Cool, just downloaded so will give it a shot.

  2. sarbogast says:
    March 3, 2006 @ 14:27 — Reply

    I just tried your hello world tutorial and I can't figure out why instead of the hello world message, I get "false"! (see http://tagspot.sourceforge.net/helloworld.html)

  3. blu ray ripper says:
    April 18, 2010 @ 06:37 — Reply

    Comment pending moderation

  4. 642-067 says:
    May 19, 2010 @ 00:37 — Reply

    Comment pending moderation

  5. virbram five fingers says:
    June 4, 2010 @ 23:38 — Reply

    Comment pending moderation

  6. LOUIS VUIttON Outlet says:
    June 9, 2010 @ 23:02 — Reply

    Comment pending moderation

  7. CT0-101 says:
    June 12, 2010 @ 18:10 — Reply

    Comment pending moderation

  8. evening dresses says:
    June 18, 2010 @ 09:04 — Reply

    Comment pending moderation

  9. replica watches says:
    June 22, 2010 @ 02:26 — Reply

    Comment pending moderation

Leave a Comment

Line and paragraph breaks automatic, HTML allowed: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <code> <em> <i> <strike> <strong>

Comments disabled due to spammers being losers that lead sad lives.