#155908 - 2006-01-2606:09 AMRe: Translate it to KIX?
NTDOCNTDOC Administrator
Registered: 2000-07-28
Posts: 11629
Loc: CA
Try clearing your cache, try a different browser.
Try running this script on your system but MAKE SURE you have KiXtart 4.52 Beta 2 as it WILL NOT work correctly with any earlier version.
WARNING If you do run this script it will remove all Internet Explorer cache,cookies, history for every profile on the system as well as Java cached files and all %temp% files.
Code:
Break On Dim $SO $SO=SetOption('Explicit','On') $SO=SetOption('NoVarsInStrings','On') $SO=SetOption('NoMacrosInStrings','On')
ClearTemporary()
Function ClearTemporary() Dim $ProL,$PL,$Tmp,$DV $ProL = ExpandEnvironmentVars(ReadValue('HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList','ProfilesDirectory')) $PL = Dir($ProL) $DV = DelKey('HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\UserAssist\{5E6AB780-7743-11CF-A12B-00AA004AE837}\Count') $DV = DelKey('HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\UserAssist\{75048700-EF1F-11D0-9888-006097DEACF9}\Count') While $PL <>'' If $PL If Not InStr($PL,'.') And Not InStr($PL,'..') If Exist($ProL+'\'+$PL+'\Local Settings\Temporary Internet Files\Content.IE5\index.dat') RD $ProL+'\'+$PL+'\Local Settings\Temporary Internet Files\Content.IE5\' /S If @ERROR DEL $ProL+'\'+$PL+'\Local Settings\Temporary Internet Files\Content.IE5\index.dat' /P EndIf MD $ProL+'\'+$PL+'\Local Settings\Temporary Internet Files\Content.IE5' EndIf If Exist($ProL+'\'+$PL+'\Cookies\index.dat') RD $ProL+'\'+$PL+'\Cookies\' /S If @ERROR DEL $ProL+'\'+$PL+'\Cookies\index.dat' /P EndIf MD $ProL+'\'+$PL+'\Cookies\' EndIf If Exist($ProL+'\'+$PL+'\Local Settings\History\History.IE5\index.dat') RD $ProL+'\'+$PL+'\Local Settings\History\History.IE5\' /S If @ERROR DEL $ProL+'\'+$PL+'\Local Settings\History\History.IE5\index.dat' /P EndIf MD $ProL+'\'+$PL+'\Local Settings\History\History.IE5\' EndIf If Exist($ProL+'\'+$PL+'\Local Settings\Temp') RD $ProL+'\'+$PL+'\Local Settings\TEMP\' /S MD $ProL+'\'+$PL+'\Local Settings\TEMP' EndIf If Exist($ProL+'\'+$PL+'\Application Data\Sun\Java\Deployment\cache\') RD $ProL+'\'+$PL+'\Application Data\Sun\Java\Deployment\cache\' /S MD $ProL+'\'+$PL+'\Application Data\Sun\Java\Deployment\cache' EndIf If Exist($ProL+'\'+$PL+'\.jpi_cache\') RD $ProL+'\'+$PL+'\.jpi_cache\' /S MD $ProL+'\'+$PL+'\.jpi_cache' EndIf EndIf EndIf $PL = Dir() Loop If Exist('%windir%\system32\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\index.dat') RD '%windir%\system32\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\' /S If @ERROR DEL '%windir%\system32\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\index.dat' /P EndIf MD '%windir%\system32\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\' EndIf If Exist('%windir%\system\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\index.dat') RD '%windir%\system\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\' /S If @ERROR DEL '%windir%\system\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\index.dat' /P EndIf MD '%windir%\system\config\systemprofile\Local Settings\Temporary Internet Files\Content.IE5\' EndIf If Exist('%windir%\Application Data\Sun\Java\Deployment\cache\') RD '%windir%\Application Data\Sun\Java\Deployment\cache\' /S MD '%windir%\Application Data\Sun\Java\Deployment\cache' EndIf If Exist('%windir%\Temporary Internet Files\Content.IE5\index.dat') If @INWIN=2 Dim $RC RD '%windir%\Temporary Internet Files\Content.IE5\' /S $RC=WriteProfileString ('%windir%\Wininit.ini','rename','NUL','%windir%'+'\TEMPOR~1\CONTENT.IE5\INDEX.DAT') Else RD '%windir%\Temporary Internet Files\Content.IE5\' /S If @ERROR DEL '%windir%\Temporary Internet Files\Content.IE5\index.dat' /P EndIf MD '%windir%\Temporary Internet Files\Content.IE5' EndIf EndIf $Tmp = '%temp%' If Exist($Tmp) If Len($Tmp) >4 RD $Tmp+'\' /s MD $Tmp EndIf EndIf Exit @ERROR EndFunction
Registered: 2000-01-24
Posts: 4946
Loc: Leatherhead, Surrey, UK
I would have thought so too, but I assume that the stuff does paste ok, otherwise he would see it missing from the input box before submitting the post. Interesting that the end of line characters seem to be there. I wonder if changing to "using UBBCode/HTML" or "without UBBCode/HTML" might help.
#155912 - 2006-01-2601:13 PMRe: Translate it to KIX?
MartMart KiX Supporter
Registered: 2002-03-27
Posts: 4673
Loc: The Netherlands
Looking at the source code of the page I see this. Looks like this is the code that kingfisher wanted to post. It's a JavaScript. The board sees it as a script it should run so it is not shown.
Is this the script you originally wanted to post Kingfisher?
Code:
{ //////////////////////////Main Program var WshShell = WScript.CreateObject("WScript.Shell");
///////////OS Info var envSystem = WshShell.Environment("SYSTEM"); var OS = "98"; OS = envSystem("OS");
/////////////Batch File Path var batchPath = "\\\\godetia\\inventory\\test\\alloy.bat";
////////////////////////StartTimer jTimer();
function jTimer() { WshShell.Popup("Timer Started", 2, "Timer Status"); //for Testing var i, nowDate, runningHour, runningMinute, timeResult; i = true; while (i) { nowDate = new Date(); runningSecond = 01; runningMinute = 01; runningHour = 12; timeResult = nowDate.getHours() - runningHour; // timeResult = nowDate.getMinutes() - runningMinute; // timeResult = nowDate.getSeconds() - runningSecond; if (timeResult == 0 && nowDate.getMinutes() == runningMinute ) { var strThisTime = "Now is " + nowDate.getHours() + ":" + nowDate.getMinutes(); if (OS == "") { OS = "Windows 95/98" WshShell.Popup("OS is : " + OS + "\n" + strThisTime, 2); //for testing WshShell.Run("cmd /C start " + batchPath, "3", true); } else { WshShell.Popup("OS is : " + OS + "\n" + strThisTime, 2); //for testing WshShell.Run("cmd /C start " + batchPath, "3", true); } } ///////////running interval WScript.Sleep(59000); } WshShell.Popup("Timer Stop", 2, "Timer Status"); //for Testing } } catch (e) { var test = e; }
#155914 - 2006-01-2609:40 PMRe: Translate it to KIX?
MartMart KiX Supporter
Registered: 2002-03-27
Posts: 4673
Loc: The Netherlands
Quote:
Yep, that's his code, but you left out a little bit (so you could post I suppose) ....
Yep. Got no postprep so all stuff in between the less then and greater then brackets get executed as part of the pages code and therefore does not show. Don’t know where the package and job stuff is for but i guess it's from some kind of app that somehow requires it. Afaics it’s not needed for the translation but what do I know, I’m blind and unknowing in the JavaScript world
The codes is a timer, when users logon, the script stays at background,once time came out, it launchs a batch file. How to write a such timer with Kix and users can not see the console window?