instruction_seed
stringlengths
1
35.8k
_source
stringclasses
1 value
I have a metric table that I expect to be very large. It has a polymorphic association so that it can belongs_to other models that want to record some metric. I typically index association columns like this to speed up association loading. I've heard people talking about joint-indexing this association. This looks ...
stackexchange/codereview
I am trying to learn simple operations with the datastore and I am having problems. Can someone help why this is not working? class Pet(db.Model): name = db.StringProperty pet = Pet(name="Fluffy") pet.put() query = Pet.all() results = query.fetch(limit=5) print pet.name When I run this I get <class 'google.app...
stackexchange/codereview
I have found out that sometimes the simplest things you want to do are almost impossible to fund an answer for. I have an ASPX page in ASP.NET V2 programmed in Visual Studio 2005. The ASPX page has a behind code ASXP.VB page and is tied to a .master file. I have two buttons [Button_Process] that will eventually call a ...
stackexchange/codereview
Appcircle is a cross selling solution: it lets a publisher to seel an application within its own Iphone application. When such a purchase is done the publisher earns a commission. To do so appcircle should be able to associate the click on the buy button to a successful selling transaction on the app-market. I wonder h...
stackexchange/codereview
I am trying to load content from the database using simpletip. My code: <script type="text/javascript"> $(document).ready(function(){ $('a.regularsList').simpletip({ onBeforeShow: function(){ this.load('/regulars/tooltip', {id: $(this).attr("id")}); } }); ...
stackexchange/codereview
I have a question regarding dup2(). What does it exactly do? Copies the File Descriptor? I don't quite understand the use of dup2(). I tried Google, and still don't quite understand what it means.
stackexchange/codereview
How can I get the distance between two google.maps.LatLng points using the Mars/Moon tileset? Python/Javascript preferred, but any language would do just fine.
stackexchange/codereview
I'm writing a script to add a genre artist and title of song to django project. Here are parts from my models class GenreManager(models.Manager): def isGenreInDb(self,genre): try: genre=self.get(name__iexact=genre) return genre.id except Genre.DoesNotExist: return...
stackexchange/codereview
A User can have many roles, but only one role per Brand. Class User < AR::Base has_and_belongs_to_many :roles, :join_table => "user_brand_roles" has_and_belongs_to_many :brands, :join_table => "user_brand_roles" end The problem with this setup is, how do I check the brand and the role at the same time? Or woul...
stackexchange/codereview
Can android MediaRecorder capture video with resolution higher than 320*240? When I used MediaRecorder::setVideoSize() to set the video size, the captured video were all at the resolution of 320*240. Whats even worse, the higher ones can not get a clear video, they were somehow greenish. (encoder used is h263, format i...
stackexchange/codereview
This is from a very good book by Steven Sanderson I am trying to follow the chapter 4 and trying to setup IOC on my mvc code from the code sample of the book but its not working. I follow the code from page 97 to page 101 where I set up Inversion of Control and run the code but I get the following error. A dialog box ...
stackexchange/codereview
I'm having trouble getting the Ruby Version Manager rvm to source from my Ubuntu 10.04 .profile. The code: [[ -s "$HOME/.rvm/scripts/rvm" ] && . "$HOME/.rvm/scripts/rvm" ...never does what I expect it to (i.e. give me the rvm program when I open a new shell or start a new session); but if I execute source .profile in...
stackexchange/codereview
I've a question about initialization of inherited members in constructor of derived class. Example code: class A { public: int m_int; }; class B: public A { public: B():m_int(0){} }; This code gives me the following output: In constructor 'B::B()': Line 10: error: class 'B' does not have any ...
stackexchange/codereview
I always tried to learn using the most recent versions of SQL Server, books, articles, docs. I started to doubt whether it is efficient. I've got a feeling that I am frequently inefficiently loosing time with learning materials based on bloated AdventureWorksXXX sample databases from SQL Server 2005+. Even simplest p...
stackexchange/codereview
I am able to display the SPRING_SECURITY_LAST_EXCEPTION.message ("Bad Credentials") when a user tries to log in with incorrect credentials. My login jsp currently uses the following code: <c:if test="${not empty SPRING_SECURITY_LAST_EXCEPTION.message}"> <c:out value="${SPRING_SECURITY_LAST_EXCEPTION.message}" /> </...
stackexchange/codereview
I'm trying to have a counter increase gradually. The following works: function _award(points){ var step = 1; while(points){ var diff = Math.ceil(points / 10); setTimeout( "_change_score_by("+diff+");" /* sigh */, step * 25); points -= diff; step++; } } However, it uses an impl...
stackexchange/codereview
I want to create Type object from string value, e.g., "int", "long". I know I can create Type object from .net framework type name, like Type t = Type.GetType("System.Int32"). Is there a built-in way to do same from C# type, "int", "long".
stackexchange/codereview
I'm working on a Rails app that has one database per account. (I know this is a controversial approach in itself, but I'm confident it's the right one in this case.) I'd like to automate entirely the process of creating a new user account, which means I need to be able create a new database and populate it with some s...
stackexchange/codereview
I have a query that looks something like SELECT to_number FROM sent_texts WHERE to_number NOT IN(SELECT mobile FROM action_6_members); A WHERE is applied to the result set after the query is complete. What would the effect be (improve/degrade) if the sub query contained WHERE mobile = to_number A HAVING is applied t...
stackexchange/codereview
Am working my way thru Ruby on Rails Tutorial: Learn Rails by Example. I'm in the section entitled Mostly Static Pages. I get an error after I create an HTML page in the public directory which is called public/hello.html and should appear as in Figure 3.3. My problem is that when I try to create the page and make it ap...
stackexchange/codereview
Probably it is a basic question, but could not found the answer anywhere in the web. I am trying to use a second level cache (using ehcache) and just checked that some objects were being retrieved from database every time I tried to load them, the only difference was that I was not getting them by id but by a property...
stackexchange/codereview
I have a scenario outline with multiple scenarios. I'd like my Before hook to run only once so I can bootstrap the ActiveRecord objects I need to run against all of the scenarios. The problem is if I use Before do # my code here end This will execute before each Scenario. Is there anyway to run it once for the ent...
stackexchange/codereview
Is there a way to control/navigate windows explorer from the windows command prompt? Or just sync explorer with the prompt's current directory? If for example I enter the command "c:>cd d:\folder\" in the prompt, the prompt's current directory will change right? What I'm aiming for is that as soon as prompt's directory...
stackexchange/codereview
This is my pom.xml (part of it): [...] <dependency> <groupId>com.sun.jersey</groupId> <artifactId>jersey-server</artifactId> <version>${jersey.version}</version> </dependency> <dependency> <groupId>com.sun.jersey.jersey-test-framework</groupId> <artifactId>jersey-test-framework-embedded-glassfish</artifactId>...
stackexchange/codereview
I'm working on a .net system that will both expose and consume web-services with another system to pass data back and forth - the other system is java based. Our proposed XSD contains complex types and some concern has been expressed about using complex types and how we'd be better sticking to simple types. I'd have t...
stackexchange/codereview
Up for consideration is the following function which can be used to (relatively quickly) factor a 64-bit unsigned integer into its prime factors. Note that the factoring is not probabalistic (i.e., it is exact). The algorithm is already fast enough to find that a number is prime or has few very large factors in a matte...
stackexchange/codereview
I’m an experienced VB.NET developer, who wants to start with C#. I’m searching for a web based comparison between both languages syntax as quick reference. I found myself arranging VB.NET syntax templates such as... Public MustInherit Class BaseClass Public MustOverride Sub PublicMustOverrideSub(ByVal byValParam As...
stackexchange/codereview
I would like to implement a strobe light on my iphone 4 I already have the code to turn on and off the LED. I figure I should use an NSTimer to repeat the method that turn the light on and off, also i figure i would use a UISlider to change the rate at which the strobe flashes. I just need to know what the best way to ...
stackexchange/codereview
I have a text file in UTF-7, I would like to create another file with same data like this : using (var sw = new StreamWriter(@"D:\toto.csv.copy", false, Encoding.UTF7)) { using (var sr = new StreamReader(@"D:\toto.csv", Encoding.UTF7)) { string line; while (null != (line ...
stackexchange/codereview
I'm still learning my way through iOS development and working with Core Data and have just come across retain cycles. It is my understanding from reading the Core Data Programming Guide that after you're done working with a relationship, you use the managed object context method refreshObject:mergeChanges to ensure tha...
stackexchange/codereview
Here's the code: import urllib2 import base64,hashlib,hmac,time from urllib import urlencode from xml.dom import minidom AWS_ACCESS_KEY_ID = "secret" AWS_SECRET_ACCESS_KEY = "secret" base_url = "http://ecs.amazonaws.com/onca/xml" url_params = {"Version": "2010-09-01", "Operation": "ItemSearch", ...
stackexchange/codereview
I'm trying to encode and transfer raw video frames over LAN (100 Mbps) connection (frames captured by a web cam). What video/image encoding format is recommended for fast compression (with not much regard for the compression ratio) ? Thanks,
stackexchange/codereview
I'm trying to display an .swf file (with an accompanying .flv file) using SWF Tools, which I understand is possible. So far, I have: Created the field "video". Enabled the SWF Tools module (version 6.25). At this point, I'm really stuck. I created a block in Views, but it only displays an anchor link to the .swf fil...
stackexchange/codereview
I'm trying to show a second select element only if a certain option of a first one is selected. Should be straight forward but it doesn't work. So I have a few of select elements of class "one" each followed by a select o class "two". Within document ready function I first hide all of the selects of class "two": $('.tw...
stackexchange/codereview
I have a requirement to retrieve an item from a data structure by key. But I also have a requirement to traverse that data structure in sorted order, using a field other than the key. Something like this (pseudocode, for illustrative purposes only): var list = new SortedDictionary<TKey, TSortField, TItem>(); How woul...
stackexchange/codereview
And as a result its not passing validation. This is my embedded form : - form_for [@organization, @referral] do |f| = f.error_messages = render :partial => 'referral_fields', :locals => { :f => f } = f.submit "Submit", :class => "button" #_referral_fields.html.haml .grid_7 .grid_1{:style => "width: 64px;"}...
stackexchange/codereview
I'm trying to make system of multiple dialogs in one page using jquery dialog... Functions looks like... function open_w(id){ $('.opened').dialog('close'); $(id).addClass('opened'); $(id).dialog({position: 'center', modal:true, width: '750px' }); }; function close_w(){ ...
stackexchange/codereview
I'm working on a WinForms solution in VB.NET. It's been a while since I'm mostly a web developper. So what I need to do is to replicate the behavior of Microsoft Office product for the Cut, Copy, Paste and Undo menus and toolbar. Which meens, I need to enable Cut and Copy when and only when there's some selected text o...
stackexchange/codereview
I'm trying to send data from my application to a webserver. The catch is that I want to encrypt the sent data and also make sure it comes from my application. (From what I've read so far it's easy to decrypt the data if it's not sent via HTTPS. On the unique application I didn't find anything except the Application ID ...
stackexchange/codereview
I have a textfield where the user enters some number and clicks the "search" button. On clicking the "Search" buttton it displays all the associated JSON records with that number. How do I construct the dynamic HTML table by looping through each record? Here is my JSON structure returned from PHP: [{"number":"ABC123-p...
stackexchange/codereview
I am running Ubuntu 10.04 Lucid and am developing a application in QT using Python. Today I tried to create a database binding to a SQLite database via QtSQL.QAddDatabase and got the following error: QSqlDatabase: QSQLITE driver not loaded QSqlDatabase: available drivers: QMYSQL3 QMYSQL So obviously I don't have the S...
stackexchange/codereview
I'm using Visual Studio 2005 for a project I'm working on right now. I've created a new, custom control that inherits from 'UserControl'. Now I need to add that control to another Windows Form within the same project. I thought that the IDE would place this custom control into the Toolbox (as I know it's done in the ...
stackexchange/codereview
Does anyone know of an end to end tutorial/example showing how to upload binaries to a WCF host from say a desktop application (probably Silverlight or WPF but it most likely doesn't matter).
stackexchange/codereview
I am working on a project that basically monitors a set remote directories (FTP, networked paths, and another), if the file is considered new and meets criteria we download it and process it. However i am stuck on what the best way is to keep track of the files we already downloaded. I don't want to download any duplic...
stackexchange/codereview
I know next to nothing about the URI class. I need to make an Relative URI to reference a file in my project (that is on the root of the project). How can I do that? This is what I have tried and it does not seem to work: var uri = new Uri("ModuleCatalog.xaml", UriKind.Relative) I have also tried: var uri = new Uri("...
stackexchange/codereview
im trying to pass the information of a specific data to be edited in another form which is edit_doc.php. However, when i click "Edit" it doesnt seem to work. Only edit_doc.php opens but the information the does not appear. Is ther any mistake in the codes? Please help. [php] echo "<table border='1'> <th>File Refe...
stackexchange/codereview
I'm new to android programming and I would like some help. I have the following code: Object[] list_cities = parsedData.getCityname().toArray(); Object[] list_countries = parsedData.getCountryname().toArray(); // Display the available locations list_search.setAdapter(new ArrayAdapte...
stackexchange/codereview
When I do an interactive search for some pattern, each time I hit n, I get the next result. How do I delete / change each result that I come to? Ideally, what I'm looking for would work like this: I hit n to get the search result, and then magic command to highlight that result in visual mode, and then I can do d or c ...
stackexchange/codereview
I have implemented a standard UITableViewController. I have made only some rows in the table to be moveable, ie. canMoveRowAtIndexPath returns true only for some indexPaths (for rows in the first part of the table). I would like to allow exchange of only those rows that are moveable, ie. for which canMoveRowAtIndexPath...
stackexchange/codereview
In base64 what happens if the character you want to encode isn't A-Z, a-z , + or /? If I wanted to encode a URL in base64 which has a colon (:) in it what would happen since its not in the base64 index.
stackexchange/codereview
I'm building a simple app too that needs to access a calendar that's in my Google Apps account. But I'm having problems with authentication. I've tried the following code but it doesn't work: Service service = new Service("<appname>"); service.setUserCredentials("<email>", "<password>"); CalendarEntry entry = (Cal...
stackexchange/codereview
today i get this error The specified path, file name, or both are too long. The fully qualified file name must be less than 260 characters, and the directory name must be less than 248 characters. note that I've been working on the same solution and in the same directory since 1 month and i didn't get this e...
stackexchange/codereview
Just a quick one here, does anyone know of a good regular expression for a percentage? Including 2 decimal places, i.e. 15.22%. I'm looking to put it inside a regularexpressionvalidator in ASP.NET.
stackexchange/codereview
Why is it that threads were never included as part of the C++ standard originally? Did they not exist when C++ standard was first created?
stackexchange/codereview
I can't find any function to acquire spinlock in Win32 Apis. Is there a reason? When I need to use spinlock, what do I do? I know there is an CriticalSectionAndSpinCount function. But that's not what I want. Edit: I want to synchronize a memory which will be shared between kernel space and user space. -The memory will ...
stackexchange/codereview
I have to create a WinZip compatible zip file from a PHP application on a linux box, and it must use AES 256 encryption. I have found a few solutions for PHP on Windows, but they don't help me! A PHP package would be great, but if I need to, I can always have my PHP code run exec() or something to run a linux command l...
stackexchange/codereview
In my web root I have a .htaccess which uses a RewriteRule, for example: RewriteRule ^/t/([0-9]+)/$ ../list.php?id=$1 [L] Is this correct if list.php is in the folder below the current one? I can't find any information about this and it's currently not working, so I'm not sure whether it is either possible, or I am doi...
stackexchange/codereview
i have tinymce embedded in my website, so if users want to edit content, then can click on an "EDIT" link and it brings up the content in tinymce editor. when they click "Save", i save the html to a database. this works perfect and avoids them calling me when they need content changes as they can go in directly and n...
stackexchange/codereview
I have an application which needs to be run as admin for all of the features to work correctly. I would like to be able to install the app and create shortcuts with that option automatically toggled on. Is this possible? I'm using InstallAware 9 to create my installation. Thanks, brian
stackexchange/codereview
I'm trying to understand the usage of pipe. A parent process will pipe and if the parent forks, the child process will inherit the pipe. So now we hae a direct link to the child process and they can communicate? I get lost when we start to close pipes and redirect pipes. Does anyone have a good explanation on closing ...
stackexchange/codereview
I have a method that that is suppose to calculate the bearing between two geographic coordinates (in 40.7486, -73.9864 example format). I am however, having an issue where the heading that it calculates is different from the heading I calculate using a tried and tested application. For example, the initial bearing betw...
stackexchange/codereview
Given a parent child relationship between User and FailedLogin where a user has many failed logins. I'd like to map this into class User { public virtual FailedLogin LastFailedLogin { get; set; } } class FailedLogin { public virtual User User { get; set; } public virtual DateTime AttemptOn { get; set; } }...
stackexchange/codereview
Microsoft Windows lets programmers draw GUI elements using the look and feel of the current theme using functions like DrawThemeBackground and DrawThemeText. The elements are specified by Class, Part, and State, as described at the Parts and States page at MSDN. Unfortunately, the page is not very informative (at all!)...
stackexchange/codereview
What is the pattern to validate a twitter username using preg_match?
stackexchange/codereview
What is the difference between (1) AllowServerPaging (2) AllowCustomPaging (3) AllowPaging of PagedDataSource ? please explain the situation to pick up the appropriate one.
stackexchange/codereview
I'm using Eclipse to develop a PyQt application using PyDev. It's using two threads, one for gui and one for network traffic and Eclipse refuse to break on breakpoints set in the network traffic thread, I know it runs because it's throwing exceptions but I can't inspect things which is highly annoying. Has anybody else...
stackexchange/codereview
HI, I'm trying to use for loop to find the difference between every two object by minus each other. So, how can I find the next value in a for loop? for entry in entries: first = entry # Present value last = ?????? # The last value how to say? diff = last = first
stackexchange/codereview
I need to translate the following LINQ query to Dynamic LINQ that accepts several grouping columns based on user input. Basically I have a bunch of dropdownlists that apply groupings and I don't want to enumerate every combination of groupings. If Dynamic LINQ fails, I may have to construct a SQL query manually, and no...
stackexchange/codereview
Is there a way to programmatically transfer an iTunes gift card to some user? Or credit an iTunes account? Thanks!
stackexchange/codereview
I followed this tutorial and got problem that certificate has expired. I looked up in Air forum and found http://forums.adobe.com/message/2320586#2320586 which says the same problem that I got. Unfortunately, it has not been solved. I am looking forward to your suggestion.
stackexchange/codereview
I have the following scenario for a customer of mine: He has a hosted server (1) (i.e. http://customer.net) which basically redirects to an address in this format: http:///app (server 2) The IP address changes frequently (they told me even each two weeks). There's an application in server 2 with a jnlp link which obvio...
stackexchange/codereview
Why do the last == and === operators return true here? var object1 = {value: 10}; var object2 = object1; alert(object1 == object2); // result makes sense object2.otherValue = 15; alert(object1 == object2); // doesn't make intuitive sense to me alert(object1 === object2); // neither does this
stackexchange/codereview
I have a standalone html page that contains a dojo DataGrid that works just fine. I am including the relevant code below. <script type="text/javascript"> var readStore, grid; var gridLayout = [ new dojox.grid.cells.RowIndex({ name: "Row #", width: 5, styles: "text-align: left;" }), { ...
stackexchange/codereview
With the latest Java update on MacOSX 10.6, Eclipse does not find the Java sources anymore. I am not exactly sure (i.e. don't remember anymore) if I have downloaded the sources manually in the past and put them somewhere or if MacOSX provided them and Eclipse found them automatically. Does MacOSX have the sources somew...
stackexchange/codereview
Is it possible to think to have in future an automatic garbage collector in Delphi? There are many applications in which a higly detailed control on when to free an object is not so important and it is just an extra thing to care about. For such applications having a kind of garbage collector that works like java's one...
stackexchange/codereview
I have a Silverlight / WCF RIA Services application that uses EF 4. Currently, there is a domain service that returns two types of classes, OrderItem and Event. I'd like to create a class that contains both of these items for easier manipulation of the data at the XAML level. Here is what the class that combines the...
stackexchange/codereview
I am trying to add a reply to address to my php mailer and it just puts from "me" and replies to my address. Any ideas what I am doing wrong? I have added the $mail->AddReplyTo. I want it to reply to the sender of the web form. $name = $_POST['name']; $telephone = $_POST['telephone']; $email = $_POST['email']; $messag...
stackexchange/codereview
I've posted a video of this happening to YouTube, this was the easiest way to show what is actually happening. That video is at: http://www.youtube.com/watch?v=XwXbilxME1A Around 6 seconds in I was just typing, no key commands or anything. All of a sudden some lines disappear, some appear, and the insertion point chang...
stackexchange/codereview
i using doctype: http://www.w3.org/TR/html4/strict.dtd full code: <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd"> <HTML> <BODY> <div style="border:1px solid red;background-color:blue;"><img src="http://www.google.com/intl/en_ALL/images/srpr/logo1w.png"></div> </BODY> </HTML> ...
stackexchange/codereview
I try to add a .mp3-file to an AVMutableCompositionTrack and after that I want to export the new file. The Problem is: The generated file exists after exporting but it is empty and can not be played. Does someone see the error in my code? AVMutableComposition *saveComposition = [AVMutableComposition composition]; NSAr...
stackexchange/codereview
I am using local storage to store user entries and am displaying the entries on another page. I need a way to sort them based on the most recent date and time of edit. Is there a way to do this with HTML5. If not, what's the easiest/most effective way to do so? Thanks for the inputs.
stackexchange/codereview
Frustratingly my laptop has Rails 3 on it, although I cannot find much supporting documentation on how to use Rails 3, excepting the API reference. There appears to be a significant amount about regarding rails 2.2. Would you recommend downgrading and learning 2.2 or just plough ahead with 3 and hope for the best?
stackexchange/codereview
I'm trying to code an application that can work for several projects. I'm facing a problem that I have always to specify the name of the project when I do the imports like doing import some_project_name.models inside my app, how can I overcome this coupling so that I can use the app in several projects?
stackexchange/codereview
I sub classed the BitSet class to add some additional methods. One of the is called "fold". It splits the BitSet in 2 halves and "combines" them with an or. (increases Information density) This works but the size (1024) of the folded BitSet is still the original size. Code: BitSet firstHalf; BitSet secondHalf; ...
stackexchange/codereview
This could be a stupid question. What we did We just want to use FindRelatedProducts action to check existing installation's version, by following Wix tutorial: <Upgrade Id='YOURGUID-7349-453F-94F6-BCB5110BA4FD'> <UpgradeVersion OnlyDetect='yes' Property='SELFFOUND' Minimum='1.0.1' IncludeMinimum='yes' Maximu...
stackexchange/codereview
Given an ordered collection of strings: var strings = new string[] { "abc", "def", "def", "ghi", "ghi", "ghi", "klm" }; Use LINQ to create a dictionary of string to number of occurrences of that string in the collection: IDictionary<string,int> stringToNumOccurrences = ...; Preferably do this in a single pass over th...
stackexchange/codereview
I have a situation where I have to generate a lot of HTML and then return it as a string JSONP style. So the eventual HTTP response will actually be javascript text like this: myglobaljavascriptcallbackfunction('<HTML here>'); Since the HTML is complex, the only sane way to construct it is with a JSP. So what I would l...
stackexchange/codereview
We have an application that has multiple identical databases apart from customer customizations. we would like to centralize the stored procedures that are common across all databases. Currently, we are having problems with keeping all databases up to date as customizations are done in the common database. We have trie...
stackexchange/codereview
I'm trying to change the way we handle uploaded files before storing them to disk. We have had some problems when users from non-windows operative systems upload files with characters that are illegal in windows file names. The idealist in me tells me that file names should be made legal as close to the web layer as p...
stackexchange/codereview
I am working developing a tab layout based RSS Feed reader app for my android. I have four different sites to get the feeds from and each feed should go into the separate tab. Now I have the app working fine but I was just wondering if there is a way to pass in the feed url while invoking the feed activity? I guess wh...
stackexchange/codereview
When I'm viewing IIS log files I can see various times during the day where the header line is written out to the log file. The only time I've seen this is happening is when IIS resets; or starts up. For example the header line below; #Software: Microsoft Internet Information Services 6.0 #Version: 1.0 #Date: 2010-10-1...
stackexchange/codereview
I have a chunk of data coming from an ajax call. I need to split this chunk up into smaller chunks of a predefined amount, not by a delimiter character, but by an amount. 2k is what I would like. I am trying to come up with a snippet that would bit shift divide the data, and place each chunk including the remaining dat...
stackexchange/codereview
filename = filename.gsub("_"," ").nil? ? filename.gsub("_"," ") : filename
stackexchange/codereview
My autocomplete field: http://www.faressoft.org/autocomplete/ What is the best way to make autocomplete field using jquery (With mySql or XML ?) and what is the reason ? How to minimize consumption of server resources ? What is the best way if i have a big database or a small batadase ? mySql or XML
stackexchange/codereview
How to write a .htaccess that has in result: ALL Requests on that domain go forwarded to the index.html at the rootfolder of the same domain. The index.html itself is not forwarded (excluded) as it includes 2 outbound links. thanks chris
stackexchange/codereview
hi i am making an app in which user sends xml to server and get response.... now i have to save the date and time of sending and response of that request....for this should i use iphone's date or check it online? because my thinking is that the iphone's date and time may not be correct.....always...so it is better to ...
stackexchange/codereview
Good day good-looking computer people, I might be asking a bit too much, but here it goes. I'm trying to do a bit of reserve engineering on this sound library. Looking at the main.cpp file (which I have posted below) it has two methods, setup and play. I'm a bit confused as to how this is working: When you run the Xco...
stackexchange/codereview
I have a set of radio buttons inside a div which has a fixed height and overflow:hidden. Some of the radios get hidden because they would be naturally positioned outside the height of the containing div. When a radio is selected, and that radio is outside the visible part of the div, the div gets scrolled. What I want...
stackexchange/codereview
As in the question, if I define a string operator in my class: class Literal { operator string const () { return toStr (); }; string toStr () const; }; and then I use it: Literal l1 ("fa-2bd2bc3e0"); cout << (string)l1 << " Declared" << endl; with an explicit cast everything goes right, but if I remove the...
stackexchange/codereview
For example (maybe a bit clumsy from a real life view, but just to illustrate): "User" is a case class containing user name and id. Id can be never set manually, and a User class instance with no id set has no sense. A UserBase class maintains users base and has a "getUser (name : String) : User" method returning a con...
stackexchange/codereview