Jump to content

sungpeng

Members
  • Posts

    290
  • Joined

  • Last visited

Posts posted by sungpeng

  1.  

     

    Address: 351 Hougang Ave 3 (769057) 
    Contact No: 6752 5513 
    Operating Hours: 8.00am - 9.30pm (Thursday to Tuesday & Public Holidays)
    Background: Opened to the public on 30 Mar 88

     

    Hi good day, if I paste the above address into one of the mysql field, I found out that I cannot fetch it using php. It give me a blank page.

     

    Address: 351 Hougang Ave 3 (769057) Contact No: 6752 5513 Operating Hours: 8.00am - 9.30pm (Thursday to Tuesday & Public Holidays) Background: Opened to the public on 30 Mar 88

     

    When I sort it together then i can see mysql working, very strange.. Can anyone help?

     

     

  2.  'Reply-To: sun@hotmail.com' . "\r\n" . 
    'X-Mailer: PHP/' . phpversion();
    mail($to, $subject, $message, $headers);

     

    The above code sent a message to inbox not junk mail.. but the result is as follow..

     

    From:	 server@hostingserver.com
    Sent:	 03 July 2010 20: 13PM
    To:	sungpeng@hotmail.com
    

     

    The "FROM" is not "sun@hotmail.com" instead it is "server@hostingserver.com".. can I know is there any solution to it?

  3. <?php 
    include "config.php"; 
    
    $code="<form action='https://www.paypal.com/cgi-bin/webscr' method='post'>
    <input type='hidden' name='cmd' value='_s-xclick'>
    <input type='hidden' name='hosted_button_id' value='KC2XXFRYLSBF6'>
    <input type='image' src='https://www.paypal.com/en_GB/SG/i/btn/btn_buynowCC_LG.gif' border='0' name='submit' alt='PayPal - The safer, easier way to pay online.'>
    <img alt='' border='0' src='https://www.paypal.com/en_GB/i/scr/pixel.gif' width='1' height='1'>
    </form>
    ";
    
    echo "$code";
    
    mysql_query("INSERT INTO paybutton (code)
    VALUES ('$code')")or die(mysql_error());   
      
    ?>

     

    I have an error "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'https://www.paypal.com/cgi-bin/webscr' method='post'> "

     

    I don't know what went wrong. Can anyone help?

  4. <?php

     

    if($_POST[action]=="submit")

    {

    $insert_student=mysql_query("UPDATE login SET credit = credit - 1");

     

    $_POST[action] = NULL;

    unset($_POST[action]);

    }

    ?>

     

    <HTML>

    <body>

     

    <form name="form" action="<?php print $PHP_SELF ?>" method="post">               

    <input type="submit" name="action" value="submit">

    </form>

     

    </BODY>

    </HTML>

     

    Good day, Check when i click on the submit button, it will execute "UPDATE credit". Then when i click on the refresh button, it will execute "UPDATE credit" again. I need to destroy the _POST[action]==submit so that when I click on refresh button it will not execute the "UPDATE credit".. pls help.. I tried the whole day still cannot work

     

     

  5. <meta http-equiv="content-type" content="text/html; charset=UTF-8"/></meta>

     

    Have anyone use UTF-8 for google API map? If you put UTF-8 on the header section, the height="80" will be double to height="160" for internet explorer 6, why is that so?

     

    Second question is can I use together both

    <meta http-equiv="content-type" content="text/html; charset=UTF-8"/></meta>

    <meta http-equiv="content-type" content="text/html; charset=gbk"/></meta>

    ?

     

     

  6. $result = mysql_query("SELECT * FROM track" ) or die ("Query failed");
    
    echo "<?xml version=\"1.0\"?>\n"; 
    echo "<products>\n"; 
    
    while($row = mysql_fetch_array($result)){
    echo "<item>".$row[name]."</item>\n";
    
         }
    
    
    echo "</products>\n";

    test21.php

     

    theXML.load("http://www.test.com/test21.php");
    theXML.ignoreWhite=true;
    nameArray = Array($row[name]);

    in flash

    Pls help, I need the "Array($row[name]);" to be flash nameArray=Array("firstname","secondname","thirdname",etc);

     

  7. date_default_timezone_set('Asia/Singapore');
    $time=date('D,F j, Y, H:i:s A');
    $insert_student=mysql_query("insert into listings (listdate) values ('$time')");
    

    The setting for "listdate" field is datetime.

    Can I know how what should I input "default" in mysql?

     

    $time=date('D,F j, Y, H:i:s A');

    Check also how to make it 24 hours. I find it difficult to insert into mysql the PM & AM if listdate setting is datetime default is 0000-00-00 00:00:00

×
×
  • 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.