r3wp [groups: 83 posts: 189283]
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r3wp

[Plugin-2] Browser Plugins

Louis
12-Oct-2006
[1788x4]
I'm running Cheyenne so I can test the plug in on my local computer.
I don't know about the caching question. How do I check that?
Sorry for the delays in answering. I'm paying by the minute, so have 
to log off while waiting for people to answer.
I just deleted all off-line content cached by Internet Explorer. 
The problem remains.
Anton
12-Oct-2006
[1792]
You would examine the cached file using:
	editor path-thru http://localhost/slideshow/test.r
But let us see what this returns:
	print read http://localhost/slideshow/test.r
Louis
12-Oct-2006
[1793x2]
editor path-thru http://localhost/slideshow/test.r


brings up an erro message saying the file cannot be read (perhaps 
because it doesn't exist?)

print read http://localhost/slideshow/test.rreturns 

>> print read http://localhost/slideshow/test.r
connecting to: localhost
What?
Continue?
>>

>> print read http://localhost/slideshow/test.r
connecting to: localhost
What?
Continue?
>>>> print read http://localhost/slideshow/test.r
connecting to: localhost
What?
Continue?
>>>> print read http://localhost/slideshow/test.r
connecting to: localhost
What?
Continue?
>>
Whoops! a few repeats there; I pasted too many times.
Anton
12-Oct-2006
[1795x3]
exists? path-thru http://....
probe info? path-thru http://...
But that "What? Continue?" doesn't look right to me :)

Try 127.0.0.1 instead of localhost and see if that makes a difference.
Louis
12-Oct-2006
[1798x2]
>> exists? path-thru http://localhost/slideshow/test.r
== false
>> probe info? http://localhost/slideshow/test.r
connecting to: localhost
make object! [
    size: 15
    date: none
    type: 'file
]
>>
127.0.0.1 makes no difference.
Anton
12-Oct-2006
[1800]
Right, well, it looks like it is not a plugin issue, but a url or 
webserver issue.
Louis
12-Oct-2006
[1801]
OK, thanks.
Anton
12-Oct-2006
[1802]
Have you tried opening that url in a browser ?
Louis
12-Oct-2006
[1803]
Yes, that is when I get the error message. First the web page displays 
with a box containing the message REBOL/Plugin 2.6.6.3.1, then a 
REBOL/ViewDLL window pops up with the error message.
Anton
12-Oct-2006
[1804x2]
No I mean directly opening that url in a browser, eg:

browse http://localhost/slideshow/test.r
It seems to me that reading this url is not getting the rebol script 
that you are expecting, so of course the plugin is going to fail 
when you direct it to it.
Anton
13-Oct-2006
[1806x3]
I expected your console session to look like this:

>> print read http://localhost/slideshow/test.r
connecting to: localhost
REBOL []
print "What?"
ask "Continue?"
>>

and not this:

>> print read http://localhost/slideshow/test.r
connecting to: localhost
What?
Continue?
>>
You're using Cheyenne as the web server, so probably Cheyenne is 
doing the rebol script as it would to support Rebol Server Pages.
You should look into Cheyenne's options regarding Rebol Server Pages 
and see it there's a way to disable it for certain scripts.
Louis
13-Oct-2006
[1809x2]
Anton said: 

No I mean directly opening that url in a browser, eg:

browse http://localhost/slideshow/test.r


OK, that works! Would you believe it? I was doing the same thing 
wrong that I did earlier.  I misunderstood the reason behind it. 
Anyway this does not appear to have been caused by Cheyenne, but 
merely by my ignorance. Anton, thanks again for your help!
No, I spoke too soon. http://localhost/slideshow/test.ris the plug 
in script.  

http://localhost/slideshow/SlideShow2.htmlstill gives the error.
Anton
13-Oct-2006
[1811]
What does 
	browse http://localhost/slideshow/test.r
give you ? What is shown in the browser ?
Louis
13-Oct-2006
[1812]
What? Continue?
Dockimbel
13-Oct-2006
[1813x5]
.r files are treated as CGI script by default in Cheyenne. To change 
that, you have to edit the httpd.cfg file and change the following 
line :
bind-extern CGI to [ .cgi .r ]
to
bind-extern CGI to [.cgi]
So .r files will be treated as static ressources.
Graham
13-Oct-2006
[1818]
so change the extension ?
Louis
13-Oct-2006
[1819x12]
Doc, thanks. My test script now runs.
However, when I try to run my slideshow script, the plugin is unable 
to load the data file.
Ok, I put the data into the script as a block of blocks, but now 
the plugin cannot load the image files.


Am I at a deadend here? or is there still a way to make this work?
Simplicity is turning complicated.
If I use to-binary to convert an image to a binary string that can 
be stored in the View script, how can I then display it? 

image to-image binary-string 

doesn't work.
I remember seeing a script that did this once, but I don't remember 
which script it was. One of Carl's perhaps.
build-pack.r from the library seems to be just what I need.
No, I don't think build-pack.r will work either, as it would have 
to download all the data with the script before the slideshow would 
start.
I have one other idea.
Sweet success!  It now works perfectly running under Cheyenne on 
my local machine. Now for testing on a remote server.
Thank you Dockimbel! Cheyenne made this possible.
Thanks also to Anton, who always helps me through the difficult parts.
Anton
13-Oct-2006
[1831x2]
>> do as-string to-binary mold logo.gif
== make image! [100x24 #{
25252514141414.....
Louis, no problem. Glad I could help you.
Graham
22-Oct-2006
[1833x2]
Can someone at RT update the plugin test page http://www.rebol.net/plugin/tests/test.html
Anyone know how to set the footers, and headers for printing using 
the plugin ?
Graham
24-Oct-2006
[1835x3]
Since IE7 always opens a new window on browse/only, I wonder if I 
can use the plugin to setup a little server to control IE behaviour.
so, this little server waits for commands, and then either browses 
to the required page in an iframe, or, opens up a new tab and puts 
the page there.
What do people think?