Search Results

Search found 1948 results on 78 pages for 'tom davies'.

Page 58/78 | < Previous Page | 54 55 56 57 58 59 60 61 62 63 64 65  | Next Page >

  • is it possible to use a python scrapper in a website?

    - by Tom
    I want to scrap a website and use that content in a website of my own. I am just wondering if that can be done with python 2.7, and if so how? If not, do I have to use JavaScript to scrap it? And do you have a good place to learn how to do that or good libraries for it. For those of you wondering, the website I am scrapping is legal, and they allow for this to be done. I have searched all over but apparently nobody tries to implement these scrappers that they write. I can write a web scrapper in python just fine. Say my scrapper scraps a name from a wikipedia page (John Doe for example), how can I use that name that I get in my website? Another update, I have found pjsrape and PhantomJS. I have only found one stack overflow post and the github examples with aren't very intuitive. If anybody has any experience or better ways to do it I would very much appreciate it

    Read the article

  • T4MVC and Ajax method with parameter

    - by Tom
    I am trying to apply T4MVC to my project. Say, I have an ajax search box, it calls Home/SearchQuery action which takes in a string q as parameter. How do I write that line in T4MVC? From Ajax.BeginForm("SearchQuery", "Home", .... To Ajax.BeginForm(MVC.Home.SearchQuery(???)... .cshtml file @using (Ajax.BeginForm("SearchQuery", "Home", /* <-----Convert to T4MVC Here */ new AjaxOptions { LoadingElementId = "loadingGif", OnSuccess = "parseResults", OnFailure = "searchFailed" })) { <input type="text" name="q" /> <input type="submit" value="Search" /> <img id="loadingGif" style="display:none" src="@Url.Content("~/content/images/loading.gif")" /> } <div id="searchResults" style="display: table"></div>

    Read the article

  • Cross-Domain + iFrame Question

    - by Tom
    Hi Guys, We are creating a "widget" for our site and wanted to ensure we have got this right. I realize this all relates to X-Browser permissions but little worried about how this works with like Cookies and permissions ?

    Read the article

  • Howto get iframe linking to internal document source using javascript/jQuery?

    - by Tom
    Hi there, I have an iframe with id "appframe", the source is page.html and it's on the same server. I want to get the source of the page using jQuery. alert($("#appframe").contents().find("html").html()); returns <head></head><body></body> even though the document does not contain those tags, it only contains "Default page", so that is exactly what it should return. Any idea how to get the right source script of the whole document using jQuery? Eg. if the document would be "test" then that is exactly what it should return. Please note: I did ask this before a few weeks ago. Unfortunately, I got no solving answer. Because of my lower reputation (~85), I can not request a bounty... This doesn't make much sense to me. Anyway, it forced me to repost this question.

    Read the article

  • Finding vars from dynamically created namespaces in clojure

    - by Tom Crayford
    The following test fails: (ns clojure_refactoring.rename-fn-test (:use clojure.test)) (deftest test-fn-location (in-ns 'refactoring-test-fn-rename) (clojure.core/refer-clojure) (defn a [b] (inc b)) (in-ns 'clojure_refactoring.rename-fn-test) (is (not= (find-var 'refactoring-test-fn-rename/a) nil)) (remove-ns 'refactoring-test-fn-rename)) That is, find-var (of a var I've just created, in a namespace I've just create) returns nil. This behaviour doesn't happen at the repl, where typing out the steps of the test works just fine. Am I doing something wrong, or is this just something that doesn't work in clojure right now?

    Read the article

  • Django: Site-Wide URL Prefix

    - by Tom
    I've built a Django site that will live at the root when it's live. Right now it's functioning perfectly at the IP address. For testing purposes, the client has pointed a proxy url at it, but the url has /folder/path in it, so none of the URL patterns match. I put (/folder/path)? into all the url patterns so they now respond, but all of the links are broken because I'm using the {% url %} tag and while the url patterns will match the optional path, they don't include it in that tag. Clearly I can just hard-code /folder/path into all of my urls (well, into all of the url includes) until testing is complete, but is there a better way to do this?

    Read the article

  • Confused by "let" in Clojure

    - by Tom Dalling
    I just started playing with Clojure, and I wrote a small script to help me understand some of the functions. It begins like this: (def *exprs-to-test* [ "(filter #(< % 3) '(1 2 3 4 3 2 1))" "(remove #(< % 3) '(1 2 3 4 3 2 1))" "(distinct '(1 2 3 4 3 2 1))" ]) Then it goes through *exprs-to-test*, evaluates them all, and prints the output like this: (doseq [exstr *exprs-to-test*] (do (println "===" (first (read-string exstr)) "=========================") (println "Code: " exstr) (println "Eval: " (eval (read-string exstr))) ) ) The above code is all working fine. However, (read-string exstr) is repeated so I tried to use let to eliminate the repetition like so: (doseq [exstr *exprs-to-test*] (let [ex (read-string exstr)] ( (do (println "===" (first ex) "=========================") (println "Code: " exstr) (println "Eval: " (eval ex)) ) )) ) But this works once for the first item in *exprs-to-test*, then crashes with a NullPointerException. Why is the addition of let causing the crash?

    Read the article

  • Both Flash and Alternate Displaying In Firefox, Nothing but Errors in IE (sIFR)

    - by Tom Davison
    Hi guys, I've just installed and setup sIFR on my Magento store. An example page can be seen here: http://www.mint-creative.co.uk/shop And you can see it loads the heading brilliantly, but still displays the alternate text-only headline. I've quadruple checked the .css files and everything's loading ok I think. Also, in IE it doesn't display at all and every .css and .js file has an error according to the error log in IE8. Any help on this would be great as it's an urgent project! Cheers.

    Read the article

  • Switching 2003 SRV to 2008 caused Asp.net application not to load DLL

    - by Tom
    Switching aged 2003 SRV to 2008 caused my Asp.net 2 application fail: The application is no more loading the required library DLL from /bin/ folder anymore. What should I change in my code or web.config to make this webapp load OK also in new 2008 server? Now I receive this error when I access the application: This type is in IMPORTS ( Dll ). Compiler Error Message: BC30002: Type 'Facebook.Entity.User' is not defined.

    Read the article

  • How can I get my business objects layer to use the management layer in their methods?

    - by Tom Pickles
    I have a solution in VS2010 with several projects, each making up a layer within my application. I have business entities which are currently objects with no methods, and I have a management layer which references the business entities layer in it's project. I now think I have designed my application poorly and would like to move methods from helper classes (which are in another layer) into methods I'll create within the business entities themselves. For example I have a VirtualMachine object, which uses a helper class to call a Reboot() method on it which passes the request to the management layer. The static manager class talks to an API that reboots the VM. I want to move the Reboot() method into the VirtualMachine object, but I will need to reference the management layer: public void Reboot() { VMManager.Reboot(this.Name); } So if I add a reference to my management project in my entities project, I get the circular dependency error, which is how it should be. How can I sort this situation out? Do I need to an yet another layer between the entity layer and the management layer? Or, should I just forget it and leave it as it is. The application works ok now, but I am concerned my design isn't particularly OOP centric and I would like to correct this.

    Read the article

  • Creating a Dynamic calendar in Silverlight

    - by Tom
    I am attempting to create a long range calendar that dynamically loads (and unloads) event data as the user scrolls left or right through time. I'm really struggling to figure out how to lay the basic framework of the UI out and how to dynamically build the interface as the user scrolls by clicking and dragging the mouse in the view area. See the image below for a basic diagram of the intent. Each slice would have potentially multiple rectangles in it for events that occurred on that day (slice). I would like each slice to be a canvas to allow me to position those rectangles appropriately. There are a few problems that I am not yet sure how to tackle but this is the first big one that I've been mulling over for a while and can't quite wrap my head around: I know how to dynamically create controls but how would I go about adding things to one end of the scrollable content while removing things from the other depending on the way the user is scrolling? Any guidance in the right direction would be much appreciated! Thanks.

    Read the article

  • Alternatives to FastDateFormat for efficient date parsing?

    - by Tom Tucker
    Well aware of performance and thread issues with SimpleDateFormat, I decided to go with FastDateFormat, until I realized that FastDateFormat is for formatting only, no parsing! Is there an alternative to FastDateFormat, that is ready to use out of the box and much faster than SimpleDateFormat? I believe FastDateFormat is one of the faster ones, so anything that is about as fast would do. Just curious , any idea why FastDateFormat does not support parsing? Doesn't it seriously limit its use? Thanks! EDIT Holy crap, I just left a comment and that literally REMOVED a good answer! This appears a serious bug on stackoverflow!

    Read the article

  • How to pop items from a collection in Java?

    - by Tom Brito
    Is there a method in JDK or apache commons to "pop" a list of elements from a java.util.List? I mean, remove the list of elements and return it, like this method: public Collection pop(Collection elementsToPop, Collection elements) { Collection popped = new ArrayList(); for (Object object : elementsToPop) { if (elements.contains(object)) { elements.remove(object); popped.add(object); } } return popped; }

    Read the article

  • Google Map only showing Grey Blocks on load - Debug Cert has been obtained

    - by Tom
    I am attempting to follow the Google Map View under the views tutorial for the Android. I have followed step by step but still only see grey blocks when viewed. First: I created a Virtual Device using "Google API's(Google Inc.) Platform 2.2 API Level 8" Second: When creating my project I selected "Google API's Google Inc. Platform 2.2 API Level 8". Third: I obtained the SDK Debug Certificate Fouth: Began Coding. Main.xml <?xml version="1.0" encoding="utf-8"?> <com.google.android.maps.MapView xmlns:android="http://schemas.android.com/apk/res/android" android:id="@+id/mapview" android:layout_width="fill_parent" android:layout_height="fill_parent" android:clickable="true" android:apiKey="0l4sCTTyRmXTNo7k8DREHvEaLar2UmHGwnhZVHQ" / HelloGoogleMaps.java package com.example.googlemap; import android.app.Activity; import android.os.Bundle; import com.google.android.maps.MapView; import com.google.android.maps.MapActivity; public class HelloGoogleMaps extends MapActivity { @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.main); } @Override protected boolean isRouteDisplayed() { return false; } } HelloGoogleMaps Manifest: <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="com.example.googlemap" android:versionCode="1" android:versionName="1.0"> <application android:icon="@drawable/icon" android:label="@string/app_name"> <uses-library android:name="com.google.android.maps" /> <activity android:name=".HelloGoogleMaps" android:label="@string/app_name"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> </application> <uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/> </manifest> Any thoughts?? Thanks!

    Read the article

  • Is it possible to place Joomla under revision control?

    - by Tom
    We are a team of many developers working on a website that uses both Joomla and custom PHP scripts. The problem is that there are multiple developers working on various features which need to update information in Joomla (adding modules, changing existing ones or changing settings) and when one developer changes something, he usually makes the change locally first and then does the same thing (hopefully) on the production server. Not only that this is very error-prone, but the developers often forget to tell other developers about the changes. The custom PHP scripts are easily shared between developers, but the changes in Joomla are often forgotten and they lead to serious conflicts when a developer tries to replicate his local changes in production. I have thought about placing Joomla in a Mercurial repository, but how could we distribute the changes in the database between the development, the testing and the production machines?

    Read the article

< Previous Page | 54 55 56 57 58 59 60 61 62 63 64 65  | Next Page >