Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / New
Stats: 3,189,980 members, 7,938,942 topics. Date: Tuesday, 03 September 2024 at 03:20 PM

Ajax Help - Webmasters - Nairaland

Nairaland Forum / Science/Technology / Webmasters / Ajax Help (704 Views)

Form Validation Tutorial Using Javascript, Php And Ajax! / Create Ajax Chat & Learn Web Page Data Xchange via Json Vs Xml / Dynamic Web Design Tutorials Ft Javascript,Ajax,DOM,PHP,MySQL... (2) (3) (4)

(1) (Reply) (Go Down)

Ajax Help by robola: 9:25am On Jan 24, 2011
hello evryone, wld like to know how to test if my ajax application is working, any advice.
Re: Ajax Help by instinctg(m): 10:05am On Jan 25, 2011
maybe u should come out clearer. did u write it urself? if yes, then debug where d problem lies or paste d code for review. if no, then that may seem more complicated.
anyway, lets see d code for review
Re: Ajax Help by yawatide(f): 10:46am On Jan 25, 2011
insert alert statements all over your code to see if what it is returning is what you are expecting
Re: Ajax Help by Nobody: 1:12pm On Jan 25, 2011
na wa o. or get this ehm firephp - a google chrome mozilla firefox extension. it is the best i have seen to debug and test ajax stuffs.
Re: Ajax Help by yawatide(f): 1:26pm On Jan 25, 2011
and out of curiosity, what happens if the OP isn't coding with PHP?
Re: Ajax Help by Nobody: 10:24pm On Jan 25, 2011
yawa-ti-de:

and out of curiosity, what happens if the OP isn't coding with PHP?
He can use similar techniques to firePHP - namely - saving some form of output into a text-file - in a known location.
Similar to file_put_content - every programming language i know (about 15) - happen to have a way of saving some
form of output into text files - this helps in some kinda step-by-step manual debugging, so you know if a particular segment
of code has been called, and you can save the information into a text file - this is from the server side though.

However, if the aspect to be tested is within the client side (JS) - then the method of using Alert.show (similar to ur earlier suggestion)
will suffice.

However, if the backend language is PHP - my strongest recommendation will remain firePHP!
Re: Ajax Help by Nobody: 2:23am On Jan 26, 2011
he can use use console.log functions for wenkit browsers to log response from ajax but i doubt OP will be asking a uestion like this if he indeed coded it,cuz if u can code ajax u are as good as knowing how to test it
Re: Ajax Help by Nobody: 4:01am On Jan 26, 2011
exacta, if you code ajax then you should know how to test it even if it is the crude ways. . .then the question should be - what methods are best for testing.
Now, even from the question, i am not too sure if it is the frontend aspect (jscript) or the backend aspect (php/aspx/whatever) that he is having problems with testing.
Re: Ajax Help by robola: 9:08am On Jan 26, 2011
just started on ajax actually,coded it using php of course, bt even after putting my wamp online, d ajax part wont work.
so i thot i might not be doing something properly , tho d php part validates
Re: Ajax Help by yawatide(f): 1:21pm On Jan 26, 2011
Weeell, I would disagree somewhat with the assertion that because you code in a language means you should know how to debug it. I say this based on experience.

Now, not to hold brief for OP cos he could have just lifted the code somewhere without knowing how it works (just saying, not implying), but it is possible he means he has tried to debug it as best he can but isn't able to narrow down the problem undecided
Re: Ajax Help by Nobody: 9:16pm On Jan 26, 2011
These are the basic rules for testing Ajax Application, create your normal form without AJAX and if it works well,ur AJAX will work well also.thats the Simplest solution i can give you however note that you should set enctype on your form and u cannot upload images via Ajax.
Re: Ajax Help by Nobody: 9:29pm On Jan 26, 2011
yawa, i did not say, debug - i said test - i was quoting partly what the op said in the first post - that he does not know how to test it!

Anyway, i suspect from what the client said now that the problem is from the javascript part and not from the server end.

So, my OP, you can learn how to use firebug, the console.write or whatever that function is, can help you to see what's up with your
javascript.

Or better still, you might get one of us here to help you - you are in the midst of professionals here.
Re: Ajax Help by yawatide(f): 10:25pm On Jan 26, 2011
So from OP's perspective, since OP doesn't know how to test, isn't OP saying in essence that OP needs help with debugging?

I am getting ahead of myself and becoming more philosophical than I would want to. Ignore what I just wrote. Sorry grin
Re: Ajax Help by Nobody: 6:59am On Jan 27, 2011
cual es "philosophy"? sentimos pero vamos a ayudar senor poster. . .

(1) (Reply)

Website Review / New Socail Network Review / 3 Easy Steps Making Money From Google

(Go Up)

Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health
religion celebs tv-movies music-radio literature webmasters programming techmarket

Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10)

Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 16
Disclaimer: Every Nairaland member is solely responsible for anything that he/she posts or uploads on Nairaland.