mastermike707
-
Posts
23 -
Joined
-
Last visited
Never
Posts posted by mastermike707
-
-
o ok nvm then, I only am getting the e-mail error now. What is wrong with my e-mail regxp?
-
Wow, ok Thanks a ton.
EDIT: I think register_globals is off, how do I fix this? -
yes all of the error checking messages are outputted.
-
[code]$title = (isset($_POST['title'])) ? strip_tags(htmlentities($_POST['title'])) : false;
$err = ($title && preg_match("/[A-Za-z0-9]{3, 50}/", $title)) ? '' : "Your title must be at least three characters long and only letters and numbers.<br />\n";
$author = (isset($_POST['author'])) ? strip_tags(htmlentities($_POST['author'])) : false;
$err .= ($author && preg_match("/[A-Za-z0-9]{3, 50}/", $author)) ? '' : "Your name must be at least three characters long and only letters and numbers.<br />\n";
$email = (isset($_POST['email'])) ? strip_tags(htmlentities($_POST['email'])) : false;
$err .= ($email && preg_match("/[+]@[+]\.[A-Za-z]{2,3}/", $email)) ? '' :"Your e-mail address must be valid.<br />\n";
$comment = (isset($_POST['comment'])) ? strip_tags(htmlentities($_POST['comment'])) : false;
$err .= ($comment && strlen($comment) > 3 && strlen($comment) < 500) ? '' :"You must have at least 3 characters in your comment, but not over 500.<br />\n";[/code]
This code never works correctly, even when the values are correct. Any idea why? -
Can you give me a example of something that would cause this error and then the fixed version of that code.
Thank you already. -
Uh, what causes undefined index errors? Is it sql related or session related?
-
I honestly don't know, I had just never thought about it like that. I guess it would be a little more load, but I think that would outweigh the load of (running, not necesssarily the query) MySQL tho? If I am wrong then just pretend I wasn't in this conversation.
-
Just echo whatever variable contains the user's username where u want their name.
-
[quote author=BillyBoB link=topic=102454.msg407919#msg407919 date=1154507062]
wouldn't sessions like kill your bandwidth?
[/quote]
Can you explain that please? Doesn't the user still load the same amount of pages? -
Can't you just use a session?
I am getting that the author does not want to store these scores, just display them.
EDIT: Used to talking on an IM (used "u" instead of "you" lol) -
Try changing the query to this:
[code]$sql = "SELECT username
FROM chaoworld_b
WHERE username = '$userId' AND password = '$password'";[/code] -
Ok, what I think you want to know is what variable is the refering url:
[code=php:0]$_SERVER["REFERER"][/code] -
Ok idk what to do, here is the session code I ussually use:
[code=php:0]class session
{
function start($auth = true)
{
session_start();
if(!isset($_SESSION['user_id']) && $auth)
{
header('Location: login.php');
exit;
}
$_SESSION['ip'] = $_SERVER['REMOTE_ADDR'];
define('LOGGED_IN', (isset($_SESSION['logged_in'])) ? $_SESSION['logged_in'] : false);
}
function destroy()
{
$_SESSION = array();
session_destroy();
}
}[/code]
Try that and see if it works. -
Maybe try clearing ur cookies?
Look at the settings in php info for sessions. -
dang, ok figured u copied and pasted so thats why I said it.
-
[quote]//login.php
ob_start();
SESSOIN_START();[/quote]
I think the misspelling of SESSION_START() might have something to do with it. -
Thank you VERY much. ;D
-
The only problem with that is that MonkeyQuest is just a example, the MonkeyQuest could just as easily be ChickenSoup. I only want to capture the Title portion into a var.
-
Ok, there is a file that I want to read info from. Here is an example file:
[code]
## Interface: 11100
## Title: MonkeyQuest v2.3.1
## Notes: Displays your quests for quick viewing. (http://www.toctastic.net/)
## Author: Trentin (trentin@toctastic.net)
## SavedVariables: MonkeyQuestConfig
## Dependencies: MonkeyLibrary
## OptionalDeps: aftt_extreme, BhaldieInfoBar
MonkeyQuest.xml
BIB\BIB_MonkeyQuest.xml
[/code]
What I want to capture into a variable is:
[code]MonkeyQuest v2.3.1[/code]
Now, heres how far I got (dosen't work):
[code]
$h2 = fopen('./'.$file.'/'.$file'.toc', 'rb');
$fd = strpbrk(strrev(substr((fread($h2, filesize('./'.$file.'/'.$file'.toc')), 30)), '';
fclose($h2);
[/code]
(.toc is the file extension) Any help would be appreciated. -
I have a directory full of files, I want to make a page that gives you a list of files in the directory, then zips the files in the directory into a gzip file and puts it on a directory on my webserver. Any help would be appreaciated.
-
Try reinstalling Dreamweaver, updating your virus scan and scanning, scanning for spyware, etc. Reboot your comp.
Reinstalling Dreamweaver should make the biggest difference.
-
Ok, first delete ALL of those recordsets you made, now, make one new recordset, called rs_nav, then select your connection. Now select the nav table. Under columns select all.
Now insert a repeating region for the nav section, deleting all but one of the 'global links'. make sure that it is a repeating region under server behaviors, and not under templates. Change the text 'global link', and put dynamic text there, making it content, and then select it and change it to a link, now make it a dynamic link by selecting the url field.
EDIT: if thats too complicated, I will make a easier to follow version, (with images).
Page scrolls horizontally, but nothing in the section scrolled
in CSS Help
Posted
I can post the stylesheet if need be...