Nielsie schreef:En kan je ook zeggen hoe ik dat nu gebruik?AfbeeldingEerdere citaten tonen
Sanderc schreef:Hoe doe ik dit? Met javascript?var string = "Hallo"; var max = 240; var over = max - string.length;
Want ik kan echt 0% van javascript

Nielsie schreef:En kan je ook zeggen hoe ik dat nu gebruik?AfbeeldingEerdere citaten tonen
Sanderc schreef:Hoe doe ik dit? Met javascript?var string = "Hallo"; var max = 240; var over = max - string.length;


$(document).ready(function() {
var start = 240;
var countdownid = "countdown";
$("#" + countdownid).html(start + " tekens resterend");
$("#idvanjetekstbox").keypress(function() {
var val = $(this).val();
var length = val.length;
$("#" + countdownid).html((start - length) + " tekens resterend");
});
}); Bartw schreef:Vraag je school om de App te financieren.Is het raar als ik in mijn rooster app advertenties zet?
Bartw schreef:(Sorry, even geen uitlijning), miss kan je zelf doen dat je niet verder kan typen als het minder dan 0 is.@Sanderc$(document).ready(function() { var start = 240; var countdownid = "countdown"; $("#" + countdownid).html(start + " tekens resterend"); $("#idvanjetekstbox").keypress(function() { var val = $(this).val(); var length = val.length; $("#" + countdownid).html((start - length) + " tekens resterend"); }); });
Sanderc schreef:En hoe gebruik ik dit in de HTML?Eerdere citaten tonen
Bartw schreef:$(document).ready(function() { var start = 240; var countdownid = "countdown"; $("#" + countdownid).html(start + " tekens resterend"); $("#idvanjetekstbox").keypress(function() { var val = $(this).val(); var length = val.length; $("#" + countdownid).html((start - length) + " tekens resterend"); }); });
(Sorry, even geen uitlijning), miss kan je zelf doen dat je niet verder kan typen als het minder dan 0 is.
<input id="idvanjetekstbox"><br>
<div id="countdown"></div> Riick schreef:Iemand?Hoi,
kan iemand mij helpen met glybe?
Mijn glybe script laat geen forum categorieen enzo zien terwijl ik deze wel heb gemaakt in phpmyadmin.
Ook kan ik mezelf geen admin maken, ik heb mezelf wel rang 20 gegeven (full admin).
Demo: www.lastpray.nl naam: demo wachtwoord: demo123

Luukieboy schreef:Wat wil je precies zien? welke row?Laat je db eens zien
Sanderc schreef:En hoe gebruik ik dit in de HTML?Eerdere citaten tonen
Bartw schreef:$(document).ready(function() { var start = 240; var countdownid = "countdown"; $("#" + countdownid).html(start + " tekens resterend"); $("#idvanjetekstbox").keypress(function() { var val = $(this).val(); var length = val.length; $("#" + countdownid).html((start - length) + " tekens resterend"); }); });
(Sorry, even geen uitlijning), miss kan je zelf doen dat je niet verder kan typen als het minder dan 0 is.
Nielsjojo schreef:Die notices komen omdat de variable nog niet bestaat.
Dat kun je oplossen met isset
[COLOR= #0000BB]<?php[/COLOR]
[URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]]) ||[/COLOR] [URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]wachtwoord[/COLOR][COLOR= #007700]])) {[/COLOR]
[COLOR= #0000BB]$naam[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]];[/COLOR]
[COLOR= #0000BB]$wachtwoord[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]wachtwoord[/COLOR][COLOR= #007700]];[/COLOR]
[COLOR= #0000BB]$aQuery[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT id, naam, wachtwoord, status FROM leden WHERE
naam = "[/COLOR][COLOR= #007700].[/COLOR][URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR]htmlentities[COLOR= #007700]([/COLOR][COLOR= #0000BB]$naam[/COLOR][COLOR= #007700])).[/COLOR][COLOR= #DD0000]" AND
wachtwoord = "[/COLOR][COLOR= #007700].[/COLOR][URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/md5"]md5[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$wachtwoord[/COLOR][COLOR= #007700])).[/COLOR][COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR]
[COLOR= #0000BB]$aFetch[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_assoc"]mysql_fetch_assoc[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$aQuery[/COLOR][COLOR= #007700]);
}[/COLOR]
?> Aarclay schreef:Waarom mysql_real_escape_string) over een md5()?Dat kun je oplossen met issetEerdere citaten tonen
Nielsjojo schreef:Die notices komen omdat de variable nog niet bestaat.[COLOR= #0000BB]<?php[/COLOR] [URL="http://www.php.net/if"]if[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]]) ||[/COLOR] [URL="http://www.php.net/isset"]isset[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]wachtwoord[/COLOR][COLOR= #007700]])) {[/COLOR] [COLOR= #0000BB]$naam[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]naam[/COLOR][COLOR= #007700]];[/COLOR] [COLOR= #0000BB]$wachtwoord[/COLOR] [COLOR= #007700]=[/COLOR] [COLOR= #0000BB]$_POST[/COLOR][COLOR= #007700][[/COLOR][COLOR= #DD0000]wachtwoord[/COLOR][COLOR= #007700]];[/COLOR] [COLOR= #0000BB]$aQuery[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_query"]mysql_query[/URL][COLOR= #007700]([/COLOR][COLOR= #DD0000]"SELECT id, naam, wachtwoord, status FROM leden WHERE naam = "[/COLOR][COLOR= #007700].[/COLOR][URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR]htmlentities[COLOR= #007700]([/COLOR][COLOR= #0000BB]$naam[/COLOR][COLOR= #007700])).[/COLOR][COLOR= #DD0000]" AND wachtwoord = "[/COLOR][COLOR= #007700].[/COLOR][URL="http://www.php.net/mysql_real_escape_string"]mysql_real_escape_string[/URL][COLOR= #007700]([/COLOR][URL="http://www.php.net/md5"]md5[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$wachtwoord[/COLOR][COLOR= #007700])).[/COLOR][COLOR= #DD0000]""[/COLOR][COLOR= #007700]);[/COLOR] [COLOR= #0000BB]$aFetch[/COLOR] [COLOR= #007700]=[/COLOR] [URL="http://www.php.net/mysql_fetch_assoc"]mysql_fetch_assoc[/URL][COLOR= #007700]([/COLOR][COLOR= #0000BB]$aQuery[/COLOR][COLOR= #007700]); }[/COLOR] ?>