instruction_seed stringlengths 1 35.8k | _source stringclasses 1
value |
|---|---|
I have a question about cURL. I am using cURL with this function:
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true);
Only this was causing an error: "Message: curl_setopt() [function.curl-setopt]: CURLOPT_FOLLOWLOCATION cannot be activated when in safe_mode or an open_basedir is set"
So I asked my hosting provider to fix... | stackexchange/codereview |
I have seen a lot of posts and found lots of data on the net about this but I am still confused.
I have downloaded a .jar file and I need to increase its heap size. I have added the jre1.6/bin in the Path of Windows 64 bit and I run from cmd.
The problem arises that it says unable to access jar file.
Can anybody expla... | stackexchange/codereview |
In my application first I am displaying home activity. In home activity I am getting the value from webservice and parsing the value and displaying to the user. From the home activity user click it will display to article display activity. From article display activity if user clicks it will come back to the home activ... | stackexchange/codereview |
So I'd like to know what is the general algorithm to implementing an instant search that is not load intensive. Not specifically on the web but even in a desktop/winforms application.
Correct me if Im wrong but one cannot send async calls on every key stroke right? (Not sure how google instant manages this) It would c... | stackexchange/codereview |
I have a text in utf-8 and I want to decode it, using utf8_decode()
But when I do that I lose a part of the text, utf8_decode() decodes the string until it finds a character –
Any idea to solve this problem ?
| stackexchange/codereview |
I would like some feedback regarding the IService class listed below. From what I know, this type of class is related to the "active-object" pattern. Please excuse/correct if I use any related terminology incorrectly. Basically the idea is that the classes using this active object class need to provide a start and a st... | stackexchange/codereview |
If this is a sample XML::
<root>
<tag1>data
data
data</tag1>
<tag2>
</tag2>
<tag3> </tag3>
</root>
This file is viewed differently in different browsers and XML viewer/editors,
some viewers display 1st <tag/> element as <tag>data data data</tag> some display as is,
Some viewers, treat new line as nbsp... | stackexchange/codereview |
I have following problem
I have a structure
typedef struct
{
Int16 real;
Int16 imag;
}sCplx16;
Int32 Data; //Data has real-imag packed into 32 bits. real-imag are 16 bits each.
Now I am getting Int32 Value with real-imag packed together. I have already written function that takes sCplx16 argument and I don... | stackexchange/codereview |
Here's my code:
<Grid>
<Button Content="Button" Click="button1_Click" />
<DataGrid ItemsSource ="{Binding Lst}" />
</Grid>
Code-Behind:
private void button1_Click(object sender, RoutedEventArgs e)
{
(this.DataContext as Some).remove();
}
DataSource is:
public class Some : INotifyPropert... | stackexchange/codereview |
At the moment, I have a process-buffer which is utf-8-auto (emacs modeline reports the buffer as utf-8-auto-dos) with CRLF style newlines. When I write multi-line text into the buffer via a process-send-region or process-send-string each line is suffixed with ^M.
What makes this problem odd is that text written to the ... | stackexchange/codereview |
As you probably already know (or read quote at the end of this post), Facebook is deprecating FBML in favor of iframes for developping applications.
I am currently launching a new browser plug in and need a landing tab on my facebook page with personalized install buttons and all the useful features one can wish to hav... | stackexchange/codereview |
i have installed wamp but my mysql service is not starting.
i got an error in mysql log file. It says "The first specified data file .\ibdata1 did not exist:"
| stackexchange/codereview |
In order to prevent another command windows from showing, I have tried the following two methods
1)
StartInfo.UseShellExecute = true;
StartInfo.WindowStyle = ProcessWindowStyle.Hidden;
2)
StartInfo.UseShellExecute = false;
Is there any pros and cons of those usage?
| stackexchange/codereview |
How can I check the URL path for certain folders? I ask so that if we're in a certain folder, we can make a tab selected in the nav bar (just apply a style to that specific li).
So far I know
$pagePath = $_SERVER['REQUEST_URI'];
So I can get a return that says something like /music/song/120/ (or whatever it is). What... | stackexchange/codereview |
I'm using cfchart tag to draw my line chart in ColdFusion.
My x-axis range is from 1 to 24 and it is fix number of labels for all my charts.
But in my chart, I may have values for first 10 (or any fix number from 1 to 24) points. I mean, my query row count will be 10.
So query with 24 points will show full graph ad que... | stackexchange/codereview |
If I do this it fails validation
<header>
<hgroup>
<a href="#">
<h1>Title</h1>
<h2>Tagline</h2>
</a>
</hgroup>
</header>
But if I do this, then Firefox chokes on it
<header>
<a href="#">
<hgroup>
<h1>Title</h1>
<h2>Tagline</h2>
</hgroup>
</a>
</header>
What is the correct way to have the whol... | stackexchange/codereview |
I have the following code:
namespace WebService1
{
[System.Web.Services.WebService(Namespace = "mynamespace",
Name = "ControlModuleService")]
[System.ComponentModel.ToolboxItem(false)]
[System.Web.Services.WebServiceBindingAttribute(Name = "ControlModulePort"),
SoapDocumentService(SoapB... | stackexchange/codereview |
I know you can put a row into an array but I am having trouble putting a column into an array. I have no code yet. I just wanna get the auto incrementing column "id" and put it into an array like like..
$array[0] = 1;
$array[1] = 2;
$array[2] = 3;
| stackexchange/codereview |
I'm trying to get the textual contents of the divs in the markup below. However, I can't seem to select the textual content of the div with class='ui-selected'. I need to "200", "x", "200". How do I get those?
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><... | stackexchange/codereview |
I am not sure how to send HTTP Auth headers.
I have the following HttpClient to get requests, but not sure how I can send requests?
public class RestClient extends AsyncTask<String, Void, JSONObject> {
private String convertStreamToString(InputStream is) {
/*
* To convert the InputStrea... | stackexchange/codereview |
I want to programmatically bind an XML file containing some results pulled out from database to my Datagrid. My XML looks like:
<root>
<resultset>
<header>
<column> Col 1 </column>
<column> Col 2 </column>
</header>
<data>
<row>
<field>Valu... | stackexchange/codereview |
I have a S60 5th edition mobile which supports English language only. How to develop an application for it in any other language? Can we install required language pack? Or do we need phones which support required language pack? (Basically I want to develop an application entirely in Tamil language)
Thanks
| stackexchange/codereview |
I have a WPF canvas that I can scale, scroll and whatever.
Now I want to draw (tiling) gridlines on it - preferably depending on the scale, which means that when you zoom out the old gridlines fade away and new (bigger scale, but due to zooming seemingly the same) gridlines fade in.
I've heard some people yelling "Tile... | stackexchange/codereview |
Is it possible to include a clause in the where (LINQ) but only if its "NOT" empty ?
i.e.
where c.Code == sCode && p.Code == code
In this case the variable (standard c#) is called code ... if its NOT empty then the above where is great.. but if its empty then i don't want to include in it the where
i.e.
where c.Co... | stackexchange/codereview |
I am very new to iOS development. The app I need is very simple: just open a web browser and go to a specific URL when my app is launched. So in the delegate file, in didFinishLaunchingWithOptions, I add a line of code:
[[UIApplication sharedApplication] openURL:[NSURL URLWithString:@"http://www.google.com"]];
The app ... | stackexchange/codereview |
I got a question with xml parsing. Normally,the XML file style like this:
<person>
<name> abc </name>
<age> 19 </age>
<gender> male </gender>
</person>
In this way, we use
elementName isEqualToString:@"name"
elementName isEqualToString:@"age"
elementName isEqualToString:@"gender"
to identify the eleme... | stackexchange/codereview |
here is the setup
sshd_config:
Match User sftp
ChrootDirectory /chroot/sftp
I connect just fine to the folder
/chroot/sftp
However I cannot access the website developer folder due to it being outside the scope of the defined chrootdirectory
/usr/lib/apache2/htdocs
How can I access this directory? Is it possible ... | stackexchange/codereview |
Hey im writing a small program in python 2.6 and i have defined
2 helper functions which does almost all i want, for instance
def helper1:
...
def helper2:
...
Now my problem is that i want to make a new function that gather the two functions in one function so i dont have to write (in shell):
list(helper1(... | stackexchange/codereview |
I a bigginer to this FlashBuilder, i have developed an application, but when i want to run the app, an error "Unbale to resolve resource bundle "containers: for locale en_US" is showing, eventhough i did not configure any locales to my appl. My Flex Compiler shows only -locale en_US. Please help ?
| stackexchange/codereview |
I have a requirement which take lots of rules validated against the java value objects and produces results. (we cant use any rule engine apps in our company, lots of formalities and lots of questions to be answered).
So, rather than implementing the rules as ifs' in java code I suggested to implement a small rule engi... | stackexchange/codereview |
The Method request.getRequestURI() returns URI with context path.
For example, if the base URL of an application is http://localhost:8080/myapp/ (i.e. the context path is myapp), and I call request.getRequestURI() for http://localhost:8080/myapp/secure/users, it will return /myapp/secure/users.
Is there any way we ca... | stackexchange/codereview |
I cannot really get it. Why do we need it at all? I mean if I use the same type parameter, I think that means they should be the same type.
I heard it can help the compiler to avoid the infinite loop. Can someone tell me some more details about that?
In the end, are there any 'patterns and practices' we should follow o... | stackexchange/codereview |
I am started navigation based application. how can i access from Uitableview to second menu ( xib ).any sample
| stackexchange/codereview |
I've been looking for a while to sort a JSON object like this
{"results": [
{
"layerId": 5,
"layerName": "Pharmaceutical Entities",
"attributes": {
"OBJECTID": "35",
"FACILITYTYPE": "Pharmacy",
"FACILITYSUBTYPE": "24 Hr Pharmacy",
"COMMERCIALNAME_E": "SADD MAARAB PHARMACY",
}... | stackexchange/codereview |
I'm writing a search form for my Rails (2.3.9 but I've checked that this problem exists also on 3.0.3) application.
The problem is that Rails is stripping quotation marks from the users input.
I would like to give the users possibility to write:
"ruby on rails" : and this would search full text for the whole string
r... | stackexchange/codereview |
I understand that you can describe your REST webservice while using WSDL.
Is this a good idea if you don't use WCF? Is there a better way to allow service discovery and bind your request/response to certain types?
If you use json you can use SMD and JSON-Schema but what if you use XML or YAML?
EDIT:
I have found this s... | stackexchange/codereview |
I'm attempting to send a DELETE request through csharp, ASP.NET and its returnin a (405) Error. Below is the code that I'm using:
request =
System.Net.HttpWebRequest.Create(myTargetURL);
request.Method = "DELETE"; response =
(System.Net.HttpWebResponse)request.GetResponse();
Anybody can shed some light on this?... | stackexchange/codereview |
I have this simple setup:
<StackPanel>
<TextBox Text="wpf1" PreviewLostKeyboardFocus="TextBox_PreviewLostKeyboardFocus" />
<TextBox Text="wpf2" PreviewLostKeyboardFocus="TextBox_PreviewLostKeyboardFocus" />
<WindowsFormsHost>
<wf:TextBox Text="winforms" />
</WindowsFormsHost>
</StackPanel>
priv... | stackexchange/codereview |
I haven't used LINQ extensively but the more I use it the more I realize how powerful it can be. Using the LinqDataSource.OrderBy clause is obviously easy if you want to sort from a property on the bounded items but what if you want to sort the items based on a method return? Take this class for instance (please ignore... | stackexchange/codereview |
I am tasked with requirements for the production machine (Server 2008 R2), and am wondering if this project setup would work with only .NET 4.0 installed and IIS 7 for WCF Service. Is .NET 3.5 needed to load assemblies that that are targeted to it?
A VS2010 solution contains several projects:
Projects targeted to .NET ... | stackexchange/codereview |
After reading some posts about the railties, I've didn't understand if i should only create railsties for gem/plugins that direct interfere with the rails initialization (e.g. create a generator, change some configuration) or if I should also use it for gem/plugins that only add functionality to rails (e.g. include som... | stackexchange/codereview |
Im having some problem with a service that acts as a listener of some events that are originated from an external library, that library creates a thread for reading comm port and send back the data to my listener (the grails service) on certain cases.
The problem is that i cannot update the database when methods are c... | stackexchange/codereview |
i have got a table (stores data of forum, means normally no edit and update just insert) on which i have a primary key column which is as we know a clustered index.
please tell me, will i get any advantage if i creates a non-clustered index on that column (primary key column)?
EDIT: my table has got currently around 60... | stackexchange/codereview |
How do I manually install a plugin in Eclipse? Or how do I force the installer to install a plugin, even when it doesn't want to?
E.g., I am trying to downgrade a plugin (an update for which contained a bug that I cannot work with). I have tried going to About Eclipse -> Installation Details -> Installation History and... | stackexchange/codereview |
I'm trying to write a script that will make produce an easy overview over a list of orders.
I have an array that looks like this:
Array(
[0]=>Array(
[0] => name of product 1
[1] => name of options for product
[3] => quantity (an integer)
)
[1]=>Array(
... | stackexchange/codereview |
I'm new at using WCF with secure services.
I'm trying to connect to a java webservice with secure HTTPS transport and it uses WS-Security UsernamePassword Token Authentication.
I've trying to connect with WCF client using the following binding with no luck.
<bindings>
<wsHttpBinding>
<binding name="OperationsEnd... | stackexchange/codereview |
#pragma omp parallel for default(none) shared(x) private (y, z, f) ordered
for (i = 0; i < 512; i++) {
#pragma omp ordered
for (y = 0; y < 512; y++) {
for (z = 0, f = 0; z < 512; z++) {
x[f++] = z + i + y;
}
}
}
The above code runs slower than non SMP execution by about 20%
on ... | stackexchange/codereview |
I wonder how can I remove object in other method, for example I want to delete the dog object in deleteObject method, but it just deletes the current reference to the object!
Is there any solution or not?
public class Main {
public static void main(String[] args) {
Dog dog = new Dog("Max");
deleteO... | stackexchange/codereview |
Is there any way we can add the same functionality like Gesture recognization available for ios 4.0 + in iPhone 3.1.3
Please help with some links or codes available as i am unable to find it.
Also please inform is it really possible to do such smooth zoom+rotate in iphone 3.1.3
Thanks in advance
| stackexchange/codereview |
I found the answer for both C Structs and C# classes but came back empty-handed concerning C++.
EDIT : In C, you can't.
In C# it's the GetProperties() method.
The context: I have a C++ class with public attributes (let's say a Point with X, Y, Z). I want to send these attributes via UDP to a Java client. My idea was t... | stackexchange/codereview |
I've got a project I've moved over from VS2008 to VS2010.
The VS2008 project contains some Crystal Reports files.
Yesterday, someone asked me to add a new element to one of these. I did so. Crystal Reports now won't load the file.
I realise there's some difference between Crystal Reports in VS2008 and VS2010, so I trie... | stackexchange/codereview |
I have label within a DetailsView.
I need to change Text property of this Label inside the DetailsView after event ItemInserted has been trigged.
Script does not throws any error, but the Label does not change its text property.
Any ideas what I am doing wrong?
Thanks for your time!
Markup:
<asp:DetailsView ID="uxInser... | stackexchange/codereview |
I am a c++ programmer, Here is a C++ code, how to have similar JS code,
class A {
public:
void sayHello();
};
class B {
public:
A a;
};
main()
{
B b;
b.a.sayHello();
}
| stackexchange/codereview |
I'm developing an app which uses a UIScrollView to show a list of images based on search criteria. Using a button the user can load more images.
When testing on an iPhone 4 the ViewController receives a memory-warning at ~750 images. When testing on an iPod 2nd generation a memory warning is received at ~150 images.
My... | stackexchange/codereview |
I´m learning Perl, I would like to surrounded an expression like that
function1(mathematical_expresion1)*function2(mathematical_expresion2)
Where 'function1'and 'function2' could be whatever word and combine numbers inside, for instance function1 could be fun3dec, fun4nels, factor9 or whatever...
so my code will becam... | stackexchange/codereview |
I have a ASP.NET application. From that, User register, User will get email after registration.
My Req : When user click on link provided in email. Then it should go to my ASP.Net application page . That page should install a wincows application on Client system through web ( I was inspired by Microsoft Windows update... | stackexchange/codereview |
I am debugging a VB 6.0 application which deals a lot in collections. In one such scenario the application is fetching the object from a collection using text entered in a textbox as a key.
Now I want to know what key needs to be entered in the textbox for me to fetch the required object in the collection.
| stackexchange/codereview |
Hi everyone
I think this is a simple question but its got me stuck. I've been using the Leptonica image library and came across the term "Words Per Line" or "WPL". I tracked down the code but have no idea what its for:
wpl = (width * depth + 31) / 32;
Has anyone ever come across wpl when working with images?
Thanks,
La... | stackexchange/codereview |
I have a string and want to test using PHP if it's a valid base64 encoded or not.
| stackexchange/codereview |
I have a scenario where I want a user when viewing a list item to be presented with a custom action to create a site. This is pretty similar to the scenario provided in the MOSS 2007 SharePoint Guidance. What makes it different is that I want the site created with the url and name taken from the list item, and then a w... | stackexchange/codereview |
i wanted to pass parameters to the java program when i run it through php script
could anyone tell me how to do that
| stackexchange/codereview |
When I am tryng to pass the gridview cell values to an array everything is perfect but the array is empty after executing the code.
When I see through debug mode the index of selected row also is fine, i.e. when I select two rows using checkbox among 1000 the count shows exactly 2 in the array but the data is empty.
I'... | stackexchange/codereview |
In normal blocking socket, I can use Socket.getOutputStream().flush() to partly control when to send out a TCP packet. Is there an equivalent operation for SocketChannel?
Edit: My guess is that every time I call SocketChannel.write(ByteBuffer src), at least one individual packet will be sent, even the buffer has only 1... | stackexchange/codereview |
How can I convert a number held by a string into a double?
| stackexchange/codereview |
So I have an application and I want to keep it working even if the screen is turned off.
Previously when I wanted to do that I used this hack/trick - I play a silent/empty sound in a loop in the background (AudioServicesPlaySystemSound) so if user presses the on/off button the application still works in the background ... | stackexchange/codereview |
I'm trying to set the following members of Component org.jboss.seam.mail.mailSession which are defined as:
boolean ssl;
boolean tls = true;
(both have getter and setter methods)
before the method create which is annotated with @Create is called .
I want to prevent the framework to use SSL,TLS. The mailSession componen... | stackexchange/codereview |
Is it possible to create connected web parts in Sharepoint that have multiple connections to the provider.
For example,
Web Part A and B are the provider, and Web Part C is the consumer.
A is the provider to consumer C, and B is also the provider to consumer C.
Thanks.
Rhys,
I tried this and doesn't seem to work. ... | stackexchange/codereview |
What is the best way to run a static method in several threads, using a thread pool?
Also I trying to pass an argument to the static method. something like
Class A{
public static runTask(int i){
....
}
}
and from a main:
ThreadPool pool = new ThreadPool(5, "poolname");
for(int i=1; i<10; i++){
A.runTask(i) ... | stackexchange/codereview |
I'm no Makefile expert, and I was wondering if someone knew of some kind of analyzer or simulator that would start from the top-most Makefile all the way down to the inner-most Makefile, each time showing me the value of each variable and the order in which it goes through rules.
Thank you.
| stackexchange/codereview |
arrays.jsp:
//...
var x = <c:out value="${x}"/>
<c:if test="${empty doExternal}">
processExternalArrays();
</c:if>
//...
I want to minify/obfuscate JavaScript contained in a large JSP file in which numerous JSP/JSTL variables are mixed into the JavaScript code such as in the snippet above.
The code relies on variables... | stackexchange/codereview |
I've got a console application that crashes with an I/O error 6 when the output is redirected to a file. It probably has something to do with the fact that the console application changes the text color, which doesn't make much sense in a file.
This works: c:\dir\app.exe
This crashes: c:\dir\app.exe >out.txt
When I s... | stackexchange/codereview |
I'm writing an applications and I want two version's of it on the market,
the first would be a trial version, and the second is a full version.
I wanted to ask what is the best way to have it as 2 package names?
If I just change the package name in the manifest I also need to change all the references in my classes, w... | stackexchange/codereview |
I'm seeing behavior I don't expect with the cat commands and flush.console() in RGui 2.12.0 (but not Rterm) for Windows. I wanted to see whether it was a problem with my system (or a known behavior) before reporting it as a bug. Specifically I'm seeing strange UNICODE looking characters as it iterates through. Pleas... | stackexchange/codereview |
PrintDialog.Document don't exist as element in the drop down list from visual studio 2010;
Demonstration:
| stackexchange/codereview |
I would like to have a select listed by offset difference to UTC, like:
<select value=1>(GMT 00:00) GMT</select>
<select value=1>(GMT 00:00) Lisbon</select>
<select value=1>(GMT +00:01) Madrid</select>
Just like in Rails:
https://signup.37signals.com/highrise/Free/signup/new
We're using Sinatra+Padrino.
| stackexchange/codereview |
I have a certain problem with IE8 (and only IE), when I focus an input field which has text in it the cursor moves to the beginning of that field. I'm trying to set the cursor at the end. I've googled around and found the following solution:
function setSelectionRange(input, selectionStart, selectionEnd) {
input = ... | stackexchange/codereview |
for some reason the Wix shortcut is not removed on uninstall.
this is my code:
<Directory Id="ProgramFilesFolder">
<Directory Id="INSTALLDIR" Name="App">
<Component Id="AppExecutable" DiskId="1" Guid="12854481-BE33-4733-8B46-FDB424057C9A">
<File Id="App1ExecutableFile" Source="$(var.RESOURCEDIR)\Ap... | stackexchange/codereview |
I am trying to test my controller's create action. I am using Devise for authentication, and have used the before_filter method to limit access to the create action to logged-in users. Here is the relevant part of my controller.
class RawDataSetsController < ApplicationController
before_filter :authenticate_user!, :e... | stackexchange/codereview |
I want to make a VBO(view bulk operation module) in drupal, with radio buttons instead of a checkbox for each field of my view.
Is it any way to configure VBO for this purpose? Or should I use another module?
My problem is to make a list of a node type and for each of them set a status and finally submit status for al... | stackexchange/codereview |
I am using solr search in my MVC .NET application. Now I am doing a free search on it. How can I use boosting in my solr search?
Thanks.
| stackexchange/codereview |
I need to be able to select two records from a table based on ID.
I need the first one, and the last one (so min, and max)
Example:
Customer
ID NAME
1 Bob
50 Bob
Any ideas? Thanks.
| stackexchange/codereview |
I'm trying to write a plugin, and among the tasks I want to perform I want to be able to call route helper methods from within the plugin. For instance, if I have map.resources :user, I want to be able to call user_path(:id => 1) from my plugin. I keep getting undefined method user_path error.
In rails 3, you can do th... | stackexchange/codereview |
Can you please guide, is there any feasibility to track/get current incoming call. Is any framework exposing is this?
| stackexchange/codereview |
For a Windows Phone 7 app, I have several Customer records that I need to display based on when the customers where created, so something like a start date and end date filter (maybe some canned entries listbox that lets you pick - tomorrow, week, month, custom)
Any UI guidance of how to do this so that the interface i... | stackexchange/codereview |
I have an application running SDK 3.2, I am using NSXMLParserDelegate for parsing XML.
I upgraded it to SDK 4.2 and my application keeps crashing when using the NSXMLParserDelegate, a warning said:
'Class' does not implement the 'NSXMLParserDelegate' protocol
I have tried the following:
Add the protocol to my class N... | stackexchange/codereview |
We can launch the app in two ways, 1 is form the app, clicking on device back button till we reach the android home screen and launching the app or 2nd is from the app we can click the device home button and then we can launch.
How can we differentiate these to launches? In 2nd type launch onrestart will be called, onr... | stackexchange/codereview |
How to covert the NSTimeInterval to NSString? I have
NSTimeInterval today = [[NSDate date] timeIntervalSince1970];
I have to give "today" as input as NSString.
| stackexchange/codereview |
All my blog post URLs currently look like this: http://www.HeyItsMyBlog.com/?p=368
I want to change the URLs so instead they look like http://www.HeyItsMyBlog.com/2010/11/new-kittens-omg/
This is an easy change in the WordPress admin panel, but there are a bunch of people who have linked to my currently-formatted URLs ... | stackexchange/codereview |
I wanted to create a vector of a subclass of QGraphicsRectItem, named MyRect. This vector is initialized in MyClass:
MyClass::MyClass () : myVector_(80, std::vector<MyRect>(60, MyRect(true,true)))
...
I learned that vector constructs the first element and then copies it with the copy constructor. The problem is that Q... | stackexchange/codereview |
I'm trying to write a single piece of code to parse javascript in both IE and firefox.
The following works in IE, and functions without complaining in firefox
function XmlDom(sXml){
var oXml;
if (window.ActiveXObject) {
// ie
oXml = new ActiveXObject("Microsoft.XMLDOM");
oXml.resolveExte... | stackexchange/codereview |
How do i fire a ASP.NET click event when the user press enter.
This is what i do now but it does not work:
function KeyDownHandler(event) {
if (event.keyCode == 13) {
__doPostBack('<% ButtonGetListforUser.ClientID %>', 'OnClick');
isClicked = true;
}
}
| stackexchange/codereview |
I'm trying to automate my db restores during development, using TSQL on SQL Server 2008, using sqlalchemy with pyodbc as a transport.
The command I'm executing is:
"""CREATE DATABASE dbname
restore database dbname FROM DISK='C:\Backups\dbname.bak' WITH REPLACE,MOVE 'dbname_data' TO 'C:\Databases\dbname_data.mdf',MOVE '... | stackexchange/codereview |
Can someone tell me what I am doing wrong here? I have a wrapper at 100% and two divs inside. The top div needs to be at the top of the wrapper and the bottom div needs to be at the bottom of the wrapper. It isn't working.
Here is what I have. I've tried vertical-align on both inner divs but it doesn't work either.
<st... | stackexchange/codereview |
how to call javascript function from anchor tag which is part of a javascript string?
var htmlVar = '<span> Name: ' + arNames[j] + '</span></br><span> Last: ' + arLast[j] + '</span><br/><a javascript:setProfile(\\"+ dob[j]+\\",\\"+state[j]+\\") >View</a>';
| stackexchange/codereview |
When calling javah on a .java file in my android project, javah was unable to find the android classes (specifically android.graphics.Bitmap).
here's the terminal output:
thomas@THOMASDESKLINUX:~$ javah -classpath .:/home/thomas/Documents/LinuxProgramming/EclipseWorkspace/RenderScene/bin org.me.renderscene.Billboard
ja... | stackexchange/codereview |
I am planning to use SlopeOne algorithm to predict if a gamer can complete a given level in a Game or not?
Here is the scenario:
Lots of Gamers play and try to complete 100 levels in the game.
Each gamer can play a level as many times as they want until they cross the level.
The system keeps track of the level and the... | stackexchange/codereview |
I have part of an application which is used to save a users signature on a hand-held device.
I have managed to do this by having an arraylist of "Lines" which contains an arraylist of "points".
I need to store this information in a SQL database. The only info I have seen to do this, is to use the image data type and p... | stackexchange/codereview |
I have a PHP script that grabs a chunk of data from a database, processes it, and then looks to see if there is more data. This processes runs indefinitely and I run several of these at a time on a single server.
It looks something like:
<?php
while($shouldStillRun)
{
// do stuff
}
logThatWeExit... | stackexchange/codereview |
Ultimately I wish to produce a compressive Contact Manager with some specific features.
I thought it would be good to experiment by extending Contact.
So using git I checked out froyo-release and tried to build it.
That didn't work so well as it contains things like
import
com.android.internal.telephony.CallerInfo;... | stackexchange/codereview |
I am trying to query a list using LINQ.
The query statement contains entries which should match items from an array.
In other words get entries from SourceList which match any one of the items from the items array.
Example:
private List<string> GetSearchResult(List<string> SourceList,
string name, string[] items)
{... | stackexchange/codereview |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.