why does the following js expression:
"test1 foo bar test2".replace(/foo.bar/, "$'")
result in the following string?
"test1 test2 test2"
is the $' in the replace string some sort of control code for including everything after the match???
this behavior was screwing with me most of the day. can anyone explain this?
thanks a lot
ps- this is the case in all browsers i've tested
Hi,
I am passing the email address as part of the url,
for ex. http://example.com/hello/[email protected]
but, when being passed to the application controller it is changed to " user%40hotmail.com ".
I can't seem to understand this special character escaping; confusion.
please help me explain the problem here, and also what can I do to fix it.
I am using python's "webapp" web application framework.
Hey,
For some time i see that employers demand from programmers knowing Sharepoint, but I have problem with understand what it is :/
But today I was at IT training, and main guy told something like that:" Sharepoint is platform for commit code for programmer, control of version etc..."
It is true? It looks like SVN tool... Can someone explain me what advantages it have for c# programmer?
Thanks ;)
$fp = fopen("http://feeds.reuters.com/Reuters/PoliticsNews?format=xml","r")
or die("Error reading RSS data.");
The above coding working correctly in localhost;;;
but in server display "Error reading RSS data."...
i dont know why....
anybody please explain me...
i am waiting...
thanks
My database is growing slower even though I have a bunch of indexes setup. Yesterday I figured out that I need to setup a maintenance plan to build the indexes etc.
So my question is what's the ultimate configuration for this?
Do I need All: "Rebuild idex task", "Reorganize index task" and "update statistics task". Anything else I need to setup. Shrink database? (Today, the only maintenance plans I have is backup)
Does it matter in what order I run them?
Any configuration options I should be aware of?
I've read of problems with log growing wild, how do I fix that? My transaction log is quite small and is usually a problem for me.
-
path fill="none" stroke="#000000" d="M151.5,85.5c0-36.48,29.52-66,66-66"
can anyone explain d="" in detail Im able to understand M tag but i can understand what C tag is? and their details
c0-36.48,29.52-66,66-66
I have the following code that i found on the net. The problem is that it adds in nicely with the group policy editor and i can see it's Catogary under administrative controls but it doesn't show any controls for user input.
What am i doing wrong here?
CLASS USER
category EmailStationary
POLICY "SetEmailStationary"
EXPLAIN "This policy sets the value for stationary"
KEYNAME "Software\Microsoft\Office\11.0\Common\MailSettings"
PART "What is the new stationary to use"
EDITTEXT
VALUENAME "NewStationery"
END PART
END POLICY
END category
Explain which algorithm you would use to implement a function that takes an array of integers and returns the maximum integer in the collection, assuming that the length of the array is less than 1000. Would you use Bubble Sort or Merge Sort and Why?
Also, what happens to the above algorithm choice, if the array length is greater than 1000?
Hi,
guys could anyone explain to my like to a not very inteligent child what is declared here:
(this is taken from another post on this forum)
template<typename C> static char (&f(ChT<int Fallback::*, &C::x>*))[1];
how I read it is:
template of static function f called with (ChT*) but then I can't make sense why is there address of operator and why is there array?
When explaining please picture not very inteligent child and then try to make it clear to it.
Thanks for any help
I am on my way to Europe for 20 days with the wife and teenage kids.
Among us, we have 3 iPhones, 1 Blackberry, 2 iPad 3G and 2 Macbook Pro laptops. Each has Skype. I am very concerned about AT&T data charges, and I am looking for a sensible alternative. For example, the AT&T data plans for the phones and iPads are $200 EACH for 200 MB per device. That is $1,200 and does not even cover the laptops. Ouch!!!
I am thinking about a prepaid data plan from a European cell system of some sort combined with a GSM data modem and a Cradlepoint router, such as the CTR500.
So, questions:
1) Anyone know of a GSM data source in Europe where I can buy a GSM Modem compatible with the CTR500 at a reasonable prepaid rate?
2) Experience with the CTR500?
I am new to powerbuilder and having a lot of trouble using datawindows. I can't get my head around the insert mechanism of it. Can someone explain it to me, or at least point me in the right direction(article, tips etc...) ?
I'm planning to host a website where in the first phase I would target 30,000 users. It is in php and runs on Apache server.
I'm assuming 8,000 users can be online in worst case scenario and 1000 of them will be uploading photographs.
A photograph will be resized to around 1MB at client side and one HTTP request is uploading only one photograph.
My plan:
2 Small EC2 instances to run Apache httpd
2 Small EC2 instances to DB (Postgresql). I to write data and other its read replica.
EBS volumes for DBs
Last, Amazon S3 for uploaded photographs.
My question here
Is Small EC2 instance more than what I require. I mean should I go for micro
Is 8000 simultaneous user a right no. (to decide what EC2 instance to choose) for a new website
Or should I go for Small instance so to make it capable of spikes
Got this code snippet from some website:
int num = 1;
if(*(char *)&num == 1)
{
printf("\nLittle-Endian\n");
}
else
{
printf("Big-Endian\n");
}
Can anyone explain this step-by-step?
&num - Adress of a
(char *)&num - Type-cast address of a into a string
*(char *)&num - Points to the first character of the string
Am I missing anything here?
I have two variables:
char charTime[] = "TIME";
char buf[] = "SOMETHINGELSE";
I want to check if these two are equal... using charTime == buf doesn't work.
What should I use, and can someone explain why using == doesn't work?
Would this action be different in C and C++?
Hi,
I have browsed lift's MegaProtoUser and encountered this construction: ??("Last Name"). Can anyone explain, what that means? Also, I didn't find a way how to add a custom field into MegaProtoUser. The maven's lift's basic archetype defines another field, but it never shows anywhere. (Version 1.0)
Thanks for answering
I reroute certain websites through a proxy with a proxy.pac file.
It basically looks like this:
if (shExpMatch(host, "www.youtube.com"))
{ return "PROXY proxy.domain.tld:8080; DIRECT" }
if (shExpMatch(host, "youtube.com"))
{ return "PROXY proxy.domain.tld:8080; DIRECT" }
At the moment about 125 sites are rerouted using this method.
However, I plan on adding quite a few more domains to it, and I'm guessing it will eventually be a list of 500-1000 domains.
It's important to not reroute all traffic through the proxy.
What's the best way to keep this file optimized, performance-wise ?
Thanks
Can anyone can tell me the N-tier Structure used in Web Programming?
Primarily, in 3 tier structure one is presentation layer, another is business logic layer and last is database access layer.
But for N-tier or 4 tier structure what are the layers and what sort of functions do they hold on them? Please explain me with a brief example of each.
Hi all. I have created a C# DLL that has some forms in it. ( I needed it to be a DLL, not a Windows Application.)
How can I run it as a Windows App? Should I create another app and load it? How? What do I need to learn to do that?
please let me know if I should explain more about my question.
Is it possible to trick the GoGo Inflight WiFi on airlines into thinking that you have a mobile device instead of a laptop?
It seems like most airlines that offer in flight wireless these days use GoGo. They offer different pricing for mobile and laptops. It seems like they are checking the browser's user agent.
Out of curiosity, is it possible to use a Firefox extension like this one to spoof the user-agent and allow a laptop to access the internet under a GoGo mobile plan? How would GoGo handle something like an IMAP email client, like Thunderbird. Do IMAP clients have a user-agent field as well that would normally identify whether the mail client is running on a laptop or mobile device?
Hi there, I have a Motorola Droid 1 with Android 2.2 on it. I found something odd that I don't understand why it works.
If I plug my phone into my home computer which is Windows 7 and I turn on the tethering ability, I am met with a Verizon captive portal and it tells me I need to pay for a tethering plan (which I don't have).
Now the weird thing, if I plug the same phone into my Ubuntu 10.10 laptop and enable tethering it works and can get on the internet with no captive portal showing up.
The only thing I could notice that was different about the connections was Windows connected to the phone with an NDIS driver and Linux connected to the phone with what I think is a raw device mapping.
Would that have anything to do with it?
I want my intent to be launched when the user goes to a certain url: for example, the android market does this with http://market.android.com/ urls. so does youtube. I want mine to do that too. If anybody could explain this, thank you very much. Isaac Waller
Hello all:
I'm an intermediate Linux user and a relative beginner to servers. I would like some help finding resources on setting up a basic server. I have Googled, and am a member of the Ubuntu Forums, but just figure it can't hurt to ask the Stack Overflow community for help as well.
I plan on installing on an old laptop (Lenovo Thinkpad R61i or Toshiba Satellite A105). I have downloaded the latest Ubuntu (9.10) but don't know how to do any of the configurations.
I just want a server to store my files where I can access (download and/ or stream) from a browser. Any help you can give is greatly appreciated.
Thanks!
Thomas
Say I have this url:
http://site.example/dir/
In this folder I have these files: test.ascx.cs and test.ascx
Just to be clear, I am not a .NET developer.
From a security point of view - why can't I access http://site.example/dir/test.ascx.cs and how secure is it to keep those files there?
I assume IIS filters out request that query these kind of files, but can someone explain me this?
Thank you.
Closures are poor man's objects and vice versa.
I have seen this statement at many places on the web (including SO) but I don't quite understand what it means. Could someone please explain what it exactly means?
If possible, please include examples in your answer.
Thanks.