Re: Calling scripts




d43m0n AT shaw DOT ca wrote:

To execute a new script, or to reproduce the results of your script
there are many ways. First you have to determin what you want to
acomplish.

What I actually have going is a switch operation with a number of
cases. After completing certain of the cases, I want it to return to
the top in oredr to start over.

I personally am a command/terminal programmer, I like seeing my results
come through a shell, rather then preprocess through http, as in a "web
site". Now, to get to the point, the best way to look at php is like
looking at any other language. Variables are your best freind, and can
do more then just define foo=bar. To reproduce results, with previous
results, you need to use variables to its fullest. Define functions to
use multiple times or later on in your script. Too loop your script,
that means to start a funtion, and then restart the funtion from the
start to reprocess your data and reexecute the functions.

So what I'm hearing here, I think, is a suggestion to, in this case for
example, create fucntion containing the switch conditional and the call
the function every time I want to start it over, including from within
the function itself. Is this right?

In some cases, it is useful to me to call an external file because in
some cases the file is an html file (an input form, say) with some php
code internal to it. Having it in a separate file makes it easy to
adjust the layout in Dreamweaver which will render the html if it is in
a separate html file.

The user then does something which then recalls the script with the
switch in it. Depending on the post or get data, different cases in
the switch conditional are triggered.

Regarding OOP, I have a general familiarity with it, but haven't used
it to any extent. In this case you are suggesting that it can be used
to create a collection of functions which can be called or modified
according to the objects created from the class. Is this right?

.



Relevant Pages

  • Re: Problem deleting a printer object
    ... I tested out the script suggested by JHP. ... Dim strComputer, objWMI, objPrinter, objWSH, rtnPrinter ... Windows 2000 workstations, Windows XP can handle this without a problem. ... was hoping that someone out there might have a suggestion. ...
    (microsoft.public.scripting.vbscript)
  • Re: EXAMPLE -- Re: Strange issue with `CHOMP not working...
    ... It is not a "why is my perl 101 assignment script not ... opening but not closing files, and second creating a cache (hash of ... suggestion that I was looking for. ... If my problems reoccur, as they may, I will put that ...
    (comp.lang.perl.misc)
  • Send Complex HTML X 2.04 (Problem w Groups)
    ... I downloaded Paul Berkowitz's "Send Complex HTML X 2.04" script ... successfully with Entourage. ... HTML file in IE and then use the script's choice of attaching a web page ...
    (microsoft.public.mac.office.entourage)
  • RE: Setting NIC speed / best practice. SUMMARY
    ... creating a run script ... my suggestion would be to use a script in /etc/rc2.d to set the ... autonegotiation on both the switch and the server, ... configuration file where the settings were being set. ...
    (SunManagers)
  • Re: Automating steps to copy URL from IE into Word
    ... I can't wait to install and try this out. ... I'm curious to see if character formatting in the selection, ... I've done a script that adds a new item to your Internet ... The entire contents of the html file I use is below: ...
    (microsoft.public.word.vba.general)