I am trying to access the StackExchange API from Emacs' elisp:
(require 'url)
(require 'json)
(defvar url-http-end-of-headers)
(defun read-json ()
(interactive)
(with-current-buffer (url-retrieve-synchronously "http://api.stackoverflow.com/0.8/users/2386")
(goto-char url-http-end-of-headers)
(json-read)))
M-x read-json results in the following error: JSON readtable error.
Am I missing anything?
I'm part of a testing team and have been tasked with "behaving badly" using javascript in a firefox browser. I've tried these methods to take the browser down http://www.yuki-onna.co.uk/browserdeath.html but none of them do anything worse than cause a popup asking to shut down the script.
Any other ideas?
StructureMap has the ability to apply conventions when scanning. Thus IFoo = Foo, without explicit registration.
Is something simular available in AutoFac? Looked around and just can't find anything helpfull.
Thanks,
Wierd....
Late nite I installed Office 2010 Professional Plus.
Here I am, the next morning, and Visual Studio 2008 is freezing, like there "was some invisible dialog window", because it doesn't allow me to click on any IDE element.
In brief, after I open a ASP.MVC form, suddenly I'm not allowed to click on anything, icon, dock panel, toolbox, nothing...
Anyone has this kind of problem?
Hi, I have created a Picker view in objective C and populated it with an NSArray and that all works fine, it compiles and shows on screen but the picker doesn't do anything. I'd like to turn as the user drags their finger across like you'd expect but it doesn't react in anyway.
'lil Help?
I want to define a generator from a list that will output the elements one at a time, then use this generator object in an appropriate manner.
a = ["Hello", "world", "!"]
b = (x for x in a)
c = next(b, None)
while c != None:
print c,
c = next(b, None)
Is there anything wrong or improvable with the while approach here? Is there a way to avoid having to assign 'c' before the loop?
Thanks!
Is there a built in way of just getting the filename for the current request?
Request.RawUrl will give everything AFTER the domain (including querystring), is there anything to just give me the current filename being requested?
Which is the best overall hash algorithm. md5 or sha1. From what I know md5 is faster that sha1 but SHA1 is more complex than md5.
I am missing anything
i have to send a file to a webserver via libcurl. so i send a HTTP POST form with the file and login credentials. it responds to me with some response (can be anything like HTML code or a SUCCESS or FAILURE string). i need to handle this in my code. can someone tell me how do i capture this response in libcurl.
Is it possible to detect all the hotkeys registered by the OS as well as software applications currently running? Any native or managed approach on the Windows platform? I know that the RegisterHotKey function returns false if the hotkey is already registered, but what I am looking for is an approach, method, etc. that will give me a list of registered hotkeys. Looping all possible combinations with RegisterHotKey does not sound like a good idea. Anything more efficient?
I want to display a text with a lot of lines. I added a multiline-label to a scroll view, but it didn't show anything. Looks like this is not the correct way to use the scroll view. How to use scroll view so that users can drag down to see more text?
I realise it is possible to create a crosstab within sqlite, but is it possible to dynamically determine the relevant categories/columns at runtime rather than hardcoding them?
Given the following example, it can get rather tedious ...
SELECT
shop_id,
sum(CASE WHEN product = 'Fiesta' THEN units END) as Fiesta,
sum(CASE WHEN product = 'Focus' THEN units END) as Focus,
sum(CASE WHEN product = 'Puma' THEN units END) as Puma,
sum(units) AS total
FROM sales
GROUP BY shop_id
I managed to do this in SQLServer in a stored proceedure before and wondered if there was anything equivalent.
I do:
git commit .
git push
error: Entry 'file.php' not uptodate. Cannot merge.
Then I do
git pull
Already up-to-date.
What do I do? I just want to get the latest version from the remote copy, and overwrite anything on my local copy.
I am trying to put a "Contract" on a method call. My web application is in Spring 3.
Is writing customs Annotations the right way to go. If so, any pointers( I didn't find anything in spring reference docs).
Should I use tools like "Modern Jass", JML ...? Again any pointers will be useful.
Thanks
Does anyone know of a good Job scheduler UI widget?
The ideal component would be a Javascript widget (hopefully JQuery) that allows a user to select a frequency which is converted to a cron expression.
Anything good out there?
I'm using minidom to parse an xml file and it threw an error indicating that the data is not well formed. I figured out that some of the pages have characters like ไà¸à¹€à¸Ÿà¸¥ &, causing the parser to hiccup. Is there an easy way to clean the file before I start parsing it? Right now I'm using a regular expressing to throw away anything that isn't an alpha numeric character and the </> characters, but it isn't quite working.
Hello All...
I am just entered into the Blackberry Arena..
I am using Eclipse Plugin for running my testing application to simulator.
So, In my code somewhere I have add System.out.println("Print"); statements, but by debugging or running app to simulator, I couldn't find any log statements printed to eclipse console.
Is there anything that I need to take care for using println() methods ?
Thanks in advance...
I'm reading through this computer science book and throughout the book I see a number of things written like so:
and then there's this:
and then this:
What kind of notation is the "Boolean Expression" in example 1 written in? I've never seen anything like it before and I'm tempted to assume that whoever wrote and/or scanned this book in fell asleep at the keyboard, and assuming that it's even valid, what about the 3rd example? I'm pretty sure that's not C++ or VB.NET they're showing there.
I am trying to scrape a wiktionary entry:
uri = URI.parse("http://en.wiktionary.org/wiki/" + CGI.escape('abjure'))
doc = Nokogiri::HTML(open(uri, 'User-Agent' => 'ruby'))
but the doc shows no elements for this word. The other words work fine and this word used to work. I have no idea what changed. Anyone see anything wrong with this?
I can't find anything like that. Commercial or free ( XSQL Lite is suitable for my case and ) tools show diffs in grids with possibility to export to CSV. Also they generate sync SQL scripts when run from command line. What I need is an output as a comprehensive report ( XML , HTML ) suitable for parsing so that I would be able to show similar diff grid in my application ( updated old/new values for each column , added - all values for row , deleted - all values for row and etc... ) .
I have a URL to a image which i want to save. I looked into ruby file handling and did not come across anything. Please guide me towards some links or blogs which talk about the same. I need to then use Paperclip to produce a thumbnail of this image to be used in my application.
We are looking for a .NET PDF creator. It needs to be .NET, so we can just copy the file(s) onto the server, not having to install anything.
We only need to create a PDF with some text and images and a heading, that's all.
Anyone know a good one? We are happy to buy if there is a good one that is easy to use.
Thanks in advance.
Fiddler is an HTTP proxy that, among other things, allows one to pause outgoing and incoming HTTP packets, modify their contents and continue.
Is there anything similar to this working in lower layers of the OSI model? In particular, I want to be able to pause a TCP ACK packet and later let it continue through the pipeline. *nux or Windows suggestions are appreciated.
Hello
I want to perform few tasks during Session_Start and Session_End (when user logs in and logs out) through custom code. Where should i write it? Is it possible by writing a code behind for global.asax? Will it break anything?
Thank you