Daniel0
Staff Alumni-
Posts
11,885 -
Joined
-
Last visited
Everything posted by Daniel0
-
SELECT DATE_FORMAT(date, '%m-%d-%y') AS formatted_date FROM table; See: http://dev.mysql.com/doc/refman/5.0/en/date-and-time-functions.html#function_date-format
-
It works because in your code it looked for a folder in the root of the hd.
-
It depends on what you're trying to do.
-
out is a reserved keyword (See: http://dev.mysql.com/doc/refman/5.0/en/reserved-words.html). You need to escape it using backquotes.
-
You need to write or (with letters) and not use the logical "or" operator.
-
mod rewrite and custom error page redirection problem
Daniel0 replied to lovesmith's topic in Apache HTTP Server
I think you've misunderstood how mod_rewrite works. It does not make links look in another way once they're output but it rewrites the URLs which are requested. I.e. if the user enters http://localhost/urlrewriting/productinfo/proid/12/ into the address bar it would have worked as had he typed http://localhost/urlrewriting/productinfo.php?proid=12. How exactly doesn't it work? If you go to a page which you know doesn't exist you should get the /err/404.php page instead. Doesn't that work? -
Note that on unserialization all resources (database connections, open files, etc.) will be gone so you'll have to open them again using the magic __wakeup() method.
-
Finally getting around to this site after putting it off.
Daniel0 replied to rcorlew's topic in Website Critique
Change the header image's alt attribute to contain the text in the image. That is what the attribute is for. It holds little value for blind people that you inform them that the image is the header logo if they still cannot read what is on that. The best solution would be to have the text in the source and replace the text with an image using CSS. At the login box it would look nicer if you either positioned the boxes next to their respective label text or if you added some whitespace between Pasword [sic] and the username box. Regardless of what you do (or don't) you should add a label tag around the text and link them to their input boxes. At the top navigation bar it would look better if when hovering over the links the background change would span from the top to the bottom of it's container. -
You kind of need a header. It needs to work equally good in all browsers
-
It has not been installed yet after the recent upgrade I believe.
-
Could you elaborate a bit more? What exactly do you mean?
-
As long as abc is a folder then it should do that already.
-
See: http://www.phpfreaks.com/forums/index.php/topic,95562.0.html
-
You can put this in it: ErrorDocument 404 /error/404.html Change the path to whatever the path to your error document is of course. See: http://httpd.apache.org/docs/2.2/mod/core.html#errordocument
-
Syntax for adding value to variable within a MySQL query...
Daniel0 replied to cgm225's topic in PHP Coding Help
Other than perhaps removing the parentheses after in the LIMIT There should be nothing wrong with the syntax. "SELECT * FROM images WHERE album = $album_id ORDER BY filename ASC LIMIT " . $image + 1 . ", 1" -
Oh... yeah... forgot there was a library function called that :-\ Just call it something else.
-
Syntax for adding value to variable within a MySQL query...
Daniel0 replied to cgm225's topic in PHP Coding Help
The modification has not been reinstalled after the upgrade from 1.1.1 to 1.1.4 of SMF. -
Make a recursive function. <?php function readDir($dir) { $items = scandir($dir); foreach($items as $item) { if(in_array($item, array('.', '..'))) continue; echo $dir, $item, "\n"; if(is_dir($item)) readDir($dir . $item); } } readDir('/home/daniel'); ?>
-
Syntax for adding value to variable within a MySQL query...
Daniel0 replied to cgm225's topic in PHP Coding Help
"SELECT * FROM images WHERE album = $album_id ORDER BY timestamp DESC LIMIT (" . $upper_limit + 1 . "), 1" ? -
http://www.phpfreaks.com/forums/index.php/topic,175898.0.html
-
Put the path to javac.exe in PATH (it's an environment variable). Then you can run it by just typing javac(.exe) from anywhere.
-
Why not just run javac directly?
-
We used to have a karma system but it got removed. This sort of seems like that.
-
You cannot put 4.6 GB on a CD.
-
The top menu (Home, About, Offers, etc.) could use a little more space between the links.