Jump to content

cadams7407

New Members
  • Posts

    3
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

cadams7407's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. You did not give mktime a day or year, so it is using 31 / 2007. There is no February 31st, April 31st, June 31st, September 31st, or Novermber 31st this year, so they are spilling over into the next month. Use a day that every month has: mktime(0, 0, 0, $m, 1) right on, makes sense. its working fine today .. but todays the 1st .. so ... yeah, what you said. Thanks!
  2. hello world ... haha anyways. I have a for loop that I use to generate a list of months. Its worked very well .. until today (2007-01-31) heres code: echo "<TABLE BORDER=0 CELLPADDING=3 style=\"BORDER-COLLAPSE: collapse\"><tr><td align=right bgcolor='#F4ECA5'><B>"; //This generates the months Jan - Dec and lists them down the left of the table for($m = 01;$m <= 12; $m++){ $month = date("F", mktime(0, 0, 0, $m)); echo "<option value='$m'>".$month."<br /></option>"; } echo "</B></td><td>"; Normally I get a nice list like: January February March etc. But today the list is: January March March May May July July August October October December December ??? Wether or not this changes tomorrow (2007-02-01) will give me a clear indication if this is a php bug, or if my code is too sloppy. In the mean time, any advice out there? Thank you in advance. Almost forgot: php 4.3.11 | MySQL 4.1.11 | phpMyAdmin 2.6.4 | Apache 2.0.58 | Zend Opt. 2.6.2
  3. PHP 4.3.11 on WinXP Pro 32bit I am using [code]exec("dir pictures/$input /b/x",$pic);[/code] and then counting the number of files in $pic. $input = a product id number; this id number corresponds to a directory inside htdocs/pictures. Example, the widget is product numer 4. Pictures of the widget are in htdocs/pictures/4  I need to count the number of files in /4 and this code is returning my else command. Not what I want. Strangly, I found that if I change code to [code]exec("dir $input /b/x",$pic);[/code] and move all the subdirectories of /pictures up one level to /htdocs (ie. widget pics are now htdocs/4) it frickin works ??? So, how is it that I can use "dir" shell cmd to list the files in a directory, but I CANNOT use dir to list the files inside a directory thats inside a directory? It works fine with ls on the current redhat server .... why not Windows?
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.