I am new at using the resource function in moodle v1.5.
Can I get the input for making the google example to work?
The example I am refering to is the program example in the features page.
This is view.php?id=34
This example searches google with your login name
Thanks Martin
Can I use this same approach run an exe file on my localhost?
How can I get the options for the google command line?
This approach is meant to sent parameters to another application running on an webserver. This application then returns something to your browser. You can't use this approach to start regular pc programs... if that's what you mean with an exe file.
Now how do you know which parameters to send?
Easiest way is to do a search for Moodle
in your favorite search engine. (thus increasing Moodle's page ranking while you're at it )
On the results page, look at the location bar of your browser.
It says something like this:
http://search.yahoo.com/search?p=moodle&sm=Yahoo%21+Search&fr=FP-tab-web-t&toggle=1&cop=&ei=UTF-8
See all the a=xxxx
pairs separated by the & sign?
Take out the p=moodle&
part, because that is the part we would like to automatically contain our name.
Paste the resulting incomplete address in the Location: field.
Add one parameter Full name to the parameter list. This will contain the name of the logged in user.
Make it use p
as the variable name, because that is what Yahoo uses to pass the search term.
Try it!
Now experiment with other search engines, other parameters (Moodle knows more than just your name), etc...