instruction_seed
stringlengths
1
35.8k
_source
stringclasses
1 value
Good day all, I am trying to figure out how to allow users to call a method on some specified data. I would like to provide a predefined set of functions: Moving average, moving_ave(x,5) ..would be a 5 day moving average on x. 3*x+y....and so on... So basically, i will provide the users with various data series (x,y,...
stackexchange/codereview
I got a UIView with 2 subviews. The UIView is set to UIViewAutoresizingFlexibleWidth. Now when it enters layoutSubviews it resizes the frames of the subviews relative to the UIView like so: rect.size.width = self.frame.size.width - rect.origin.x - textLabel.frame.origin.x; But a problem occurs in landscape mode cause...
stackexchange/codereview
I want to run a query over an Array or string with PHP Let say I got a string: $Iamastring = "Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc velit est, porta sed feugiat vitae, sodales et nisl. Suspendisse ut." And I want to run a query over that string to find it: "Lorem ipsum" OR ("dolor" AND "sodales...
stackexchange/codereview
I know i can use <mt:EntryAssets lastn="1"> <img src="<$mt:AssetThumbnailURL width="100"$>" /> </mt:EntryAssets> to show the 'last' asset...how do I show the 'first' or 'oldest' assest?
stackexchange/codereview
Im wondering how I can turn off the animation of my view controller when leaving back to the parent controller. As I can set the animation property for going to the child controller, I guess there must surely be a way to set the property for the leaving task. Thanks, Markus
stackexchange/codereview
You are given a file containing a list of strings (one per line). The strings are sorted and then encrypted using an unknown substitution cipher (e.g. a < c, b < r, c < d). How do you determine what the mapping is for the substitution cipher? The unencrypted strings can be in any language. I'd like to know if that ques...
stackexchange/codereview
i am a project about using java's bouncycastle to do the encryption. However, when I encrypt the message, it throws an exception for me. javax.crypto.IllegalBlockSizeException: data not block size aligned I am using Blowfish/ECB/NoPadding, and the message is an xml. public static void main(String args[]){ String ...
stackexchange/codereview
How can i make widgets overlap one another. Lower most should be image, rest above can be other widgets like buttons.
stackexchange/codereview
why does (clojure.repl/source in-ns) not work while (doc in-ns) gives the documentation? I even tried to change my namespace into clojure.core but did not help ... Can somebody tell me why this is happening..?
stackexchange/codereview
Can anyone provide a sample code to get table of contents from PDF Document? I have googled for more than 2 days but couldn't find any proper example. I m also having Voyuer Example suggested from many blogs but was not able to understand it. Is there any simple way???
stackexchange/codereview
I was trying to add items to IList through reflection, but while calling the "Add" method an error was thrown "object ref. not set". While debugging I came to know that the GetMethod("Add") was returning a NULL reference. Type objTyp = typeof(MyObject); //HardCoded TypeName for demo purpose var IListRef = typeof (List...
stackexchange/codereview
During the new user registration process, I'm trying to find whether a user name or a user email are already in the db. To do that, I want to find the number of rows where the identifier (email or user name) matches records in the database. If I don't screw up, the only possible return values are 0 or 1. My function...
stackexchange/codereview
I have a bunch of methods that look like these two: public void SourceInfo_Get() { MethodInfo mi = pFBlock.SourceInfo.GetType().GetMethod("SendGet"); if (mi != null) { ParameterInfo[] piArr = mi.GetParameters(); if (piArr.Length == 0) { ...
stackexchange/codereview
I've found myself doing too much error handling with try\catch statements and getting my code ugly with that. You guys have any technique or framework to make this more elegant? (In c# windows forms or asp.net).
stackexchange/codereview
I've to add one event notification inside of the calendar of my users they all have an account of my Google Apps. The number of my users are for now 200 but it will increase to 1500. How can I add via PHP from Google Calendar API all those notifications? The secondary objective is that all the users that has the mobile...
stackexchange/codereview
I'm stuck on a little not understanding problem. I'm using the MS SQL Managment Studio 2008. I have a brand new database with table X. X has 3 Columns: ID, uniqueidentifier, not null username, nvarchar 50, not null password, nvarchar50, not null Now I save. Now I set the ID to primary key - no problem with saving. No...
stackexchange/codereview
I need to send some data to an Activity, which may be running in different context. For this I created a class say A, which has an ArrayList of datatype say B as its one of instance member . I declared class B as Class A's Inner class. To send this class A's instance through Intent, I made class A and B both Parcelable...
stackexchange/codereview
Hi I am using jQuery.hotkeys.js plug in for key board shortcut. All other shortcuts are working fine but f1 is not working as expected in IE. On 'f1' keypress it binds the shortcut but is being called more than one time and also it opens help window as well. the code is like this: $(document).bind('keydown', 'f1', f...
stackexchange/codereview
I'm having a little trouble with some Java code I'm trying to compile in Eclipse. I keep getting the following warning... Access restriction: The type OperatingSystemMXBean is not accessible due to restriction on required library C:\Program Files\Java\jre6\lib\rt.jar From this line of code... com.sun.management.Opera...
stackexchange/codereview
Where do I need to place a snippet of JavaScript code that initializes a variable that must be visible to all code executed with the page? (For example, event handlers on elements will need to access this variable).
stackexchange/codereview
I'm using Php default SoapClient for communication. I have to send data that looks something like this. <payloadPublication d2p1:type="GenericPublication" > ... </payloadPublication> the only problem is how to add complexType "GenericPublication" in following code, everything else is working. $payloadPublicat...
stackexchange/codereview
I wanted to use PHP Simple HTML DOM Parser to grab the Google Apps Status table so I can create my own dashboard that will only include Google Mail and Google Talk service status, as well as change the presentation (html,css). As a test, I wanted to find/output the table element but it's not displaying any results. $ht...
stackexchange/codereview
I'm looking for a way (in JavaScript) to collect a set of objects into multiple arrays, where each array contains a certain type of object, and the arrays are stored as values in an associative array, with the keys being the types. For example: Input: [<apple>, <cat>, <pear>, <mercedes>, <dog>, <ford>, <orange>] Outpu...
stackexchange/codereview
How can we know the index in Lucene is correct? Detail I created a simple program that created Lucene indexes and stored it in a folder. Using the diagnostic tool, Luke I could look inside an index and view the content. I realise Lucene is a standard framework for building a search engine but I wanted to be sure that L...
stackexchange/codereview
I am just learning php and it's my first question on this site. Hope, you will help me. I just want to send Email from my local machine to gmail. I have tried but didn't got any success. Please help How to do this. my code is form processing return mail( $message['to'], join("\n", $headers)) }; ?...
stackexchange/codereview
I am using a custom class on my model to provide image uploading, through an app called django-filebrowser. # myapp/models.py class Book(models.Model): name = models.CharField(max_length=30) image = FileBrowseField("Image", max_length=200, blank=True, null=True) ... The model uses filebrowser's custom fiel...
stackexchange/codereview
I managed to set up virtual hots on my local machine, but I kinda run into a wall now. Normally, when you type localhost/ into browser you will see what you are supposed to see. But after I have set my virtual hosts, anything I type goes to the vhost. I cant figure a way to have a virtual host AND the old functionality...
stackexchange/codereview
I have a datetime variable in my application. Its value is 01/09/2010 00:00:00. I want to get value of 01/09/2010. Still I want to use the DateTime structure. Is there any method/property for that. I know it is possible using conversion. For example I have DateTime date = new DateTime(2010,09,01); It will display 01/0...
stackexchange/codereview
I am not sure if the subject description is correct but basically this is what I want to achieve: I want to have a way to delete all binary files such as .exe, .dll to be deleted at a single click. Perhaps there are plugins available that will let me do the same, but just wondering if something like that exists already...
stackexchange/codereview
Say I have a property Foo of type SomeType in a class of type SomeClass which is edited with a custom editor SomeTypeEditor: [EditorAttribute(typeof(SomeTypeEditor), ...)] public SomeType Foo { get { return BuildFooFromInternalRepresenation(); } set { UpdateInternalRepresentation(val...
stackexchange/codereview
Can I specify that I want gdb to break at line x when char* x points to a string whose value equals "hello"? If yes, how?
stackexchange/codereview
I have to parse the url http://local.yahooapis.com/LocalSearchService/V3/localSearch?appid=YahooDemo&query=pizza&zip=94306&results=2 and show the result in android simulator I have done earlier parsing in android I did not get problem in that Can anyone help me in this regard?
stackexchange/codereview
I am trying to build an HID keyboard. I got my STM32 MCU to recognize as a keyboard, but for some reason when I try to send the HID report (8 bytes) using Endpoint 1 in Interrupt mode. The host side doesn't get the data(key pressed) . Do I need to use the standard method Get_Report ? I have also tried another implemen...
stackexchange/codereview
I'm working with Access (.accdb), and a Windows Forms application, written in C#. I get this error when I'm trying to insert data into a database table. System.Data.OleDb.OleDbException:Sintax error in INSERT INTO statement. adaptador.InsertCommand.ExecuteNonQuery(); I have tried to go through the direct route and up...
stackexchange/codereview
Possible Duplicate: How to call a JavaScript function from PHP? Can I add a javascript alert inside a PHP function? If yes, how?
stackexchange/codereview
We're about to build a Facebook application that will run inside an XFBML IFrame. We already found a good tutorial for that (kudos to the author). Right now, there's one more issue we need to deal with. Basically, we just wanted to know how to determine the UID of the person who invited a friend to join an application....
stackexchange/codereview
I have translation engine mapped as follows: <class name="Core.Model.Entities.Translation, Core.Model" table="translation" lazy="false"> <id name="Id" column="id" type="Int64"> <generator class="native" /> </id> <map name="Translations" table="translation_value" inverse="true" fetch="join" cascade="all-delete-orphan"...
stackexchange/codereview
I'm trying to convert a SVG generated by Raphael JS (and the user, since you can drag and rotate the images). I followed this Convert SVG to image (JPEG, PNG, etc.) in the browser but still can't get it. It must be easy but I can't put my finger on what I get wrong. I got my svg in a div with #ec as id and the canvas's...
stackexchange/codereview
While the following work fine in SQL Server Management Studio, it just won't work in C#: DECLARE @PeriodID AS bigint; SELECT TOP 1 @PeriodID = PeriodID FROM Periods ORDER BY PeriodID DESC; IF NOT EXISTS(SELECT * FROM information_schema.columns WHERE COLUMN_NAME = N'PeriodID' AND TABLE_NAME = N'MobilePlans') BEGIN B...
stackexchange/codereview
I want to compile a bunch of C++ files into raw machine code and the run it with a platform-dependent starter written in C. Something like fread(buffer, 1, len, file); a=((*int(*)(int))buffer)(b); How can I tell g++ to output raw code? Will function calls work? How can I make it work? I think the calling conventions o...
stackexchange/codereview
I have a base64 encoded string that I would like to convert into an image in PHP / HTML. Here is what I have: $data = "R0lGODdhAAGAAKIAAP38+/3h3cjN5P3HwgAAAP8AoP8AGv8EIywAAAAAAAGAAAAD....."; echo base64_decode($data); // OR echo '<img src="data:image/gif;base64,' . base64_decode($data) . '" />'; None of those work...
stackexchange/codereview
While i was writing a piece of code in C# using ASP.NET i needed to create a message queue to store fault messages. However, I couldn't find the System.Messaging namespace in the namespace library in Visual Studio 2010. Does anyone know how can I use message queuing now?
stackexchange/codereview
I wrote the code below for homework purposes. When I run it on XCode in OSX, after the sentence "Enter the number of a Fibonacci Sequence:", I enter the number 2 times. Why 2 and only 1 scanf. The code : #include <stdio.h> #include <sys/types.h> #include <unistd.h> #include <sys/wait.h> int main() { int a=0, b=1,...
stackexchange/codereview
I have a subversion repository under /var/svn/ I am trying to use subversion to get details of the latest revision, I have tried using shell_exec to run svn info on the external address, but I couldn't get any input from it. Is there any way I can read the information from the repository itself? Solved: Decided to go w...
stackexchange/codereview
can any one suggest how can i have a list of icons like browser icon,email icon and contacts icon upon clicking on those it should lead to android browser,email and contacts apps respectively...right now i have done it, upon clicking buttons. Now i want icons(with image and text) instead of buttons.
stackexchange/codereview
My project contains a couple of IDE configuration files that are constantly changing, but do not have any effect on the build itself. I would like these files to be included in every commit and update, but I would rather that they did not show up in the list of modified files. Is this possible? Details: My IDE (Xcode) ...
stackexchange/codereview
I just converted a WPF project from .NET 3.5 to .NET 4.0. I'm now using the .NET 4.0 DataGrid control rather than the WPF Toolkit DataGrid control. Functionally, everything is still working, but my styles are not applying as expected. As you can see from the below screen captures, the alternating row formatting, paddin...
stackexchange/codereview
I am using PHP with IMAP. I need to retrieve the 20 most new emails from a folder. I user imap_sort to sort by date, but the problem is that for a large folder with 700 and more emails it takes ages. Is there a way i can use PHP IMAP to sort messages by date and bring only the latest 20 emails? Maybe to use imap_search...
stackexchange/codereview
I have used gmail countless times and was wondering if there are standard patterns behind this scenario: user wants to attach a big file in the email,clicks attach and the selects the file which has to be attached There is some processing which takes place (uploading to server,virus scans etc) and when this is happeni...
stackexchange/codereview
Is is possible using Hibernate (prefferably the Criteria API) to use a mySql function to Order By. The function I am looking to use is :- SQRT( POW( 69.1 * ( {alias}.latitude - 51.3814282 ) , 2 ) + POW( 69.1 * ( -2.3574537 - {alias}.longitude ) * COS( {alias}.latitude / 57.3 ) , 2 ) ) where the {alias} is rooted a...
stackexchange/codereview
This may be a basic question... However I've just been picking a solution without giving much though to it... Consider a page with a grid of forms: /FormList.aspx where choosing to edit a form redirects the user to a page like: /FormEdit.aspx?Id=2 I usually am okay with passing the values in the query string, because ...
stackexchange/codereview
WPF : How to get mouse position in Window_Loaded(object sender, RoutedEventArgs e) event
stackexchange/codereview
I am a beginner, so, please bear with me, if this sounds too trivial.When i searched over the net for this, i got results showing how to do it. My question is why we do it in the first place ?
stackexchange/codereview
When deleting an @Embeddable object, I run into some problems. I have the following domain classes: SwitchVoipTrunkGroup and PrioritizedCodec. The latter contains several fields that are nullable. class SwitchVoipTrunkGroup { //... @CollectionOfElements(fetch = FetchType.LAZY) @JoinTable( name...
stackexchange/codereview
Here is the part of my page with the problem: <div id="notice_box" class="center"> <div id="notice_cont"></div> <script> function notice(more) { $('#notice_cont').load('notice.php?more_notice='+more); } </script> </div> <div id="notice_box_foot"> <img src="images/notice-box-bl.png" class="l...
stackexchange/codereview
Is it possible to use Amazon web service to host a Rails application? Thanks.
stackexchange/codereview
I have a form containing both CustomValidators and RequiredFieldValidators. The Custom Validation doesn't fire until all of the requiredFieldValidators have passed. Can someone tell me how to get them to validate at the same time? I want all the validation messages to show when no data is input.
stackexchange/codereview
I'm trying to find out how to use xemail-net, I downloaded it and it has the source but no dll which I can add to reference. If you have used it please let me know how I can add it to my current project. Best Regards!
stackexchange/codereview
I am helping to run a reporting services installation that is protected and gains its permission structure with Windows usernames and passwords. Our password policy dictates that passwords change once a month. Three of the five users of this installation only log in to the report manager site with their windows logins ...
stackexchange/codereview
Say I have this view model: public class SeriesLinkViewModel { public static Expression<Func<Series, SeriesLinkViewModel>> FromSeries = s => new SeriesLinkViewModel { Name = s.Name, Slug = s.Slug, }; public string Name { get; set; } public string Slug { get; ...
stackexchange/codereview
I'm trying to launch a console app from an IIS based web service, but its not visible on the server. Code so far is: string downloaderPath = ConfigurationManager.AppSettings["DownloaderExePath"]; System.Diagnostics.ProcessStartInfo si = new System.Diagnostics.ProcessStartInfo(); si.WindowStyle = System.Diagnostics.Pro...
stackexchange/codereview
In my modal window I have a "continue" button. Whilst I can get the modal to close by assigning the button with the simplemodal-close class, I can't get it to call my function. I've put together this code from the simple demos on the site. The button: <a href="#" class="simplemodal-close" onClick="closePopup()"><img sr...
stackexchange/codereview
Possible Duplicate: How to customize / style a UIPopoverController I need to change the border color of UIPopover controller?. By default it is dark blue. If anybody know please answer.
stackexchange/codereview
The problem is that I'd like to be able to use Mercurial, or git, as a front end for development, but have changesets and updates made in Subversion, typically in an integration branch or something that is only written to by a script for Mercurial, or by Hudson when it notices changes. Then our Mercurial repository is ...
stackexchange/codereview
I had a VC2008 project very complicated.Inorder to understand it's inner workings I tried to simplify it and now I am getting 289 errors of the following type for most of the files: Error 5 error C2471: cannot update program database 'c:\users\ryan\documents\visual studio 2008\projects\vc\myinfo\cli\debug\vc90.pdb'...
stackexchange/codereview
I've just been running some simple debug tests against arrays, and noticed that when I do a var_dump() of an array, the output is flagging any element in the array that is referenced by another variable. As a simple experiment, I ran the following code: $array = range(1,4); var_dump($array); echo '<br />'; foreach($a...
stackexchange/codereview
I had asked this question on Javaranch, but couldn't get a response there. So posting it here as well: I have this particular requirement where the increment in the loop variable is to be done by multiplying it with 5 after each iteration. In Java we could implement it this way: for(int i=1;i<100;i=i*5){} In scala I ...
stackexchange/codereview
I am pulling certain pages using query_posts to populate a dropdown menu. lets assume the list populate the following fields option1, option2, option3 and option4 Now if I have selected option3 and my page changes to this, how do I display this as the selectedIndex? <select name="speedC" id="speedC" onchange='docu...
stackexchange/codereview
I am having a boilerplate text that should be printed on bottom of the last page of the report. But report builder wouldn't let me have the "print object on" property to "last" due to the reason suggested here: http://oracle.ittoolbox.com/groups/technical-functional/oracle-apps-l/error-while-setting-one-frame-property-...
stackexchange/codereview
Consider the following XAML code: <StackPanel> <ListBox x:Name="lbColor"> <ListBoxItem Content="Blue"/> <ListBoxItem Content="Green"/> <ListBoxItem Content="Yellow"/> </ListBox> <TextBlock> <TextBlock.Text> <Binding ElementName...
stackexchange/codereview
in my current Project on WinForms with .net3.5 I imported some User32.dll functions for scrolling programmatically. I extended the TableLayoutPanel - which is ought to be scrolled. Everything worked fine after a bit of work, but now I found out that the function GetScrollInfo(this.Handle, SB_VERT, ref _si); always re...
stackexchange/codereview
I'm trying to determine what application is using certain port and get netstat -tlnp | grep <port> for Linux. This command return the following output: (Not all processes could be identified, non-owned process info will not be shown, you would have to be root to see it all.) tcp 0 0 0.0.0.0:<port> 0.0.0.0:* LISTE...
stackexchange/codereview
I have a JUnit 4 test that loops through an array of test data: public @Test void testAll() { final Object[][] sets = new Object[][] { // SET TYPE VALUE // --- valid sets // groups x(s(A,1, B,1, C,1), G), x(s...
stackexchange/codereview
I have two Delphi runtime packages. The SecondPackage includes FirstPackage in its requires clause. One of the other developers recently added several new files to the first package. Now when I compile the first package I don't have any errors but when I compile the second package I keep getting: [DCC Fatal Error] Fir...
stackexchange/codereview
I am trying to make a call from python to a dll but am getting an access violation.Can some please tell me how to use ctypes correctly in the following code. GetItems is supposed return a struct that looks like this struct ITEM { unsigned short id; unsigned char i; unsigned int c; unsigned int f; unsigned int p; ...
stackexchange/codereview
The following simple datatemplate only works at runtime. At designtime it displays nothing. Why is this so? <DataTemplate x:Key="SomeEnumDataTemplate"> <ListBox Name="list" Width="20" IsSynchronizedWithCurrentItem="True" SelectedIndex="{Binding Mode=OneWay, Converter={StaticResource EnumToIntConverter}}"> <...
stackexchange/codereview
I am currently a developer working on a very task specific application; the user(s) are often multitasking so they can often make errors inputting data. The nature of the task makes notifying them of those imputation mistakes important. We currently use a combination of panels and labels and/or a small label at the b...
stackexchange/codereview
I want to draw random coloured points on a JPanel in a Java application. Is there any method to create random colours?
stackexchange/codereview
How to increase the font size of a Text widget?
stackexchange/codereview
I have an image view in my app. when I try to make it show a jpg file exported from 3ds max, it works. But if it comes from Photoshop, it just does nothing. Why is that? If it is at all important my app gets the image from my server with the following code: public static Bitmap getWebImage(String URL) { URL myImage...
stackexchange/codereview
Is there a way to refresh the entire page content instead of just a div?
stackexchange/codereview
Hi just cant seem to construct the MYSQL query Im after. Say I have a result of two columns: 1) browser name and 2) browser count. Where it gets complicated is I want once 90% of the total count has been reached to rename all other browsers as others and mark the left over percentage accordingly. I know I can get the t...
stackexchange/codereview
Updated Hello all, MySQL here. Let's say we have 3 tables. TableA, TableB, TableC. TableB relates with foreign keys, TableA and TableC. I would like to: List some data from TableA and TableC BUT, that data should be ordered by some column of TableB. Can I have an example of the above so that I can study it and try to ...
stackexchange/codereview
Any QBFC developers out there? I'm using QBFC to pull multiple different types of objects out of Quickbooks: Customers, Items, Invoices, TaxCodes, etc. The data query code really only varies once you get to the Ret object so I'm trying to build some functions to abstract the process. A typical repose object looks l...
stackexchange/codereview
Please show me the best/fast methods for: 1) Loading very small binary files into memory. For example icons; 2) Loading/reading very big binary files of size 512Mb+. Maybe i must use memory-mapped IO? 3) Your common choice when you do not want to think about size/speed but must do only thing: read all bytes into memory...
stackexchange/codereview
this is a follow-up question for my previous question which design pattern is suitable for this workflow requirement?. I would like to know what is best way to store a boolean expression in database and then evaluate it at runtime without much effort. I have a requirement where a set of jobs need to be executed from th...
stackexchange/codereview
I want to be able to orient something toward the mouse on an HTML5 canvas. But when I use Math.atan2 and the other trig functions, the directions get messed up. It rotates in the opposite direction that it should and it's usually off by 90 degrees. It will probably be easier if you see it for yourself. Here's the javas...
stackexchange/codereview
I can usually google around and find this kind of thing but I just can't find this one. What I'm looking for is a list and description for all the variables that I can set in my deploy.rb file in a Rails 3 app with Capistrano 2. I've found and read these: https://github.com/leehambley/capistrano-handbook/blob/master/in...
stackexchange/codereview
I found Microsoft KB article: But it looks like they want me to recompile after I have created a key pair. Is there any way to just convert the assembly to a strong named assembly without recompiling?
stackexchange/codereview
just wondering... but is it possible to generate SQL commands for django's models? e.g. the session model python manage.py sql django Any ideas?
stackexchange/codereview
I have an item event receiver for a specific content type that is used in a Pages library. I am using the event logger to debug it, and I can tell that whenever I edit a page and publish it, it fires 3 ItemUpdating and 3 ItemUpdated events. I am certain that no other pages are being saved in that specific time. What is...
stackexchange/codereview
Is there anything, talking about graphic capabilities, that a Java application can do, while an applet cannot? I'm referring to java libraries (like Swing), not to native ones. edit: I need to create a user interface for graph visualization, probably using the spring embedder algorithm Initial downloading times are no...
stackexchange/codereview
I'm currently using the javax.script package for interpreting and executing Javascript code on the fly. Incidentally, this is the same engine used by Mozilla's Rhino JS interpreter. Question: is there any Java-based Javascript Engine that is faster than Rhino?
stackexchange/codereview
Having the following code, it keeps reporting inconsisteng accessibility but I do not understand why. It depends on the Program class being or not being public: enum Test {A,B} public class Program //when I remove public, it works { public Test a = Test.A; static void Main(string[] args)...
stackexchange/codereview
Hey, I want to be able to check if user touches my UIView so I can dismiss my picker how can I do it actually? Thanks!
stackexchange/codereview
What needs to happen to allow an HTTP POST to a WCF service? I would like to allow people to not only use SOAP with this service, but they must also be able to HTTP POST to this service and ideally receive an XML response. I cannot find an easy way to allow a WCF service to accept an HTTP POST. I am past the HTTP 415 e...
stackexchange/codereview
I am currently reading the book "SQL Programming Style" wrote by Joe Celko. In the first chapter, at the paragraph "Develop Standardized Postfixes" he states for the id column : "_id" = identifier. It is unique in the schema and refers to one entity anywhere it appears in the schema. Never user ">table_name<_id"...
stackexchange/codereview
I want to check if a file exists on a remote webserver with php. I now have this function: function url_exists($url) { // Version 4.x supported $handle = curl_init($url); if (false === $handle) { return false; } curl_setopt($handle, CURLOPT_HEADER, false); curl_setopt($handle, CURLOPT_FAIL...
stackexchange/codereview
I'm processing a large number of database records, each with a unique key. Due to the nature of my database, my processing method may encounter the same key twice since it is a relational database and one record may have more than one "parent" record. It is a waste of precious time, processing power, memory, and file s...
stackexchange/codereview
I have a multi-language system, and all over the place I have what I would call "wrapper properties" in every class, such as: Public Property Name(Optional ByVal ForceLanguageCode As String = Nothing) As String Get Return Translations.GetByCode(Me.EntityID, "name", ForceLanguageCode) End Get Set(ByV...
stackexchange/codereview