Daily Archives

Articles indexed Wednesday March 24 2010

Page 14/131 | < Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >

  • Best library to parse HTML with Python 3 and example?

    - by TMC
    I'm new to Python completely and am using Python 3.1 on Windows (pywin). I need to parse some HTML, to essentially extra values between specific HTML tags and am confused at my array of options, and everything I find is suited for Python 2.x. I've read raves about Beautiful Soup, HTML5Lib and lxml, but I cannot figure out how to install any of these on Windows. Questions: What HTML parser do you recommend? How do I install it? Do you have a simple example on how to use the recommended library to snag HTML from a specific URL and return the value out of say something like this: fooLink (say we want to return "/blahblah")

    Read the article

  • Validation of dependent properties in a "live edit" WPF app

    - by Ryan Cromwell
    I'm working on an app which supports live editing. That is you update properties in one area and their impact is seen in another with hitting "apply". Happens to be a charting app. One such edit "group" allows specifying a range. A triple range in fact: High, Target and Low. Our validation is such that High must be greater than target, target must be greater than Low (rocket science). Our dilemma is that the visual experience is a bit jarring when someone wants to go from say 30,20,10 to 15,10,5. I'm curious if anyone has implemented a mechanism for this scenario that might fit well in our situation such that we don't "yell" at the user as they change the range values.

    Read the article

  • Parantheses around method invokation: why is the compiler complaining about assignment?

    - by polygenelubricants
    I know why the following code doesn't compile: public class Main { public static void main(String args[]) { main((null)); // this is fine! (main(null)); // this is NOT! } } What I'm wondering is why my compiler (javac 1.6.0_17, Windows version) is complaining "The left hand side of an assignment must be a variable". I'd expect something like "Don't put parantheses around a method invokation, dummy!", instead. So why is the compiler making a totally unhelpful complaint about something that is blatantly irrelevant? Is this the result of an ambiguity in the grammar? A bug in the compiler? If it's the former, could you design a language such that a compiler would never be so off-base about a syntax error like this?

    Read the article

  • Android Certificate Changed?

    - by rgrandy
    I recently formatted my computer and updated to Windows 7. I backed up my keystore and tried to sign my apk with it but it gave me an error that said my certificate expires in 22yrs. which is just shy of what the market requires to upload the apk. So now I am stuck not being able to update my app... How did this happen? Is there a way to extend the lifetime of certificates so that I can update my app? Is there a way to verify this certificate against an old apk that has been uploaded to the market so that I can be sure I am trying to sign with the same certificate and I didn't have a mix up? Error Pic

    Read the article

  • Link to file outside context root of weblogic

    - by khue
    Hi, If I want to display an image in my webpage and its src is a file outside context root. At the IDE, the image is shown to be loaded. But when I test the web page, nothing displayed. How can I config weblogic server to allow the image to be displayed. If not is there anyway to run around this problem. Thanks a lot.

    Read the article

  • Can we use the task list from "another" web site of same site collection as task list for Sharepoint

    - by Khurram Aziz
    Can I specify/use an existing task list from "another" website but from same site collection to be used in my Sequential Sharepoint Workflow? I am using Visual Studio to code the workflow, and it will be deployed in /subsite, the root site already has a task list to which everyone has connected to Outlook etc...Instead of creating a new task list in /subsite and asking concerned to subscribe to this new task list...I want to use the existing one..

    Read the article

  • phpThumb cannot find ImageMagick / Imagick

    - by fistameeny
    Hi, I'm having a problem with phpThumb. It says in the documentation that to get the best out of it, use ImageMagick / Imagick. I've got this installed on the Server (running Centos 5.1), and can run convert --version and get the right info back. I can also run which convert which returns /usr/bin/convert However, phpThumb can't location the convert program - the demo's show that: (requires ImageMagick, this server is running "n/a" so it will not work) Does anyone have any pointers on how to fix this? Cheers, Matt

    Read the article

  • How do I create a Launcher in Ubuntu 9.1 that runs a shell script?

    - by mkelley33
    Here's my situation: New to Ubuntu (just nstalled 9.10 Karmic Koala 64 bit) Purpose: to easily run PyCharm without too much typing (ie. cd... ./pycharm.sh) Want to create desktop Launcher instead of terminal & typing (without resorting to the "Run in Terminal" option) Tried to create Launcher to executes .sh script in Document directory Right-clicked Desktop Create Launcher a. Type == Application; Browse [insert absolute path to .sh script]; no luck b. Type == Application in Terminal; Browse ...ditto I'm open to any other alternatives that involve as little typing as possible. I would like to just start Ubuntu, click Launcher icons, and have terminals spring to life, running the intended scripts. Crazy? No. Lazy? Probably. Productive? Hopefully :)

    Read the article

  • What is the Simplest Possible Payment Gateway to Implement? (using Django)

    - by b14ck
    I'm developing a web application that will require users to either make one time deposits of money into their account, or allow users to sign up for recurring billing each month for a certain amount of money. I've been looking at various payment gateways, but most (if not all) of them seem complex and difficult to get working. I also see no real active Django projects which offer simple views for making payments. Ideally, I'd like to use something like Amazon FPS, so that I can see online transaction logs, refund money, etc., but I'm open to other things. I just want the EASIEST possible payment gateway to integrate with my site. I'm not looking for anything fancy, whatever does the job, and requires < 10 hours to get working from start to finish would be perfect. I'll give answer points to whoever can point out a good one. Thanks!

    Read the article

  • Svn import with auto-props & pre-commit hook

    - by James Tisato
    My company's svn repo has a lot of MS Word docs in it. We've implemented a policy that all .doc files must have the svn:needs-lock property set to prevent parallel access on files that are hard to merge (we've also done this for xls, ppt, pdf etc.). We've implemented the policy by distributing a svn config with auto-props set appropriately for all relevant document types. We've also set up a pre-commit hook that checks that all added files of these types have the needs-lock property set (i.e. if they forget/are too lazy to update their svn config file, they won't be able to add any docs to the repo). The problem I'm having, however, is that the pre-commit hook fails when users try to import files into the repo, e.g. some users like to add files directly thru TortoiseSVN's Repo Browser, which effectively is an svn import. Through testing on other file types, I have seen that doing an import does in fact apply the auto-props listed in my config, but they don't seem to be applied at the point that the pre-commit hook runs. When importing .doc files, the hook fails, saying that the needs-lock property is missing. Is there really much difference between adding a single file to a working copy and committing it vs importing a file directly? Do we need to tailor our precommit hook in some way to cater for this scenario?

    Read the article

  • checkbox update the record using jquery?

    - by python
    <? include("connect.php"); $sql="select * from sampledb"; $res=mysql_query($sql) or die("query failed"); ?> <script type="text/javascript" src="scripts/jquery.js"></script> <script type="text/javascript"> function updateCheckVal() { var valcheck = []; $('#checkbox :checked').each(function() { valcheck.push($(this).val()); }); $('#store_checkbox').val(valcheck) } $(function() { $('#checkbox input').click(updateCheckVal); updateCheckVal(); }); $(function(){ $("a.modify").click(function(){ var val = []; $(':checkbox:checked').each(function(i){ val[i] = $(this).val(); }); $("#deleted_id").val(val); page=$(this).attr("href"); $("#Formcontent").html("loading...").load(page); return false; }); }); </script <form name=""> <table width="100%" border="1" cellpadding="1" cellspacing="1"> <thead> <tr bgcolor="#CCCCCC"> <th></th> <th>ID</th> <th>Fullname</th> </tr> </thead> <tbody> <? while($row=mysql_fetch_assoc($res)){?> <tr> <td id="checkbox"><input type="checkbox" name="chk[]" class="chk" value=<?php echo $row["student_id"];?> ></td> <td><?php echo $row["id"];?></td> <td><?php echo $row["fullname"];?></td> </tr> <? }?> </tbody> </table> <input type="hidden" name="store_checkbox" id="store_checkbox" value=""> <a href="formstudent.php?action=update&id=<?php echo $_POST["store_checkbox"]; ?>" class="modify">modify</a> I want to pass the checkbox value that is checked in something like this: example :formstudent.php?action=update&id=1, I am doing here is pass like this but does not work. <a href="formstudent.php?action=update&id=<?php echo $_POST["store_checkbox"]; ?>" Anybody know how to do this?

    Read the article

  • Recording Skype Video

    - by Leah Peterson
    I have two problems - When doing a Skype video call, I can't see the other person. Skype says both my input and output are fast/good. I need a good recording program that will save both sides at once in a podcast. I've been playing around with Vodburner, but it seems to be very temperamental. I can't get anything longer than 30 seconds to save and even when if it does save, the file isn't compatible with Windows Live Movie Maker, even when I change the extension to .MP4 or .WMV. I tried to downlowd the format changer http://www.mediacoderhq.com/ that Vodburner suggests, but only got errors. I'm using Windows 7 with 62 GB free.

    Read the article

  • US (Postal) ZIP codes: ZIP+4 vs. ZIP in web applications

    - by FreekOne
    Hi guys, I am currently writing a web application intended for US users that asks them to input their ZIP code and I just found out about the ZIP+4 code. Since I am not from the US and getting a user's correct ZIP code is important, I have no idea which format I should use. Could anyone (preferably from the US) please clarify what's the deal with the +4 digits and how important are they ? Is it safe to use only the plain 5-digit ZIP ? Thank you in advance !

    Read the article

  • CSS Change background parent of element

    - by bratna
    I have some problem that i want to change it with css <div class="a"> <div class="b"> <span></span> </div> <div class="c"> <span></span> </div> <div class="d"> <span class="e"></span> </div> </div> I want to change background of div.b and div.c by using span.e Please help me. Thanks

    Read the article

  • How do I rewrite binary data in Java

    - by hayato
    I'm trying to figure out how to replace binary data using Java. below is a PHP example of replacing "foo" to "bar" from a swf file. <?php $fp = fopen("binary.swf","rb"); $size = filesize("binary.swf"); $search = bin2hex("foo"); $replace = bin2hex("bar"); $data = fread($fp, $size); $data16 = bin2hex($data); $data16 = str_replace($search, $replace, $data16); $data = pack('H*',$data16); header("Content-Type:application/x-shockwave-flash"); echo $data; ?> How do I do this in Java.

    Read the article

  • something like INotifyCollectionChanged fires on xml file changed

    - by netmajor
    It's possible to implement INotifyCollectionChanged or other interface like IObservable to enable to bind filtered data from xml file on this file changed ? I see examples with properties or collection, but what with files changes ? I have that code to filter and bind xml data to list box: XmlDocument channelsDoc = new XmlDocument(); channelsDoc.Load("RssChannels.xml"); XmlNodeList channelsList = channelsDoc.GetElementsByTagName("channel"); this.RssChannelsListBox.DataContext = channelsList;

    Read the article

  • For each <item> in CheckedListBox. <item> returns as Object and not as Control

    - by Tivie
    Hello there. I have a CheckedListBox previously populated. I want to loop with a "for each / next" through all items in the CheckedListBox and do a lot of "stuff" with each iteration element of the checkedlistbox. example code: For Each item In CheckedListBox1.Items If item.Checked = True Then 'do stuff like item.BackColor = Color.Blue Else 'do other stuff item.BackColor = Color.Brown End If Next the problem is that is an 'Object' type and not a 'Control' type. If I force the iteration var As CheckBox, it throws an InvalidCastException saying that type 'System.String' can't be associated with type 'System.Windows.Forms.CheckBox' I know I can easily work around using for i=0 to CheckedListBox.Items.Count - 1 but I want to use a for each /next loop since I have a lot of code in that loop (and With can't be used) and always poiting directly to the object is something I wish to avoid and I really need the code to be as simple as possible. I actually spent one afternoon looking for this but couldn't find any answer. If someone could be kind enough to enlight me in this, it would be extremely appreciated. Best regards

    Read the article

  • "The left hand side of an assignment must be a variable" due to extra parentheses

    - by polygenelubricants
    I know why the following code doesn't compile: public class Main { public static void main(String args[]) { main((null)); // this is fine! (main(null)); // this is NOT! } } What I'm wondering is why my compiler (javac 1.6.0_17, Windows version) is complaining "The left hand side of an assignment must be a variable". I'd expect something like "Don't put parentheses around a method invokation, dummy!", instead. So why is the compiler making a totally unhelpful complaint about something that is blatantly irrelevant? Is this the result of an ambiguity in the grammar? A bug in the compiler? If it's the former, could you design a language such that a compiler would never be so off-base about a syntax error like this?

    Read the article

  • UIButton not being clicked in iPhone programming.

    - by suse
    Hello, I've created a UIButton on a view and on action of the UIButton[UIButton* button1_obj] one more button[UIButton* button2_obj] is created on same view. i'm facing these 2 issues...please guide me how to proceed. button1_obj is appearing when i run my project, but its not being clicked or highlighted, nor any exception is thrown. On action of button1_obj , button2-obj has to appear on the same view, how to clear the view before placing button2_obj on it.

    Read the article

  • Versions. "Is not a working copy"

    - by bartclaeys
    A little background first: I'm a designer/developer and decided to use subversion for a personal project. I'm the only one working on this project. I've setup a Beanstalk account and installed Versions on Mac. Locally I have MySQL and PHP running through MAMP. What I want to do is develop locally and push code into Beanstalk. I'm not planning on deploying from Beanstalk to my live server at this moment. In Beanstalk I created a repository and imported all my code. I then installed Versions and added a bookmark to the Beanstalk repository. So far so good. Next I guess (this is a wild guess) I need to add a so called 'working copy bookmark' so that Versions can watch my local copy for changes and commit it to my Beanstalk repository. Problem: When I click 'Create working copy bookmark' in Versions and I select a folder on my computer I get the error: '/Applications/MAMP/www_mydomain' is not a working copy' I have no clue what that means and now I'm stuck. How can I tell Versions to keep track of changes of a local folder?

    Read the article

  • Tree View / File View Control for C#

    - by Jason
    I have been looking for a C# tree control for displaying a file system that has the following capabilities: Select a starting directory. I don't always want to start at a "default" top directory level. The ability to grab an event when the user double clicks on a file in the tree. I want to handle opening the file within my application. I have been looking at this C# File Browser. Unfortunately, I have not been able to figure out how to do meet my second need. (If anybody can clear that up for me, I would like that even better.) Thanks for any help.

    Read the article

< Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >