Link to home
Start Free TrialLog in
Avatar of khurram007
khurram007

asked on

What Changes to make in ASP Nuke to run???

Hi,

I want to run ASP Nuke but it is somehow not runnable for me... I have tried a lot but still not able to even see the interface. Can Any one try to run it on his own and then let me know the changes he made???

I am giving out 500 points for it... and as it is really urgent will issue another 500,  total= 1000 points for the solution provider.

Thanks....

Khurram
Avatar of sybe
sybe

>> but still not able to even see the interface

did you try "view source" and see any ASP errors there?
Cant really try it out at my side... But we can guide you through if you post the errors and the relevant code snippet here.

Also, What OS is your server running on?

Cheers!!
Avatar of khurram007

ASKER

ASP in view source??? r u kidding???

Well I m using Win2000 Pro.

Ok.. I have just again unzipped the downloaded zip file...

now the setup has 5 procedures and i have fullfilled the top 4. the fifth one states:

"Once your database is created, you will need to run the two setup
scripts found in the distribution package.  These files have the name:
"/setup/schema.sql" and "/setup/data.sql" and will setup the database
schema and data needed to run the application for the first time.  The
scripts contain Transact-SQL statements that you need to execute
through SQL Query Analyzer."

Now can you tell me the procedure how to run those 2 files???

Thanks...

Khurram.

Open SQL Query Analyzer, Choose the newly created DB from the Dropdown listing all the databases. Now click on File>Open. Choose the First SQL file (Schema.sql). Now the Query window should be loaded with lots of sql statements.. this does the actual table creation stuff. Run the script by pressing F5 on your keyboard or clicking Run from the query analyzer. It should execute the queries and say "Commands Successfully Completed" . Repeat the above steps for the swcond SQL file. Execute the SQL statements.

Now your database should be ready for use. Try accessing the asp page in the browser and see if the error persists.

Cheers!
>>  ASP in view source??? r u kidding???

What's the question: open the starting page of the application in your browser, if you can not see anything (which is what you report: "I have tried a lot but still not able to even see the interface"), then probably the production of HTML code is stopped by an error, and the error message is not rendered by the browser, because it is somewhere in an unfinished table or halway a javascript or whatever. There are many thing a browser can not render. But using "view source" in your browser reveals the ASP-error message.
nice help... seems like u r heading me in the right direction...

I executed those files and then tried index.asp again from webserver and this time the error was different.

it states:
------------------------------------------------------------------>
"Server object, ASP 0228 (0x80004005)
The call to Server.Execute failed while loading the page.
/lib/module_lib.asp, line 98"
------------------------------------------------------------------<

The error occured in the following module:

------------------------------------------------------------------>
Sub modShowGroup(sGroupCode)
      Dim nCount

      nCount = 1
      Do Until Application("MODULE" & sGroupCode & nCount) = ""
            Server.Execute(Application("ASPNukeBasePath") & Application("MODULE" & sGroupCode & nCount))
            nCount = nCount + 1
      Loop
End Sub
------------------------------------------------------------------<

When I commented out the loop, there was finally a page displayed with background color and header but nothing else...I tried to find these Application variables and found a sub procudure on another page. The whole procedure is written here...


