Search Results

Search found 2582 results on 104 pages for 'mike selby'.

Page 82/104 | < Previous Page | 78 79 80 81 82 83 84 85 86 87 88 89  | Next Page >

  • Potential Django Bug In QuerySet.query?

    - by Mike
    Disclaimer: I'm still learning Django, so I might be missing something here, but I can't see what it would be... I'm running Python 2.6.1 and Django 1.2.1. (InteractiveConsole) >>> from myproject.myapp.models import * >>> qs = Identifier.objects.filter(Q(key="a") | Q(key="b")) >>> print qs.query SELECT `app_identifier`.`id`, `app_identifier`.`user_id`, `app_identifier`.`key`, `app_identifier`.`value` FROM `app_identifier` WHERE (`app_identifier`.`key` = a OR `app_identifier`.`key` = b ) >>> Notice that it doesn't put quotes around "a" or "b"! Now, I've determined that the query executes fine. So, in reality, it must be doing so. But, it's pretty annoying that printing out the query prints it wrong. Especially if I did something like this... >>> qs = Identifier.objects.filter(Q(key=") AND") | Q(key="\"x\"); DROP TABLE `app_identifier`")) >>> print qs.query SELECT `app_identifier`.`id`, `app_identifier`.`user_id`, `app_identifier`.`key`, `app_identifier`.`value` FROM `app_identifier` WHERE (`app_identifier`.`key` = ) AND OR `app_identifier`.`key` = "x"); DROP TABLE `app_identifier` ) >>> Which, as you can see, not only creates completely malformed SQL code, but also has the seeds of a SQL injection attack. Now, obviously this wouldn't actually work, for quite a number of reasons (1. The syntax is all wrong, intentionally, to show the oddity of Django's behavior. 2. Django won't actually execute the query like this, it will actually put quotes and slashes and all that in there like it's supposed to). But, this really makes debugging confusing, and it makes me wonder if something's gone wrong with my Django installation. Does this happen for you? If so/not, what version of Python and Django do you have? Any thoughts?

    Read the article

  • How do I force MyEclipse to hot-deploy a JavaScript file to my JBoss instance?

    - by Mike Cialowicz
    I'm having trouble with MyEclipse 7.1.1 hot-deployment of files to my JBoss 4 server. The problem is this: while my server is running, I can make changes to various JAVA and HTML files, which are then hot-deployed immediately (I can see the changes reflected in my browser when I refresh the page). However, while working on a particular JavaScript file, my changes are not being hot-deployed. This makes it very difficult to work on and debug this file, since I have to stop my server, redeploy, and start it again each time I make changes. This is a new problem - it didn't used to happen with this file, so I think something got screwed up in my MyEclipse configuration. I've verified that my projects (JBoss 4 instances) are all set up in "Exploded" mode for hot-deployment. I'm also 99% sure that this isn't an issue with my browser, since I always refresh with CTRL+F5, and I've tried a number of things like clearing my browser cache to get the currently deployed version of the file. I've also tried doing a "clean" on the project while the server is running, and that didn't force a deployment either. Any sort of solution would be helpful. I'd love for MyEclipse to deploy the file automatically, but I'm also open to manually forcing hot-deployment of this particular file while I work on it. Thank you.

    Read the article

  • Javascript - Function call will not enter function body

    - by Mike S
    I have a function acting as a constructor that, when called, gets as far as the function definition in the debugger, but never to the function body. Is there a common reason this may happen that I am overlooking? Example code below: myconstructor.js function MyConstructor(optionalParam) { //this breakpoint gets hit var newobj = {}; //breakpoint never hit //code to check for null parameter //other code }; main.js var myConstructor = new MyConstructor(); There must be something I have overlooked, but I can't see what that is. Neither firefox/firebug nor VS report errors or warnings. Thanks!

    Read the article

  • Regex for zeroing in on build output text error

    - by Mike Atlas
    I'd like to quickly hone in on what failed in a build log output that is nearly 5k lines long, using Notepad++ as my editor for the file. Notepad++ has the nice ability to specify regular expressions, so I am wondering if there is a way to not match: Compile complete -- 0 errors, 0 warnings but to match, for example: Compile complete -- 1 errors, 0 warnings Compile complete -- 100 errors, 0 warnings where the match would be (1 or more) errors. If this isn't possible, I will probably just write a quick line-by-line parsing tool instead, but I was hoping someone on StackOverflow could whip out a regular expression in the same amount of time - I'm definitely not proficient enough with regular expressions to be able to write one for my needs in a short amount of time.

    Read the article

  • Using adaptive step sizes with scipy.integrate.ode

    - by Mike
    The (brief) documentation for scipy.integrate.ode says that two methods (dopri5 and dop853) have stepsize control and dense output. Looking at the examples and the code itself, I can only see a very simple way to get output from an integrator. Namely, it looks like you just step the integrator forward by some fixed dt, get the function value(s) at that time, and repeat. My problem has pretty variable timescales, so I'd like to just get the values at whatever time steps it needs to evaluate to achieve the required tolerances. That is, early on, things are changing slowly, so the output time steps can be big. But as things get interesting, the output time steps have to be smaller. I don't actually want dense output at equal intervals, I just want the time steps the adaptive function uses.

    Read the article

  • What's the best CDN for image hosting on a high-volume web site?

    - by Mike
    Akamai is way too expensive. Photobucket is not reliable. Is there a great content delivery network that I can use just to host my images? We deploy images programmatically via FTP, so there is some programming behind the scenes. Having some sort of reporting about the reliability of the service, whether it's raw logs files or a web-based admin screen that shows http errors, would also be important. Has anyone worked with edgecast?

    Read the article

  • Is the situation with Java ME improving?

    - by mike g
    It seems to be the consensus that developing for Java ME is not as cross platform as you might expect, particularly compared to say java SE, but it is difficult to assess how the situation is evolving. Is the situation improving significantly? Are problematic implementations being patched? Are problematic implementations dying out as a proportion of mobile devices? Is the tool chain improving? Are there ways to identify at least some cross platform 'errors' without necessarily deploying to each and every device?

    Read the article

  • What's the best way to move "a child up" in a .NET XmlDocument?

    - by Mike
    Given an XML structure like this: <garage> <car>Firebird</car> <car>Altima</car> <car>Prius</car> </garage> I want to "move" the Prius node "one level up" so it appears above the Altima node. Here's the final structure I want: <garage> <car>Firebird</car> <car>Prius</car> <car>Altima</car> </garage> So given the C# code: XmlNode priusNode = GetReferenceToPriusNode() What's the best way to cause the priusNode to "move up" one place in the garage's child list?

    Read the article

  • Project works in eclipse but not when exported

    - by Mike
    I wrote an application that uses GraphViz to generate some graphs as .gif's according to the DOT syntax. When I run from Eclipse the images are generated fine but when I export it as a jar the images are created but there is no data in them. When I view them in Microsoft Picture Viewer its just the red X. It was working as an exported jar until I put the picture generation in its own thread. I can't seem to figure out whats going on here. Are there any problems exporting multi-threaded projects? Any one have any ideas? Thanks

    Read the article

  • Create comma seperated values in perl

    - by Mike
    Let's say I have a list of elements @list=(1,2,3); #desired output 1,2,3 And I want to print them as comma seperated values. And most importantly, I do not want the last element to have a comma after it. What is the cleanest way to do this in Perl?

    Read the article

  • What is this weird script I found on facebook?

    - by Mike Turley
    Not so much a question to help my own programming, but I found this page on facebook with a cool illusion and a page that says "to see the real illusion, copy and paste this code into your address bar" and there is a script: http://pastebin.com/LQUVQ8hm What the hell is this? What would happen if I put it in my address bar, which I assume would be a very unwise idea? I am confused.

    Read the article

  • Java Swing - good idea?

    - by Mike
    hi, simple question : I need to write cross platform application (basically CRUD). Is usage of Java Swing good idea? Or is it out-dated and you know better solution? I dont want to use like 5 languages for various stuff, one or two should be enough. Thanx!

    Read the article

  • Which is the best sql schema comparison tool for Oracle?

    - by mike g
    It should be a tool to enable versioning of a database schema and efficiently updating databases with older versions of the schema: robustness, does it handle all edge cases support for data migration command line execution flexibility, can some data be compared as well In the answers a breakdown on support for these points (and anything I may have missed) would be appreciated.

    Read the article

  • What non-standard behaviour features does Gmail exhibit, when it is programmatically used as a POP3 server?

    - by Mike Green
    I am trying to prepare a complete list of behaviour that Gmail POP3 exhibits, that you wouldn’t expect to generally find in a POP3 server. For example, Gmail appears to ignore the DELE (delete) command from a POP3 client. Instead, it implements its own delete and archive strategy. The purpose of preparing a list is to avoid developers testing a POP3 client against the Gmail POP3 server and then assuming that all POP3 servers behave in the same way. Can anyone provide a more complete list of non-standard behaviour?

    Read the article

  • jQuery .load() call doesn't execute javascript in loaded html file

    - by Mike
    This seems to be a problem related to Safari only. I've tried 4 on mac and 3 on windows and am still having no luck. What I'm trying to do is load an external html file and have the Javascript that is embedded execute. The code I'm trying to use is this: $("#myBtn").click(function() { $("#myDiv").load("trackingCode.html"); }); trackingCode.html looks like this (simple now, but will expand once/if I get this working): <html> <head> <title>Tracking HTML File</title> <script language="javascript" type="text/javascript"> alert("outside the jQuery ready"); $(function() { alert("inside the jQuery ready"); }); </script> </head> <body> </body> </html> I'm seeing both alert messages in IE (6 & 7) and Firefox (2 & 3). However, I am not able to see the messages in Safari (the last browser that I need to be concerned with - project requirements - please no flame wars). Any thoughts on why Safari is ignoring the Javascript in the trackingCode.html file? Eventually I'd like to be able to pass Javascript objects to this trackingCode.html file to be used within the jQuery ready call, but I'd like to make sure this is possible in all browsers before I go down that road. Thanks for your help!

    Read the article

  • C# compile error for simple Annual Salary Calculator

    - by Mike Vignapiano
    I am new to C# and trying to create my 1st app. I have 3 errors. The first two say that txtSalary and Salary do not exist. The 3rd says that it cannot convert method group 'ToString' to non-delegate type 'string'. and asks if I intend to invoke the method. Here is what I have: protected void Button1_Click(object sender, EventArgs e) { int salary, AnnualHours, Rate; string txtAnnualHours, txtSalary, txtRate; salary = AnnualHours * Rate; txtsalary = int.Parse(Salary); txtAnnualHours = salary.ToString; MessageBox.Show(salary); } According to my book, when you enter numerics in AnnualHours and Rate textbox, when click Button1, these values are converted from string to integers, then multiplied for salary. Then numeric answer converted to string and displayed in messagebox named txtSalary. Please show me what I got wrong because according to the book, I am not missing anything.

    Read the article

  • PHP - displaying 1 random record for each week

    - by mike
    I want to display 1 random record from a database based on the week. I need to determine if it's a new, and if it is a new week, then select the record and display the new record. I'm thinking I can just use a single day of the week to generate the new record, either way will work. I'm really having a hard time conceptualizing how I'll store the record id and not select a new one when someone visits again the same day or refreshes the page. Any ideas? Let me know if I wasn't clear enough.

    Read the article

  • How to make same UIWebView take data from different local .html files?

    - by Mike Rychev
    I have an app, where there's one UIWebView and a UITableView. I don't want to create many .xib's, so I decided to make one .xib for all elements of the table. When user chooses a table element, the UIWebView appears and I want it to load data from different .html's depending on the name of the parent controller. I tried this: if (selectedTableElement==@"FirstElement") { [childController.message loadRequest:[NSURLRequest requestWithURL:[NSURL fileURLWithPath:[[NSBundle mainBundle] pathForResource:@"_" ofType:@"html"]isDirectory:NO]]]; } And then myWebView=message; But it didn't work. Thanks in advance!

    Read the article

< Previous Page | 78 79 80 81 82 83 84 85 86 87 88 89  | Next Page >