Write ajax function to repetitively call cgi until success code is returned
$10-30 USD
Abgeschlossen
Veröffentlicht vor fast 8 Jahren
$10-30 USD
Bezahlt bei Lieferung
I need an ajax function that does the following:
- has 3 parameters: companies_id, subclient_id, span_name
- calls a cgi [login to view URL]
- if cgi returns 0,
replace image in span id=pdf_image2 with different image ([login to view URL]), and
waits/sleeps for 5 seconds then calls the [login to view URL] url again. this needs to loop, waiting 5 seconds each time, until a) get a non-zero response, or b) 2 minutes have elapsed
- if the cgi returns 1, replace the current span with a) an image, and b) a new link
image ([login to view URL]) and url ([login to view URL]), and
Base html:
<span id="pdf_image2"><input alt="Convertir a PDF" type="image"
src="[login to view URL]" width=10 height=11
onClick="javascript:gen_pdf(\'424\',\'63618202\',\'pdf_image2\')"></span>
Some crappy attempts i made to get this to work (with the html above inline):
[login to view URL]
notes:
needs to work in internet explorer 8 and greater, firefox, chrome
must have as minimal browser impact possible
must close every cgi session between 5 second calls...
I will encapsulate jQuery in anonymous namespace so that:
1> Widest browser support (as using jQuery)
2> Minimal browser impact: the jQuery was declared in an anonymous function and will not be visible to global JS environment.
Only the function you need (we can named as auo_pull(companies_id, subclient_id, span_name) ) is visible to global JS environment.
$25 USD in 1 Tag
0,0 (0 Bewertungen)
0,0
0,0
6 Freelancer bieten im Durchschnitt $29 USD für diesen Auftrag