Search Results

Search found 2860 results on 115 pages for 'javaone feed'.

Page 85/115 | < Previous Page | 81 82 83 84 85 86 87 88 89 90 91 92  | Next Page >

  • How to login with python and save cookie, then use that info to view page for member only

    - by patcsong
    I am quite new in python and trying to write a script to login to the page at http://ryushare.com/login.python. I have try many attempt, but it fails to login and i have no idea why. After login to the page, I wish to get the return of http://ryushare.com/file-manager.python Here's the code I try to attempt by reading the example from others. import urllib, urllib2, cookielib username = 'myusername' password = 'mypassword' cj = cookielib.CookieJar() opener = urllib2.build_opener(urllib2.HTTPCookieProcessor(cj)) login_data = urllib.urlencode({'login' : username, 'password' : password}) opener.open('http://www.ryushare.com/login.python', login_data) resp = opener.open('http://ryushare.com/file-manager.python') print resp.read() I check the source code of the login page, it said the username and password value is "login and password" so i change it. I have try some other example which can be found here like google news feed, It also can not able to login : (

    Read the article

  • Facebook photo additions showing as separate / individual posts

    - by user1143693
    When posting additional photos to an existing Facebook album, each individual photo is being displayed on the mobile Facebook view as a separate post. Desktop display still groups them (correctly) into 1 album and shows as a single post. For instance, if I add 20 photos to an album, the people who have liked my page will see 20 individual posts in their feed from my account on their mobile devices. This has been happening for about 2 weeks now as far as I've noticed. My upload process has not changed. I should note that I've noticed this behavior by uploading via Lightroom as well as through the direct Facebook interface. Has anyone else experienced this? Did something change that I am not aware of? Thanks.

    Read the article

  • Monitoring an audio line.

    - by Stefan Liebenberg
    I need to monitor my audio line-in in linux, and in the event that audio is played, the sound must be recorded and saved to a file. Similiar to how motion monitors the video feed. Is it possible to do this with bash? something along the lines of: #!/bin/bash # audio device device=/dev/audio-line-in # below this threshold audio will not be recorded. noise_threshold=10 # folder where recordings are stored storage_folder=~/recordings # run indefenitly, until Ctrl-C is pressed while true; do # noise_level() represents a function to determine # the noise level from device if noise_level( $device ) > $noise_threshold; then # stream from device to file, can be encoded to mp3 later. cat $device > $storage_folder/`date`.raw fi; done;

    Read the article

  • Oracle: delete suddenly taking a long time

    - by Damo
    Hi We have a feed process which runs every day of the year. As part of that we delete every row from a table (approx 1 million rows) every day, repopulate it using 5 different stored procedures and then commit the transaction. This is the only commit statement that we call. All of a sudden the delete has started takign about 2 hours to complete. The delete is also very simple (delete from T_PROFILE_WORK) This has worked perfectly well for the past year, but in the past week i have noticed this issue. Any help on this is greatly appreciated Thanks Damien

    Read the article

  • How can I unit test an Android Activity that acts on Accelerometer?

    - by Corey Sunwold
    I am starting with an Activity based off of this ShakeActivity and I want to write some unit tests for it. I have written some small unit tests for Android activities before but I'm not sure where to start here. I want to feed the accelerometer some different values and test how the activity responds to it. For now I'm keeping it simple and just updating a private int counter variable and a TextView when a "shake" event happens. So my question largely boils down to this: How can I send fake data to the accelerometer from a unit test?

    Read the article

  • Add Wordpress Video Gallery from YouTube User account to template

    - by Derek Organ
    I'm trying to create a small gallery of my youtube videos in wordpress. I need to have full control of style though. What i'm looking to do is have one big video (latest) and the next three as small thumbs underneath that. Can anyone recommend the best way to do this. I've can get use RSS feed from my youtube page to get a list of the videos. I now need a simple way to embed this info in my template.

    Read the article

  • Setting many key/value pairs

    - by Andrew
    Hi, I'm working on a rake task which imports from a JSON feed into an ActiveRecord called Person. Person has quite a few attributes and rather than write lines of code for setting each attribute I'm trying different methods. The closest I've got is shown below. This works nicely as far as outputing to screen but when I check the values have actually been set on the ActiveRecord itself it's always nil. So it looks like I can't use .to_sym to solve my problem? Any suggestions? I should also mention that I'm just starting out with Ruby, have been doing quite a bit of Objective-c and now need to embrace the Interwebs :) http = Net::HTTP.new(url.host, url.port) http.read_timeout = 30 json = http.get(url.to_s).body parsed = JSON.parse(json) if parsed.has_key? 'code' updatePerson = Person.find_or_initialize_by_code(parsed['code']) puts updatePerson.code parsed.each do |key, value| puts "#{key} is #{value}" symkey = key.to_sym updatePerson[:symkey] = value.to_s updatePerson.save puts "#{key}....." # shows the current key puts updatePerson[:symkey] # shows the correct value puts updatePerson.first_name # a sample key, it's returning nil end

    Read the article

  • How to set the URL of a link to a variable using WATIR

    - by Alex
    Using WATIR and Excel, I'd like to take the first row of a table in Excel, visit the URL, then set the 12th link on the page as a variable in the cell next to the cell with the URL, then go to the next line and repeat. I'm stuck on getting the URL of the 12th link on the page to set as a variable that I can feed into the next cell in Excel. Here's what I have and it's not working. worksheet = workbook.WorkSheets(1) # get first workbook #declare test site test_site = worksheet.Range("a2").text #open ie ie = Watir::IE.new #go to test_site ie.goto test_site #find primlink ie.link(:index, 12).text = "primlink" puts primlink Any ideas?

    Read the article

  • How to break up HTML documents into pages for ebook?

    - by radnoise
    For an iPhone ebook application I need to break arbitrarily long HTML documents up into pages which fit exactly on one screen. If I simply use UIWebView for this, the bottom-most lines tend to get displayed only partly: the rest disappears off the edge of the view. So I assume I would need to know how many complete lines (or characters) would be displayed by the UIWebView, given the source HTML, and then feed it exactly the right amount of data. This probably involves lots of calculation, and the user also needs to be able to change fonts and sizes. I have no idea if this is even possible, although apps like Stanza take HTML (epub) files and paginate them nicely. It's a long time since I looked at JavaScript, would that be an option worth looking at? Any suggestions very much appreciated!

    Read the article

  • Getting text from a URL in ASP.NET

    - by user102533
    I am looking for a reliable way of extracting text given the web address, in ASP.NET/C#. Can anyone point me the right direction? Also, the web address could be say a news site that might have a lot of ads and menus etc. I need some intelligent way of extracting only the relevant content. Not sure how this could be done as how would I define what relevance is? Should I maybe read from a RSS feed? Any thoughts on this?

    Read the article

  • Google MAP API v3: Link markers to an external list

    - by meo
    Given is a database with locations, we feed those tho the google map api and all points are displayed. Now there is a list of this location right next to the google map. How can i link the places in the list to the dots on the map? Like this: http://www.local.ch/en/q/ubs.html I want to light up the point on the map on the list item hover and open the info-box by clicking on the list item. Can anyone point me into the right direction?

    Read the article

  • How do I return a variable from $.post() in jQuery? Closure variable?

    - by James Bao
    I am having trouble passing data retrieved from a $.post() function to use in other places in my code. I want to save the data as a variable and use it outside of the post() function. This is my code: var last_update = function() { $.post('/--/feed', {func:'latest', who:$.defaults.login}, function($j){ _j = JSON.parse($j); alert(_j.text); // This one works }); } alert(_j.text); // This one doesn't }; last_update(); //run the function Please help!

    Read the article

  • jQuery: use filter(), but work with both results

    - by Tomalak
    In jQuery, filter() reduces your result to those elements that fulfill a certain condition. This splits the list in two parts. Working with the "good half" of the elements is easy: $("some selector").filter(function() { // determine result... return result; }).each( /* do something */ ); But how can I work with the "other half" of my elements, too - but without doing the equivalent of this: $("some selector").filter(function() { // determine result... return !result; }).each( /* do something */ ); Basically, I'd like to feed two separate /* do something */ parts to a single filter. One for those that match, and one for the others - without having to select and filter twice.

    Read the article

  • How to get the stream of a public Facebook fanpage in php?

    - by Bundy
    Hi, I want to display my public fanpage feed onto my website via the Facebook API without requiring a login. I'm doing this require_once('../includes/classes/facebook-platform/php/facebook.php'); $fb = new Facebook($api_key, $secret); $fb->api_client->stream_get('',$app_id,'0','0','','','','','')); But I get this error Fatal error: Uncaught exception 'FacebookRestClientException' with message 'user id parameter or session key required' in includes/classes/facebook-platform/php/facebookapi_php5_restlib.php:3065 Stack trace: #0 includes/classes/facebook-platform/php/facebookapi_php5_restlib.php(1915): FacebookRestClient->call_method('facebook.stream...', Array) #1 facebook/api.php(12): FacebookRestClient->stream_get('', 13156929019, '0', '0', 30, '', '', '', '') #2 {main} thrown in includes/classes/facebook-platform/php/facebookapi_php5_restlib.php on line 3065 Then I figured, because of 'user id parameter or session key required', to add my user id to the call require_once('../includes/classes/facebook-platform/php/facebook.php'); $fb = new Facebook($api_key, $secret); $fb->api_client->stream_get(502945616,13156929019,$app_id,'0','0','','','','','')); But then I got this error Fatal error: Uncaught exception 'FacebookRestClientException' with message 'Session key invalid or no longer valid' I'm totally clueless :)

    Read the article

  • Can StructureMap be configured so that one can use different .config settings based on whether the p

    - by Mark Rogers
    I know that in StructureMap I can read from my *.config files (or files referenced by them), when I want to pass specific arguments to an object's constructor. ForRequestedType<IConfiguration>() .TheDefault.Is.OfConcreteType<SqlServerConfiguration>() .WithCtorArg("db_server_address") .EqualToAppSetting("data.db_server_address") But what I would like to do is read from one config setting in debug mode and another in release mode. Sure I could surround the .EqualToAppSetting("data.db_server_address"), with #if DEBUG, but for some reason those statements make me cringe a little when I put them in. I'd like to know if there was some way to do this with the StructureMap library itself. So can I feed my objects different settings based on whether the project is built in debug or release mode?

    Read the article

  • Best practice for passing configuration to each GUI object

    - by Laimoncijus
    Hi, I am writing an application, where I do have few different windows implemented, where each window is a separate class. Now I need somehow to pass a single configuration object to all of them. My GUI is designed in way, where I have one main window, which may create some child windows of its own, and these child windows can have their own childs (so there is no possibility to create all windows in initialization part and feed the config object to all of them from the very beginning)... What would be best practice for sharing this configuration object between them? Always passing via constructor or maybe making it somewhere as final public static and let each window object to access it when needed? Thanks

    Read the article

  • NSDateFormatter Does not convert correctly

    - by deamonsarea
    Hi, I have a NSString which is passed from an xml feed........ NSString *strDate =@"Thu, 22 Apr 2010 10.30 am CEST"; I'm currently using this code to format the date........ NSDateFormatter *dateFormatter = [[NSDateFormatter alloc] init]; [dateFormatter setDateFormat:@"EEE, dd MMM yyyy hh:mm a vvvv"]; NSDate *myDate = [dateFormatter dateFromString:date]; [dateFormatter setDateFormat:@"HH"]; NSLog(@"%@", [dateFormatter stringFromDate:myDate]); I want to format my string only to display only hours and currently I'm getting value like this. strDate =@"2010-04-10 14:00:00 +0530"; Can anyone please help me with this?......

    Read the article

  • How do I pass a Yahoo Pipes item into a YQL query?

    - by Joe Shaw
    One common thing to want to do in the Yahoo Pipes YQL element is pass in a Pipes value to the YQL query. For example: select * from html.tostring where url='<someurl>' and xpath='//div[@id="foo"]' and you want to pass in a dynamic value for <someurl>. Let's say that it's an RSS feed item's URL called item.link. Attempting to simply replace the quoted someurl with item.link gives you this error: Invalid identifier item.link. me is the only supported identifier in this context How can I pass this value in?

    Read the article

  • Making bash script to check connectivity and change connection if necessary. Help me improve it?

    - by cypherpunks
    My connection is flaky, however I have a backup one. I made some bash script to check for connectivity and change connection if the present one is dead. Please help me improve them. The scripts almost works, except for not waiting long enough to receive an IP (it cycles to next step in the until loop too quick). Here goes: #!/bin/bash # Invoke this script with paths to your connection specific scripts, for example # ./gotnet.sh ./connection.sh ./connection2.sh until [ -z "$1" ] # Try different connections until we are online... do if eval "ping -c 1 google.com" then echo "we are online!" && break else $1 # Runs (next) connection-script. echo fi shift done echo # Extra line feed. exit 0 And here is an example of the slave scripts: #!/bin/bash ifconfig wlan0 down ifconfig wlan0 up iwconfig wlan0 key 1234567890 iwconfig wlan0 essid example sleep 1 dhclient -1 -nw wlan0 sleep 3 exit 0

    Read the article

  • Read Text File line by line using Command Prompt/Batch

    - by user353305
    Hello All, First of all I am very thankful to the owner of this website. I have learned and implement various technologies with the help of solutions provided by the readers. I know the question I asked is posted many time in this forum. And I have tired all of the solutions available, but no luck I may case I am trying to read a dat file which is basically a msg/feed file having more than 22000 Characters. Every line may or may not be of same length. My requirement is to convert the file to fixed line length character file. I have a logic that work well using vb script, however its pretty slow. I have checked with For f/ but no luck. The only delimiter I have is EOT, which i can see in Textpad but not in notepad. I have tried with \n, token=. Please help me in resolving the issue. Regards, Rajiv [email protected]

    Read the article

  • Scala: XML Attribute parsing

    - by Chris
    I'm trying to parse a rss feed that looks like this for the attribute "date": <rss version="2.0"> <channel> <item> <y:c date="AA"></y:c> </item> </channel> </rss> I tried several different versions of this: (rssFeed contains the RSS data) println(((rssFeed \\ "channel" \\ "item" \ "y:c" \"date").toString)) But nothing seems to work. What am I missing? Any help would really be appreciated!

    Read the article

  • Can you detect if and excel find and replace is active during worksheet_change()?

    - by John Griffiths
    Hi I've just crashed excel using amazon spreadsheet to update feed. When doing find and replace [replace all] with 2 cells selected after the first replacement the worksheet_change() function finished with the whole spreadsheet selected. This meant that the replacements took place outside of the original area. Unfortunatly the replcement text included the find text and each replacement re-selected the entire area excel ran until it ran out of space then crashed. Pressing control-break brings up the vba dialog STOP/CONTINUE/DEBUG. DEBUG is greyed out as amazon had protected the sheet. STOP would stop one run but would then continue to crash. CONTINUE would switch back to the current change and continue to crash. Is there any way to detect if a find&replace operation is in action whilst executing excel vba? Regards John

    Read the article

  • How to use cbreak mode in Ruby terminal application?

    - by Thomas
    In a small Ruby application, I'd like user input to be accepted without having to wait for a carriage return. My understanding is that cbreak mode needs to be enabled in order for the terminal to feed user input directly into the script. I tried simply running x%[cbreak()] at the top of my script but that didn't work. I've also seen that it's possible to use (n)curses to achieve the same results, although that seems like overkill. Does anybody have a suggestion on how to implement this? Thanks

    Read the article

  • how to play an encrypted file in Android.

    - by user306517
    I need to be able to play an encrypted file in Android. The file is AAC. The only way I can see to do this is either: decrypt the file to internal private storage and point the player at that file to play, or decrypt & decode the file to pcm and feed it to an AudioTrack. 1 isn't great because it takes a long time to do that. 2 isn't great either because I don't know how I can take advantage of the HW decoder to do this. Any ideas? tia.

    Read the article

  • How to remove hyperlink but keep text for an array of links?

    - by Keith Donegan
    My question is fairly similar to this question: Remove hyperlink but keep text? but, I can't seem to workout how I can feed an array of class names and do this in one go? For Example <a class="unwrap" href="#">Blah</a> <a class="unwrap" href="#">Blah</a> <a href="#">Blah</a> <a class="unwrap" href="#">Blah</a> I would just like the links with the unwrap class to be modified.

    Read the article

< Previous Page | 81 82 83 84 85 86 87 88 89 90 91 92  | Next Page >