Everything posted by smithmr8
-
PHP Tables
Hehe, yeah. Same here. Always coming across new things.
- PHP Tables
-
PHP Tables
Hopefully it'll help
-
MAC or PC
If I could afford a Mac, I would buy one. Despite the fact they are overpriced style icons. They are the glamour models of the technology world. Not saying they aren't amazing machines, but they are by no means perfect . But would never get rid of my desktop (Windows 7). Yes, you can run it on a mac. But, I couldn't get rid of it. Desktop > Laptop. .
-
Can't Align Website
What browser are you using ? Name & Version.
-
PHP Tables
<?php $sql = mysq_query("SELECT * FROM table"); $index = 0; //Defining a variable, called $index, with a value of 0. while($data = mysql_fetch_array($sql)) { //This statement is dividing the value of $index by 2, and returning a value. This value is the remainder of the operation. //If this is equal to 0, then the number is divisible by two. //If this is not equal to 0, then the number is not divisible by two. if(($index % 2) > 0){ $color = "#CCC"; //If the remainder is greater than zero, the value of the variable $color is set to #CCC } else { $color = "#FFF"; //If the remainder is not greater than zero, the value of the variable $color is set to #FFF } $index++; //The value of $index is increased by one each time th while loop, loops. //This means than every other the time it loops, the number is not going to be divisible by two, which will result in the alternate colour being used. ?> <table> <tr> <td style="background:<? echo $color; //Inserting the value of the $color variable ?>"><?php echo $data['title']; ?></td> </tr> </table> <?php } ?>
-
Bit of help please
I've been with them for 3/4 years, and never had any problems with them .
-
PHP Tables
<?php $sql = mysq_query("SELECT * FROM table"); $index = 0; while($data = mysql_fetch_array($sql)) { if(($index % 2) > 0){ $color = "#CCC"; } else { $color = "#FFF"; } $index++; ?> <table> <tr> <td style="background:<? echo $color; ?>"><?php echo $data['title']; ?></td> </tr> </table> <?php } ?> That should do it.
-
PHP doesn't load a page
PHP will just show a blank page if the syntax is incorrect. From looking at it, there are a couple of things which don't look right. if ($next) $next = "<a href='news_p.php?id=$next'>next</a>"; if ($prev) $prev = "<a href='news_p.php?id=$prev'>previous</a>"; Should be something like: if (isset($next)) { $next = "<a href='news_p.php?id=$next'>next</a>"; } if (isset($prev)) { $prev = "<a href='news_p.php?id=$prev'>previous</a>"; } Also, not sure whether PHP likes having full-stops in file names. require("./include/bamboo.setup.php");
-
onFocusOut problem.
Anyone able to help ? Is this just one of those problems which can't be fixed ?
-
Design Critique ?
I have you to thank for that
-
Warning: mysql_query() [function.mysql-query]: Access denied for user
How is your config file configured / laid out ? According to that, you're not providing a password that it can read. Should be something like: <?php $dbhost = ""; $dbuname = ""; $dbpass = ""; $dbname = ""; $db_handle = mysql_connect($dbhost, $dbuname, $dbpass); $db_found = mysql_select_db($dbname, $db_handle); ?>
-
onFocusOut problem.
Website Here I'm having trouble with the onFocusOut event in Firefox. When you focus on the text field, it's supposed to clear the initial text out, which it does. Then, when you focusout of it.. if its blank, it's supposed to replace the initial text. In firefox, it clears the text, but the onfocusout doesn't seem to work. However, in IE, it works flawlessly (suppose there's a first for everything ) Any ideas ?
-
Design Critique ?
Hopefully have one in a couple of days .
-
Design Critique ?
Yeah, pretty much. If you've every heard of FML, I thought it would be a bit like that. But a bit more stylish .
- Design Critique ?
-
Design Critique ?
Hi, In the process of a personal project at the moment, and am now working on the front-end. Just wanted to see what people thought ? It's supposed to be simple, and straight forward. The words: type, enter, relax -> Will each have an image-over popup which will in turn explain how to use the site.. even thought for many it would be self explanatory. This is only the top part of the page. Will be a bit more at the bottom, showing the most recent "emotional releases", and the copyright statement. This will be both vertically and horizontally centered in the browser. Thoughts ?
- My Pants...
-
Hello All
Again.. It's "On behalf of.."!
-
Header feedback
The second one, the logo / S image looks better.. But the outside/border looks jagged to me and personally preferred the glow of the first one. If it was smoother out.. it would look the business.
-
Android Phone Apps
Never had any problems with o2, and their customer service is actually decent.
-
Portfolio Design
Didn't think the brushes added much to it, so have removed them. Will have a logo up there once I have one .
-
Portfolio.
Design one looks the best, I think.
-
Rapid mass traffic -is it real?
I hate sites which have those prompts when you try to exit the page.
-
Lock computer to one screen
Hi, Having a party later, and using my laptop as the "Music Center". Is there a way I can lock it so it only shows e.g.iTunes ? Don't really want people going through my stuff or using it for anything other than iTunes. Cheers.