Jump to content

ryanlwh

Staff Alumni
  • Posts

    511
  • Joined

  • Last visited

    Never

Everything posted by ryanlwh

  1. hmm i guess you're talking about 'include' or 'file_get_contents' make sure you strip away the header codes... it probably will output correctly, but sometimes you might get unexpected results.
  2. Try google Javascript Rich Text Editors or Javascript WYSIWYG editors. You should get a lot of choices. EDIT: freakus_maximus, nice find!
  3. also check out basename() to use with PHP_SELF and such
  4. sometimes the browser will not give you the correct value of a GET variable if it contains url special characters (examples: "/" ,"&"). but if you use urlencode or rawurlencode, then these special chars will be changed into escape codes that the browser understands... sort of like the backslashes for browsers address bar
  5. while you can't possibly set a variabe within the same script from javascript, you can, however, use AJAX or set a cookie with javascript. but i haven't seen any javacript code to listen to file download dialogs, and if you output the javascript in this same script, it will be treated as the text content of the file... maybe use frames. as far as i know, jsp might be able to sniff packets :)
  6. because of the "attachement", it opens a popup without trying to open the download page in the browser
  7. try [code]<a href="?pg=login&redir=<? echo rawurlencode('http://my.server.domain/?pg=page_you_are_on') ?>">login</a>[/code]
  8. wildteen, should be [code]$num = sprintf("%05d", $num);[/code]
  9. [quote author=spires link=topic=104660.msg417596#msg417596 date=1155842498] Just tryed it, it  only plays the track. It dont download it. [/quote] It downloads to the temp folder on your computer and plays it immediately with your default player. So technically you've "downloaded" it, just without the prompt. If you want to "force" download then use the php header method, and you need to print/echo the file to screen after the headers, so that user will get the data.
  10. try $_GET instead of $HTTP_GET_VARS
  11. the limit from php.ini wouldn't give you "This page cannot be displayed".. Have you tried it in Firefox? What's your version of apache? I'd also recommend you to use the array notation for hte files [code]<input type="file" name="uploadedfile[]">[/code] [code] for($i=0;$i<=29;$i++) {   if(move_uploaded_file($_FILES['uploadedfile'][$i]['tmp_name'].$target_path[$i]))   {       ...   }   ... }[/code]
  12. have you forgotten to pass $precio after the page is reloaded??
  13. have you tried 20 small files (a total of less than 1M)?? if you can successfully upload these small files, then it's probably a setting in apache that caused the problem.
  14. [code]SELECT * FROM table WHERE date=CURDATE()[/code]
  15. mysql_fetch_row if you want to use numeric index
  16. oh, why do you have value in the <select> tag?
  17. if you name your selection boxes like this: [code]echo "<select name=\"p[" . $period . "]\" value=\"3\">";[/code] Then you can reduce the first line of the processing to: [code]$p_array = $_POST['p'];[/code]
  18. i think you have something in header2.php that overrid $title
  19. missing a closing ): [code]if(!preg_match( '/^[A-Z0-9._-]+@[A-Z0-9][A-Z0-9.-]{0,61}[A-Z0-9]\.[A-Z.]{2,6}$/i' , $field_name_1)) {   .... }[/code]
  20. remove the first mysql_fetch_assoc right after mysql_query. that one is advancing the row pointer by one.
  21. you still have A-z in your second and third character class. [code]<?php preg_match('/^[a-zA-Z0-9\._\-]+@[a-zA-Z0-9_\-]+(\.[a-zA-Z0-9\_\-]+)+[a-zA-Z]{2,4}$/',$field_name_1) [/code]
×
×
  • 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.