Search Results

Search found 69 results on 3 pages for 'hanan cohen'.

Page 1/3 | 1 2 3  | Next Page >

  • what to learn & practice to be a programmer (not for Job) [closed]

    - by Hanan N.
    I want to be able to write programs (tools) for my own needs, and I want to tell the computer what to do, not to be strict to what other's told it to do. I have a good knowledge of Linux & Windows, I am also have a bit of Python in my head, but I think that I need some guidance on what languages or practices to invest my time into in order to be able to tell the computer what to do. I know there is a lot of posts similar to what I am asking here, but there is a big difference and so I have opened this thread. My goal isn't to work at a company, so I don't need to learn how to work as a team, I don't need to learn as much how to maintain my code nor how to write it nice for others to understand (I know it is important but not for me). I don't want to learn it as a profession, but as a serious hobby (you can call it hacking as long as you know what cracking means), my end goal is to be able to understand other's people code, and to write my own code with a lot of deep knowledge of the ins and outs of the computer system in order to gain from it as much as I can. So in essence my questions are: How can I understand, in depth, computers, in order to exploit them as much as I can? What should I learn? Are there any books that I should read? Is it possible to do this, or do I have to learn every aspect of programming?

    Read the article

  • how to fix: www.domain.com redirected to domain.com

    - by cohen
    Hi this website livingalignment.com is very slow to load. The domain and hosting is all with go daddy. In pingdom I found that it is redirecting from www.livingalignment.com to livingalignment.com and it takes about 2 seconds to do so. you can see that here taking about 10 seconds when I entered www.livingalignment.com: http://tools.pingdom.com/fpt/#!/kNZeCxO8r/www.livingalignment.com If I test it and put in livingalignment.com then it takes about 4 seconds: http://tools.pingdom.com/fpt/#!/csgePmsNx/livingalignment.com What should I do to fix this? thanks.

    Read the article

  • libimobiledevice wants to remove all my other packages

    - by Dror Cohen
    When running the command sudo apt-get remove libimobiledevice2 I get: The following packages will be REMOVED: ... gdm gdm-guest-session gnome-power-manager gnome-session gnome-session-bin gvfs-backends indicator-power indicator-session kde-plasma-desktop kde-standard libgpod-common libgpod4 libimobiledevice2 nautilus-share ubuntu-desktop upower` Is it really nessecary to remove all of my KDE and Gnome packages? The source of the problem is that the installed oneric package doesn't recognize my ios 5.1 - so I wanted to switch to the latest and greatest (1.0.7 and if that's not good enough I'll go to the dev version 1.1.2). I'm using oneric 64bit.

    Read the article

  • cocos2d: syncing CCAnimation frames with Box2d Shape manipulations

    - by Hezi Cohen
    hi everybody! my cocos2d game currently has a ccsprite attached to a box2d body. during the game i apply different CCAnimations on my sprite, i would like to perform certain manipulations to the box2d body according to the frame currently displayed by the sprite (change rotation of the body, etc.) my current idea on implementing this is to subclass ccsprite and change the setDisplayFrame implementation but i thought somebody here probably did the same and already has a solution, so any suggestions on how to implement this? thanks!

    Read the article

  • facebook share and opengraph

    - by hannit cohen
    I'm managing a video blog. The blog contains a main youtube video on the homepage and several thumbnail images of other videos elsewhere. I have a share button for the main page and the single posts pages and have added opengraph to specify the used image. For some reason facebook ignores my opengraph image and uses othe images it finds in the page... the header looks like this: (for the homepage) <!-- Facebook Opengraph --> <meta property="fb:app_id" content="155967927783206" /> <meta property="og:url" content="http://mttv.co.il/2010/12/%d7%9e%d7%a4%d7%92%d7%a9-%d7%a1%d7%99%d7%99%d7%a2%d7%95%d7%aa-%d7%92%d7%a0%d7%a0%d7%95%d7%aa-%d7%9c%d7%93%d7%95%d7%a8%d7%aa%d7%99%d7%94%d7%9d-1959-2010-%d7%91%d7%9e%d7%a2%d7%9c%d7%95%d7%aa/"/> <meta property="og:title" content="???? ?????? ????? ???????? 1959-2010 ??????" /> <meta property="og:description" content="???? ????? ?? ?????? ????? ?????? ????????? ???? ?????? 1959 ??? 2010 ?????? ????? ??????? ???' ??? ??? ????? ???? ??????? ???????? ?????? ?&quot;? ???? ??? ?&quot;? ????? ?????? ????? ???? 08.12.10 " /> <meta property="og:type" content="article" /> <meta property="og:image" content="http://www.mttv.co.il/wp-content/uploads/2010/12/Gvi91UEjCAw_mid-135x77.jpg" /> The website address is: http://mttv.co.il Any help will be appreciated

    Read the article

  • Using SSH to find access to a problematic script in logs of multiple domains

    - by Hanan Cohen
    I run several (~20) sites on a Dreamhost VPS. Lately I max my memory allocation for the VPS and I want to find the problem. I would like to have an SSH script that will scan all the log files of all the domains and show me what object (image, php script etc) gets lots of calls. It will count the calls in each /logs/*/http/access.log, do an descending sort and show me the top 10 across domains. But I don't know how to do that. Can it be done? Can anyone suggest a script that will do that? Thanks. (Cross posted to Stack Overflow)

    Read the article

  • Printer spooler service stop running when sent print job

    - by Hanan N.
    Every time i am sending a print job to the printer, i am don't get any response from the printer, and at the printer job list at the status of the job, i see that there was an Error, but it don't give me any clue on what could be the problem. After some investigation i found that every time that i send the print job to the printer the printer spooler service stops to run, then after a second or two it start again (i think that this behavior is related to the printer spooler settings to rerun it self after it stops). Things that i have tried so far: Remove and Install again the Driver. After removing the driver, i have removed the unnecessary registry keys according to this article from Microsoft, these are: Rename all files and folders in: c:\windows\system32\spool\drivers\w32x86 Remove anything but Drivers Print and Processors: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Environment\Windows NT x86 Remove anything in here: HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Print\Monitors but: BJ Language Monitor Local Port Microsoft Document Imaging Writer Monitor Microsoft Shared Fax Monitor Standard TCP/IP Port USB Monitor WSD Port Disconnect and Reconnect the Printer. Clean the computer from Viruses & Spywares. Currently i am stuck, i have no more things to try, if anybody know about any kind of solution please let me know about it. Since i am want to keep this post as general problem that relate to the printer spooler, and not just my particular problem, i didn't included inside the windows version & the printer model, they are (although i think that it isn't relate just for that particular model): Windows 7 32bit, HP Officejet 4500 G510g-m (connect to the computer via USB). Thanks.

    Read the article

  • NT4 server generate too much weird DNS queries, How can i see the source PID?

    - by Hanan N.
    I have a NT4 server that in the last two weeks started to generate too many weird DNS queries to the DNS server is set to use. I have got warnings from the IPS system that it has blocked the responses from the DNS server back to the NT4 server. The queries it generate doesn't relate to any computer in the network, it is like 120624100088.xxxxxxx.net where xxx is the internal network, the numbers are just random at each query. I have done some research on how to get the PID that is generating the queries, and i found that only Process Monitor could give me that information, but since it is NT4 system Process Monitor doesn't work on it. It is a production server and i am just can't stop services as i want. I would like to get your advice on how can i get the PID that is generating these queries? Thanks.

    Read the article

  • access denied trying extracting an archive on the windows user temp folder

    - by Hanan
    I'm trying to run a command-line process (which is extraction of a .7z archive) on a file that lies in a temporary folder on the windows user temp directory (C:\Documents and Settings\User\Local Settings\Temp), using Process in my c# app. I think the process return error that happens because of "access denied" because I can see a win32Exception with error code 5 when I dig in the prcoess object of .NET. doing the same on some other location worked fine before, so I guess maybe it's something I'm not supposed to do ? (running a process to use a file on the the %TEMP%) perhaps I need to pass security somehow?

    Read the article

  • Windows 7 - swap file on a USB disk? [closed]

    - by Sara Cohen
    Possible Duplicate: How to move the page file to another physical disk location Windows 7 I was given temporarily a PC, running Windows 7 Ultimate. The problem is it's hard drive is full, there are like 250 MB free. The swap file is set to none. It has 4 GB RAM. When I load a few tabs in Chrome or IE and start a game it runs out of memory. I already emptied Recycle Bin, %temp%, etc. Deleting/moving user files or adding RAM is not an option. Now I have a USB 3 7200 RPM drive, it's connected to a USB 3 port and is really fast. Is there a way to create a swap file on that drive?

    Read the article

  • How to rate-limit in nginx, but including/excluding certain IP addresses?

    - by Jason Cohen
    I'm able to use limit_req to rate-limit all requests to my server. However I'd like to remove the rate restriction for certain IP addresses (i.e. whitelist) and use a different rate restriction for certain others (i.e. certain IPs I'd like as low as 1r/s). I tried using conditionals (e.g. if ( $remote_addr = "1.2.3.4" ) {}) but that seems to work only with rewrite rules, not for rate-limit rules.

    Read the article

  • Map Network Drive with Password

    - by Lea Cohen
    I mapped a network drive to a location that needs a password. Now whenever my computer starts up, it tells me that it could not connect to that network drive because a password is needed. How do I make set my computer to remember the password for that mapped network drive? EDIT: My PC is running Windows XP Professional

    Read the article

  • How to fix Apache from crashing with PHP+Curl on an SSH request?

    - by Jason Cohen
    My Apache process segfaults whenever I call curl_exec() from PHP with an "https://" URL. If I use http instead of https as the URL transport, it works perfectly, so I know curl and the other curl options are correct. I can use curl from the command-line on that server using the https version of the URL and it works perfectly, so I know the remote server is responding correctly, the cert isn't expired, etc.. My server is: Linux 2.6.32-21-server #32-Ubuntu SMP Fri Apr 16 09:17:34 UTC 2010 x86_64 GNU/Linux My Apache version is: Server version: Apache/2.2.14 (Ubuntu) Server built: Apr 13 2010 20:21:26 My PHP version is: PHP 5.3.2-1ubuntu4.2 with Suhosin-Patch (cli) (built: May 13 2010 20:03:45) Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies My PHP curl module info is: cURL support => enabled cURL Information => 7.19.7 Age => 3 Features AsynchDNS => No Debug => No GSS-Negotiate => Yes IDN => Yes IPv6 => Yes Largefile => Yes NTLM => Yes SPNEGO => No SSL => Yes SSPI => No krb4 => No libz => Yes CharConv => No Protocols => tftp, ftp, telnet, dict, ldap, ldaps, http, file, https, ftps Host => x86_64-pc-linux-gnu SSL Version => OpenSSL/0.9.8k ZLib Version => 1.2.3.3

    Read the article

  • Decrypting Windows XP encrypted files from an old disk

    - by Uri Cohen
    I had an old Windows XP machine with an encrypted directory. When moving to a new Win7 machine I connected the old disk as a slave in the new machine, and hence cannot access the encrypted files. Chances don't seem good as documentation warns you: "Do not Delete or Rename a User's account from which will want to Recover the Encrypted Files. You will not be able to de-crypt the files using the steps outlined above." On the other hand, I have full access to the machine, so maybe there's a utility which can extract the keys and use the to decrypt the files... BTW, I didn't have a password in the old machine, if it's relevant. Ideas, anyone? Thanks!

    Read the article

  • GNS3 Cannot ping/resolve DNS record

    - by Eldad Cohen
    I set up an internet lab with GNS3, which has 3 routers, in each node there is a computer directly connected. One of the hosts is a DNS server, Windows 2003 Server. The other one is a Windows XP machine. Ping is good between routers and machines but no ability to ping domain.com record on DNS server 2003. I set a static nat on the router to route all traffic from gateway to the DNS server internal ip address, still no answer for the dns request. Any ideas or thoughts will be most welcome.

    Read the article

  • Building a Web proxy to get around same-origin restrictions for collaborative Webapp based on a MEAN stack

    - by Lew Cohen
    Can anyone point to books, articles, blogs, or even applications - open-source or proprietary - that detail building a Web proxy? This specific proxy will exist to get around the same-origin restrictions that prevent, for instance, loading a given Website into an <iframe> in a Webapp. This Webapp is a collaborative application in which a group of users log in to the app's Website and can then load different Websites into this app's <iframe> and do various collaborative things (e.g., several users simultaneously browsing a Website, in synch). The Webapp itself is built on a MEAN stack (MongoDB, Express, AngularJS, and Node.js). The purpose of this proxy is not to do anonymous browsing or to bypass censorship. Information on how to build such a vehicle seems not to be readily available from my research. I've come across Glype but am not sure whether this is a feasible solution. I don't want to reinvent the wheel, so if a product is available for purchase, great. Else, we'd need to build one. The one that seems to be close is http://www.corsproxy.com. In effect, we'd like to re-create this since it evidently does what's needed. I don't care what server-side technology is used. Our app is MEAN-based, if that has any bearing. Also, the proxy has to obviously honor basic security considerations (user cookies, etc.) and eventually be scalable. So, anyone know of any sources that would detail how to build one of these? Is it even worth building if something already exists? If so, what would be a good candidate? Any other issues that should be considered with this proxy/application? Thanks a lot!

    Read the article

  • Hebrew filenames in the URL

    - by Lea Cohen
    We have a CMS that enables users to upload images and flashes to their site. Sometimes the filenames are in Hebrew. In our development server there is no problem, but in our production server we get a 404 error when the filename ends with Hebrew characters. I tried comparing the sites in the IIS, but I'm not sure what to even look for, so I'd be very happy to get pointers as to what might be causing the problem.

    Read the article

  • UITableViewCell selected subview ghosts

    - by Jonathan Cohen
    Hi all, I'm learning about the iPhone SDK and have an interesting exception with UITableViewCell subview management when a finger is pressed on some rows. The table is used to assign sounds to hand gestures -- swiping the phone in one of 3 directions triggers the sound to play. Selecting a row displays an action sheet with 4 options for sound assignment: left, down, right, and cancel. Sounds can be mapped to one, two, or three directions so any cell can have one of seven states: left, down, right, left and down, left and right, down and right, or left down and right. If a row is mapped to any of these seven states, a corresponding arrow or arrows are displayed within the bounds of the row as a subview. Arrows come and go as they should in a given screen and when scrolling around. However, after scrolling to a new batch of rows, only when I press my finger down on some (but not all) rows, does an arrow magically appear in the selected state background. When I lift my finger off the row, and the action sheet appears, the arrow disappears. After pressing any of the four buttons, I can't replicate this anymore. But it's really disorienting and confusing to see this arrow flash on screen because the selected row isn't assigned to anything. What haven't I thought to look into here? All my table code is pasted below and this is a screencast of the problem: http://www.screencast.com/users/JonathanGCohen/folders/Jing/media/d483fe31-05b5-4c24-ab4d-70de4ff3a0bf Am I managing my subviews wrong or is there a selected state property I'm missing? Something else? Should I have included any more information in this post to make things clearer? Thank you!! #pragma mark - #pragma mark Table - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView { return ([categories count] > 0) ? [categories count] : 1; } - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section { if ([categories count] == 0) return 0; NSMutableString *key = [categories objectAtIndex:section]; NSMutableArray *nameSection = [categoriesSounds objectForKey:key]; return [nameSection count]; } - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath { NSUInteger section = [indexPath section]; NSUInteger row = [indexPath row]; NSString *key = [categories objectAtIndex:section]; NSArray *nameSection = [categoriesSounds objectForKey:key]; static NSString *SectionsTableIdentifier = @"SectionsTableIdentifier"; UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier: SectionsTableIdentifier]; NSArray *sound = [categoriesSounds objectForKey:key]; NSString *soundName = [[sound objectAtIndex: row] objectAtIndex: 0]; NSString *soundOfType = [[sound objectAtIndex: row] objectAtIndex: 1]; if (cell == nil) { cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:SectionsTableIdentifier] autorelease]; } cell.textLabel.text = [[nameSection objectAtIndex:row] objectAtIndex: 0]; NSUInteger soundSection = [[[sound objectAtIndex: row] objectAtIndex: 2] integerValue]; NSUInteger soundRow = [[[sound objectAtIndex: row] objectAtIndex: 3] integerValue]; NSUInteger leftRow = [leftOldIndexPath row]; NSUInteger leftSection = [leftOldIndexPath section]; if (soundRow == leftRow && soundSection == leftSection && leftOldIndexPath !=nil){ [selectedSoundLeftAndDown removeFromSuperview]; [selectedSoundLeftAndRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundLeft]; selectedSoundLeft.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundLeft]; } NSUInteger downRow = [downOldIndexPath row]; NSUInteger downSection = [downOldIndexPath section]; if (soundRow == downRow && soundSection == downSection && downOldIndexPath !=nil){ [selectedSoundLeftAndDown removeFromSuperview]; [selectedSoundDownAndRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundDown]; selectedSoundDown.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundDown]; } NSUInteger rightRow = [rightOldIndexPath row]; NSUInteger rightSection = [rightOldIndexPath section]; if (soundRow == rightRow && soundSection == rightSection && rightOldIndexPath !=nil){ [selectedSoundDownAndRight removeFromSuperview]; [selectedSoundLeftAndRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundRight]; selectedSoundRight.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundRight]; } // combos if (soundRow == leftRow && soundRow == downRow && soundSection == leftSection && soundSection == downSection){ [selectedSoundLeft removeFromSuperview]; [selectedSoundDown removeFromSuperview]; [selectedSoundLeftAndDownAndRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundLeftAndDown]; selectedSoundLeftAndDown.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundLeftAndDown]; } if (soundRow == leftRow && soundRow == rightRow && soundSection == leftSection && soundSection == rightSection){ [selectedSoundLeft removeFromSuperview]; [selectedSoundRight removeFromSuperview]; [selectedSoundLeftAndDownAndRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundLeftAndRight]; selectedSoundLeftAndRight.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundLeftAndRight]; } if (soundRow == downRow && soundRow == rightRow && soundSection == downSection && soundSection == rightSection){ [selectedSoundDown removeFromSuperview]; [selectedSoundRight removeFromSuperview]; [selectedSoundLeftAndDownAndRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundDownAndRight]; selectedSoundDownAndRight.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundDownAndRight]; } if (soundRow == leftRow && soundRow == downRow && soundRow == rightRow && soundSection == leftSection && soundSection == downSection && soundSection == rightSection){ [selectedSoundLeftAndDown removeFromSuperview]; [selectedSoundLeftAndRight removeFromSuperview]; [selectedSoundDownAndRight removeFromSuperview]; [selectedSoundLeft removeFromSuperview]; [selectedSoundDown removeFromSuperview]; [selectedSoundRight removeFromSuperview]; [cell.contentView addSubview: selectedSoundLeftAndDownAndRight]; selectedSoundLeftAndDownAndRight.frame = CGRectMake(200,8,30,30); } else { [cell.contentView sendSubviewToBack: selectedSoundLeftAndDownAndRight]; } [indexPath retain]; return cell; } - (NSMutableString *)tableView:(UITableView *)tableView titleForHeaderInSection:(NSInteger)section { if ([categories count] == 0) return nil; NSMutableString *key = [categories objectAtIndex:section]; if (key == UITableViewIndexSearch) return nil; return key; } - (NSMutableArray *)sectionIndexTitlesForTableView:(UITableView *)tableView { if (isSearching) return nil; return categories; } - (NSIndexPath *)tableView:(UITableView *)tableView willSelectRowAtIndexPath:(NSIndexPath *)indexPath { [table reloadData]; [selectedSoundLeft removeFromSuperview]; [selectedSoundDown removeFromSuperview]; [selectedSoundRight removeFromSuperview]; [selectedSoundLeftAndDown removeFromSuperview]; [selectedSoundLeftAndRight removeFromSuperview]; [selectedSoundDownAndRight removeFromSuperview]; [selectedSoundLeftAndDownAndRight removeFromSuperview]; [search resignFirstResponder]; if (isSearching == YES && [search.text length] != 0 ){ searched = YES; } search.text = @""; isSearching = NO; [tableView reloadData]; [indexPath retain]; [indexPath retain]; return indexPath; } - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { [table reloadData]; selectedIndexPath = indexPath; [table reloadData]; NSInteger section = [indexPath section]; NSInteger row = [indexPath row]; NSString *key = [categories objectAtIndex:section]; NSArray *sound = [categoriesSounds objectForKey:key]; NSString *soundName = [[sound objectAtIndex: row] objectAtIndex: 0]; [indexPath retain]; [indexPath retain]; NSMutableString *title = [NSMutableString stringWithString: @"Assign Gesture for "]; NSMutableString *soundFeedback = [NSMutableString stringWithString: (@"%@", soundName)]; [title appendString: soundFeedback]; UIActionSheet *action = [[UIActionSheet alloc] initWithTitle:(@"%@", title) delegate:self cancelButtonTitle:@"Cancel" destructiveButtonTitle: nil otherButtonTitles:@"Left",@"Down",@"Right",nil]; action.actionSheetStyle = UIActionSheetStyleDefault; [action showInView:self.view]; [action release]; } - (void)actionSheet:(UIActionSheet *)actionSheet clickedButtonAtIndex:(NSInteger)buttonIndex{ NSInteger section = [selectedIndexPath section]; NSInteger row = [selectedIndexPath row]; NSString *key = [categories objectAtIndex:section]; NSArray *sound = [categoriesSounds objectForKey:key]; NSString *soundName = [[sound objectAtIndex: row] objectAtIndex: 0]; NSString *soundOfType = [[sound objectAtIndex: row] objectAtIndex: 1]; NSUInteger soundSection = [[[sound objectAtIndex: row] objectAtIndex: 2] integerValue]; NSUInteger soundRow = [[[sound objectAtIndex: row] objectAtIndex: 3] integerValue]; NSLog(@"sound row is %i", soundRow); NSLog(@"sound section is row is %i", soundSection); typedef enum { kLeftButton = 0, kDownButton, kRightButton, kCancelButton } gesture; switch (buttonIndex) { //Left case kLeftButton: showLeft.text = soundName; left = [[NSBundle mainBundle] pathForResource:(@"%@", soundName) ofType:(@"%@", soundOfType)]; AudioServicesCreateSystemSoundID((CFURLRef)[NSURL fileURLWithPath:left], &soundNegZ); AudioServicesPlaySystemSound (soundNegZ); [table deselectRowAtIndexPath:selectedIndexPath animated:YES]; leftIndexSection = [NSNumber numberWithInteger:section]; leftIndexRow = [NSNumber numberWithInteger:row]; NSInteger leftSection = [leftIndexSection integerValue]; NSInteger leftRow = [leftIndexRow integerValue]; NSString *leftKey = [categories objectAtIndex: leftSection]; NSArray *leftSound = [categoriesSounds objectForKey:leftKey]; NSInteger leftSoundSection = [[[leftSound objectAtIndex: leftRow] objectAtIndex: 2] integerValue]; NSInteger leftSoundRow = [[[leftSound objectAtIndex: leftRow] objectAtIndex: 3] integerValue]; leftOldIndexPath = [NSIndexPath indexPathForRow:leftSoundRow inSection:leftSoundSection]; break; //Down case kDownButton: showDown.text = soundName; down = [[NSBundle mainBundle] pathForResource:(@"%@", soundName) ofType:(@"%@", soundOfType)]; AudioServicesCreateSystemSoundID((CFURLRef)[NSURL fileURLWithPath:down], &soundNegX); AudioServicesPlaySystemSound (soundNegX); [table deselectRowAtIndexPath:selectedIndexPath animated:YES]; downIndexSection = [NSNumber numberWithInteger:section]; downIndexRow = [NSNumber numberWithInteger:row]; NSInteger downSection = [downIndexSection integerValue]; NSInteger downRow = [downIndexRow integerValue]; NSString *downKey = [categories objectAtIndex: downSection]; NSArray *downSound = [categoriesSounds objectForKey:downKey]; NSInteger downSoundSection = [[[downSound objectAtIndex: downRow] objectAtIndex: 2] integerValue]; NSInteger downSoundRow = [[[downSound objectAtIndex: downRow] objectAtIndex: 3] integerValue]; downOldIndexPath = [NSIndexPath indexPathForRow:downSoundRow inSection:downSoundSection]; break; //Right case kRightButton: showRight.text = soundName; right = [[NSBundle mainBundle] pathForResource:(@"%@", soundName) ofType:(@"%@", soundOfType)]; AudioServicesCreateSystemSoundID((CFURLRef)[NSURL fileURLWithPath:right], &soundPosX); AudioServicesPlaySystemSound (soundPosX); [table deselectRowAtIndexPath:selectedIndexPath animated:YES]; rightIndexSection = [NSNumber numberWithInteger:section]; rightIndexRow = [NSNumber numberWithInteger:row]; NSInteger rightSection = [rightIndexSection integerValue]; NSInteger rightRow = [rightIndexRow integerValue]; NSString *rightKey = [categories objectAtIndex: rightSection]; NSArray *rightSound = [categoriesSounds objectForKey:rightKey]; NSInteger rightSoundSection = [[[rightSound objectAtIndex: rightRow] objectAtIndex: 2] integerValue]; NSInteger rightSoundRow = [[[rightSound objectAtIndex: rightRow] objectAtIndex: 3] integerValue]; rightOldIndexPath = [NSIndexPath indexPathForRow:rightSoundRow inSection:rightSoundSection]; break; case kCancelButton: [table deselectRowAtIndexPath:selectedIndexPath animated:YES]; break; default: break; } UITableViewCell *viewCell = [table cellForRowAtIndexPath: selectedIndexPath]; NSArray *subviews = viewCell.subviews; for (UIView *cellView in subviews){ cellView.alpha = 1; } [table reloadData]; } - (NSInteger)tableView:(UITableView *)tableView sectionForSectionIndexTitle:(NSMutableString *)title atIndex:(NSInteger)index { NSMutableString *category = [categories objectAtIndex:index]; if (category == UITableViewIndexSearch) { [tableView setContentOffset:CGPointZero animated:NO]; return NSNotFound; } else return index; }

    Read the article

  • Jetty 7 hightide distribution, JSP and JSTL support

    - by Lior Cohen
    Hello guys. I've been struggling with Jetty 7 and its support for JSP and JSTL. My JSP file: <%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8" %> <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"> <html> <%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> <head> <title>blah</title> </head> <body> <table id="data"> <tr class="columns"> <td>Hour</td> <c:forEach var="campaign" items="${campaigns}"> <td>${campaign}</td> </c:forEach> </tr> <c:forEach var="hour" items="${results}"> <tr> <td class="hour">${hour.key}</td> <c:forEach var="campaign" items="${campaigns}"> <td>${hour[campaign]}</td> </c:forEach> </tr> </c:forEach> </table> </body> </html> The JSP portions above work as expected. JSTL, however, does not. The campaigns and results variables are request attributes set by a servlet. I get the following errors: WARN: ... compiler.TagLibraryInfoImpl: Unknown element (deferred-value) in attribute WARN: ... compiler.TagLibraryInfoImpl: Unknown element (deferred-value) in attribute WARN: ... compiler.TagLibraryInfoImpl: Unknown element (deferred-value) in attribute ERROR: ... javax.servlet.ServletException: java.lang.AbstractMethodError: javax.servlet.jsp.PageContext.getELContext()Ljavax/el/ELContext; I am not bundling any jar files into my .war file deployed to jetty. The version of jetty I'm using is: jetty-hightide-7.0.1.v20091125 The classpath: /usr/local/jetty/lib/jetty-xml-7.0.1.v20091125.jar:/usr/local/jetty/lib/servlet-api-2.5.jar:/usr/local/jetty/lib/jetty-http-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-continuation-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-server-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-security-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-servlet-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-webapp-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-deploy-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-servlets-7.0.1.v20091125.jar:/usr/local/jetty/lib/jsp/ant-1.6.5.jar:/usr/local/jetty/lib/jsp/core-3.1.1.jar:/usr/local/jetty/lib/jsp/jetty-jsp-2.1-7.0.1.v20091125.jar:/usr/local/jetty/lib/jsp/jsp-2.1-glassfish-9.1.1.B60.25.p2.jar:/usr/local/jetty/lib/jsp/jsp-api-2.1-glassfish-9.1.1.B60.25.p2.jar:/usr/local/jetty/resources:/usr/local/jetty/lib/jetty-util-7.0.1.v20091125.jar:/usr/local/jetty/lib/jetty-io-7.0.1.v20091125.jar Any help would be greatly appreciated. Thanks in advance, Lior.

    Read the article

  • Difference of 2 NSArray's for animated insert/delete in UITableView

    - by Alexander Cohen
    At some point in my Application, I have an NSArray whose contents change. Those contents are shown in a UITableView. I'm trying to find a way to find the diff between the contents of before and after of the NSArray so i can pass the correct indexPaths to insertRowsAtIndexPaths:withRowAnimation: and deleteRowsAtIndexPaths:withRowAnimation: in order to have the changes nicely animated. Any ideas? thx

    Read the article

  • Spring 3.0: Handler mapping issue

    - by Yaniv Cohen
    I am having a trouble mapping a specific URL request to one of the controllers in my project. the URL is : http://HOSTNAME/api/v1/profiles.json the war which is deployed is: api.war the error I get is the following: [PageNotFound] No mapping found for HTTP request with URI [/api/v1/profiles.json] in DispatcherServlet with name 'action' The configuration I have is the following: web.xml : <context-param> <param-name>contextConfigLocation</param-name> <param-value>/WEB-INF/applicationContext.xml,/WEB-INF/applicationContext-security.xml</param-value> </context-param> <!-- Cache Control filter --> <filter> <filter-name>cacheControlFilter</filter-name> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class> </filter> <!-- Cache Control filter mapping --> <filter-mapping> <filter-name>cacheControlFilter</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <!-- Spring security filter --> <filter> <filter-name>springSecurityFilterChain</filter-name> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class> </filter> <!-- Spring security filter mapping --> <filter-mapping> <filter-name>springSecurityFilterChain</filter-name> <url-pattern>/*</url-pattern> </filter-mapping> <!-- Spring listener --> <listener> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class> </listener> <!-- Spring Controller --> <servlet> <servlet-name>action</servlet-name> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>action</servlet-name> <url-pattern>/v1/*</url-pattern> </servlet-mapping> The action-servlet.xml: <mvc:annotation-driven/> <bean id="contentNegotiatingViewResolver" class="org.springframework.web.servlet.view.ContentNegotiatingViewResolver"> <property name="favorPathExtension" value="true" /> <property name="favorParameter" value="true" /> <!-- default media format parameter name is 'format' --> <property name="ignoreAcceptHeader" value="false" /> <property name="order" value="1" /> <property name="mediaTypes"> <map> <entry key="html" value="text/html"/> <entry key="json" value="application/json" /> <entry key="xml" value="application/xml" /> </map> </property> <property name="viewResolvers"> <list> <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver"> <property name="prefix" value="/WEB-INF/jsp/"/> <property name="suffix" value=".jsp"/> <property name="viewClass" value="org.springframework.web.servlet.view.JstlView" /> </bean> </list> </property> <property name="defaultViews"> <list> <bean class="org.springframework.web.servlet.view.json.MappingJacksonJsonView" /> <bean class="org.springframework.web.servlet.view.xml.MarshallingView"> <constructor-arg> <bean class="org.springframework.oxm.xstream.XStreamMarshaller" /> </constructor-arg> </bean> </list> </property> </bean> the application context security: <sec:http auto-config='true' > <sec:intercept-url pattern="/login.*" filters="none"/> <sec:intercept-url pattern="/oauth/**" access="ROLE_USER" /> <sec:intercept-url pattern="/v1/**" access="ROLE_USER" /> <sec:intercept-url pattern="/request_token_authorized.jsp" access="ROLE_USER" /> <sec:intercept-url pattern="/**" access="ROLE_USER"/> <sec:form-login authentication-failure-url ="/login.html" default-target-url ="/login.html" login-page ="/login.html" login-processing-url ="/login.html" /> <sec:logout logout-success-url="/index.html" logout-url="/logout.html" /> </sec:http> the controller: @Controller public class ProfilesController { @RequestMapping(value = {"/v1/profiles"}, method = {RequestMethod.GET,RequestMethod.POST}) public void getProfilesList(@ModelAttribute("response") Response response) { .... } } the request never reaches this controller. Any ideas?

    Read the article

  • hover effect jQuery

    - by Ori Cohen
    I have a bunch of li elements that I want to alternate in color using odds and evens, and then highlight based on mouse hover. In order to un-highlight I need to keep track of what the color used to be, odd or even. To do this when I apply the highlight color, I first set an arbitrary attribute to it. Are there any downsides to doing it this way? Is there a better way? Here's the code: <script type="text/javascript"> var init = function(event){ $("li:odd").css({'background-color' : '#eeeeee', 'font-weight' : 'bold'}); $("li:even").css('background-color', '#cccccc'); //initial colors setup $("li").hover( function () //hover over { var current = $(this); current.attr('old-background', current.css('background-color')); current.css('background-color', '#ffee99'); } , function() //hover out { var current = $(this); current.css('background-color', current.attr('old-background')); }) } $(document).ready(init); </script> So is there a better way to do this?

    Read the article

1 2 3  | Next Page >