Ir para conteúdo
Fórum Script Brasil

Henriko04

Membros
  • Total de itens

    5
  • Registro em

  • Última visita

Tudo que Henriko04 postou

  1. Bom dia pessoal, acho q tenho um pequeno problema, criei um banco de dados em mysql, bdeimobiliaria, onde em uma parte desse bd existem as tabelas pessoa, pessoa física e funcionário. Criei uma listener pra visualizar estes dados, chamada de listar_funcionarios, onde ele vai pegar todos os dados dessas 03 tabelas e eventualmente exibir numa tela de um projeto web de meu desenvolvimento. Mesmo dentro do banco ele não mostra nada nesta lista, e nas tabelas, já existem informações cadastradas. Alguém pode me dá uma dica? Vejam o Script da listar_funcionarios. CREATE ALGORITHM=UNDEFINED DEFINER=`root`@`localhost` SQL SECURITY DEFINER VIEW `listar_funcionarios` AS select `f`.`idFuncionario` AS `idFuncionario`,`f`.`senha` AS `senha`,`f`.`administrador` AS `administrador`,`p`.`idPessoa` AS `idPessoa`,`p`.`nome` AS `nome`,`p`.`telefone` AS `telefone`,`p`.`email` AS `email`,`pf`.`cpf` AS `cpf`,`pf`.`rg` AS `rg`,`pf`.`endereco` AS `endereco`,`pf`.`bairro` AS `bairro`,`pf`.`complemento` AS `complemento`,`pf`.`cidade` AS `cidade`,`pf`.`uf` AS `uf`,`pf`.`profissao` AS `profissao`,`pf`.`data_nasc` AS `data_nasc`,`pf`.`estado_civil` AS `estado_civil`,`pf`.`nome_pai` AS `nome_pai`,`pf`.`nome_mae` AS `nome_mae` from ((`funcionario` `f` join `pessoa` `p` on((`p`.`idPessoa` = `f`.`pessoa_Fisica_pessoa_idPessoa`))) join `pessoa_fisica` `pf` on((`pf`.`pessoa_idPessoa` = `p`.`idPessoa`))) where (`f`.`excluido` = 0) order by `p`.`nome`;
  2. Henriko04

    $nothing

    Agora caro amigo, lógico, se dentro do código eu declarar a varável $nothing, esse erro desaparecer, mais segundo o LIVRO a variável $nothing é avaliada com uma string vazia, que são variável não-inicializadas, acho que ve me entender The value of variable a is 5 Variable a after adding constant VALUE is 10 Multiplying variable a by 2 yields 20 Variable a is less than 50 Variable a after adding 40 is 60 Variable a is now between 50 and 100, inclusive Notice: Undefined variable: nothing in C:\xampp\htdocs\Projeto03\teste01.php on line 49 Using a variable before initializing: Notice: Undefined variable: num in C:\xampp\htdocs\Projeto03\teste01.php on line 52 An uninitialized variable plus constant VALUE yields 5 Adding a string to variable a yields 63
  3. Henriko04

    $nothing

    The value of variable a is 5 Variable a after adding constant VALUE is 10 Multiplying variable a by 2 yields 20 Variable a is less than 50 Variable a after adding 40 is 60 Variable a is now between 50 and 100, inclusive Notice: Undefined variable: nothing in C:\xampp\htdocs\Projeto03\teste01.php on line 49 Using a variable before initializing: Notice: Undefined variable: num in C:\xampp\htdocs\Projeto03\teste01.php on line 52 An uninitialized variable plus constant VALUE yields 5 Adding a string to variable a yields 63
  4. Henriko04

    $nothing

    Este é o código postado no LIVRO - Deitel para programadores WEB <?php print( '<?xml version = "1.0" encoding = "utf-8"?>' ) ?> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> <!-- Fig. 19.4: operators.php --> <!-- Using arithmetic operators. --> <html xmlns = "http://www.w3.org/1999/xhtml"> <head> <title>Using arithmetic operators</title> </head> <body> <?php $a = 5; print( "The value of variable a is $a <br />" ); // define constant VALUE define( "VALUE", 5 ); // add constant VALUE to variable $a $a = $a + VALUE; print( "Variable a after adding constant VALUE is $a <br />" ); // multiply variable $a by 2 $a *= 2; print( "Multiplying variable a by 2 yields $a <br />" ); // test if variable $a is less than 50 if ( $a < 50 ) print( "Variable a is less than 50 <br />" ); // add 40 to variable $a $a += 40; print( "Variable a after adding 40 is $a <br />" ); // test if variable $a is 50 or less if ( $a < 51 ) print( "Variable a is still 50 or less<br />" ); // test if variable $a is between 50 and 100, inclusive elseif ( $a < 101 ) print( "Variable a is now between 50 and 100, inclusive<br />" ); else print( "Variable a is now greater than 100 <br />" ); // print an uninitialized variable print( "Using a variable before initializing: $nothing <br />" ); // nothing evaluates to "" // add constant VALUE to an uninitialized variable $test = $num + VALUE; // num evaluates to 0 print( "An uninitialized variable plus constant VALUE yields $test <br />" ); // add a string to an integer $str = "3 dollars"; $a += $str; print( "Adding a string to variable a yields $a <br />" ); ?><!-- end PHP script --> </body> </html> <!-- ************************************************************************** * © Copyright 1992-2008 by Deitel & Associates, Inc. and * * Pearson Education, Inc. All Rights Reserved. * * * * DISCLAIMER: The authors and publisher of this book have used their * * best efforts in preparing the book. These efforts include the * * development, research, and testing of the theories and programs * * to determine their effectiveness. The authors and publisher make * * no warranty of any kind, expressed or implied, with regard to these * * programs or to the documentation contained in these books. The authors * * and publisher shall not be liable in any event for incidental or * * consequential damages in connection with, or arising out of, the * * furnishing, performance, or use of these programs. * ************************************************************************** -->
  5. Henriko04

    $nothing

    Bom dia galera, espero que me ajudem, sou novo em PHP, estudando por auto-didática, mas gostaria de saber se há a existência dessa variável que retorna uma string vazia: $nothing, estou vendo esse conteúdo por DEITEl para Programadores WEB, e em um de seus exemplos, essa variável é encontrada, ao rodar o aplicativo web, se esta variável que retorna uma string vazia não deveria mostrar nem um valor, lógico, mas o compilador da erro que a variável não foi declarada. Agradeço a ajuda de todos sobre está dúvida, já pesquisei sobre essa variável, mas ainda não encontrei resposta. Obg...
×
×
  • Criar Novo...