Jump to content

voip03

Members
  • Posts

    693
  • Joined

  • Last visited

Everything posted by voip03

  1. If you google it 'php date format' you will get the answer.
  2. You need tp put space between <? php and $result <? $result = mysql_query("SELECT * FROM opi order by row desc");
  3. voip03

    onclick

    ManiacDan ! which part is look like text to you?
  4. voip03

    onclick

    When I am writing a story; I would do that! Thank u ManiacDan .
  5. is it good practices to have admin table
  6. voip03

    onclick

    onclick can I call serverside code?
  7. voip03

    onclick

    Before onclick the function call() is calling ? Why TIA <? session_start(); require("config.php"); //LOGGED IN ID VALIDATION - Only registered user Access ! if(isset($_SESSION['SESS_LOGGEDIN'])== FALSE) { header("Location:".$config_basedir."login.php?error=2767"); } ?> <script type="text/javascript" > function downloadPdf(el) { var iframe = document.createElement("iframe"); iframe.src = "download/itil.zip"; iframe.onload = function() { // iframe has finished loading, download has started el.innerHTML = "Download"; } iframe.style.display = "none"; document.body.appendChild(iframe); } </script> <? function call() { //get ip address... if(!empty($_SERVER['HTTP_CLIENT_IP'])) { // share internet $ip=$_SERVER['HTTP_CLIENT_IP']; $ip .= "/S"; } elseif(!empty($_SERVER['HTTP_X_FORWARDED_FOR'])) { // pass from proxy $ip=$_SERVER['HTTP_X_FORWARDED_FOR']; $ip .= "/P"; } else { $ip=$_SERVER['REMOTE_ADDR']; $ip .= "/O"; } $sql = "INSERT INTO downloadUserIP( date, userID, ProductID,IP ) VALUES ( NOW(),'".$_SESSION['SESS_USERID']."','".$a."','".$ip."');"; $res = mysql_query($sql); if(!$res) { die(" Could not query the database customers 24 : <br/>". mysql_error() ); } $_SESSION['SESS_GUEST_IP'] = mysql_insert_id(); echo "ok"; } ?> <br/> <a href="download/ECDL.zip" onclick="this.innerHTML='<? call(); ?>'; downloadPdf(this);">Download</a>
  8. Just want to try with jq that all.
  9. Faq/Code Snippet board ? can u post the link pl.
  10. http://www.phpfreaks.com/forums/index.php?topic=339907.msg1602474#msg1602474
  11. I am trying using ‘js’ but can tell me any better way.
  12. <a href='download/downlaod.zip"'> [ Download ] </a> When use click the download link download box will appear. Before the download box I want to get the user id.
  13. echo "<td><a href='download/".$dlrow['link']."'> [ Download ] </a> </td>"; when user click the download link , I want to process 1. Capture the user id 2. Start download file Can anyone advice me TIA
  14. then use header("Location:".$config_basedir."page.php?variable1=value&variable1=".$value2);
  15. When using HTML forms you can set the form method parameter to either "GET" (default) or "POST". So, which one to use? When working with GET method you can access all form variables with the $_GET array in PHP and when using POST you can access the variables using $_POST No matter which method used you can also access all variables using $_REQUEST array. When using GET all the submitted information is displayed in the address bar as part of the URL. You will see that as information shown after ? (called a query string), something like: http://domain.com/script.php?name1=value1&name2=value2 This can be useful for example where you want to be able to bookmark a page with specific query string values. However, the GET method is limited by the length of the URL (2083 characters in Internet Explorer according to Microsoft) and each of the input values must not exceed 100 chars. Obviously you also don't want to use GET when submitting sensitive information like passwords or credit card details as they would show up in the address bar. The POST method can send a lot of data (usually limited by the server settings) and should be used for every form unless the specific application benefits from the query string in the URL when using GET. No submitted data is shown in the address bar so most browser cannot correctly bookmark pages shown after a HTTP POST method. There you have it. Unless you need the query string that you get when using the GET method (and aren't effected by it's limits) you should use POST for your forms. If you are submitting any sensitive information that should not be displayed in the address bar the only way to go is with the POST method. http://www.tizag.com/phpT/postget.php
  16. http://php.net/manual/en/function.header.php google it ' rediretc'
  17. <? $config_basedir="http://address/"; $value2 = $_GET['some value from post']; header("Location:".$config_basedir."page.php?variable1=value&variable1=".$value2); ?>
  18. are u trying to redirect one page to new page. or display the result on a same page
  19. http://www.crosscode.co.uk/php/why-using-isset-post-submit-is-not-compatible-with-internet-explorer/
×
×
  • 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.