On Fri, Mar 27, 2015 at 06:00:28PM -0300, Release Edl wrote: > Sorry, Jim, about the thread. > > About the script your help was really nice. This warning disapear. I have > others, though... > > I'll try to open my own thread now. > > Thanks a lot. Remember that a WARNING would not, generally, cause a script to stop functioning, per se. If execution stops, you should see a "Fatal: " error. Kevin Kinsey > > "Jim Lucas" <lists@xxxxxxxxx> escreveu na mensagem > news:5515AB32.30406@xxxxxxxxx... > > On 03/27/2015 11:54 AM, Release Edl wrote: > >> My file uploader doesn't work since I update the php verdion. One notice > >> I > >> found was "Use of undefined constant tmp_name" and others.... > > > > First, please do not hijack someone's thread. Please start your own. > > > >> > >> A piece of the problem script: > >> > >> $url = $_FILES['url']; > >> if(file_exists("Imagem1/$url[name]")) { > >> $url2 = $url_name."1"; > >> } else { > >> $url2 = $url_name; > >> } > >> if(!copy($url[tmp_name], "Imagem1/$url2")) { > >> } > >> $urlf = $root."Imagem1/$url2"; > >> > >> Thanks in advance for some help. > >> > > > > The notice was probably hidden by your previous configuration. With the > > update of PHP the notice is now displayed. > > > > PHP thinks you are trying to us a constant, when you are actually trying > > to use a string. Surround tmp_name with single quotes and your warning > > will disappear. > > > > > > -- > > Jim Lucas > > > > http://www.cmsws.com/ > > http://www.cmsws.com/examples/ > > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php