Jump to content

duncan121

New Members
  • Posts

    9
  • Joined

  • Last visited

Profile Information

  • Gender
    Not Telling

duncan121's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Excellent Thanks so much for your help.
  2. Sorry it's the new id I want to create. That is just an example of what I want to acheive. Thanks
  3. Hi all, I am trying to add a grouping id when I select the table but a loss how to do it. Any ideas? Thanks so much New id Pupil name 1 John Smith 1 John Smith 1 John Smith 1 John Smith 2 Jenny Wills 2 Jenny Wills 2 Jenny Wills 3 Mark Long 3 Mark Long 3 Mark Long
  4. yes they need to remain there. being different users may have the files installed and others not. Thanks Duncan
  5. I have an interesting challenge. So, I have a simple table displaying files in a directory. These files are waiting to be approved and installed. When they are installed they are entered into the MySQL database. Very straight forward and easy so far.  However the directory of files list files waiting to be installed and have been installed. So I want to do a comparison between a directory and a database and ONLY display the items which are not in the database. Once I have got all the files from the directory I am using a simple ignore script and trying to get to include the database values.  But it doesn’t work. Please see the code below… Thanks for your help. Duncan //Database call       $get_modules2 = new DB();       $get_modules2->query("SELECT * FROM ".DB_PREFIX."_modules");       while ($display_modules2 = $get_modules2->next_record()) {       $mods = $display_modules2['name'];       }       //Directory call       $this_dir = dir('modules/');       while ($file = $this_dir->read()) {         if($file != '.' && $file != '..' && $file != $mods)         {         echo $file;         }       }
  6. Hi experts. I have a directory with files waiting to be installed. Once they have been installed they are registered in a MySQL database. I want the files which have been installed to be invisible in a list. I have managed to write the code to look at the directory and remove a single file.  However I can get it to do the operation for all the installed files. Please see my code... Thanks for your help. Duncan $get_modules2 = new DB(); $get_modules2->query("SELECT * FROM ".DB_PREFIX."_modules"); while ($display_modules2 = $get_modules2->next_record()) { $mods = $display_modules2['name']; } $this_dir = dir('modules/'); while ($file = $this_dir->read()) { if($file != '.' && $file != '..' && $file != 'home' && $file != 'admin' && $file != 'system' && $file != $mods) { echo $file; } }
  7. Hi I have quite a simple problem whereby one of my pages does quite a large database pull. It takes about 20-30 secs depending on the server. Instead of having an empty page I am hoping to replace with a simple preloader. However all I have only found an image based or .swf based preloaders. Does anybody have a script where I can display somewhile the page is loading from the database. Thanks
  8. [!--quoteo(post=362331:date=Apr 6 2006, 07:23 PM:name=lead2gold)--][div class=\'quotetop\']QUOTE(lead2gold @ Apr 6 2006, 07:23 PM) [snapback]362331[/snapback][/div][div class=\'quotemain\'][!--quotec--] [code] $bgcolor ="yellow"; $lastname = ""; while ($row={fetching array information}){    if($row[name] != $lastname){         $lastname=$row[name];         $bgcolor = ($bgcolor=="yellow")?"red":"yellow";    }    // bg color will always alter on a name change     echo $bgcolor; } [/code] [/quote] Works a treat... Thanks
  9. I have an alternative color row problem. I am quite familiar with the normal alternative color rows. But I have multiple rows with same user so I wanted to highlight all the same users in the same color. Please the example below. Mr Smith = yellow Mr Smith = yellow Mr Smith = yellow Mr West = red Mr West = red Mr White = yellow Mr White = yellow And so on…. Any help would be warmly appreciated
×
×
  • 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.