Code
$FireFoxVersion=Readvalue(HKLMSoftware32 + "\Mozilla\Mozilla Firefox","")
 
for each $folder in dirplus("%appdata%\Mozilla\Firefox\Profiles\","/ad") if right($folder,8)=".default" for each $plugfolder in dirplus($folder + "\extensions","/ad") ? $plugfolder.name " - " + iif(FirefoxUpdatePlugin($plugfolder,$firefoxversion)=0,"Updated","Unchanged") next endif next

Functions
function FirefoxUpdatePlugin($path,$version)
  dim $objXMLDoc, $RC, $FirefoxEMID, $AppNodes, $i
  $FirefoxUpdatePlugin=1
  $objXMLDoc = CreateObject("Microsoft.XMLDOM")
  $objXMLDoc.async = False
  if exist($path + "\install.rdf")
    $RC=$objXMLDoc.load($path + "\install.rdf")
    $FirefoxEMID="{ec8030f7-c20a-464f-9b0e-13a3a9e97384}"
    $AppNodes=$objXMLDoc.documentElement.selectNodes("Description/em:targetApplication/Description")
    for $i=0 to $AppNodes.length
      if $Objxmldoc.getelementsbytagname("em:id").item($i).text=$FirefoxEMID
        if $Objxmldoc.getelementsbytagname("em:maxVersion").item($i-1).text<>$version
          $Objxmldoc.getelementsbytagname("em:maxVersion").item($i-1).text=$version
          $objxmldoc.save($path + "\temp.rdf")
          if comparefiletimes($path + "\temp.rdf",$path + "\install.rdf")
            move $path + "\install.rdf" $path + "\install.rdf.bak"
            move $path + "\temp.rdf" $path + "\install.rdf"
            $FireFoxUpdatePlugin=0
          endif
        endif
      endif
    next
  else
    exit 2
  endif
endfunction
 
function HKLMSoftware32 $HKLMSoftware32="HKLM\Software" + iif(@onwow64,"\WOW6432Node","") endfunction
Function DirPlus($path,optional $Options, optional $f, optional $sfflag) If not vartype($f) DIM $f EndIf If not vartype($sfflag) DIM $sfflag EndIf
DIM $file, $i, $temp, $item, $ex1, $mask,$mask1,$maskArray,$maskarray1, $ex2, $code, $CodeWeight, $targetWeight, $weight, $masktrue DIM $tarray[0]
$ex1 = SetOption(Explicit,on) $ex2 = SetOption(NoVarsInStrings,on) $codeWeight = 0
If not Exist($path) Exit(2) EndIf If not vartype($f) $f = CreateObject("Scripting.FileSystemObject").getfolder($path) EndIf If @ERROR $temp = SetOption(Explicit,$ex1) $temp = SetOption(NoVarsInStrings,$ex2) Exit(@ERROR) EndIf
For Each $temp In Split($options,"/") $temp=Trim($temp) Select Case left($temp,1) = "s" If not vartype($sfflag) If Val(right($temp,-1)) = 0 $sfflag = -1 Else $sfflag = Val(right($temp,-1)) EndIf EndIf Case Left($temp,1) = "a" Select Case Right($temp,-1)="d" $codeWeight = $codeWeight + 1 $temp = "if $file.type = 'File Folder' " Case Right($temp,-1)="-d" $codeWeight = $codeWeight + 1 $temp = "if $file.type <> 'File Folder' " Case Right($temp,-1)="s" $codeWeight = $codeWeight + 1 $temp = "if $file.attributes & 4 " Case Right($temp,-1)="-s" $codeWeight = $codeWeight + 1 $temp = "if ($file.attributes & 4)=0 " Case Right($temp,-1)="h" $codeWeight = $codeWeight + 1 $temp = "if $file.attributes & 2 " Case Right($temp,-1)="-h" $codeWeight = $codeWeight + 1 $temp = "if ($file.attributes & 2)=0 " Case Right($temp,-1)="r" $codeWeight = $codeWeight + 1 $temp = "if $file.attributes & 1 " Case Right($temp,-1)="-r" $codeWeight = $codeWeight + 1 $temp = "if ($file.attributes & 1)=0 " Case Right($temp,-1)="a" $codeWeight = $codeWeight + 1 $temp = "if $file.attributes & 32 " Case Right($temp,-1)="-a" $codeWeight = $codeWeight + 1 $temp = "if ($file.attributes & 32)=0 " EndSelect $code = $temp + "$weight=$weight+1 endif" +@CRLF + $code
Case Left($temp,1) = "m" $maskarray = Split(Right($temp,-2),"|") $codeweight = $codeweight + 1 $code = "$masktrue=0 for Each $mask in $maskarray if instr($file.name,$mask) $masktrue=1 " + "EndIf Next If $masktrue $weight=$weight+1 endif" + @CRLF +$code Case Left($temp,1) = "f" $maskarray1 = Split(Right($temp,-2)," ") $codeweight = $codeweight + 1 $code = "$masktrue=0 for Each $mask1 in $maskarray1 if substr($file.name,Instrrev($file.name,'.')+1)" + "=$mask1 $masktrue=1 EndIf Next If $masktrue $weight=$weight+1 endif" + @CRLF +$code
EndSelect Next $code = "$weight = 0 $targetWeight = " + $codeweight + @CRLF + $code $code = $code + "if $weight = $targetweight Exit(1) endif"
For Each $file In $f.subfolders If Execute($code) $tarray[$i] = $file $i = $i + 1 ReDIM preserve $tarray[$i] EndIf If $sfflag $temp = dirplus($file,$options,$file,$sfflag-1) For Each $item In $temp $tarray[$i] = $item $i = $i + 1 ReDIM preserve $tarray[$i] Next EndIf Next For Each $file In $f.files If Execute($code) $tarray[$i] = $file $i = $i + 1
ReDIM preserve $tarray[$i] EndIf Next
If $i ReDIM preserve $tarray[$i-1] $i=0 Else $tarray = 0 EndIf
$dirplus = $tarray $temp = SetOption(Explicit,$ex1) $temp = SetOption(NoVarsInStrings,$ex2) Exit(@ERROR) EndFunction