www.webdeveloper.com
Results 1 to 3 of 3

Thread: Javascript / PHP call

Hybrid View

  1. #1
    Join Date
    Aug 2009
    Posts
    3

    Javascript / PHP call

    I'm trying to call a javascript function using ajax for logging searchs made within my search engine.
    Previously, I do that in the same tima as the search query, but it incredibly slow down query..

    Then this is my code... basic one.. But if you have any other idea for speeding up my initial request ;-)

    Thansk !!!

    Mg

    Code:
    <script type="text/javascript">
    function WriteLogNow(){
    	alert"";
    getdata('/inc/scripts/logwritter/logwritter.php?lang=fr-BE&amp;searchstring=fze&amp;searchtype=simple&amp;resultscount=0&amp;resultscount=0&amp;queryduration=9.0122222900391E-5','logresult',&lt;div class=ajaxloader&gt;&lt;img src=/res/ani/ajaxloader_8cells_grey.gif&gt;&lt;/div&gt;);
    }
    </script>
    
    <input name="" type="button" onclick="WriteLogNow();" value="WriteLogNow()">

  2. #2
    Join Date
    Aug 2009
    Posts
    3
    Correct code here.

    Sorry.

    Code:
    <script type="text/javascript">
    function WriteLogNow(){
    getdata('/inc/scripts/logwritter/logwritter.php?lang=fr-BE&amp;searchstring=fze&amp;searchtype=simple&amp;resultscount=0&amp;resultscount=0&amp;queryduration=9.0122222900391E-5','logresult',&lt;div class=ajaxloader&gt;&lt;img src=/res/ani/ajaxloader_8cells_grey.gif&gt;&lt;/div&gt;);
    }
    </script>
    
    <input name="" type="button" onclick="WriteLogNow();" value="WriteLogNow()">

  3. #3
    Join Date
    Aug 2009
    Posts
    3
    When i execute, i receive from firefox:

    Code:
    WriteLogNow() is not defined

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles