- Fórum WMO
- → Inu_yasha's Content
Inu_yasha's Content
There have been 263 items by Inu_yasha (Search limited from 20/04/2023)
#635164 Gerar Miniaturas
Posted by Inu_yasha on 06/09/2005, 14:31 in Artigos, Dicas e Tutoriais de PHP
se ela n esta no mesmo diretorio, poe:
diretorio/imagem.jpg
ok?
#601647 Papas Do Webmaster E Webdesign
Posted by Inu_yasha on 18/06/2005, 19:25 in Dúvidas Gerais
#622838 Validate_email()
Posted by Inu_yasha on 06/08/2005, 09:22 in Artigos, Dicas e Tutoriais de PHP
$nome = $_POST["nome"]; $email = $_POST["email"]; function validate_email( $email ) { return ( eregi( '^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'. '@'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+\.'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$', $email ) ); } $cadastrar = mysql_query("INSERT INTO news (nome, email) VALUES ('$nome', '$email')", $db); if($cadastrar) { echo "<script>window.alert('Email cadastrado com sucesso.'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; }
eu n consigo inserir isso:
<?php echo "Email " . (validate_email("guilhermeblanco@dominio.com.br") ? "válido" : "inválido"); ?>simplesmente não sei onde inserir. e nao entendi o q mais tem q modificar!
#622895 Validate_email()
Posted by Inu_yasha on 06/08/2005, 13:15 in Artigos, Dicas e Tutoriais de PHP
function validate_email( $email ) { return ( eregi( '^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'. '@'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+\.'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$', $email ) ); } $cadastrar = mysql_query("INSERT INTO news (nome, email) VALUES ('$nome', '$email')", $db); if($cadastrar) { echo "<script>window.alert('Email cadastrado com sucesso.'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; } else { echo "<script>window.alert('Houve um erro ao tentar cadastrar seu email. Tente novamente!'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; }ficaria assim:
function validate_email( $email ) { return ( eregi( '^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'. '@'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+\.'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$', $email ) ) { $cadastrar = mysql_query("INSERT INTO news (nome, email) VALUES ('$nome', '$email')", $db); if($cadastrar) { echo "<script>window.alert('Email cadastrado com sucesso.'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; } else { echo "<script>window.alert('Houve um erro ao tentar cadastrar seu email. Tente novamente!'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; } else { echo " email invalido"; }
??
#623008 Validate_email()
Posted by Inu_yasha on 06/08/2005, 22:42 in Artigos, Dicas e Tutoriais de PHP
<?php include "config.php"; $nome = $_POST["nome"]; $email = $_POST["email"]; $cadastrar = mysql_query("INSERT INTO news (nome, email) VALUES ('$nome', '$email')", $db); if(eregi( '^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'. '@'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+\.'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$', ($email)) { if($cadastrar) { echo "<script>window.alert('Email cadastrado com sucesso.'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; } else { echo "<script>window.alert('Houve um erro ao tentar cadastrar seu email. Tente novamente!'); </script>"; echo "<script>window.location = 'javascript:history.go(-1);'</script>"; } ?>so da erro.
Parse error: parse error, unexpected '{' in c:\appserv\www\news\upload\cad.php on line 14!
#623023 Validate_email()
Posted by Inu_yasha on 06/08/2005, 23:56 in Artigos, Dicas e Tutoriais de PHP
#623016 Validate_email()
Posted by Inu_yasha on 06/08/2005, 23:10 in Artigos, Dicas e Tutoriais de PHP
if(eregi( '^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'. '@'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+\.'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$', ($email)) { $cadastrar = mysql_query("INSERT INTO news (nome, email) VALUES ('$nome', '$email')", $db);
<?php include "config.php"; $nome = $_POST["nome"]; $email = $_POST["email"]; if(eregi( '^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'. '@'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+\.'. '[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$', ($email)) { $cadastrar = mysql_query("INSERT INTO news (nome, email) VALUES ('$nome', '$email')", $db); } if($email) { echo "<script>window.alert('Email cadastrado com sucesso.'); </script>"; echo "<script>window.location = 'java script:history.go(-1);'</script>"; } else { echo "<script>window.alert('Houve um erro ao tentar cadastrar seu email. Tente novamente!'); </script>"; echo "<script>window.location = 'java script:history.go(-1);'</script>"; } ?>
Parse error: parse error, unexpected '{' in c:\appserv\www\news\upload\cad.php on line 7!
mas porque isso? o q eu fiz de errado?
#621960 Sistema de Login - Iniciante
Posted by Inu_yasha on 03/08/2005, 21:24 in Artigos, Dicas e Tutoriais de PHP
sorte qe nom eh mod ake... zuera titia!
ake funcionou, estyou ate usando... mto bom...
#587356 Erro, Pq?
Posted by Inu_yasha on 21/05/2005, 16:30 in Apache
os erros do log:
[Sat May 21 11:17:28 2005] [error] [client 127.0.0.1] (2)No such file or directory: couldn't spawn child process: c:/appserv/www/be/index.cgi [Sat May 21 11:18:05 2005] [error] [client 127.0.0.1] Premature end of script headers: c:/appserv/www/be/index.cgi [Sat May 21 11:18:05 2005] [error] [client 127.0.0.1] Can't locate CGI.pm in @INC (@INC contains: .) at c:\appserv\www\be\index.cgi line 4. [Sat May 21 11:18:05 2005] [error] [client 127.0.0.1] BEGIN failed--compilation aborted at c:\appserv\www\be\index.cgi line 4. [Sat May 21 11:18:38 2005] [error] [client 127.0.0.1] Premature end of script headers: c:/appserv/www/be/index.cgi [Sat May 21 11:18:38 2005] [error] [client 127.0.0.1] Can't locate CGI.pm in @INC (@INC contains: .) at c:\appserv\www\be\index.cgi line 4. [Sat May 21 11:18:38 2005] [error] [client 127.0.0.1] BEGIN failed--compilation aborted at c:\appserv\www\be\index.cgi line 4. [Sat May 21 11:19:50 2005] [error] [client 127.0.0.1] attempt to invoke directory as script: c:/appserv/www/cgi-bin [Sat May 21 11:20:43 2005] [error] [client 127.0.0.1] attempt to invoke directory as script: c:/appserv/www/cgi-bin/be [Sat May 21 11:20:49 2005] [error] [client 127.0.0.1] Premature end of script headers: c:/appserv/www/cgi-bin/be/index.cgi [Sat May 21 11:20:49 2005] [error] [client 127.0.0.1] Can't locate CGI.pm in @INC (@INC contains: .) at c:\appserv\www\cgi-bin\be\index.cgi line 4. [Sat May 21 11:20:49 2005] [error] [client 127.0.0.1] BEGIN failed--compilation aborted at c:\appserv\www\cgi-bin\be\index.cgi line 4. [Sat May 21 11:20:53 2005] [error] [client 127.0.0.1] attempt to invoke directory as script: c:/appserv/www/cgi-bin/be [Sat May 21 11:24:31 2005] [error] [client 127.0.0.1] Premature end of script headers: c:/appserv/www/cgi-bin/blog/index.cgi [Sat May 21 11:24:31 2005] [error] [client 127.0.0.1] Can't locate CGI.pm in @INC (@INC contains: .) at c:\appserv\www\cgi-bin\blog\index.cgi line 3. [Sat May 21 11:24:31 2005] [error] [client 127.0.0.1] BEGIN failed--compilation aborted at c:\appserv\www\cgi-bin\blog\index.cgi line 3.Alguem ai sabe pq isso?:S
#587222 Erro, Pq?
Posted by Inu_yasha on 21/05/2005, 11:25 in Apache
mas eu fui testa um cgi e botei ele no diretorio cgi-bin...
http://localhost/cgi.../blog/index.cgi
acessei essa url
dai adivinha:
Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator, [no address given] and inform them of the time the error occurred, and anything you might have done that may have caused the error.
More information about this error may be available in the server error log.
--------------------------------------------------------------------------------
Apache/1.3.29 Server at localhost Port 80
trokei tb o user bin perl... pra esse e salvei: #!C:/perl/bin/perl
dai testei pondo esse: #!C:/perl/bin/perl -w
mas msm assim n deu
pq?
eu preciso desses sistemas AINDA HOJE...
e sao do http://cgiclube.cida...area=script-ghp .
#587736 Erro, Pq?
Posted by Inu_yasha on 22/05/2005, 14:55 in Apache
o daew fala isso:
----------------------------------------------------------------------------------
Instalando o Active Perl:
1. Clique duas vezes no arquivo: ActivePerl-5.6.1.635-MSWin32-x86.msi
2. Clique em next
3. Entao marque a opção: I accept the terms in the license Agreement, depois clique em next
4. Selecione a pasta que vai instalar o perl, conforme o dito a pasta recomendada eh c:\perl
5. Clique em next, Marque a opção: Enable PPM3 to send profile info to ASPN
6. Clique em next, next novamente e depois install
7. Agora eh so clickar em finish e se vc quer reiniciar o pc agora clique em yes, se quer reiniciar manualmente depois clique em no.
Depois que reiniciar o pc, iremos instalar algumas modules basicas q são alem de recomendadas muito uteis.
1. Va em c:\perl\bin, e execute o arquivo ppm.exe
2. Digite install DBI de enter, aperte y e de enter
3. Ele ira instalar a module sozinho.
4. Repita esse processo com as seguintes modules: CGI, LWP::Simple, DBD::mysql
5. Depois que terminar digite quit.
Prontinho o perl esta todo ok.
O perl eh o interpretador eh o que faz com q o cgi e o perl sejam executados via web.
#611480 [shoutcast] Detalhes Detalhados Da Rádio Hehe
Posted by Inu_yasha on 11/07/2005, 15:51 in Artigos, Dicas e Tutoriais de PHP
vlw pelo elogio
#599021 Visitantes E Usuarios Online
Posted by Inu_yasha on 14/06/2005, 13:52 in Artigos, Dicas e Tutoriais de PHP
http://forum.wmonlin...howtopic=113654 ?
#585289 Como Impedir...
Posted by Inu_yasha on 17/05/2005, 18:22 in Blogs & Flogs
Mas tipow, a unika maneira de evitar isso msm é usando FLASH.
Ele nao e facil d copiar
#609764 [shoutcast] Obtenha Alguns Dados Da Sua Rádio
Posted by Inu_yasha on 06/07/2005, 19:57 in Artigos, Dicas e Tutoriais de PHP
como resolver?
Musica atual:
nome da musika
keria assim:
Musica Atual: nomedamusica
nomedamusika = tipo, Pitty - Equalize
no meu codigo n tem mais br, mas fika um espaco... cmo tira ele? (c/ br no html, e no php n tem br)
- Fórum WMO
- → Inu_yasha's Content
- Privacy Policy
- Regras ·