Search Results

Search found 130 results on 6 pages for 'asad butt'.

Page 1/6 | 1 2 3 4 5 6  | Next Page >

  • Android Bottombar with two buttons having different backgrounds and a common background for two butt

    - by cppdev
    Hi, I have a linear layout in my main.xml which has a listview. Now I want to create a bottom bar below listview. Bottombar has a background image and two buttons with their individual background images. I want to put these two buttons on common background image. I have read that this can be achieved using FrameLayout. But since I am using LinearLayout as base layout in my main.xml, is there any way to this design using linearlayout ?

    Read the article

  • Java Script – Content delivery networks (CDN) can bit you in the butt.

    - by Ryan Ternier
    As much as I love the new CDN’s that Google, Microsoft and a few others have publically released, there are some strong gotchas that could come up and bite you in the ass if you’re not careful. But before we jump into that, for those that are not 100% sure what a CDN is (besides Canadian).   Content Delivery Network. A way of distributing your static content across various servers in different physical locations.  Because this static content is stored on many servers around the world, whenever a user needs to access this content, they are given the closest server to their location for this data. Already you can probably see the immediate bonuses to a system like this: Lower bandwidth Even small script files downloaded thousands of times will start to take a noticeable hit on your bandwidth meter. Less connections/hits to your web server which gives better latency If you manage many servers, you don’t need to manually update each server with scripts. A user will download a script for each website they visit. If a user is redirected to many domains/sub-domains within your web site, they might download many copies of the same file. When a system sees multiple requests from the same  domain, they will ignore the download   Those are just a handful of the many bonuses a CDN will give you. And for the average website, a CDN is great choice. Check out the following CDN links for their solutions: Google AJAX Library: http://code.google.com/apis/ajaxlibs/ Microsoft Ajax library: http://www.asp.net/ajaxlibrary/cdn.ashx The Gotcha There is always a catch. Here are some issues I found with using CDN’s that hopefully can help you make your decision. HTTP / HTTPS If you are running a website behind SSL, make sure that when you reference your CDN data that you use https:// vs. http://. If you forget this users will get a very nice message telling them that their secure connection is trying to access unsecure data. For a developer this is fairly simple, but general users will get a bit anxious when seeing this. Trusted Sites Internet Explorer has this really nifty feature that allows users to specify what sites they trust, and by some defaults IE7 only allows trusted sites to be viewed.  No problem, they set your website as trusted. But what about your CDN? If a user sets your websites to trusted, but not the CDN, they will not download those static files. This has the potential to totally break your web site. Pedantic Network Admins This alone is sometimes the killer of projects. However, always be careful when you are going to use a CDN for a professional project. If a network / security admin sees that you’re referencing an outside source, or that a call from a website might hit an outside domain.. panties will be bunched, emails will be spewed out and well, no one wants that.

    Read the article

  • UIButton overlapping problem in the UIView?

    - by sai
    im trying to create buttons as ahierarchy, first some buttons are displayed if i click any of the buttons it will navigate to the next viewcontroller displaying some more buttons. But here my problem is butons are overlapped with one another . means the buttons that should not be displayed are also comming along with those should be . my code is for(.................) { butt = [[UIButton alloc] initWithFrame:CGRectMake(...)]; image = [UIImage imageWithData:[NSData dataWithContentsOfURL:[NSURL URLWithString:[arr objectAtIndex:i]]]]; imageView = [[[UIImageView alloc] initWithImage:image] autorelease]; [butt setBackgroundImage:imageView.image forState:UIControlStateNormal]; [butt setTag:i]; [butt addTarget:self action:@selector(onClick:) forControlEvents:UIControlEventTouchUpInside]; [containerView addSubview:butt]; [butt release]; x+=butt.frame.size.width+2*hgap; i+=1; if (i==count+1) //[arr count] { printf("\nIN BREAK BUTTON\n"); break; } } y=y+(butt.frame.size.height+2*vgap); } Thankyou for the solution.

    Read the article

  • How do I get a jQuery dialog window to display only if a form validates when I click the submit butt

    - by user338413
    I've got a form that is using jQuery validation. When the user clicks the submit button, a dialog window displays thatshows the fields the user filled out along with the data the user entered. It asks the user if this information is correct. If it is, the user clicks the submit button in the dialog window and the form is submitted. If the user clicks the 'Fix it' button, the dialog window closes and the user returns to the form. My problem is my dialog window displays when the user clicks the form's submit button even if there are errors in the form. I only want to display the dialog window if the form data is validated by jQuery. How do I do this? I'm thinking of something like: if ((#form).validates() == true) { $('#verification_dialog').dialog('open'); } Is there a way in jQuery to determine whether the whole form has validated? Or do I have to create my own function to do this?

    Read the article

  • How to play mpg/3gp 5 sec video at start of application?

    - by Asad Ahmed
    I am developing an application in which i want to play a short 5 seconds video at the startup. which is the best format 3gp, mpg or something else? i have generated a title activity. I wanted to play the video before title. Help please!!! Below is the code of my title activity. public class Title extends Activity { @Override protected void onCreate(Bundle savedInstanceState) { // TODO Auto-generated method stub super.onCreate(savedInstanceState); setContentView(R.layout.title); setTitle("M.I.S.T"); this.setTitleColor(Color.BLUE); View title = getWindow().findViewById(android.R.id.title); View titleBar = (View) title.getParent(); titleBar.setBackgroundColor(Color.YELLOW); Thread timer = new Thread(){ public void run(){ try{ sleep(3000); }catch (InterruptedException e){ e.printStackTrace(); }finally{ Intent open= new Intent("com.congestion6.asad.MENU"); startActivity(open); } } }; timer.start(); } protected void onPause() { // TODO Auto-generated method stub super.onPause(); finish(); } }

    Read the article

  • Javascript add a PHP file.

    - by Jordan Pagaduan
    var editing = false; if (document.getElementById && document.createElement) { var butt = document.createElement('BUTTON'); var buttext = document.createTextNode('Ready!'); butt.appendChild(buttext); butt.onclick = saveEdit; } function catchIt(e) { if (editing) return; if (!document.getElementById || !document.createElement) return; if (!e) var obj = window.event.srcElement; else var obj = e.target; while (obj.nodeType != 1) { obj = obj.parentNode; } if (obj.tagName == 'TEXTAREA' || obj.tagName == 'A') return; while (obj.nodeName != 'P' && obj.nodeName != 'HTML') { obj = obj.parentNode; } if (obj.nodeName == 'HTML') return; var x = obj.innerHTML; var y = document.createElement('TEXTAREA'); var z = obj.parentNode; z.insertBefore(y,obj); z.insertBefore(butt,obj); z.removeChild(obj); y.value = x; y.focus(); editing = true; } function saveEdit() { var area = document.getElementsByTagName('TEXTAREA')[0]; var y = document.createElement('P'); var z = area.parentNode; y.innerHTML = area.value; z.insertBefore(y,area); z.removeChild(area); z.removeChild(document.getElementsByTagName('button')[0]); editing = false; } document.onclick = catchIt; This code is a quick edit and I want to add a PHP script that will UPDATE my database base on the changes on the text.

    Read the article

  • Handling multiple Scene in AndEngine

    - by Asad
    I am Developing a game in AndEngine Gles2. I have splash scene, loading scene, menu scene and Level1 scene. I am using a Screen Manager to manage all scenes through which i can easily switch between splash, loading and menu scene, the level1 scene is also loaded from menu perfectly but problem occur when i go back to menu scene on the completion of level, screen turned to black and nothing shown after that. I think the problem is with unloading the resources of Level1 because the switching between other scene is perfect. I can't give complete code, as it is to much lengthy. I am using bitmapTexture region, Sprites, bodies, physics Word, hud and fixtures etc. here is my unload method.. 1 more thing when i loaded the menu scene at the end of level 1 screen turn to black, but the music played and all logs are showed in logcat which i set in menu scene. unload(){ setChildrenIgnorUpdate(); clearChildScene(); clearEntityModifier(); clearTouchAreas(); clearUpdateHandler(); BitmapTextureManager.getInstance().destroyInstance(); destroyPhysics(); } Please Any help...

    Read the article

  • Single and Double Jump with single button.

    - by Asad
    I want to make Single Jump on Single Tap and Double Jump on Double Tap. My problem is that if I make double Tap on ground then it’s fine but if I make first Tap on ground and second Tap in Air then Player gain more height then usual As in image 1. I want to Make my jump like in Image 2, No matter from which point user gives second Tap, player Always get a specific height. I Used both Impulse and Linear velocity to make Jump but my problem did not solved.

    Read the article

  • Google affecting my SERP Rank?

    - by Asad Moeen
    The following are some of my website's details. Home-page: [thebluewaffles].[com] Keywords: Blue Waffles- Rest of the keywords are post/subject specific. Site Description: Health Articles Blog Site Age: 1.5 years A short history: When I started my website, the few things in my mind when posting content were at-least 500 words on each page and writing of all the articles with to the point information. I didn't go really fast with it which is why I only have about 15 articles in 1.5 years. The SEO strategy was more simple. I shared links through Social Marketing websites and some Article Sharing websites after which I could see my website's rankings in top 5 SERP results. I ranked good enough for about 8 months continuously but didn't keep updating content due to which there were some 3 rough months when no content was posted due to some personal work. The SERPS dropped to 2nd page in April and almost started disappearing in May. I asked a lot of people about it and most came up with the reason of "no updates to site" so I started updating my site again since the day, November has almost started and I see no signs of my website's ranking. Another important point is that when I post a new article, and do a title search in Google, I see it ranks good enough for the first 10 hours and then disappears. What could be wrong here?

    Read the article

  • Ubuntu for Internet radio

    - by user93100
    I am planning to set up a streaming server purely for internet radio using Icecast2. what software packages do i require during Ubuntu installation and any third party apps i may require. I am going to use BUTT(Broadcast using this tool) Encoder and would like to be able to run BUTT on any computer so that other people can broadcast to my server from anywhere. I am looking for tips or tutorials on how to achieve the above. I mainly need info on cofiguring Ubuntu Server and icecast2. Also GUI? if so what one. Preferablly lightweight. I am choosing Ubuntu for its level of security and reliability. I hope someone can help me as i plan to make this a community Radio station. Many Thanks Khz

    Read the article

  • Error! File In use: SQLSERVER

    - by Asad Butt
    I am trying to copy a database from one folder to another. There is no program at all running except operating system.(I mean all windows shut) I keep getting this : The action cannot be completed because the file is open is another program close file and try again Try again, Try again , Try again ......... what the hell on earth is holding that file and how can I carry on with copy / delete / overwrite files(DB) as this problem is something very common. Thanks

    Read the article

  • Getting a TTY in a Connectback Shell

    - by Asad R.
    I'm often asked by friends to help with small Linux problems, and more often than not I'm required to login to the remote system. Usually there are a lot of issues with making an account and logging in (sometimes the box is behind a NAT device, sometimes SSHD isn't installed, etc.) so I usually just ask them to make a connect-back shell using netcat (nc -e /bin/bash ). If they don't have netcat I can just ask them to grab a copy of a statically compiled binary which isn't that hard or time consuming to download and run. Though this works well enough for me to enter simple commands, I can't run any apps that require a tty (vi, for example) and can't use any job control functions. I managed to bypass this issue by running in.telnetd with a few arguments within the connect-back shell that would assign me a terminal and drop me to a shell. Unfortunately in.telnetd isn't usually installed by default on most systems. What's the easiest way to get a fully functional connect-back terminal shell without requiring any non-standard packages? (A small C program that does the job would be fine as well, I just can't seem to find much documentation on how a TTY is assigned/allocated. A solution that doesn't require me to plough through the source code for SSHD and TELNETD would be nice :))

    Read the article

  • why licenced code is packed and then is reviewable using Disassembler at the same time ?

    - by Asad Butt
    Is it legal / ethical to copy code for any reason, or utilize it (like code review) from the .Net framework or any other .Net based API using Reflector or similar tools ? If it is, what advantages do Microsoft and other licence based softwares have for packing there code ? If it is not, Why can we use ILDasm and Reflector ? Another way of saying this is Why to pack it up if it is fine to review it ? probably I am missing some bits in the question, any one who feels, could ask this question in a better way, is most welcome to edit. Thanks

    Read the article

  • When making a branch in TortoiseSVN, what do "head", "working copy", and "specific" revisions mean?

    - by Asad Butt
    A new user of Tortoise SVN, working over source control. I have a Visual Studio solution which consists of 5 webAppliation projects. I need to take one out and work over it in a branch. When I try to branch it, It is asking me of one of these options head revision in repository specific revision in repository working copy revision Problem 1: What exactly are these ? I am confused with "head revision" and "working copy", as they appear same to me. EDIT: Problem 2: Why cant we branch from Repository GUI itself, (would be head revision) ? Problem 3: Can you list the steps, needed to branch from a directory !

    Read the article

  • Symlink error when installing MySQL via Homebrew

    - by Asad Syed
    Trying to install MySQL via Homebrew. The install seems to work fine but i get an error: "Error: The linking step did not complete successfully The formula built, but is not symlinked into /usr/local You can try again using `brew link mysql'" Naturally, after this I ran: brew link mysql Which spat out: Error: Could not symlink file: /usr/local/Cellar/mysql/5.5.20/include/typelib.h /usr/local/include is not writable. You should change its permissions. So I ran it with sudo and got a "cowardly refusing to brew link mysql".

    Read the article

  • Rate-Limit affects All clients or single IP?

    - by Asad Moeen
    Well up-til now I've considered iptables rate-limit commands with the "recent" module to work for each IP Address. For example rate-limit rule of 20k/s will trigger only if a single IP exceeds 20k/s rate and not if 4 different IPs exceed 5k/s rate. Please correct me if I considered this wrong as I've only used these rules for TCP/ UDP. But today I tried similar rules for ICMP and applied 4/s Input/Output. But then on trying to ping-test from just-ping.com I could see packet loss on almost all IP Addresses. How could that happen because if it worked for each IP Address then it wouldn't be triggering the rule because I believe each IP from just-ping has a rate of probably 1/s. I still think the first one is true because if it wasn't then my GameServer would block everyone if the combined rate ( in case of more connected players ) increased the threshold. This hasn't happened up til now so the ICMP thing really confused me. Thank you.

    Read the article

  • Socks5 proxy "Dante" leaves many child processes stuck in FIN_WAIT2 / CLOSE_WAIT state

    - by Asad R.
    I'm running dante v1.2.1 as a SOCKS proxy server. The proxy works fine but at the end of the day there are around 40-50 or more child processes of sockd running even though there are no active connections. lsof shows that the child processes all have sockets in the CLOSE_WAIT and FIN_WAIT2 state. These child processes stay in this state unless I manually killall/restart the daemon. I'm running Gentoo Linux on a 2.6.24-23-xen kernel. I recently upgraded from dante v1.1.19-r4 which was giving me the exact same problem. Is this a configuration issue with Dante, my system, or is it a coding issue in the dante code?

    Read the article

  • Expert iptables help needed?

    - by Asad Moeen
    After a detailed analysis, I collected these details. I am under a UDP Flood which is more of application dependent. I run a Game-Server and an attacker is flooding me with "getstatus" query which makes the GameServer respond by making the replies to the query which cause output to the attacker's IP as high as 30mb/s and server lag. Here are the packet details, Packet starts with 4 bytes 0xff and then getstatus. Theoretically, the packet is like "\xff\xff\xff\xffgetstatus " Now that I've tried a lot of iptables variations like state and rate-limiting along side but those didn't work. Rate Limit works good but only when the Server is not started. As soon as the server starts, no iptables rule seems to block it. Anyone else got more solutions? someone asked me to contact the provider and get it done at the Network/Router but that looks very odd and I believe they might not do it since that would also affect other clients. Responding to all those answers, I'd say: Firstly, its a VPS so they can't do it for me. Secondly, I don't care if something is coming in but since its application generated so there has to be a OS level solution to block the outgoing packets. At least the outgoing ones must be stopped. Secondly, its not Ddos since just 400kb/s input generates 30mb/s output from my GameServer. That never happens in a D-dos. Asking the provider/hardware level solution should be used in that case but this one is different. And Yes, Banning his IP stops the flood of outgoing packets but he has many more IP-Addresses as he spoofs his original so I just need something to block him automatically. Even tried a lot of Firewalls but as you know they are just front-ends to iptables so if something doesn't work on iptables, what would the firewalls do? These were the rules I tried, iptables -A INPUT -p udp -m state --state NEW -m recent --set --name DDOS --rsource iptables -A INPUT -p udp -m state --state NEW -m recent --update --seconds 1 --hitcount 5 --name DDOS --rsource -j DROP It works for the attacks on un-used ports but when the server is listening and responding to the incoming queries by the attacker, it never works. Okay Tom.H, your rules were working when I modified them somehow like this: iptables -A INPUT -p udp -m length --length 1:1024 -m recent --set --name XXXX --rsource iptables -A INPUT -p udp -m string --string "xxxxxxxxxx" --algo bm --to 65535 -m recent --update --seconds 1 --hitcount 15 --name XXXX --rsource -j DROP They worked for about 3 days very good where the string "xxxxxxxxx" would be rate-limited, blocked if someone flooded and also didn't affect the clients. But just today, I tried updating the chain to try to remove a previously blocked IP so for that I had to flush the chain and restore this rule ( iptables -X and iptables -F ), some clients were already connected to servers including me. So restoring the rules now would also block some of the clients string completely while some are not affected. So does this mean I need to restart the server or why else would this happen because the last time the rules were working, there was no one connected?

    Read the article

  • Jquery ajax request error callback is called instead of success even after response recieved from server

    - by Muhammad Tahir Butt
    I am using jquery ajax funtion to get some content from my webservice. Response from the server is received but every time error callback is called instead of success callback. And this error is returned in xhr.error: function (){if(l){var t=l.length;(function i(t){x.each(t,function(t,n){var r=x.type(n);"function"===r?e.unique&&p.has(n)||l.push(n):n&&n.length&&"string"!==r&&i(n)})})(arguments),n?o=l.length:r&&(s=t,c(r))}return this} Here is the screenshot of response from server: and here is the code i am using to make the request: function abcdef() { $.ajax({ url: "http://192.168.61.129:8000/get-yt-access-token/", type: "GET", contentType:"application/json", error: function(xhr, textStatus, errorThrown){ alert("its error! " + xhr.error); }, success: function(data){ alert(data); } }); }

    Read the article

  • Dos/ Flood Lag even though Port not Saturated

    - by Asad Moeen
    My GameServers had been under some UDP Floods due to which they generated outputs to the attacker which gave the GameServers some huge lags. Thanks to friends at ServerFault that upon different kind of testing, I was able to successfully block the attack. My question is actually something else but it is important to know how the GameServers reacted to the attack and if the machine kept stable or not: 300kb/s Input would cause GameServer to generate 2mb/s Output. So as the Input Rate kept increasing, output rate would reach so high that it would no longer be possible for the GameServer to control it and hence it would give a huge Lag until the attack is stopped. Usually the game server starts to lag when it sends out something greater than 5mb/s and under that is controllable. Theoretically, I was able to receive a 60mb/s output from my GameServer on inputting 10mb/s. Its just the way the GameServer works if not protected. Now on some of my machines, only the GameServer under attack lagged and although the server was generating 60mb/s output, rest of the gameservers on other ports would run fine without lags on the same machine. But there was another machine which also runs on a 100 MBPS Network port, even 1 mbps input ( and ZERO output because attack is blocked ) even on an unused port would give a constant yellow line ( on the Lag-o-Meter ) to all the clients on all GameServers indicating lag because that line is actually blue under normal conditions. It would remain the same even on 50mbps or 900mbps input. I tried contacting the host about it because I believe its the way their Network is bridged, but they can't help me about it. Anyone else knowing about such issues because if 900mbps input does not Saturate the port, how can 1mbps input lag the servers although port is not saturated and enough bandwidth is available?

    Read the article

1 2 3 4 5 6  | Next Page >