floridaflatlander
-
Posts
671 -
Joined
-
Last visited
-
Days Won
1
Posts posted by floridaflatlander
-
-
Have you attempted to put any debugging echos ...
-
<!DOCTYPE html> <html lang="en"> <?php include('include/header.php'); ?>
I'm assuming you have doctype info in header.php
-
sorry try $url = $_SERVER['HTTP_HOST'];
-
I think this is it $url = dirname($_SERVER['PHP_SELF']);
be sure to clean it with htmlentities or strip_tags and if you're inserting into a db mysqli_real_escape_string
-
Is this your first? My wife is due at the end of this month with our first and I can't wait.
They are a blast. We were also lucky, all three of ours, they were two years apart, would sleep through the night from the start. , thank God
-
I started with one of the earlier editions of that book. It covers all the basics in a very easy to understand manner.
Same here, I started with books that were a step above this had problems then backed up and ordered Ullman's PHP Visual QuickStart Guide.
-
So you didn't get an error message?
I thought mysqli_query() expects 2 parameters, you have one
Try
$result=mysql_query($dbc, $sql) or die("Error: ".mysqli_error($dbc));
where $dbc = mysql_connect("$host", "$username", "$password")or die("cannot connect");
-
Plug this in and see what it tells you,
$result=mysql_query($sql) or die("Error: ".mysqli_error($dbc));
where $dbc = mysql_connect("$host", "$username", "$password")or die("cannot connect");
-
A variable starts with a dollar sign and uses letters numbers and underscores, After the $ sign it must be a letter or an underscore.
-
You need to get fire foxes firebug, it is a big help. When you use it, it will highlight the margins and padding. Also when you hover over or click an html tag it will tell you what file and line number a style is coming from(a big help) and the inheritence of any.
-
Hey my elements are all inside the container so my technique is just put the background color I want also on the container.
There is a color(white) and a margin for the body.
try
body {margin: 0;}
-
also try a body background color like a shade of gray or something, just in case something happens in the future the colors will at least blend.
also container needs to be
#container{
width:100%;
...............
}
-
try
body {margin: 0;}
-
Well call me an idiot yoursurrogategod. I clicked the above link.
-
Thanks for the reply. I looked at SMF and tried to figure out what SMF does by looking at their members table, I think they use a cookie/session too.
Anyway, I'll come back tomorrow morning and mark solved.
Thanks
-
What is the big picture on an effective way to implement an user agreement?
Do most people use a special db table column indicating that a user has agreed to the user agreement or do they use a session or cookie and if it exist let the user proceed to register?
Thanks
-
Looks like it may be a late 1960s Dodge Dart GT.
That's my vote
-
Thanks for the reply.
Is it even worth worrying about using mb_detect_encoding? I've don't think I've seen it here(or anyone talking about UTF-8 encoding/decoding) before and the only place I've seen that said it needed to be used is the book "Wicked Cool PHP"
-
Just throwing this out there and it sounds like a jury rig but … assign your queried variables to a list and then use if statements or a loop inside the main loop if any to reassign the empty variable to if needed.
Then you'll have a named variable with the value from the query or to use in your results or in your while() loop.
-
I have a book "Wicked Cool PHP" and in the security section it suggest that one would should use utf8_decode to "prevent potential Unicode codec problems"
Something like this $name = utf8_decode($_POST ['name']);
Is this a good idea? I have "<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />" in the header, are these diffent things?
I've found web sites saying this is a bad thing
Wicked Cool PHP suggest
$name = utf8_decode($_POST ['name']); $name = htmlentities($name, ENT_NOQUOTES); $name = str_replace("#", "#", $name); $name = str_replace ("%", "%", $name);]
Is this a good idea or just extra work?
I use the standard strip_tags & mysqli_real_escape_string now.
-
Wow, you realize he was agreeing with you about the OP's site, right?
Sh--. The answer is no, sorry Mahngiel. Anyway there are some links for the OP.
-
You're a web developer with an attitude and your web page doesn't even have a header?
This is a prime example why there's enough work out there for the rest of us.
Us? lol, Here's a menu people like us can use. http://ago.tanfa.co.uk/css/examples/menu/tutorial-h.html. Here's another http://htmldog.com/articles/suckerfish/dropdowns/
Also last I looked, you don't have a html header and you don't have opening and closing html tags or opening and closing body tags.
Do you know what these things are?
-
You're a web developer with an attitude and your web page doesn't even have a header?
-
CSS looks good, 72 errors in your html. Fix those then see what happens.
captcha validation fails
in PHP Coding Help
Posted
I set a session with the captcha value sha1 'pass_phrase' then
// $_POST user_phrase from captcha
if (isset($_POST['image'])) {
$user_pass_phrase = sha1($_POST['image']);
}
then
if ($_SESSION['pass_phrase'] == $user_pass_phrase)