instruction_seed
stringlengths
1
35.8k
_source
stringclasses
1 value
We have an ASP.NET MVC site that uses Entity Framework abstractions with Repository and UnitOfWork patterns. What I'm wondering is how others have implemented navigation of complex object graphs with these patterns. Let me give an example from one of our controllers: var model = new EligibilityViewModel { C...
stackexchange/codereview
Firstly, I realize this doesn't follow any particular convention. I'm just wondering if it is possible. I'd like to give my users the ability to perform an action on many items in a ListView. My ListView items already contain a checkbox for something different; and adding another checkbox is not an option (it would l...
stackexchange/codereview
How to replace "i" in <li>anything</li> using regex Code : var code = "<li>anything</li>"; // i don't know what is in <li>......</li> result should be : var code = "<li>anyth1ng</li>"; // i don't know what is in <li>......</li>
stackexchange/codereview
Is there an easier way to do this in Python (2.7)?: Note: This isn't anything fancy, like putting all local variables into a dictionary. Just the ones I specify in a list. apple = 1 banana = 'f' carrot = 3 fruitdict = {} # I want to set the key equal to variable name, and value equal to variable value # is there a mor...
stackexchange/codereview
I'm trying to populate my JComboBox with the following items: public class DropDownItem { private String text; private int id; public void setText(String text) { this.text = text; } public void setId(int id) { this.id = id; } public String toString() { return text; } public int getId() { return id;...
stackexchange/codereview
I want to be able to load a customized log in page depending on a couple of parameters passed into the querystring. Each customized login page needs to be able to dynamically display log in errors and possibly have other variables passed in. Let's say the dynamic login page looks like this (over-simplification here): <...
stackexchange/codereview
I sometimes reload table data and I need to redraw the table so that I see the data from the first row again. What I do now is the following: NSIndexPath *ip = [NSIndexPath indexPathForRow:0 inSection:0]; [self.tableView selectRowAtIndexPath:ip animated:NO scrollPosition:UITableViewScrollPositionTop ]; [self.tableView ...
stackexchange/codereview
I have an async queue processor that has a Run method which keeps running with a pause of 100ms. This code results in CPU usage of almost 100%. following the thr code of 'Run' method of this async queue processor. private void Run() { while (true) { if (q.Count !=...
stackexchange/codereview
I have a simple Rails 3 blog app that needs an admin user so I can restrict creating and editing blog entries to the admin. I've used devise before, but only for users that are public and can be created by anyone. I don't want the ability to create an admin to be publicly accessible. How should I configure devise to be...
stackexchange/codereview
I'm a Python newbie, I worked with list for 2 months and I have some questions. I have some list and they have duplicate items. I can get duplicate items between 2 lists, now I want the number of lists and the deepness increased like this example: http://i219.photobucket.com/albums/cc213/DoSvn/example.png. I want to ge...
stackexchange/codereview
one of my client want an private application for iPhone. actually what my client need is, they want the application only for their company employees they are not interested to go for the app store for this. their company has 100+ employees. is it possible to sale the application without the app store. if its give me th...
stackexchange/codereview
Normally we use @interface interface_name : parent_class <delegates> { ...... } @end method in .h file and in .m file we synthesis the properties of variables declared in .h file. But in some code, this @interface.....@end method is kept in the .m file also. What does it mean? What is the difference between them? Al...
stackexchange/codereview
In ADDPage.xaml page there i s a Back Button with the code NavigationService.GoBack() to go back to the previous page. Problem: In the Listbox SelectionChanged Event of another page (SubPage.xaml)i am using the NavigationService.Navigate(new ADDPage(search)); When ever the page executes NavigationService.GoBack() of ...
stackexchange/codereview
Is there a .Net open source library to convert the word dococument to HTML to display inside the webpage. I know several tools to convert word docs to html files, but my requirements is to convert the doc(either from the file or just extracted text) to HTML on the fly in the ASP.Net application. I found the converting...
stackexchange/codereview
Is double buffering makes any sense on android? Can it be implemented?
stackexchange/codereview
I am list of tuple as: mylist = [ (user1, 23, 32), (user1, 23, 34), (user3, 34, 34), (user2, 34, 45), (user1, 45,23),(user2, 56, 56), (user5, 4,4)] I need to find out average time for each user. My problem is I dont know how many user are there and values. So i cannot do for item in mylist: if item[0] == 'user1':...
stackexchange/codereview
Title should make my problem well described.Here goes my code. <div id="adiv"><text>Some text</text></div> <script type="text/javascript"> function vb(){ alert(document.getElementById("adiv").firstChild.nodeValue); //returns null } </script> <input type="button" onclick="vb();" value="get"/> wheres the problem..?
stackexchange/codereview
I need to create an account on my server for a user when they process a payment through Google checkout. I will be using a php script to process the payment notification. Has anyone done this? Are there some sample PHP scripts already out there? I read something about the notification history API and the Polling AP...
stackexchange/codereview
Possible Duplicate: Best C++ Code Formatter/Beautifier is there a simple command-line command in linux to justify C++ code? I could use an editor, maybe, but I would rather just have some command that spits out indented justified code.
stackexchange/codereview
I get the fault "CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views." The problem commes from the onDraw call in TutorialThread. The code works if the call to startAnimation in onDraw is removed. Why does the code work if startAnimation is removed? Why is this cal...
stackexchange/codereview
i have a form which on submit should redirect to an external URL to perform some action with my form data, as well as remain on the home page after successful submission. i used redirection, but this will make my second option possible, but not my first one. Please help..
stackexchange/codereview
I've extended ViewGroup to achieve something like a FlowLayout. I put my custom ViewGroup into a ScrollView, dynamically add a bunch of content and it doesn't scroll. The content that flows off the screen is not viewable. What am I missing, how can I allow my ViewGroup to be compatible with ScrollView?
stackexchange/codereview
I'm developing a chromium extension so I have cross-host permissions for XMLHttpRequests for the domains I'm asking permissions for. I have used XMLHttpRequest and got an HTML webpage (txt/html). I want to use XPath (document.evaluate) to extract relevant bits from it. Unfortunatly I'm failing to construct a DOM object...
stackexchange/codereview
Say I have a graph where nodes are workloads of various kinds and edges are dependencies between the workloads. (This is a DAG since cyclical dependencies must not exist.) I also have a set of multiple agents who can perform the work. Some workload varieties may be given to any agent, others must be given to a specific...
stackexchange/codereview
Can we set animation in android widget? For example, i have several buttons if i press button1 they will play animation1, press button2 play animation2 and so on.. Any idea how to do this? Thanks a lot..
stackexchange/codereview
Hello I'm working to slide a DIV to the left (off the page). ... I have the following which works: $('.mybigbox').live('click', function() { leftDistance = $(this).attr('name'); // set px so I know how far $lefty.animate({left:leftDistance}) // Makes the slide }); What what I want to happen, is on the first click i...
stackexchange/codereview
Tags can have multiple attributes. The order in which attributes appear in the code does not matter. For example: <a href="#" title="#"> <a title="#" href="#"> How can I "normalize" the HTML in Javascript, so the order of the attributes is always the same? I don't care which order is chosen, as long as it is always th...
stackexchange/codereview
There are many questions about detection of the integer overflow BEFORE the actual addition/substraction because of possible undefined behavior. So, my question is Why it will produce this undefined behavior in the first place? I can think of 2 causes: 1) A processor that generates exception in this case. Sure, it can ...
stackexchange/codereview
Greetings, I have a java project which I export as a jar. This java project also uses JNI. So far, the only method I could find to use this jar in an Eclipse plugin is to wrap it in an other eclipse plugin project, and add this jar wrapper plugin to dependencies of my actual plugin. I've wrestled with Eclipse's path...
stackexchange/codereview
I'm trying to build a new rails 3 app from scratch using OmniAuth. Currently I just have a completely empty app, where I've added omniauth to the Gemfile, and added a omniauth.rb in config/initializers that looks like this: Rails.application.config.middleware.use OmniAuth::Builder do provider :facebook, 'APP_ID', 'AP...
stackexchange/codereview
I'm a bit of a scheme newbie and I'm trying to do write a function that takes a function name, and and an expression and binds the function name as the first argument of the expression. IE: Something like: (bind-function-name '+ '(param 'a "First")) Would produce a lambda that evaluates (param '+ 'a "First") Best I'v...
stackexchange/codereview
I have this situation in my code: <!-- This is the global CSS file --> <style type="text/css"> #show_div{ display: none; } </style> <!-- This is the local CSS file (only in this page)--> <style type="text/css"> #show_div{ /* However to disable display: none;*/ } </style> <body> <div id = "show_div"> Text ...
stackexchange/codereview
I want to make a simple 2D game where the user has to navigate a ball through a maze (using the accelerometer of course). I used a simple view to make use of the accelerometer and move a ball on the screen. Now how do I go about building the maze? Would I have to use cocos2d or something similar? How do I make the ball...
stackexchange/codereview
I try to write a script that counts connected components of a graph and I can't get the right solution. I have a simple graph with 6 nodes (vertexes), nodes 1 and 2 are connected, and nodes 3 and 4 are connected (6 vertexes; 1-2,3-4,5,6). So the graph contains 4 connected components. I use following script to count con...
stackexchange/codereview
This question: Best way to return status flag and message from a method in Java is similar to mine, however I would do it in PHP, not Java (which could make a slight difference here). The problem: There's a method that can have either a successful outcome (this may change to be more successful ones) or a "problematic" ...
stackexchange/codereview
I'm working on a new Joomla! module where I need to store a read-only data of about 40 key/value pairs with a keyword and corresponding URL link. There are several options but I'm not sure which one would be convenient for the programmer and fast-loading for the user. Or maybe because the data amount is so small it doe...
stackexchange/codereview
Assuming a user has multiple bluetooth headsets attached, and an audio session is running (playing something through one of the headsets). Is there a way to get the list of attached bluetooth headsets (maybe using the External Accessory Framework?) and switch the audio session to the other headset?
stackexchange/codereview
I am setting the .Content value of a Button to a string that contains underscores; the first underscore is being interpreted as an accelerator key. Without changing the underlying string (by replacing all _ with __), is there a way to disable the accelerator for non-menu Buttons?
stackexchange/codereview
Code: $('#Inputfield').keyup(function(e) { if(e.which == 13) { functionXyz(); } else { functionZyx(); } }); $(document).keyup(function(exit) { if (exit.keyCode == 27) { functionZzy(); }...
stackexchange/codereview
I m parsing a file that has MalFormed data from time to time. and it s throwing an exception, i d like to recover from the exception and ignore the bad formatted data. What s the best way to do this? try{ // parse file }catch(Exception){ //eat it. } *EDIT:*I think, my question wasnt understood well. i d like to recove...
stackexchange/codereview
I have a server side code written in java and client side code written in flex. As client makes a request roughly every 3 seconds to the server, then I'm pretty sure I'm running into scalability problems at some point. As far as I can see, I can host the application either in Google Apps Engine or Amazon Cloud. As I un...
stackexchange/codereview
I want my code to do two things that is currently not doing @students = Student.where(["first_name = ? OR middle_name = ? OR last_name = ?", params[:query].split]) Work. (it says im supposed to pass 4 parameters but I want the user to be able to type words and find by those words on each of those fields and return wh...
stackexchange/codereview
I want to use the UIManager.get method in order to get and save the system look and feel for JFileChooser and FileDialog and then I want to change the look and feel. The problem is that I don't know what are the keys for Swing components that UIManager.get method uses. Is there any reference or any convention for that?...
stackexchange/codereview
I have a program that does a limited form of multithreading. It is written in Delphi, and uses libmysql.dll (the C API) to access a MySQL server. The program must process a long list of records, taking ~0.1s per record. Think of it as one big loop. All database access is done by worker threads which either prefetch...
stackexchange/codereview
I was trying to develop a chat application using C programmable sockets. I need to check whether the stdin buffer has some value in it to send the message to the client/server and receive it. But I don't know how to check the stdin buffer for values. Please help.
stackexchange/codereview
is there a way in visual studio to select some type and display how it gets included into the current file? for example i'd like to click on some membervariable SomeType a; and then get displayed something like "first_include.h"->"second_include.h"->"SomeType.h" to understand what chain of includes the compiler uses t...
stackexchange/codereview
SalesForce Opportunity example at http://www.salesforce.com/us/developer/docs/api/Content/sforce_api_objects_opportunity.htm#topic-title uses "Opportunity" class to begin with. For some reason I'm not able to find this class (or any Standard SalesForce classes) in the classpath at all. I'm able to find others classes t...
stackexchange/codereview
frame with 10 rows and 3 columns a b c 1 1 201 1 2 2 202 1 3 3 203 1 4 4 204 1 5 5 205 4 6 6 206 5 7 7 207 4 8 8 208 4 9 9 209 8 10 10 210 5 I want to delete all rows where the same value in the column "c" repeated less than 3 times. In this example I want to remove rows 6, 9 and 10. (my real d...
stackexchange/codereview
I am using this according plugin link text the 3rd one down...3: Non-accordion (standard expandable menu) and each li looks like this <li> <a href="#">Burswood Dome - Burswood Wa, Australia</a> 2010-10-04 <ul class="acitem"> <br><input id="yes_song1" name="yes" type="radio" value="song[1]...
stackexchange/codereview
I'm using the post thumbnail feature to show portfolio work, so for example <?php the_post_thumnail(); ?> the problem is I want to show a particular width of image only, which is 640 but because my pieces are website they have varying heights. I'm using this code to create the images: add_image_size( '640', 480 ,true )...
stackexchange/codereview
In my mvc asp.net application, I have various modules in that I have insert and edit functionality . Some time I am getting this error: at System.Data.EntityClient.EntityTransaction.Commit() at System.Data.Objects.ObjectContext.SaveChanges(SaveOptions options) at System.Data.Objects.ObjectContext.SaveChanges() at admi...
stackexchange/codereview
How to know if .keyup() is a character key (jQuery) $("input").keyup(function() { if (key is a character) { //such as a b A b c 5 3 2 $ # ^ ! ^ * # ...etc not enter key or shift or Esc or space ...etc /* Do stuff */ } });
stackexchange/codereview
Here is line 37; $write = mysql_query("INSERT INTO `trial' VALUES (" '', '".$ip."', '1' ") or die(mysql_error()); The error may be coming from further up.. But I'm not quite sure :S I am trying to block the ip of a
stackexchange/codereview
HEllo. I need replace double slashes in one slash. I am planning do this in Global.asax Application_BeginRequest event. Is it enough? or better do a http module? Thank you. UPD Sub Application_BeginRequest(ByVal sender As Object, ByVal e As EventArgs) ' Fires at the beginning of each request Thread.CurrentT...
stackexchange/codereview
How we can select the second largest mark or whatever from a table without using the LIMIT ? I know it is possible using LIMIT, but is it possible without using that? Suppose we have the columns id and marks.
stackexchange/codereview
I need to do a regular expression match in php . the case is that . 2 digits before decimal and 2 digits after decimal. the problem is that it may and may not have decimal and after decimal digits . how do i write a expression for this ?
stackexchange/codereview
I have a few doubts which i am already sure of it but still want to be very precise about it. If this is a duplicate question then please give me links so that i will delete this question and will refer the provided links I need to preload few images. I dont want to preload if they already exists in the browser cache....
stackexchange/codereview
I read a lot about Dalvik and Google's Android OS when it first came out. One of the things that I don't quite understand though is why Java is used. The way I understand it is this: Java code -> Java bytecode -> Dalvik bytecode What I don't understand is why I have yet to see anything compile to straight Dalvik code ...
stackexchange/codereview
I am creating a treeview which wil have folder images for directories and want to know if there is a way to access the system image list so that I can display the system default folder image. Thx Mark.
stackexchange/codereview
The MSDN help isn't very helpful in that its startup time is long and that it quite often doesn't get you to the correct help file. I always end up opening MSDN in a browser instead. Is there some customization for Visual Studio 2008 that opens MSDN Help in a browser when hitting F1?
stackexchange/codereview
I have a question regarding how to make the same website appear consistently in different browsers on different platforms. The following is a website that I made for my professor: http://youlab.wustl.edu/Home.html. The site itself was made using iWeb while the drop down menu was manually inserted using an external HTML...
stackexchange/codereview
I'm having trouble getting the results I want from a Salesforce/Apex/SOQL query. I want: A list of Contact objects containing only contacts who are CampaignMembers of a set of campaigns; and they should have the data from that Campaign member easily accessible. (my eventual goal is a VF page with a list of all Contacts...
stackexchange/codereview
I'm creating a watch dog service that will be monitoring other services on various remote servers (all in the same domain). The user that I'm using to connect to the remote servers is not an admin. When I try to enumerate the services in the Win32_Service class, I get an access denied error. I've given the user 'Rem...
stackexchange/codereview
i want migrate a database from Sql Server 2008 to MySql using a the tool MySql Migration Toolkit but when the tool is establishing the database connection i receive this error : Connecting to source database and retrieve schemata names. Initializing JDBC driver ... Driver class MS SQL JDBC Driver Opening connection ....
stackexchange/codereview
I am trying to access videos in iPhone library using AssetsLibrary Framework with the help of following code...but when I run the application the code is not working...the array assets is still empty? What am I doing wrong? by the way my iPhone is a 3G upgraded to iPhone 4.1.(but assets framework is not giving any erro...
stackexchange/codereview
I'm a first year computer science student having a problem with part of an assignment. The goal of the assignment was to store the coefficients for a polynomial and find its roots using both an array and a linked list. I was able to successfully complete the array version; however the linked list is giving me a headach...
stackexchange/codereview
It has been a while since I looked at C (still learning) and I just got back into the K&R book. I just had a go to Exercise 5-3 (p107). Write a pointer version of the function strcat that we showed in Chapter 2: strcat(s,t) copies the string t to the end of s. I came up with this... void strcat(char *s, char *t); vo...
stackexchange/codereview
I have Eclipse 3.0 recently installed on a desktop and a laptop. The laptop installation is missing several menu items under Window/Preferences that appear under the desktop. The missing items include: Data Management Plug-in Development Remote Systems Servers terminal Web Web services I installed them both from Eclip...
stackexchange/codereview
There is one shortcut I know of, ^ which means "the base URL of the current repository". I know there a bunch of other ones introduced with Subversion 1.6. What are they?
stackexchange/codereview
My ASP.NET application is a download application (no pages) which reads huge binary files (1-2 GB -> over 1 hours download time with resume support) from local network and stream them to web clients (each request -> one large binary response, so there's no text/html response at all). I use a HTTP Handler (.ashx) instea...
stackexchange/codereview
I guess I have a little understanding about functions and how they work.. Idea is to get "user's group" from database, but I don't want to write the code evey time when I need it so I decided to put it in function. function get_role() { $user_id = $_SESSION['login_ok']; $res = mysql_query('SELECT role FROM users WHE...
stackexchange/codereview
what is the name of the property to set the number of items displayed when the list pops up?
stackexchange/codereview
I am using SLF4J and as per requirement i have to store the logs into the .log file. But when i run the program the log are not written into thelog file. Class : import org.slf4j.Logger; import org.slf4j.LoggerFactory; public class TestSLF4J { // private static Logger _logger = LoggerFactory.getLogger(Tes...
stackexchange/codereview
My problem is with respect to debugging web application on an already installed glassfish using eclipse. If I create a web project using eclipse then eclipse will let be deploy and debug application on an already installed glassfish application server. However, if I have created a web project using maven archetype, ecl...
stackexchange/codereview
I've recently been developing a website using asp.net webforms that uses in proc sessions and I noticed that session ids are shared amongst browser tabs. So I was wondering what you would do for the following situations: Problem: Multiple logins with different users in the one browser problem User opens browser tab 1,...
stackexchange/codereview
I've been trying to find a way to do this for a while now and can't quite seem to figure it out. I know you can change the orientation of a JSlider, using setOrientation(HORIZONTAL|VERTICAL), and that you can also invert the scale, using setInverted(true). My problem is as follows: 1) The JSlider needs to be horizontal...
stackexchange/codereview
Below is the XML schema I am trying to conform to: <?xml version="1.0" encoding="UTF-8"?> <urlset xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"> <url> <loc>http://www.example.com/</loc> <lastmod>2005-01-01</lastmod> <changefreq>monthly</changefreq> <priority>0.8</priority> </u...
stackexchange/codereview
Possible Duplicate: Instance variable initialization in java Hello, can someone tell me what the difference / pros or cons of creating an object with the declaration of the class instance vars ie.. public class ClassName{ Object o = new Object(); } to in the contructor public class ClassName{ Object o; ...
stackexchange/codereview
I am trying to create a report and am looking to pull out some information from a table 'contact'. I am trying to pull out the 'advisor' relating to the contact and a count of contacts who have that advisor based on a set of criteria. This is fine and works, however, I want to pull out a third column which is also a 'C...
stackexchange/codereview
I have a class with a DateTimeOffset property: public class Sample { public DateTimeOffset expires { get; set; } } and eventually a collection of them: IEnumerable<Sample> collection; 2 questions: What is the best way to create a method that returns all the Sample items from the collection where expires is ...
stackexchange/codereview
I know I can use componentResized to listen for when the user resizes a window. This isn't a very nice solution. If I do this and add a resize() method for the children components, then it waits until the user finishes the resizing before it calls the resize() method. Is there a way to resize the child elements as the ...
stackexchange/codereview
suppose my list<struct> in list some struct have the date 31 january some have date 5 march some have 12 august then i want to make a list of all same date struct how i can do this in c#
stackexchange/codereview
I have been trying to create a pointer variable in the called function and somehow pass the value pointed by it to the main function. I wrote a few sample programs but it i still seem to be missing something out. and the challenge was to achieve this using pointers to pointers to pointers. Here is the code that I wrote...
stackexchange/codereview
Is it possible to append query strings to the links created by the pagination class? Currently if you are on this page: http://127.0.0.1/~panayi/xryses/Nicosia/browse/Homes?price_low=19&price_high=300 the links are incorrectly generated as http://127.0.0.1/~panayi/xryses/Nicosia/browse/Homes&per_page=20 http://127.0....
stackexchange/codereview
I have a .NET desktop application, which is used by 5000 users who are distributed across Canada. One of the functionality is to communicate with some modems using some parameters that we get from the database. The unique thing about this functionality is: 1 - it should be extremely fast because it is communicating wit...
stackexchange/codereview
At university we have introduction to OpenGL and it's first time I'm working with it. So far I have implemented simple thing like Sierpinski carpet and I noticed that most of (both fixed and floating point) calculations are performed on CPU. Does OpenGL provide some API, which can "forward" these calculations to GPU? I...
stackexchange/codereview
If there are any Sybase ASE experts out there, I was wondering if there is a way to get Sybase to trace all the queries that it receives. I currently have a program running that usually begins displaying some strange behaviour after 7 hours from startup. I would like to find out what Sybase is doing at this time, so t...
stackexchange/codereview
What are the correct ways/practice/implementation/strategies (or whatever we call it as) for not to wait for code block/method to finish execution in Java? Assume the following method: private void myMethod() { // Some lines of code here ..... ..... ..... anotherMethod(); // or this could be a...
stackexchange/codereview
I have been using tinyMCE over dojo dijit.editor because tinyMCE wins out on functionality. Though I've just come across this: http://phphtmledit.com/dojo/ShowEditor.php?gclid=CPizxJzR3qQCFQpBbgodFidd9A which, if I'm reading it correctly, claims to be a dojo editor but has all the functionality of tinyMCE. So my questi...
stackexchange/codereview
I'm going to get a WP7 silverlight project at work, and I'd like to ask you guys what documentation do you recommend to somebody who's willing to write silverlight apps for WP7 but who's never touched silverlight itself before.
stackexchange/codereview
I have a dojox.grid.DataGrid, and one of the columns has date data in it. e.g. 09:01:00 18/10/2010 09:03:00 18/10/2010 09:02:00 19/10/2010 When I click the heading and sort the column, I get this... 09:01:00 18/10/2010 09:02:00 19/10/2010 09:03:00 18/10/2010 It has sorted on the String value, not sorting it as a ...
stackexchange/codereview
i have a problem with django's render_to_string and encoding single quotes. ... = render_to_string('dummy.txt', {'request':request, 'text':text,}, context_instance=RequestContext(request))) why are only these quotes translated to '#39;' and all other special characters not?
stackexchange/codereview
I started using bundler and have some problems getting it working. I have the following gemfile: source "http://rubygems.org" gem "rack", "~>1.1" gem 'pg','>= 0.8.0' gem 'rails','2.3.8' gem 'authlogic','2.1.3' gem 'ajaxful_rating','2.2.3' gem 'will_paginate','2.3.12' gem 'right_aws','1.10.0' gem 'aws-s3','0.6.2' gem 'd...
stackexchange/codereview
I'd like to display snippets of programming language code, and also HTML code, inside an HTML document using CSS. I want it to be indented and in fixed-width font... I'm thinking of something like: <blockquote style="some_style"> my code here my code here also </blockquote> and have it appear in a nicely formatted way...
stackexchange/codereview
I found a string tokenizer query on the net and packaged it into the below function, which return the dynamic set of tokens. The function compiles successfully but somehow I get the error "ORA-00933: SQL command not properly ended". Can someone please help me debug this? Thank you. CREATE OR REPLACE TYPE KEY_VALUE_TYPE...
stackexchange/codereview
Is it possible for me to write my own Java Main Class that calls methods in compiler.jar. I would like to make multiple calls to the compiler and do not want to write code to use Runtime.exec and also do not want to have to wait for Java to load up before every call.
stackexchange/codereview
Being spoiled by jQuery I now include it into every project even if all I need from it is to call $("#div).hide() or $("#link").click() once. I know that jQuery often takes care of cross-browser issues for you, but sometimes it is just a convenient wrapper for a native javascript methods. So my question is which jQuery...
stackexchange/codereview
I've just set up a simple PHP Code Igniter project on a Windows 7 box, IIS 7, Fast CGI, no modules. when I load up database in one of the function of a Model class by doing such this->load->database() the thread seem to stop on that particular line. None of the subsequent operations are done. class Account_model extend...
stackexchange/codereview
I was reading about Firesheep and wondering how I can protect my Spring MVC 3.0 site against attacks like this: It's extremely common for websites to protect your password by encrypting the initial login, but surprisingly uncommon for websites to encrypt everything else. This leaves the cookie (and the user)...
stackexchange/codereview
I'm trying to build a static library that I can use with both ios3.x and ios4.x. I can build a static library with ios3.0 that works with another project in ios3.0 but won't compile in ios4. The same is true going from ios4 to ios3. Here's how to recreate: Open XCode 3.2.4 and start a new project that's a Cocoa Touch...
stackexchange/codereview