I am trying to optimize the speed of a query that calculates bias/mean absolute error of forecasts against observations. The forecasts are issued hourly, and make hourly forecasts to the 48th hour. Furthermore, there are about 20 different forecast methods. On top of that, there are 12 different...
Ignore last post. If I could edit posts here I would have.
-> Turns out it was indeed the input being messed with. I was using an AJAX script to pass the username to the server, and I was using encodeURI and not encodeURIcomponent which seems to have fixed the bug. Thanks for your help...
I'm a dumdum, I should have just forced input. I didn't think my scripts were physically changing input, as for some reason the + and & characters are being converted to whitespace. I'll have to look into it more.
Out of curiosity, do you have to escape the '-' character in '/[^A-Za-z0-9]/'...
I'm trying to write a preg_match function that matches invalid characters in an input (in this case, a username). Here is the function:
if ( preg_match('/[^A-Za-z0-9]/', $username) ) { error; }
Based on the regex, the if-statement should return true when it matches a character other than A-Z...
I've been coding in PHP too much lately, and have really fallen short on the HTML/CSS/JScript standards of today. My goal is to have a website that conforms to the HTML 4.01 Strict standard (I do not plan on using XML unless "AJAX" operations that do not return XML- ie. just simple HTML, are...
Ahh, I couldn't help taking a shot at M$.
Anyway, the thing worked, and I'll keep the suggestion in mind. It surprises me that the Error Console didn't pop a warning about having the same names, it's been pretty helpful in getting those bugs.
Appreciate all the help guys.
Ironic, I might have the same problem as him then. I'll have to go off and change my hidden "action" variable which controls 100% of my site to usraction or something because poor little IE can't tell the difference between a form element and a form field based on syntax.
Thanks for finding...
Hate to double post, but I can't see an edit link on my own above.
I changed the function again based on monksnake's suggestion:
function preview_post() {
document.getElementById("postform").action = 'submain.php';
document.getElementById("postform").d.value = 'preview';
w =...
I changed the code accordingly and received the same error.
New code for "preview_post()":
function preview_post() {
document.forms['postform'].action = 'submain.php';
document.forms['postform'].d.value = 'preview';
w =...
Hello, my script is rather simple:
function preview_post() {
document.postform.action = 'submain.php';
document.postform.d.value = 'preview';
w = window.open('submain.php?d=preview','previewwin','scrollbars=yes,width=500,height=600');w.focus();
document.postform.target = 'previewwin'...
What about for percentage values? If you look at that code, (and if I were to show you others), it's the FIELDSET code that seems to jump out of bounds.
I believe this problem happens in a lot of browsers, even in IE for Mac. The tables basically explode, going to a width of 2000px or more. However, these tables are confined in a div:
<div style="position:absolute; top:96; left: 33; width:750;">
which is properly closed at the end of the file...
You can also try to have JavaScript print out the list, to save filesize (and bandwith) on your system, but such scripts are difficult to ensure on all Browser platforms.
How would I set that to 1, if I'm not a Server Administrator (ie. is there a runtime function to set it to 1? Since I am not sure if the administrator will set it up for everyone on the server)
And why would you consider it a security risk? (Besides the obvious fact that users can submit any...
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.