Hello there!
I have this funtion that converts all special chars to uppercase:
function uc_latin1($str) {
if(!defined("LATIN1_UC_CHARS"))
define("LATIN1_UC_CHARS", "ÀÁÂÃÄÅÆÇÈÉÊËÌÍÎÏÐÑÒÓÔÕÖØÙÚÛÜÝ");
if(!defined("LATIN1_LC_CHARS"))
define("LATIN1_LC_CHARS", "àáâãäåæçèéêëìíîïðñòóôõöøùúûüý");
$str = strtoupper ( strtr (…
In the code below I have a function int GetTempString(char Query[]);
calling it in main works fine.
However, when calling the function from a fork the fork hangs (stops running, no errors, no output) before this line: pch = strtok (Query," ,"); the printf shows that the pointer to pch is null. Again this only happens when the fork is executing…
Hello! First and foremost thank you for checking out my problem, and for any help you may give!
Okay, so like the title says I'm in need of calling a php function from my index page, which adds a new record in my database as a vote, using JQuery Ajax. This function will return one integer, which will then be printed inside the form button in…
I need some way to loop in a single line.
Is there a way to simulate new lines in AutoIt? Because if I try
While 1 MsgBox (0,1,2) Wend
It will not work. So I was wondering if there is a way to simulate a new line, something like
While 1 - MsgBox (0,1,2) - Wend
Or some function to do this. I also already tried to make this:
Func…
Hi guys,
I know that there has been much discussion here about this topic, but none of the threads I got across helped me solve this problem. I'm hoping that mine is somewhat unique, and may actually merit a different solution.
I'm instantiating an asp:Button inside a data-bound asp:GridView through template fields. Some of the…
can anyone help me rewrite the function i wrote below using only points and pointer increment/decrement? I dont have much experience with pointer so I dont know what to do.
void reverse(char * s)
{
int i, l = strlen(s);
char c;
for(i = 0; i < (l >> 1); i++)
{
c = s[i];
s[i] = s[l - i - 1];
…
I have a webpage using jquery 1.42
The following 2 segments of code live in my page.
$('body').delegate('h2', 'click', function() {
$(this).after("<p>delegate paragraph!<\/p>");
});
$('body h2').live('click', function() {
$(this).after("<p>live paragraph!<\/p>");
});
The live method always…
Why was the arguments.callee.caller property deprecated in JavaScript?
It was added and then deprecated in JavaScript, but it was omitted altogether by ECMAScript. Some browser (Mozilla, IE) have always supported it and don't have any plans on the map to remove support. Others (Safari, Opera) have adopted support for it,…
So I have this function that I'm trying to convert from a recursive algorithm to an iterative algorithm. I'm not even sure if I have the right subproblems but this seems to determined what I need in the correct way, but recursion can't be used you need to use dynamic programming so I need to change it to iterative bottom…
Hi,
I've been using the following code to trace the execution of my programs:
import sys
import linecache
import random
def traceit(frame, event, arg):
if event == "line":
lineno = frame.f_lineno
filename = frame.f_globals["__file__"]
if filename == "<stdin>":
filename =…
I'm trying to use the Resource Governor in SQL Server 2008 but I find it hard to debug the classification function and figure out what the input variables will have, i.e. does SUSER_NAME() contain the domain name? What does the APP_NAME() string look like?
It's also hard to verify that it's working correctly. What…
I'd be following the procedure outlined here (unless of course someone has a better way to do it), and I'm wondering if I could just have some help being pointed in the right direction on how to start.
Basically I need help first on HOW to create functions, and general tips on making it adjustable for varying…
Hello,
I've intercepted(interposed) dlopen function under MacOS X and some other functions.
I see how my applications calls dlopen in the log, but don't find anything related to open/read functions after dynamic library was dlopened. How does the system accesses and reads the dynamic library file? I've looked…
I'm writing some terrible, terrible code, and I need a way to put a free() in the middle of a statement. The actual code is:
int main(){
return printf("%s", isPalindrome(fgets(malloc(1000), 1000, stdin))?"Yes!\n":"No!\n") >= 0;
// leak 1000 bytes of memory
}
I was using alloca(), but I can't be…
Let's say that we have a function like so
template <class T, class T2>
T getMin(T a, T2 b) {
if(a < b)
return a;
return b;
}
if we call the function like so
int a, b;
long c;
a = getMin(b, c);
if c is < a, then the value of c will be type casted to int.
Is it possible to make the…
I created a GUI and used uiimport to import a dataset into matlab workspace, I would like to pass this imported data to another function in matlab...How do I pass this imported dataset into another function....I tried doing diz...but it couldnt pick diz....it doesnt pick the data on the matlab…
I'm usin the OpenPrinter function and the first parameter the function gets called "pPrinterName"
and that's it's MSDN description:
[in] Pointer to a null-terminated string that specifies the name of the printer or print server, the printer object, the XcvMonitor, or the XcvPort.
For a…
Hi all
I have a series of asp:ImageButtons and one asp:Image(Big). Clicking on each ImageButton should change the ImageUrl of asp:Image to a new ImageUrl. How can we handle this using one Javascript function. Because I dont wanna code ImageButton_Click for each and every asp:ImageButton. This…
I want to add the return value from the function call to an array iff something is returned (not by default, i.e. if I have a return statement in the subroutine.)
so I'm using unshift @{$errors}, "HashValidator::$vfunction($hashref)"; but this actually adds the string of the function call…
I have a Game.cpp, and I am calling a update function in my Player class. In my player update Function I have it to check for keyboard input, and it seems to work, but whenever I try to call the .move() function, it seems to not work. I get no errors either. I am new to sfml, and decent…