
allworknoplay
Members-
Posts
385 -
Joined
-
Last visited
Never
Everything posted by allworknoplay
-
Well you could do: if(!$_SESSION['SESS_LOGGEDIN'] { \\DO SOMETHING } OR you can do: if($_SESSION['SESS_LOGGEDIN'] != "TRUE") { \\DO SOMETHING }
-
[SOLVED] alternating table background color
allworknoplay replied to Lambneck's topic in PHP Coding Help
that looks fine. Show us your current code now that displays the double-rows.... There's something that's duplicating each row... -
Need help with a MYSQL row count in php
allworknoplay replied to tekhead2004's topic in PHP Coding Help
Well it's really difficult to read your query because it contains a subquery, maybe a better SQL guru can explain why, but since I don't know the structure of your DB at all, it makes it very difficult to know why it only returns 1 row. -
Ok then just to be save, run this to clear out your POST. foreach ($_POST as $key => $val) { unset($_POST[$key]); } I think that should work.
-
[SOLVED] alternating table background color
allworknoplay replied to Lambneck's topic in PHP Coding Help
I don't think there's any issue with the FOR loop, it looks fine. What does your CSS look like? -
Are you saying that the $POST data is still there when you go from thankyou.php to ionline3.php??
-
This is a cron job issue, I do this all the time. I have my script running once a minute since that's the least you can do for cron's... You could also write a PHP program that runs once, gets kicked off by cron, and the program is a continuous WHILE loop that can clear out your info faster than 1 minute....but I am always weary of writing a continuous WHILE loop...
-
if($user == admin) header('Location: http://www.whatever1.com/'); exit; if($user == client) header('Location: http://www.whatever2.com/'); exit; if($user == guest) header('Location: http://www.whatever3.com/'); exit;
-
They will allow it to run on their pc if the end user let's it. Simple as that, if it really is legit, people will know to allow it and the source is trusted. If not they will just deny the Activex controls. Oh sure, if it's legit. You know the average mom or dad sitting at a website will get the pop up and probably just hit OK... I just hope this guys question is legit that's all, he's jumping around with what things to do...
-
[SOLVED] alternating table background color
allworknoplay replied to Lambneck's topic in PHP Coding Help
$class = "$i % 2 ? 'EVEN' : 'ODD' "; this is a one line IF conditional. $class would be your "$i" if you were using a FOR loop. Then you are basically saying, if $i is divisible by 2 then show EVEN, if not show ODD. So for your code since you are using CSS... for($i=0;$i<$num;$i++){ $class = "$i % 2 ? 'EVEN' : 'ODD' "; echo '<tr class="' . $class . '">'; echo "<td><strong>"; Now doesn't that look simpler? -
Just do an unset on the POST variables. So if you have one called $_POST[username]; You just do: unset($_POST[username]);
-
Dude, this sounds like border line hacking. IE or FF isn't going to let activex controls or whatever run scripts on someone's PC...what are you trying to do exactly? Your original post was about checking file exists, and now you want to run scripts on someone's PC?
-
[SOLVED] alternating table background color
allworknoplay replied to Lambneck's topic in PHP Coding Help
I don't understand why you are doing that work when I gave you a one line code that will do it all... Am I just not understanding your question correctly? $color = "$class % 2 ? '#000000' : '#FFFFFF' "; echo '<tr bgcolor='".$color."'>'; -
session_destroy() won't work. That's for sessions. You're using POST variables. You can try running this function to loop through your POST variables and clear them out.
-
All this does is get the IP from your DB, you also need to grab the IP of the web $_SERVER['REMOTE_ADDR']; And compare....
-
LOL....
-
[SOLVED] creating a php script to log everyone off by CRON JOB
allworknoplay replied to wmguk's topic in PHP Coding Help
Umm...you just write your script to change the value from ONLINE to OFFLINE?? "UPDATE users SET online='offline' "; -
If you only want ONE output, just put a LIMIT on your query. LIMIT 1;
-
So is it working now!!!??
-
[SOLVED] force something besides index.php
allworknoplay replied to aebstract's topic in PHP Coding Help
The default index pages are set in your Apache or IIS config. then from there, you can redirect the user to whatever pages you want after the splash page. -
[SOLVED] alternating table background color
allworknoplay replied to Lambneck's topic in PHP Coding Help
Put this in your TR tags.... Obviously change the 2 colors to whatever you want. Here it is black and white. $row['color'] % 2 ? "#000000" : "#FFFFFF" -
Searching a DB and returning Results
allworknoplay replied to poorrichard's topic in PHP Coding Help
Ok, after your MYSQL Query, you're not doing anything to grab the records and printing them out....