• Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

World: r4wp

[Web] Anything related to the WWW

Chris
27-Sep-2012
[55x6]
do http://reb4.me/r/oauth

test-site: http://192.168.0.60.xip.io:8080/

probe-lowercase: func [str [string!]][
    lowercase copy str
]

read [
    scheme: 'oauth
    target: 'get
    url: test-site
    user-data: context [a: "Foo"] ; params
    key: make key [
        consumer-key: consumer-secret: "Your Keys Here"
    ]
    user: make user [token: secret: "Your User Keys Here"]
    awake: :probe-lowercase ; result processor, like :load-json
]
(obviously you'll need to change the test-site to your own test service)
I'm pretty sure this is a grevious abuse of R2's port system, but 
it does mean there is no new global words.
Yey! Works with Twitter!!
do http://reb4.me/r/oauth
do http://reb4.me/r/altjson

tm: read [
	scheme: 'oauth
	url: https://api.twitter.com/1/statuses/home_timeline.json
	target: 'get
	user-data: context [count: 10]
	key: make key [
		Consumer-Key: #consumer_key
		Consumer-Secret: #consumer_secret
	]
	user: make user [
		token: #user_key
		secret: #user_secret
	]
	awake: :load-json
]
Endo, I don't think this will help you with Salesforce, but breaking 
the OAuth part out should make it easier to adapt to OAuth 2.0.
Endo
28-Sep-2012
[61]
Wow thanks a lot Chris! Thanks for separating OAuth port scheme, 
unfortunately I'm not familiar with OAuth but I'll try it with Salesforce. 
Thanks a lot!
Gabriele
28-Sep-2012
[62]
http://hueniverse.com/2012/07/oauth-2-0-and-the-road-to-hell/
Endo
28-Sep-2012
[63x3]
I know, I already read it. But SF uses OAuth 2. :(
Is GET supported in read/custom ?
print read/custom http://localhost/test.rsp[get "a=b&c=d"]
Or should I use Graham's custom http?
GrahamC
28-Sep-2012
[66]
Read is GET
Endo
28-Sep-2012
[67]
I tried to change the method without changing the URL when switching 
POST and GET. Didn't work. Anyway, not a problem.
GrahamC
28-Sep-2012
[68x3]
not sure why you want read/custom for unless you're altering the 
header contents
read http://localhost.rsp?a=b&c=d
read/custom http://localhost.rsp?a=b&c=d[ header [ Cookie: "authtoken=anotherfoo" 
]]
Endo
28-Sep-2012
[71]
There are different authentication methods on Salesforce, so I'm 
just testing.
Chris
4-Oct-2012
[72]
I am new to Git. I'd like to use it (or something similar) to keep 
a distributed copy of a web app I am developing. I'd like copies 
on two local systems (laptop and desktop) with the possibility of 
sharing with another developer based far away and deploying the app 
on my web host.


I sort of get the concept (at least the part about commits, etc), 
but am not really sure how to keep everything in sync. Is it worth 
using a hosting service like GitHub or Bitbucket (I know that perhaps 
defeats the purpose) to assure availability or figuring out how to 
use the web host for this purpose?
Kaj
4-Oct-2012
[73]
You may want to try Fossil. It's much easier to run your own server
Andreas
4-Oct-2012
[74]
To "keep everything in sync" with Git, you have have to do pairwise 
syncs. Each pairwise sync can be initiated from either side, the 
respective commands being "fetch" (from remote to local) and "push" 
(from local to remote).


If you want to keep many separate sites in sync, mediating the sync 
via a central host makes sense (as it avoids the exponential explosion 
of pairwise syncs).


If you have SSH access to your web host, using your web host for 
a central Git repository is trivial (assuming you have - or can get 
- Git installed on the web host).
Chris
4-Oct-2012
[75x2]
In this one case, the host has instructions to set up Git on a subdomain. 
I'd have to consider it as it doesn't appear to be private.
Thanks Kaj, will look it over...
Chris
6-Oct-2012
[77x2]
I'm trying out BitBucket with Git for now, the control over who can 
update being for now the deciding factor.  I have the following setup 
in mind:

http://www.dropbox.com/s/hkptm400jksmoet/git-setup.jpg

(sorry, bit of a crude sketch)

It's entirely probable that I'm using it naively and/or inefficiently, 
but so far I have the ME and BITBUCKET parts working just as I would 
have hoped. I'm pretty sure there's a million intricate parts to 
learn, but feel this is a good start. Am I overlooking anything obvious?
If I set up the link to the web host from the ME area, does that 
become available to the collaborator? (don't want it to)
Andreas
7-Oct-2012
[79]
Looks like a sensible setup.


No, if you link from ME to HOST, that doesn't become available to 
COLLABORATOR.
Oldes
2-Nov-2012
[80]
Apple's web animation compression :) https://docs.google.com/document/pub?id=1GWTMLjqQsQS45FWwqNG9ztQTdGF48hQYpjQHR_d1WsI
NickA
3-Nov-2012
[81]
Cool
Robert
19-Nov-2012
[82]
Does anyone know how I can pre-process an Apache2 configuration and 
store it in a single file?
NickA
19-Nov-2012
[83x2]
No, but don't try to use any GPL licenced tools to do it ... (ba 
dump bump)
(or something like that)
Gregg
19-Nov-2012
[85]
Not sure exactly what you mean Robert. I've written tools to generate 
Apache configs, if that's along the lines of what you're doing.
Evgeniy Philippov
23-Dec-2012
[86x2:last]
To start some new discussions, 1) I like Squeak/Pharo Smalltalk's 
AIDA/Seaside systems. Hope to to practice them in realworld soon 
(creating a community site)... 2) I'm coding a new Oberon system 
 which will be able to do one of the following at once: a) interpret 
oberon b) translate oberon to x86 machine code c) translate oberon 
to javascript. This is a very long-term project, but I get excellent 
support from the oberoncore.ru community, and am actually making 
good progress. Current oberon project status is c++ sourcecode-based 
ssystem interprets oberon, interpreter has many temporary stubs.
The license for oberon project is GPLv3 or later.