[CentralOH] Help for a newbie......

John Santiago jdsantiagojr at gmail.com
Wed Jun 5 21:43:15 CEST 2013


Are you trying to do something like this in Pyrhon?
 <?php
function doSomething () {
// if do something in get, fire do something function
    }

   if (isset($_GET['doSomething']))
        doSomething();
?>
http://localhost?doSomething


On Wed, Jun 5, 2013 at 3:34 PM, Kurtis Mullins <kurtis.mullins at gmail.com>wrote:

> I'm also not completely sure what you're trying to acheive. My first
> intuition is you want http://<hostname>:5555/dosomething to be served by
> Python, in which case the Python script/web-app will allow users to execute
> commands on the server. If that's the case, I recommend being very cautious
> for security purposes.
>
> If this is what you're seeking to do, please elaborate on which issues you
> are having when calling commands and I'd be glad to help out.
>
> Good luck!
> - Kurtis
>
>
> On Wed, Jun 5, 2013 at 3:14 PM, Brian Costlow <brian.costlow at gmail.com>wrote:
>
>> Hi Richard,
>>
>> Welcome!
>>
>> First, I'm not sure I completely understand the question you are asking.
>>
>> Do you want your python program itself to connect to that URL, and
>> display the okay dialog?
>>
>> Or are you trying to use Python to script a browser (Firefox, Chrome, IE)
>> so the browser connects to the URL and hits okay on a dialog displayed in
>> the browser?
>>
>> If the latter, I suggest you look into a web test application, like
>> selenium. You can script it in Python (or a number of other languages) and
>> use it to automate browsers.
>>
>> http://docs.seleniumhq.org/
>>
>> If the former, you'll need to work out how to connect to the URL and get
>> data. I suggest looking into the Requests library.
>>
>> http://docs.python-requests.org/en/latest/
>>
>> Then you'll need to work on a GUI. There are a number of possible
>> choices, though PyQt and TkInter seem to get talked about the most.
>>
>> http://wiki.python.org/moin/GuiProgramming
>>
>> Trying to give this level of help on the mailing list is tough. You might
>> want to bring your code to a dojo for help. Or get started and ask a more
>> specific question.
>>
>> You can go here to find dojos, the next one is this Friday.
>> http://cohpy.org
>>
>> --Brian
>>
>>
>>
>>
>>
>>
>> On Wed, Jun 5, 2013 at 2:36 PM, Richard.C.1 at bwc.state.oh.us <
>> Richard.C.1 at bwc.state.oh.us> wrote:
>>
>>>  First, I’m a real newbie to Python – and I mean a real newbie…  I’m
>>> still going
>>>
>>> through a tutorial on it so I think I don’t know what I don’t know…. and
>>> right
>>>
>>> now I think I’m getting a bit swamped by what seem to be the bunch of
>>> ways
>>>
>>> I might be able to do something….. and what would help is a short
>>> example or
>>>
>>> description of the command/call (s?) that I need to use. Briefly, what I
>>> want to
>>>
>>> be able to do is to execute an internal browser command that will run a
>>> shortcut
>>>
>>> on our internal web that looks like this:
>>>
>>>
>>>
>>> http://<hostname>:5555/dosomething
>>>
>>>
>>>
>>> This will call a server which after a few seconds will show an “OK” box
>>> on the
>>>
>>> screen to which I want to “pipe” an “enter” command.  There’s a lot more
>>> to
>>>
>>> the whole thing, but if I can get an example of what commands/calls/?? I
>>> would
>>>
>>> need to use to do those two actions that would get me started. Thank you
>>> very
>>>
>>> much for any help/suggestions/references/thoughts you may feel like
>>> sharing!
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>  Portions of this message may be confidential under an exemption to
>>> Ohio's public records law or under a legal privilege. If you have received
>>> this message in error or due to an unauthorized transmission or
>>> interception, please delete all copies from your system without disclosing,
>>> copying, or transmitting this message.
>>>
>>> _______________________________________________
>>> CentralOH mailing list
>>> CentralOH at python.org
>>> http://mail.python.org/mailman/listinfo/centraloh
>>>
>>>
>>
>> _______________________________________________
>> CentralOH mailing list
>> CentralOH at python.org
>> http://mail.python.org/mailman/listinfo/centraloh
>>
>>
>
> _______________________________________________
> CentralOH mailing list
> CentralOH at python.org
> http://mail.python.org/mailman/listinfo/centraloh
>
>


-- 
This electronic message is intended to be for the use only of the named
recipient, and may contain information that is confidential or privileged.
If you are not the intended recipient, you are hereby notified that any
disclosure, copying, distribution or use of the contents of this message is
strictly prohibited.  If you have received this message in error or are not
the named recipient, please notify us immediately by contacting the sender
at the electronic mail address noted above, and delete and destroy all
copies of this message.  Thank you.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/centraloh/attachments/20130605/b6e8472f/attachment-0001.html>


More information about the CentralOH mailing list