------------------------------------------------------------------>
Sub steLoadConfig
      Dim sRootPath, sPath, sBasepath, nPos, oFSO, oFile, sContents, oRegex, oMatches, oMatch
      Dim sStat, rsVar

      ' attempt to locate the global.asa configuration file
      Set oFSO = Server.CreateObject("Scripting.FileSystemObject")
      sRootPath = Server.MapPath("/")
      sPath = Server.MapPath(".")
      Do Until oFSO.FileExists(oFSO.BuildPath(sPath, "global.asa"))
            nPos = InStrRev(sPath, "\", Len(sPath) - 1)
            If nPos < 1 Then Exit Do
            sPath = Left(sPath, nPos)
      Loop
      ' abort if the global.asa file was not found
      If Not oFSO.FileExists(oFSO.BuildPath(sPath, "global.asa")) Then
            Response.Write "<P><B class=""error"">Unable to locate global.asa configuration file... " & oFSO.BuildPath(sPath, "global.asa") & "</B></P>"
            Response.End
      End If

      ' do we need to seek out the db connection string?
      If Application("adoConn_ConnectionString") = "" Then
            ' read the contents of the file
            Set oFile = oFSO.OpenTextFile(oFSO.BuildPath(sPath, "global.asa"), 1)
            sContents = oFile.ReadAll
            oFile.Close
            ' find the connection string variable
            Set oRegex = New RegExp
            oRegex.Pattern = "asaConnectionString\s*=\s*""([^""]*)"""
            oRegex.IgnoreCase = True
            Set oMatches = oRegex.Execute(sContents)
            Application.Lock
            For Each oMatch In oMatches
                  Application("adoConn_ConnectionString") = oMatch.SubMatches(0)
                  Application("adoConn_CommandTimeout") = 1000
                  Application("adoConn_ConnectionTimeout") = 500
            Next
            ' abort if the connection string could not be parsed
            If Application("adoConn_ConnectionString") = "" Then
                  Response.Write "<P><B class=""error"">Unable to parse the asaConnectionString value from: """ & sPath & "global.asa""... ABORT!</B></P>"
                  Response.End
            End If
      Else
            Application.Lock
      End If

      ' now we can connect to the database and retrieve the remaining application variables
      sStat = "SELECT      VarName, VarValue FROM tblApplicationVar WHERE Archive = 0"
      Set rsVar = adoOpenRecordset(sStat)
      Do Until rsVar.EOF
            Application(rsVar.Fields("VarName").Value) = rsVar.Fields("VarValue").Value
            rsVar.MoveNext
      Loop
      rsVar.Close
      ' calculate the base path (folder ASP nuke is installed in)
      ' Response.Write "Root Path = *" & sRootPath & "* Path = *" & sPath & "*<BR>"
      sBasePath = Replace(Mid(sPath, Len(sRootPath) + 1), "\", "/")
      If Right(sBasePath, 1) <> "/" Then sBasePath = sBasePath & "/"
      If Left(sBasePath, 1) <> "/" Then sBasePath = "/" & sBasePath
      ' build the absolute nuke root
      If Right(Application("SiteRoot"), 1) = "/" Then
            Application("ASPNukeURL") = Application("SiteRoot") & Mid(sBasePath, 2)
      Else
            Application("ASPNukeURL") = Application("SiteRoot") & sBasePath
      End If
      ' Response.Write "Base Path = *" & sBasePath & "*" : Response.End
      Application("ASPNukeBasePath") = sBasePath
      Application("steLoadConfig") = "Y"
      Application.UnLock
End Sub
------------------------------------------------------------------<

It seems that the heart lies in sRootPath and sPath... but I would be greatful if u can tell me in a bit detail... I think u worth the 1000 points...

Thanks,

Khurram
you need to do some more debugging to see what exactly goes wrong.

change this:
===========================
Sub modShowGroup(sGroupCode)
     Dim nCount

     nCount = 1
     Do Until Application("MODULE" & sGroupCode & nCount) = ""
          Server.Execute(Application("ASPNukeBasePath") & Application("MODULE" & sGroupCode & nCount))
          nCount = nCount + 1
     Loop
End Sub
=========================

to this:

===========================
Sub modShowGroup(sGroupCode)
     Response.write CHR(10) & "debugging modShowGroup() with sGroupCode = " & sGroupCode & "<br>"
     Dim nCount, sPage

     nCount = 1
     Do Until Application("MODULE" & sGroupCode & nCount) = ""
          sPage = Application("ASPNukeBasePath") & Application("MODULE" & sGroupCode & nCount)
          Response.write "sPage = " & sPage & "<br>" & CHR(10)
          Server.Execute(sPage )
          nCount = nCount + 1
     Loop
End Sub
=========================


And report back what you see in the "view source"
Sybe,

after applying your solution, no change happened. The error remain same as :

"Error Type:
Server object, ASP 0228 (0x80004005)
The call to Server.Execute failed while loading the page.
/lib/module_lib.asp, line 98"

Still waiting....

Khurram
sounds like you have edited the wrong file. Are you sure there is only one "/lib/module_lib.asp" on your server?
Yes this is the only one.. And there is no doubt that it is the right file... Cauz when I commented outs the Server.Execute..... line, the page displays the bacground color with the header.

Khurram
ASKER CERTIFIED SOLUTION
Avatar of sybe
sybe

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
I am sending request to close this quesiton now...any issues?????
didnt any of our suggestions help?...

You never really posted a reply to sybe's last comment. Anyway, the call is your's.. I've got no problems..

Cheers!!
I didn't posted my messages cauz i dropped the idea of using ASP Nuke and strarted with SOOP. Which seems more good to me...awith a lot of admin previlidges... and on and on...

no, it didn't worked for me... I have no problem in issuing points.. but am only not issuing cauz what if someone comes here following the question and didn't find the solution...

Tell me whatz your suggestions are about issuing points or not... I will postpone the request for deleting the question for 2 days...

Thanks,

Khurram

Delete and refund is Ok with me.

Hwever, you send us on a wild goose chase :o). You never mentioned that you have discontinued your efforts to get this working.

Lets see if sybe has any issues.

Cheers!!