Jump to content

priti

Members
  • Posts

    461
  • Joined

  • Last visited

Posts posted by priti

  1. javascript solution would be somethinglike this....

     

    <input type="text" name="total" value="10"> -<input type="text" name="discount" value="10" onChange="calculateBillamoutn(this.form)">=<input type="text" name="billAmount" value="">

     

    in javascript

     

    function calculateBillamoutn(frm)

    {

    var price=frm.total.value;

    var discout=frm.discount.value;

     

    frm.billAmount.value=price-disocunt;

     

    }

     

     

  2. to stop spamming we use captach to make sure the user is a human not a computer program. Next, what if someone doing it intentionaly then i have seen on certain form they pass a hidden variable to server to identify the client.

     

    secondly you can create a block_list_array={'aaaa','xxxx','ssss','tyyy'} and when you submit you form just check the content with this list to stop spam.

     

    you can set off some time between two sucessive submission of form which you might be able to see on different leading forums too.

     

    ... there are many a way to stop spam.

  3. Hi,

     

    Near

     

    </select></td>

      <td> </td>---- create a div with style hidden

     

    and on dropdown of status and its event onchange create a js function which checks wether it is status=='Rejected' then show you div and do something like

    div.innerHTML='<input type="comment" value="your message">';

     

    so when you will submi tyour form you will be able to read this comment text box.

     

    hope it help you !!

     

  4. There could be n reason for it without knowing what you are trying to do how one can help you in this.Guess could be ...... you might have used die,exists in your code. or you content is too big to get in to one page so it hangs ....

     

    once you will tell us what hte problem people here will help you more.

     

    regards

  5. dear i am gal :-)

     

    Next

     

    $page = $_GET['page'];

    mysql_query ("SELECT * FROM `Main__title` WHERE Name = '$title'") or die (mysql_error());

     

    query if correct but where is the more part you need to do

    $result=mysql_query(query); //it return the resultset resource type

    $row=mysql_fetch_row($result); //return array

     

    // you can do print_r($row) to check what result you got

    now

    $page=$row[0]; //you need to check your index

     

    now you are ready with your page to include

     

    hope it help you to sail further....

     

     

     

  6. yes you can use session to identify when you want to delete the files i.e when user has finally done with his work .It is something like your Logout facility ....

     

    so on logout you can find that user is pretending to leave the page so you can destroy session my unset($_SESSION) or session_destroy().

     

    before this you can clean up those text file too.

     

  7. simple fetch the data from database based on the page

    i.e

     

    url?page=default

     

    $page=$_GET['page'];

     

    //now query your table with this

     

    something like

    select include_link from tabl_name where page="$page"

     

    then you can use include_link as you are doing in the coding.Make it more robust i have just outline what needs to be done in order to achieve your goal.

     

    happy coding!!

  8. create a table

     

    page_details

     

    title              link

    default          include/default.txt

    more            include/more.txt

     

    store like this then make queries to fetch according to $_GET['page'] from db.

     

    Regards

     

     

  9. well you really don't need a ajax request simple js will also work fine

     

    if(document.getElementById('sel1').value != '')

    document.getElementById('text').innerHTML=document.getElementById('sel1').value

    if(document.getElementById('sel1').value != '')

    document.getElementById('text').innerHTML= document.getElementById('text').innerHTML+ document.getElementById('sel1').value

     

    something like this if kept properly can help you .

     

  10. many thanks priti,

    it gives the result  like

    ------------------------------------------

    sum                         |     Date

    ------------------------------------------

    1000                        |     15-2-2008

    800                          |     16-2-2008

     

     

    Now, can i get the date as field like

     

    ------------------------------------------

    2008-2-15                |     2008-2-16

    ------------------------------------------

    1000                        |     800

     

     

     

    is it possible?

     

     

     

     

    With mysql query i am not aware but you can get this in PHP reusltset and can easily handle the the way you want to show your results.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.