I'm a huge proponent of SELECT CASE. The main advantage is speed. In a SELECT, the condition is evaluated once, then jumps to the appropriate case whereas with an ELSEIF, each condition is evaluated! Take your code for example (sorry, I don't do line numbers :) and thus almost never use GOSUB...
This is the QBasic forum, right? And what does the Absolute Value have to do with anything?
I wanted to access the screen clipping variables within the DirectQB library but I came up with alternate solution.
this:
class Test {
public $A;
public $B;
public static $C;
}
$test = new Test();
print_r($test);
var_dump($test);
yields:
Test Object ( [A] => [B] => )
object(Test)#1 (2) { ["A"]=> NULL ["B"]=> NULL }
Where is the static var C?
Can't say for sure, but I have a negative premonition. Notice that $ext, $secret, $macaddress, and $templatename are now all arrays, containing multiple values, but you are only running one query.
Modify your code to execute three queries, one for each set of values.
for (var $i = 0; i++; i...
Where is $phone and $TName defined? It appears they are blank. Binding a blank values may produce a valid query but not one that you intend to execute. Also, bind_param() is not a PDOStatement method and results in a fatal error upon execution. That being said, I would venture the bet that...
Quick and Dirty:
Inside the while loop, assign the values of 'extension' and 'secret' to hidden inputs where the name is an array.
<input type="hidden" name="extensions[]" value="<? echo $row['extension']; ?>">
<input type="hidden" name="secrets[]" value="<? echo $row['secret']; ?>">...
I am under the impression that defining something as static is to define the var or function in a global scope. One of the first things I learned in programming is not too define things in a global scope (of course, that was back when qbasic was widely used). I was thinking about it last night...
I'm hesitant about using static variables and functions in classes. It seems as though they are becoming commonplace for simplicity sake - but there are always two sides to a coin. What is your argument and why?
-Geates
Currently, I am using a foreach() loop to count the occurrences of numbers in a string...and to count uppercase letters...and to count lowercase letter...and to count special chars. I feel like there is a "simpler" to do it with regex. Is there?
$n = 0;
$string_as_array =...
the window that opens is the "RunsAs" command called by oShell.Run. According to RunAs /?, there is no "hide" option. It appears child processes are hidden but you can try to run the oShell.Run in a hidden state.
oShell.run ("RunAs /noprofile /user:%computername%\postgres " & Chr(34) & "cmd...
I'm not sure if this the correct way to go about it but it works:
.Pattern = "(.+,){3}(?![AR|BR]{2}).*?(\r\n|$)|(\r\n)(\r\n)"
http://ns7.webmasters.com/caspdoc/html/vbscript_language_reference.htm
oops. bad regex pattern. strongm can correct it if this wrong but try:
objRegEx.pattern = "^[R|T|C|U|F|V|H]"
-Geates
http://ns7.webmasters.com/caspdoc/html/vbscript_language_reference.htm
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.