+/- assim:
$i = 0; while () { if ($i % 5 == 0) echo '<br />'; // seu codigo $i++; }
[]'s
PS: Meu nome e RenaN e estou sem MSN no pc veio da minha mae em minas.
There have been 97 items by Renan Gonçalves (Search limited from 15/05/2023)
Posted by Renan Gonçalves on 29/04/2007, 16:06 in PHP
$i = 0; while () { if ($i % 5 == 0) echo '<br />'; // seu codigo $i++; }
Posted by Renan Gonçalves on 17/08/2007, 10:34 in Java/JSP
Posted by Renan Gonçalves on 20/06/2007, 08:52 in Ajax
<input type="text" name="login" id="login" class="form" onkeyup="if (this.value.length >= 6) { startRequest(); }" />
Posted by Renan Gonçalves on 30/04/2007, 09:48 in PHP
[espaco]<?php setcookie(); ?>Retorna um erro, porque algo foi mandado para o browser antes de setar o cookie.
Posted by Renan Gonçalves on 18/06/2007, 15:51 in Ajax
eval("function mostra_alert() { alert('Aqui dentro do eval entraria o conteudo carregado'); }"); mostra_alert();
Posted by Renan Gonçalves on 12/09/2007, 19:48 in PHP
$id = addslashes(htmlentities($_POST['id']));
foreach($id as $c) {
mysql_query("DELETE FROM noticias WHERE noticia_id = '".$c."'") or die(mysql_error());
}
$id = $_POST['id']; foreach($id as $c) { $c = addslashes(htmlentities($c)); mysql_query("DELETE FROM noticias WHERE noticia_id = '".$c."'") or die(mysql_error()); }
Posted by Renan Gonçalves on 21/06/2007, 17:34 in Teoria de Programação
Posted by Renan Gonçalves on 11/09/2007, 23:33 in Java/JSP
Posted by Renan Gonçalves on 21/08/2007, 08:35 in Java/JSP
Opa, claro que é bolha !Ih cara.. isso aí não é Bolha não.. nem sei o que você fez, tá bem confuso..
Posted by Renan Gonçalves on 07/09/2007, 16:28 in Dúvidas Gerais
Posted by Renan Gonçalves on 07/07/2007, 10:07 in PHP
Posted by Renan Gonçalves on 11/07/2007, 00:52 in PHP
Discordo !Não se vicie muito no foreach, ele é bom, mas nada substitue um bom while ou um for
<?php // Algum erro ? error_reporting(E_ALL); // Construindo um array $array = array('chave' => 'valor', 'outra_chave' => 'mais um valor', 'ainda outro'); // Usando FOR echo 'Usando FOR:<br />'; $chaves = array_keys($array); for ($i = 0; $i < count($chaves); $i++) { // Pegando valor $valor = $array[ $chaves[$i] ]; printf('%d => %s => %s<br />', $i, $chaves[$i], $valor); } // Usando FOREACH echo '<br />Usando FOREACH:<br />'; foreach ($array as $chave => $valor) { printf('%s => %s<br />', $chave, $valor); } // Usando WHILE echo '<br />Usando WHILE:<br />'; $chaves = array_keys($array); $i = 0; while (isset($chaves[$i])) { printf('%d => %s => %s<br />', $i, $chaves[$i], $valor); $i++; }
Posted by Renan Gonçalves on 18/06/2007, 10:08 in Java/JSP
Posted by Renan Gonçalves on 06/09/2007, 17:30 in Artigos, Dicas e Tutoriais de PHP
$totalCaracteres=strlen($caracteres) - 1;
Posted by Renan Gonçalves on 02/12/2007, 22:11 in Teoria de Programação
$usuario = new Usuario(); $usuario->blablabla... $usuario->save();
$usuario = new Usuario(); $usuario->blablabla... $usuarioDAO = new UsuarioDAO(); $usuarioDAO->create($usuario);
Posted by Renan Gonçalves on 03/12/2007, 08:12 in Teoria de Programação
Posted by Renan Gonçalves on 20/05/2007, 15:10 in ASP.NET
Posted by Renan Gonçalves on 15/10/2007, 10:17 in Distribuições Linux
Posted by Renan Gonçalves on 17/09/2007, 14:49 in PHP
Posted by Renan Gonçalves on 17/09/2007, 13:43 in PHP
$query = parse_url($url, PHP_URL_QUERY);
(^q=|&q=)([^&]+)
<?php $url = 'http://www.google.com.br/search?source=ig&hl=pt-BR&q=WebMasters+Online&btnG=Pesquisa+Google&meta='; ereg('(^q=|&q=)([^&]+)', parse_url($url, PHP_URL_QUERY), $query); $word = urldecode($query[2]); echo $word; ?>
<?php $url = 'http://www.google.com.br/search?source=ig&hl=pt-BR&q=WebMasters+Online&btnG=Pesquisa+Google&meta='; $params = parse_str(parse_url($url, PHP_URL_QUERY)); print_r($params); ?>
Posted by Renan Gonçalves on 17/09/2007, 11:29 in PHP
foreach ($array as $chave => $valor) { echo $chave . ' => ' . $valor . '<br />'; }
Posted by Renan Gonçalves on 03/05/2007, 22:01 in PHP
foreach ($contas as $nome => $conta) { list($dominio, $plano, $owner) = $conta; }
Posted by Renan Gonçalves on 17/08/2007, 09:32 in PHP
$search = array( '[', ']', '=>', 'Array', "\n", "\t", "\r" );
Posted by Renan Gonçalves on 12/09/2007, 15:45 in PHP
q=WMonline
Posted by Renan Gonçalves on 13/09/2007, 08:57 in PHP
..... [HTTP_CONNECTION] => keep-alive [HTTP_REFERER] => http://192.168.0.1/projetos/scripts/testes/?q=Renanzinho%20homenzarrao [HTTP_COOKIE] => __utmz=224789850.1188240478.1.1.utmccn=(direct)|utmcsr=(direct)|utmcmd=(none); __utma=224789850.566357810.1188240478.1189629603.1189634259.6 ....
http://192.168.0.1/projetos/scripts/testes/?q=Renanzinho%20homenzarrao
Community Forum Software by IP.Board
Licensed to: Webmasters Online