Just starting out? Need help? Post your questions and find answers here.
ehbarba
 
Posts: 29
Joined: Thu Mar 29, 2018 2:20 am

Can not execute SpiderBite sample

by ehbarba Fri Feb 08, 2019 11:27 pm

Hello

After install SpiderBite in SpiderBasic I tryed to compile ExamplePHP.sb but it rise a sintax error in:

ProcedureDLL myPhpProcedure1()

SpiderBasic does not recognize ProcedureDLL.

What am I missing or doing wrong?
User avatar
Peter
 
Posts: 579
Joined: Mon Feb 24, 2014 10:17 pm
Location: 127.0.0.1

Re: Can not execute SpiderBite sample

by Peter Sat Feb 09, 2019 8:44 am

ehbarba wrote:SpiderBasic does not recognize ProcedureDLL.

Did you install the tools the way I described it on this page?

https://github.com/spiderbytes/SpiderBite#spiderbite-als-spiderbasic-tools-einrichten
ehbarba
 
Posts: 29
Joined: Thu Mar 29, 2018 2:20 am

Re: Can not execute SpiderBite sample

by ehbarba Mon Feb 11, 2019 11:29 pm

Hi Peter, thank you

I checked the installation, and it was Not Ok!

I think it's Ok now:

Image

Image


But when I run the example, the PB compiler generates an error as shown in the following image:

Image

I'm using Miva Merchant Mia is an engine and personal web server environment. I try with and without it installed and the error is the same.
User avatar
Peter
 
Posts: 579
Joined: Mon Feb 24, 2014 10:17 pm
Location: 127.0.0.1

Re: Can not execute SpiderBite sample

by Peter Mon Feb 11, 2019 11:57 pm

ehbarba wrote:Image

InitCGI() is only available starting with PureBasic Version 5.40.

Greetings ... Peter
swan
 
Posts: 17
Joined: Tue Dec 15, 2015 2:56 am

Re: Can not execute SpiderBite sample

by swan Tue Feb 12, 2019 4:11 am

Hi Peter.
I was going to start a new topic but it would have had the same heading so I tagged on here.
I too am having an issue with running any of the SpiderBite examples. I get this error - "Line 1: 'C' is not a valid operator"
Have checked and rechecked the installation to your instructions. I think it's OK.
SB compiles and runs as normal. Any help would be great.
Cheers,
Steve ..... :)
ehbarba
 
Posts: 29
Joined: Thu Mar 29, 2018 2:20 am

Re: Can not execute SpiderBite sample

by ehbarba Tue Feb 12, 2019 9:51 pm

Thank you, Peter, as allways!
User avatar
Peter
 
Posts: 579
Joined: Mon Feb 24, 2014 10:17 pm
Location: 127.0.0.1

Re: Can not execute SpiderBite sample

by Peter Wed Feb 13, 2019 9:24 pm

swan wrote:I get this error - "Line 1: 'C' is not a valid operator"

Unfortunately, I don't have the slightest idea what could trigger this error.

Please search for a single "C" in the code.

Greetings ... Peter
swan
 
Posts: 17
Joined: Tue Dec 15, 2015 2:56 am

Re: Can not execute SpiderBite sample

by swan Fri Feb 15, 2019 6:34 am

Hi Peter,
Bit of an update but no cigar yet.
Uninstalled everything (including SB) and reinstalled. Redownloaded all files, yet same error. A single "C" in code gives a syntax not that error.
Now, the error only occurs following "EnablePBCgi" in the code. EnableASP, EnablePHP, etc is not effected.
I'm using Win 10 and the web server is IIS. I also tried Apache but I don't think the error is reaching that point.
Here is the simplest code that produces the error.

Code: Select all
#SpiderBite_Profile = "default"
EnablePbCgi
DisablePbCgi


Sorry to be a pain but I'd love to see this work.
Steve ....
User avatar
Peter
 
Posts: 579
Joined: Mon Feb 24, 2014 10:17 pm
Location: 127.0.0.1

Re: Can not execute SpiderBite sample

by Peter Fri Feb 15, 2019 9:33 am

Hello Steve,

Okay, I think I figured it out.

Please check if you have write permissions in the directory you specified under PbCgiFilename.

Image

If I (as you can see on the screenshot) create the cgi.exe in C:\intepub\wwwroot\ then everything works.

If I want to write in C:\intepub\ (I don't have write permission there), I get the same error as you.

Greetings ... Peter
swan
 
Posts: 17
Joined: Tue Dec 15, 2015 2:56 am

Re: Can not execute SpiderBite sample

by swan Tue Feb 19, 2019 6:08 am

Apologies for the delay - yes you're right, it was write permissions in IIS. I really should have checked that - :oops:
Now PB compiles and deposits the exe as per the config profile as it should.
But I get this error in the debug window when run :
"error: error/NetworkError: Failed to execute 'send' on 'XMLHttpRequest': Failed to load 'http://localhost/PBcgi/'."

This code:
Code: Select all
#SpiderBite_Profile = "default"
EnablePbCgi
  ProcedureDLL.s myPbCgiProcedure()
    ProcedureReturn "Hello from myPbCgiProcedure"
  EndProcedure
DisablePbCgi
Debug myPbCgiProcedure()


As always thanx Peter.
Steve ...
Return to Coding Questions

Who is online

Users browsing this forum: No registered users and 2 guests