mySQL password (Mac OS X Lion)
Posted by Catalin Negraru on Fri, 22 Mar 2013Setup root password for MySQL: /usr/local/mysql/bin/mysqladmin -u root -p password...
» Read more...
Cătălin brings 15 years of brand identity & web development experience to his work. Cătălin worked 7 years in Europe, where he co-founded APACHEMEDIA. For the last 6 years he is Creative Director & CEO at MarketDental Canada. Cătălin holds a Master of Arts degree in Visual Arts and a Bachelor's degree from the University of Art Bucharest, Romania.
Many developers and designers want to release their work into the world as open-source projects. They want others to be able to build on and share their code. The open-source community is vibrant because of this. Open-source software is available for virtually any application you could think of. Most designers use open-source software or code on a regular basis (WordPress, Drupal and many other CMS’ are open source).
But many developers and designers don’t have a clear picture of what the different open-source licenses really mean. What rights are they relinquishing when they choose an open-source license? Without knowing exactly what the licenses mean and how they’re best applied, developers can’t make informed decisions about which is best for their work.
A lot of confusion is out there about what exactly licensing means. When you license your work, you’re not giving away any of your rights. You still hold the original copyright (or patent if you have one) on that work. What a license does is grant specific permissions for others to use that work.
Licensing is a great alternative to just releasing your work into the public domain or granting permissions on a case-by-case basis. By releasing into the public domain, you relinquish any copyright, and no one is obligated to list you as the original author or contributor. In the latter case, you may end up spending more time dealing with individual permissions than designing or developing.
Open-source licenses make it easy for others to contribute to a project without having to seek special permission. It also protects you as the original creator, making sure you at least get some credit for your contributions. It also helps to prevent others from claiming your work as their own.
The GNU General Public Licence (GPL) is probably one of the most commonly used licenses for open-source projects. The GPL grants and guarantees a wide range of rights to developers who work on open-source projects. Basically, it allows users to legally copy, distribute and modify software. This means you can:
* Copy the software.
Copy it onto your own servers, your client’s servers, your own computer, pretty much anywhere you want. There’s no limit to the number of copies you can make.
* Distribute the software however you want.
Provide a download link on your website. Put the software on a bunch of thumb drives and give them away. Print out the source code and throw it from the rooftops (please don’t, though, because that would waste a lot of paper and make a mess).
* Charge a fee to distribute the software.
If you want to charge someone to provide the software, set it up on their website or do anything else related to it, you can do so. But, you must give them a copy of the GNU GPL, which basically tells them that they could probably get the software elsewhere for free. Best to be up front about that, and about why you’re charging them.
* Make whatever modifications to the software you want.
If you want to add or remove functionality, go ahead. If you want to use a portion of the code in another project, you can. The only catch is that the other project must also be released under the GPL.
Please note that it is very important to see source and binaries distribution as two very different things. Also, there are issues and restrictions with some licenses when used with applications released under “each other”. You can dive into more details in the detailed article Practical Guide to GPL Compliance (via @PierreJoye). To use the GPL, you have to include certain information in the software’s code, along with a copy of the license.
You should be aware of another GNU license: the Lesser General Public Licence (LGPL). It grants fewer rights to a work than the standard GPL. Generally, the LGPL is appropriate for libraries that want to allow linking from non-GPL and non-open-source software. Because the GPL requires that other software with parts of licensed code to also be licensed under the GPL, developers cannot use GPL-licensed code for paid and proprietary software. The LGPL negates this by not requiring other projects with parts of the code to be similarly licensed.
BSD licenses represent a family of permissive free software licenses that have fewer restrictions on distribution compared to other free software licenses such as the GNU General Public License. Among different versions of the license two versons are particularly important: the New BSD License/Modified BSD License, and the Simplified BSD License/FreeBSD License. Both have been verified as GPL-compatible free software licenses, and have been accepted as open source licenses by the Open Source Initiative.
The New BSD License (”3-clause license”) allows unlimited redistribution for any purpose as long as its copyright notices and the license’s disclaimers of warranty are maintained. The license also contains a clause restricting use of the names of contributors for endorsement of a derived work without specific permission. The primary difference between the New BSD License and the Simplified BSD license is that the latter omits the non-endorsement clause.
The MIT License is the shortest and probably broadest of all the popular open-source licenses. Its terms are very loose and more permissive than most other licenses. The basic provision of the license (minus the information that it is provided without warranty, which comprises the final paragraph) is as follows:
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
* You can use, copy and modify the software however you want. No one can prevent you from using it on any project, from copying it however many times you want and in whatever format you like, or from changing it however you want.
* You can give the software away for free or sell it. You have no restrictions on how to distribute it.
* The only restriction is that it be accompanied by the license agreement.
The MIT License is the least restrictive license out there. It basically says that anyone can do whatever they want with the licensed material, as long as it’s accompanied by the license.
The Apache License, Version 2.0, grants a number of rights to users. These rights can be applied to both copyrights and patents. Because some licenses can be applied only to copyrights and not patents, this flexibility would be an obvious factor in a patent developer’s choice of license (read this article on How Stuff Works for an explanation of the difference).
Here are some more details on what the Apache License allows:
* Rights are perpetual.
Once they’ve been granted, you can continue to use them forever.
* Rights are worldwide.
If the rights are granted in one country, then they’re granted in all countries. For example, if you’re in the US and the original license was granted in India, you’re not prevented from using the code under the license.
* Rights are granted for no fee or royalty.
Not only will you not be charged any kind of up-front usage fee, but you will not be charged fees on a per-usage or any other basis either.
* Rights are non-exclusive.
You can use the licensed work, and so can anyone else.
* Rights are irrevocable.
No one can take these rights away once they’re granted. In other words, you don’t need to worry that down the road, when you’ve created some awesome derivative of the licensed code, someone will swoop in and say, “Sorry, you can’t use this code anymore.” (A clause in the license states that if you sue someone over patent infringement on anything under this license, then your license is terminated, but that only applies to patented work, and as long as you don’t sue anyone over the work, you won’t have to worry about it.)
Redistributing code also has special requirements, mostly pertaining to giving proper credit to those who have worked on the code and to maintaining the same license.
Creative Commons (CC) licenses aren’t quite open-source licenses, but they are commonly used for design projects. A wide variety of CC licenses is available, each granting certain rights. A CC license has four basic parts, which can be enacted individually or in combination. Here’s an overview of the parts:
* Attribution
The author must be attributed as the creator of the work. Beyond that, the work can be modified, distributed, copied and otherwise used.
* Share Alike
The work can be modified, distributed and so forth, but only under the same CC license.
* Non-Commercial
The work can be modified, distributed and so on, but not for commercial purposes. The language about what constitutes “commercial” is a bit vague (no express definition is provided), so you may want to clarify this in your own projects. For example, some might interpret “non-commercial” as simply meaning that you can’t sell the work. Others might take it to mean that you can’t even put the work on a website that has advertising. Still others might consider something is “commercial” only if it makes a profit.
* No Derivative Works
This means you can copy and distribute the licensed work, but you can’t modify it in any way or create work based on the original.
As mentioned, these parts of the CC license terms can be combined. The most restrictive license would be the “Attribution, Non-Commercial, No Derivatives” license, which means that you can freely share the work, but not change it or charge for it, and you must attribute it to the creator. This is a good license to get your work out there but still maintain more or less complete control over how it is used. The least restrictive would be the “Attribution” license, which means that as long as people credit you, they can do whatever they like with the work.
CC licenses are used more for design work than development, but nothing bars you from using it for the latter. Just be aware of exactly what is and is not covered under each part.
Source: smashingmagazine.com
AZ: Cand ai ajuns in Canada? Care au fost motivele pentru care ai ales aceasta tara?
CN: Am plecat din tara in 2004. Frecusurile de zi cu zi care imi umpleau nepermis de mult viata, nepasarea si atitudinea unora au fost principalele motivele pentru care am decis doar sa vizitez Romania.
AZ: Ai o diploma in arte vizuale. Cum ai facut pasul spre web design?
CN: Dupa ce am terminat studiile la Universitatea de Arte Bucuresti - Sectia Grafica, am lucrat la mai multe agentii de publicitate, urmand ca in 2001 sa incep cu un prieten un mic studio de creatie care in timp s-a speciaziat pe web design. Intodeauna am fost atras de tehnologie si am încercat sa combin cunostintele mele de perspectiva, cromatica, anatomie etc... cu tehnologia din lumea digitala. Cred ca background-ul meu mă ajuta sa vad lucrurile altfel fata de alţi web designeri.
AZ: Lucrezi de 14 ani in acest domeniu. Ce include portofoliul tau?
CN: In primul rand... multe siteuri, de la siteuri mici de prezentare - pana la proiecte mari pentru corporatii precum McDonalds. Deasemenea include proiecte de brand identity si materiale publicitare pentru diferite campanii de publicitate pentru clienţi din Nord America si Europa.
AZ: Care a fost cel mai ambitios proiect la care ai lucrat sau unul de care te-ai atasat mult?
CN: De fiecare proiect mă atasez într-un fel sau altul, probabil ca cele mai importante au fost cele care au avut feedback pozitiv de la clienţii clienţilor mei. Unul din proiectele personale la care tin este e-buyart.com. Aici am incercat sa adun artisti romani si sa ii promovez in afara tarii.
AZ: Care sunt proiectele tale pe viitor? Care este proiectul la care aspiri?
CN: In urma cu patru ani am decis sa deschid aici in Canada, a a doua agentie de publicitate (MarketDental.com) - specializata in domeniul stomatologic. In prezent toata energia mea este focusata pe cresterea companiei, iar in viitor... obiectivul meu este sa reusesc sa gasesc un mod de lucru care sa aduca performanta si echilibru intre viata profesionala si viata personala.
AZ: Care este site-ul tau preferat, din punctul de vedere ai unui web designer? De ce?
CN: Imi place foarte mult www.apple.com, pentru simplitate dar in acelasi timp si pentru puterea brandului care transmite valoare şi diferenţiază produsele din piata care era monopolizata de o companie mamut... (nu zic care, oricum incepe tot cu M :)).
AZ: Care a fost prima impresie odata ajuns in Canada?
CN: Primele 6 luni au fost grele, eu si sotia mea de mai multe ori am vrut sa ne intoarcem in Romania. Nivelul de viata scazuse odata ajunsi in Toronto. Eu mi-am caut de lucru, iar sotia mea fiind medic stomatolog a trebuit sa studieze mai bine de 2 ani ca sa poata aplica, si in cele din urma intra, intr-un program de echivalare a studiilor. Desi eram coplesiti de dorul de casa si de greutatile inevitable inceputului, vedeam lumina de la capatul tunelului....aveam SPERANTA si asta a facut o mare diferenta in "prima impresie" pe care am avut-o despre Canada.
Cred ca in Romania speranta a murit pentru multi.
AZ: Ce iti lipseste cel mai mult din Romania?
CN: Parintii si prietenii...
AZ: Ce expozitii ai avut in Romania, dar in strainatate? Cu ce lucrari ai participat?
CN: In Romania am avut doua expozitii personale la Centrul Cultural Palatele Brancovenesti - Mogosoaia si la Muzeul de Arta din Ploiesti cu lucrari de grafica si gravura. Si mai multe expozitii de grup in Romania si strainatate.
AZ: Ce parere ai despre comunitatea romanilor din Canada? Ai prieteni romani cu care obisnuiesti sa-ti petreci timpul liber?
CN: Comunitatea romanilor din Canada si Statele Unite pare ca a fost cumva "filtrata" prin obtinerea vizei si cred ca au lasat o impresie mai buna fata de cei din Italia sau Spania.
Comunitatea este uriasa, in special in orasele mari (Toronto, Montreal, Vancouver...) Conform recensamantului Census din 2006 erau aproape 200.000 de romani in Canada. In patru ani numarul lor s-a dublat, acum se estimeaza 400.000.
Am destul de multi amici romani - ironia soartei face, ca acum dupa ceva ani, sa am poate mai multi prieteni romani aici, decat cei ramasi in Romania.
AZ: Care este cea mai mare reusita a ta peste Ocean?
CN: Nu a mai trebuit sa folosesc "ciocolata", ca sa mi se deschida usile :)
AZ: Daca ar fi sa alegi o tara de pe glob in care sa locuiesti, care ar fi aceasta si de ce?
CN: Mi-ar placea sa cred ca la un moment dat va fi Romania, acum este Canada - am decis acest lucru in momentul in care am ajuns aici.
De ce am ales Canada? Pentru ca pot sa parcug 300 km in 2 ore, pentru ca lumea sta la rand cand asteapta autobuzul, pentru ca nu trebuie sa innumar restul la magazin, pentru ca nu exista apelativul gaozar, samd... pentru toate aceste lucruri marunte care te fac sa simti viata altfel.
Google Inc. says Bell Canada Inc. is breaking Canadian telecommunications law by slowing certain internet traffic, and is urging the CRTC to take action against the company.
"Bell claims its throttling of peer-to-peer applications is a reasonable form of network management. Google respectfully disagrees. Network management does not include Canadian carriers’ blocking or degrading lawful applications that consumers wish to use," the company wrote in a 15-page submission to the Canadian Radio-television and Telecommunications Commission, which was made public over the weekend.
"From consumer, competition and innovation perspectives, throttling applications that consumers choose is inconsistent with a content and application-neutral internet, and a violation of Canadian telecommunications law, which forbids unfair discrimination and undue or unreasonable preferences and requires that regulation be technologically and competitively neutral."
The Mountain View, Calif.-based search engine giant made the comments as part of an investigation by the CRTC into Bell's limiting of download speeds of peer-to-peer applications such as BitTorrent. Bell first started limiting the speeds — known as throttling — of its own Sympatico internet subscribers in November, then extended the practice to its wholesale customers in March. The company said growing usage by a small number of peer-to-peer users was threatening to cause slowdowns for its overall customer base.
That move prompted a complaint with the CRTC from the Canadian Association of Internet Providers, a group of 55 small ISPs who rent portions of Bell's network, and sparked the "net neutrality" battle over who controls the internet in Canada. Aside from Google, CAIP has attracted the support of thousands of users, consumer groups and other technology firms including internet calling provider Skype. Bell, on the other hand, saw fellow large ISPs Telus Corp. and Rogers Communications Inc. come to its defence last week.
Google said that in order to keep consumer choice and innovation alive on the internet, the CRTC must force Bell — and eventually other large ISPs — to end its throttling practices.
"The internet is simply too important to allow them to act as such a gatekeeper," the company said. "Protecting end user choice is the central issue in this proceeding, but also a much larger issue. It goes to the heart of the internet and how it acts as an extraordinary platform for innovation and fair competition."
A spokesman for Bell said the company plans to respond in its next submission to the CRTC, which is due on Thursday.
Telus, which says it does not limit the speeds of its internet subscribers, in its submission argued that Bell is within its rights to change how it delivers services to its wholesale customers. The notification of network changes required by the Telecommunications Act apply only to other network carriers, a status many of CAIP's members do not have.
"Customer relations matters that involve no network interface changes do not engage the network change notification requirements, and it would be inefficient and unwieldy to create new requirements in this regard," wrote Craig McTaggart, director of broadband policy for Telus.
The company argued there is no discrimination because Bell is treating its own Sympatico and wholesale customers the same. Telus also discounted arguments made by other parties who have made submissions to the CRTC, including Skype, that the traffic-inspection technology used by Bell violates users' privacy.
McTaggart noted that the current dispute should be limited specifically to the question of whether Bell is violating its wholesale agreement terms and should not be extended to other network owners, such as Telus.
"To the extent that this dispute may raise any policy issues relating to retail internet access services, Telus would expect the commission to initiate a proceeding by way of public notice/notice of consultation before establishing new rules of general application," he wrote. "However, in Telus' view, no such proceeding is necessary."
Rogers, which also slows peer-to-peer applications, disputed claims by CAIP that such throttling affects services such as voice over internet protocol (VoIP) and virtual private networks (VPN).
"This equipment, therefore, does not impact any other traffic such as VoIP, VPN and other online streaming applications because their signatures are different," wrote Ken Engelhart, senior vice-president of regulatory affairs for Rogers. "There is therefore no reason why VPN or other encrypted traffic would be affected."
Engelhart also reiterated that Rogers does not throttle the downloading of files over peer-to-peer applications — it only slows uploading. However, because the download speeds of many applications are tied to the upload speed, the downloads are effectively slowed as well, which is the fault of the application's provider.
"Of course, because some P2P applications (BitTorrent for example) restrict download speed to the maximum upload speed provided by the user, a customer’s P2P download speed can be limited by the upstream cap, but that is a result of the business decision taken by the P2P applications provider," he wrote.
Bell has also been supported by network equipment maker Cisco Systems Inc., which said the CRTC should refrain from imposing network management regulations.
Aside from Google and Skype, parties who have made CRTC submissions supporting CAIP include: the University of Western Ontario; the Canadian Internet Policy and Public Interest Clinic; the Union des consommateurs; Primus Telecommunications Canada Inc.; the British Columbia Civil Liberties Association; and the Canadian Advanced Technology Alliance, which counts network equipment maker Alcatel Lucent among its members.
The CRTC expects to rule on the CAIP-Bell dispute in September and has said a larger investigation into net neutrality principles is likely.
By Peter Nowak CBC News
Source: cbc.ca
Designers Rahul Mahtani & Yofred Moik from the Industrial Design program at Syracuse University came up with this concept called Google Envelopes.
Wouldn’t it be great to be able to map the course of mail and how it can tell a story? They came up with Google Envelopes, which can be sent through G-Mail itself. It’s only a concept, but totally viable and something people can immediately understand.




Speaker: Scott Berkun
Taken from the “From Business to Buttons” Conference, Scott Berkun talks about design failure and its causes. Sometimes it’s problems in our design process or how we carry it out that cause failure. But in many cases, it’s the other stuff, the non-design stuff, the business stuff that causes failure. Scott argues the need to consider these other aspects — pitching ideas, learning to talk the language of business, and so on — as design problems too.
Apple has a long relationship with Adobe. In fact, we met Adobe’s founders when they were in their proverbial garage. Apple was their first big customer, adopting their Postscript language for our new Laserwriter printer. Apple invested in Adobe and owned around 20% of the company for many years. The two companies worked closely together to pioneer desktop publishing and there were many good times. Since that golden era, the companies have grown apart. Apple went through its near death experience, and Adobe was drawn to the corporate market with their Acrobat products. Today the two companies still work together to serve their joint creative customers – Mac users buy around half of Adobe’s Creative Suite products – but beyond that there are few joint interests.
I wanted to jot down some of our thoughts on Adobe’s Flash products so that customers and critics may better understand why we do not allow Flash on iPhones, iPods and iPads. Adobe has characterized our decision as being primarily business driven – they say we want to protect our App Store – but in reality it is based on technology issues. Adobe claims that we are a closed system, and that Flash is open, but in fact the opposite is true. Let me explain.
First, there’s “Open”.
Adobe’s Flash products are 100% proprietary. They are only available from Adobe, and Adobe has sole authority as to their future enhancement, pricing, etc. While Adobe’s Flash products are widely available, this does not mean they are open, since they are controlled entirely by Adobe and available only from Adobe. By almost any definition, Flash is a closed system.
Apple has many proprietary products too. Though the operating system for the iPhone, iPod and iPad is proprietary, we strongly believe that all standards pertaining to the web should be open. Rather than use Flash, Apple has adopted HTML5, CSS and JavaScript – all open standards. Apple’s mobile devices all ship with high performance, low power implementations of these open standards. HTML5, the new web standard that has been adopted by Apple, Google and many others, lets web developers create advanced graphics, typography, animations and transitions without relying on third party browser plug-ins (like Flash). HTML5 is completely open and controlled by a standards committee, of which Apple is a member.
Apple even creates open standards for the web. For example, Apple began with a small open source project and created WebKit, a complete open-source HTML5 rendering engine that is the heart of the Safari web browser used in all our products. WebKit has been widely adopted. Google uses it for Android’s browser, Palm uses it, Nokia uses it, and RIM (Blackberry) has announced they will use it too. Almost every smartphone web browser other than Microsoft’s uses WebKit. By making its WebKit technology open, Apple has set the standard for mobile web browsers.
Second, there’s the “full web”.
Adobe has repeatedly said that Apple mobile devices cannot access “the full web” because 75% of video on the web is in Flash. What they don’t say is that almost all this video is also available in a more modern format, H.264, and viewable on iPhones, iPods and iPads. YouTube, with an estimated 40% of the web’s video, shines in an app bundled on all Apple mobile devices, with the iPad offering perhaps the best YouTube discovery and viewing experience ever. Add to this video from Vimeo, Netflix, Facebook, ABC, CBS, CNN, MSNBC, Fox News, ESPN, NPR, Time, The New York Times, The Wall Street Journal, Sports Illustrated, People, National Geographic, and many, many others. iPhone, iPod and iPad users aren’t missing much video.
Another Adobe claim is that Apple devices cannot play Flash games. This is true. Fortunately, there are over 50,000 games and entertainment titles on the App Store, and many of them are free. There are more games and entertainment titles available for iPhone, iPod and iPad than for any other platform in the world.
Third, there’s reliability, security and performance.
Symantec recently highlighted Flash for having one of the worst security records in 2009. We also know first hand that Flash is the number one reason Macs crash. We have been working with Adobe to fix these problems, but they have persisted for several years now. We don’t want to reduce the reliability and security of our iPhones, iPods and iPads by adding Flash.
In addition, Flash has not performed well on mobile devices. We have routinely asked Adobe to show us Flash performing well on a mobile device, any mobile device, for a few years now. We have never seen it. Adobe publicly said that Flash would ship on a smartphone in early 2009, then the second half of 2009, then the first half of 2010, and now they say the second half of 2010. We think it will eventually ship, but we’re glad we didn’t hold our breath. Who knows how it will perform?
Fourth, there’s battery life.
To achieve long battery life when playing video, mobile devices must decode the video in hardware; decoding it in software uses too much power. Many of the chips used in modern mobile devices contain a decoder called H.264 – an industry standard that is used in every Blu-ray DVD player and has been adopted by Apple, Google (YouTube), Vimeo, Netflix and many other companies.
Although Flash has recently added support for H.264, the video on almost all Flash websites currently requires an older generation decoder that is not implemented in mobile chips and must be run in software. The difference is striking: on an iPhone, for example, H.264 videos play for up to 10 hours, while videos decoded in software play for less than 5 hours before the battery is fully drained.
When websites re-encode their videos using H.264, they can offer them without using Flash at all. They play perfectly in browsers like Apple’s Safari and Google’s Chrome without any plugins whatsoever, and look great on iPhones, iPods and iPads.
Fifth, there’s Touch.
Flash was designed for PCs using mice, not for touch screens using fingers. For example, many Flash websites rely on “rollovers”, which pop up menus or other elements when the mouse arrow hovers over a specific spot. Apple’s revolutionary multi-touch interface doesn’t use a mouse, and there is no concept of a rollover. Most Flash websites will need to be rewritten to support touch-based devices. If developers need to rewrite their Flash websites, why not use modern technologies like HTML5, CSS and JavaScript?
Even if iPhones, iPods and iPads ran Flash, it would not solve the problem that most Flash websites need to be rewritten to support touch-based devices.
Sixth, the most important reason.
Besides the fact that Flash is closed and proprietary, has major technical drawbacks, and doesn’t support touch based devices, there is an even more important reason we do not allow Flash on iPhones, iPods and iPads. We have discussed the downsides of using Flash to play video and interactive content from websites, but Adobe also wants developers to adopt Flash to create apps that run on our mobile devices.
We know from painful experience that letting a third party layer of software come between the platform and the developer ultimately results in sub-standard apps and hinders the enhancement and progress of the platform. If developers grow dependent on third party development libraries and tools, they can only take advantage of platform enhancements if and when the third party chooses to adopt the new features. We cannot be at the mercy of a third party deciding if and when they will make our enhancements available to our developers.
This becomes even worse if the third party is supplying a cross platform development tool. The third party may not adopt enhancements from one platform unless they are available on all of their supported platforms. Hence developers only have access to the lowest common denominator set of features. Again, we cannot accept an outcome where developers are blocked from using our innovations and enhancements because they are not available on our competitor’s platforms.
Flash is a cross platform development tool. It is not Adobe’s goal to help developers write the best iPhone, iPod and iPad apps. It is their goal to help developers write cross platform apps. And Adobe has been painfully slow to adopt enhancements to Apple’s platforms. For example, although Mac OS X has been shipping for almost 10 years now, Adobe just adopted it fully (Cocoa) two weeks ago when they shipped CS5. Adobe was the last major third party developer to fully adopt Mac OS X.
Our motivation is simple – we want to provide the most advanced and innovative platform to our developers, and we want them to stand directly on the shoulders of this platform and create the best apps the world has ever seen. We want to continually enhance the platform so developers can create even more amazing, powerful, fun and useful applications. Everyone wins – we sell more devices because we have the best apps, developers reach a wider and wider audience and customer base, and users are continually delighted by the best and broadest selection of apps on any platform.
Conclusions.
Flash was created during the PC era – for PCs and mice. Flash is a successful business for Adobe, and we can understand why they want to push it beyond PCs. But the mobile era is about low power devices, touch interfaces and open web standards – all areas where Flash falls short.
The avalanche of media outlets offering their content for Apple’s mobile devices demonstrates that Flash is no longer necessary to watch video or consume any kind of web content. And the 200,000 apps on Apple’s App Store proves that Flash isn’t necessary for tens of thousands of developers to create graphically rich applications, including games.
New open standards created in the mobile era, such as HTML5, will win on mobile devices (and PCs too). Perhaps Adobe should focus more on creating great HTML5 tools for the future, and less on criticizing Apple for leaving the past behind.
Steve Jobs
April, 2010

Apple just released iOS4 for the iPhone and iPod touch, and now that you've downloaded and upgraded to the much-hyped iDevice update, here's a look at the new shortcuts, settings, and features you'll need to know—and want to use.
On a little device with just one button and no major forms of interaction beyond tapping a screen, shortcuts can be serious timesavers. Here are the new shortcuts in iOS4 you'll want to know:
![]()
Hold then drag-and-drop to create app folders: You can now create folders to store and organize the apps on your iPhone's home screen, particularly handy if you're a bit of an app junkie. To create a folder, tap and hold any icon on the home screen until they all start wiggling. Then drag and drop any application on top of another to create a folder with those apps together.
![]()
Double-tap home for quick app switching: The quick app switching shortcut pulls up your most recently opened applications whenever you double-tap the home button. Then just tap on any app you want to quickly switch to it without going back to the home screen. Note: You'll need at least an iPhone 3GS or later generation iPod touch to use multitasking. Photo via Gizmodo
Hold to kill background apps: Currently in iOS4, if an application supports multitasking, it'll run in the background by default—kind of a strange choice, considering Apple asks you to confirm push notifications for apps. What this means is that as more apps start supporting background processing, you may end up with a ton of apps running in the background that you don't really need or want running. To remove an application from running in the background, just pull up your quick switch drawer (double-tap the home button), then tap and hold on an app (like you do when you want to delete an app from the home screen until you see a red minus sign (-) on the corner of the app's icon. Tap it to kill the app.
Swipe to the left in the app drawer for iPod controls: For some quick app-switching access to simple iPod controls, double-click the home button to bring up the app switcher, then swipe to the left for pared down iPod controls. Note: 3GS and above only.
These are the handy new iOS4 in-app features you'll want to get familiar with:
![]()
Unified inbox: If you access multiple email accounts from your phone but you'd prefer to be able to read through them in one unified stream, Mobile Mail now has a unified "All Inboxes" feature that does just that.
![]()
Strong alphanumeric lock codes: A few months back we showed you how to add an alphanumeric passcode lock to your iPhone. Now to do the same, all you've got to do is go to Settings -> General -> Passcode Lock, toggle Simple Passcode to off, and enter your preferred alphanumeric pass.
Tethering: Okay, you'll have to pay AT&T a whopping $20 a month for the privilege of tethering, but at least it's finally an option. To turn it on, head to Settings -> General -> Network -> Internet Tethering.
![]()
Tweak your keyboard layout: If you prefer a different keyboard layout from the standard QWERTY, head to Settings -> General -> Keyboard -> International Keyboards -> English to try out an alternative layout for your software or connected hardware keyboard.
Source: lifehacker.com
CSS Conditional comments for IE are a perfect way of hiding this hacky code from the good browsers. Here is a way to bring in the CSS for only IE 6 and below:
< ! -- [if lte IE 6] > < link rel="stylesheet" type="text / css" href="pngfix.css" / > < ! [endif] -->
* html img,
* html .png{
position:relative;
behavior: expression((this.runtimeStyle.behavior="none")&&(this.pngSet?this.pngSet=true:(this.nodeName == "IMG" && this.src.toLowerCase().indexOf('.png')>-1?(this.runtimeStyle.backgroundImage = "none",
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.src + "', sizingMethod='image')",
this.src = "transparent.gif"):(this.origBg = this.origBg? this.origBg :this.currentStyle.backgroundImage.toString().replace('url("','').replace('")',''),
this.runtimeStyle.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + this.origBg + "', sizingMethod='crop')",
this.runtimeStyle.backgroundImage = "none")),this.pngSet=true)
);
}
Google, with 65% market share. Google is so powerful the second player, Yahoo, just bailed out of the market. And third place Microsoft is throwing billions of dollars around just to get in the game.
We’ve seen Wikia, Cuil and other well backed startups try and fail at search. Now Blekko is preparing to launch. Will they find success where everyone else has failed?
Blekko was founded in 2007 by the same team that built the open directory (DMOZ) and Topix.
USVP, CMEA Capital, Ron Conway, Jeff Clavier and lots of other prominent valley investors.
Build a disruptive search engine.
http://blekko.com
Are you shopping for a payment processing company so that you can accept credit card payments? Before you sign on the dotted line consider this. Most Canadian small business owners don't know what questions to ask payment processing companies before choose a provider and are shocked by the true costs when bills begin to arrive.
The best way to avoid being surprised is to ask the right questions. This article identifies 17 questions that will make a difference, by arming you with the information you will need to make an educated decision about which payment processing vendor is best for your business.
Every payment processing provider will have this fee. Discount rates can vary on from as low as 1.59% right up to as high as 5.0%. The discount rate is really not a discount.
Discount rates are a % of your sales that the credit card companies charges the business owner to be able to offer their customers to pay with their credit card. For example, discount rate & how you are charged: If you did $10,000 in Visa sales in one month and your discount rate was 2.5% then you would pay $250 in fees to Visa that month. Rates vary and are dependent on your business model, business volume, average sale per customer, type of product & service your business offers.
Rates also vary on the way you process payments for your products/services and how soon your clients/customers receive the products/services: online, telephone, mail-order, or in-store all affect the discount rate your business will qualify for. Usually high-risk business will have higher discount rates (2.5%-5%). High risk businesses are ones that have: (a) higher ticket prices ($1000 plus per sale), (b) Businesses that process more then 40% of their sales through internet/E-commerce, telephone (IVR), & mail-order
Most merchant account agreements are for 3 years. Do not forget to ask: what would the termination costs be if you were to terminate your agreement early? Most companies charge a $300 early termination fee that is retro-active from the time the agreement started. Also most agreements state that if you do not write them within a certain date of time at the end of your agreement the agreement will automatically renew itself for another 3 years.
Most payment processing providers will have a different discount rate for transactions that are keyed in on point-of-sale terminal instead of being swiped across the POS terminal. However, there are some exceptions for some businesses that have reoccurring billing. Typical "Keyed In" rates are 2.2% to 5%.
Transactions fees are sometime called IDP transactions. Every payment processing company has at least a transaction fee for debit and usually for credit card transactions too. It is become more common that any transaction that is made on your point-of-sale terminal will be considered a transaction and a fee will apply, whether is it is a void, debit, credit card, refund, batch close, etc. Transaction fees can range from 0.05 cents up to 0.50 cents and can be different for each type of transaction, although typical point-of-sale terminal transactions fees are between 0.08 cents to 0.15 cents. IVR, PC, & E-commerce processing solution transaction fees are usually much higher ranging from 0.35 cents to 0.50 cents.
Most bank related payment processing companies offer: rental program for point-of-sale terminals. Rental costs can range from $20 right up to as high as $100 a month dependent on the type of point-of-sale terminal your business requires. Private label payment processing companies usually only offer: Lease-to-own or buy options on their point-of-sale terminals. Lease-to-own usually run on 48 month leases with a 10% buy-out option at the end. Lease-to-own point-of-sale terminal prices range from $30 - $80 dependent on type of POS terminal. Buy-out point-of-sale terminal prices, typically run from $999 - $1800 (without taxes) dependent on type of POS terminals.
Two very important questions to ask before buying a POS terminal: 1. What are the warranty conditions? 2. Is the point-of-sale terminal smart-card ready? When renting a POS terminal if you require a new POS terminal is usually will be fixed or replaced at no cost to you. However, you pay rent forever. If you have been renting a POS terminal for $40 a month for 5 years, then you just paid $2400. If you have been renting a POS terminal for 10 years at $40/month then you just spent $4800 & no asset in your business.
When you can own a basic POS terminal for as little as, $1000 and now have another asset in your business. In terms of warranties, most private label companies will offer some type of life-time warranty, sometimes at no extra cost, sometimes for an additional fee. Sometimes it is better to pay more for a all inclusive warranty on hardware with free software upgrades then to pay less with a limited warranty.
Every payment processing company will have set-up fees, some more then others. Set-up fees can range from $50 - $300. Usually the set-up fees are one-time only set-up fees for Visa, MasterCard, Amex, & debit cards usually around $25 per card. Some companies also charge an initial set-up fee for programming the point-of-sale terminal or a fee for initial training. Set-up fees can greatly vary from company to company.
Not all payment processing companies have an application fee, however, some companies do. This is usually a non-refundable fee, whether your business is approved or not. Applications fees can vary from non-existent to $300.
Not all payment processing companies have a statement fee, however, some do. The average statement fee is usually around $5 or free if you are willing to receive your statement coming to you via e-mail. (I am not sure if this is a nickel and dime fee or if it is companies trying to go green? I let you decide!)
All payment processing companies have a settlement fee. Settlement fees can range from 0.05 cents 5 dollars.
All payment processing companies have minimum processing fees, ranging from $5 - $25. Often there are minimum processing fees for each type of card you intend to have processed. Basically, what this means is if you do not do enough business to have high enough fees you will still pay a minimum every month.
For example: Let say your discount rate 1.85% on Visa and your do a $1000 worth of sales on Visa that month and your minimum processing fee is $10. Well, 1.85% X 1000 = $18.50 in fees that month on Visa. Therefore, you have cleared your minimum of $10 and you have nothing to worry about. Now if you take the same rate and minimum, but you only made sales $250 that month on Visa. Well, 1.85% X 250 = $4.62 in fees that month on Visa. Therefore, you did not make you minimum and would be required to make the difference up of $5.38.
Most payment processing companies usually have a gateway fee, but usually only for IP POS terminals, PC, & e-commerce payment solutions. Gateway fees can range from $5 to $45 a month.
Some payment processing companies have a monthly maintenance fee others do not. If they have it, it is usually a fee that is associated with IVR, PC, & e-commerce solutions however, some companies have it on POS terminal solutions too.
Some payment processing companies have a monthly added value fee and some do not. This fee usually ranges from $5 - $10 a month.
Most payment processing companies have a monthly low achiever fee. Low achiever fees can range from $5 - $20. This is why it is important to get your monthly/annual estimate of total business volume correct on your Visa, MasterCard, & American Express applications. Most merchant account providers have 25%-35% error lenience. If you are not sure it is always better to under estimate your monthly/annual sale amounts when applying for credit card merchant accounts.
Most payment processing companies have a chargeback fee. Chargeback fees can range from $10 - $50. A chargeback is when a card holder holds a dispute on a Visa or MasterCard or Amex transaction that came from your business. If the card holder wins the dispute, they will be refunded their money and you will be charged a chargeback fee, a similar fee to bouncing a cheque. It is always the merchant burden of proof to prove that the card holder had used or bought the product or services from your business. This is why is so important to check that on credit card purchases that the signature matches the back of the card holders credit card and if it does not to ask for photo ID.
Most payment processing companies have a help desk/technical support. However, not all are 24/7 and some are better then others. The best thing to do is to get the help desk number and give it a call a few times through out a day to see what kind of service you would get.
Payment processing companies can vary on this. Some can have one to you within 24 hours others can take 2-4 weeks before they have a new POS terminal to you. The question you have to ask yourself is how long can your business run without one in your business? Sometimes it is better to pay more for better services.
Most payment processing companies usually take at least 2 weeks (sometimes as long as 4-6 weeks) to have your application processed, merchant accounts set-up, point-of-sale terminal programmed and shipped to your business ready to use. However, there are a few payment processing companies that can have one ready in your business in as little as five business days. These are usually private label payment processing companies.
Source: canadaone.com
By Matthew Hunt
The ie6-upgrade-warning is a little script (7.9kb) that displays a warning message politely informing the user to upgrade the browser to a newer version (links to newest IE, Firefox, Opera, Safari, Chrome are provided).
The webpage is still visible behind a transparent background, but access to it is prevented. The idea is to force users to upgrade from IE6 and avoid the website from a bad reputation that website is not rendering correctly in IE6.
The script is completely translatable in any language, very easy to set-up (one line of code in webpage and one parametter configuration).

An example of the warning message produced
<!--[if lte IE 6]><script src="js/ie6/warning.js"></script><script>window.onload=function(){e("js/ie6/")}</script><![endif]-->
right after the <body> declaration of the webpage and change the e("js/ie6/") to the folder where the script's icons images are located.
Source:
http://code.google.com/p/ie6-upgrade-warning/
Once you sign up your domain for Google Apps, you will have to change the MX records for your domain in order to use it in Gmail.
If you are using cPanel, this can be easily done by using the MX Entry option. There find the domain you will be pointing to Google Apps Mail and delete all of its MX records.
Then add the following MX records with the corresponding priority for your domain:
Priority Mail server
--------------------------------------
1 ASPMX.L.GOOGLE.COM
5 ALT1.ASPMX.L.GOOGLE.COM
5 ALT2.ASPMX.L.GOOGLE.COM
10 ASPMX2.GOOGLEMAIL.COM
10 ASPMX3.GOOGLEMAIL.COM
The above instructions are in full compliance with the official Google Apps instructions and have been adapted to work with cPanel. They will require 24 hours to propagate and take effect. After that your mail will be handled exclusively by Google Apps Mail.
Gmail has proven to provide the best mail experience even to the most demanding users. That's why all web hosts should provide easy means to change the MX records to Gmail.
As technology changes, design changes to adapt. Consider screen resolutions over time. In the past decade, designs have moved from accommodating 640 x 480 (still over 10% of users in 2000) to 800 x 600, and now to at least 1024 x 768 pixels (with around 75% of users having higher resolutions).
In the same time period, the physical size of displays has also generally increased but now includes a lot more variety. A decade ago, 15” desktop screens were common, and 20” screens were about the largest in regular use. Today, anything under 19” is uncommon for desktops, with screens ranging up to 30”. But notebooks with smaller screens are everywhere, netbooks with displays even smaller yet abound, and mobile devices proliferate with comparatively tiny screens. Technology solutions have largely helped deal with this disparity, such as the iPhone’s easy zooming feature for web browsing. And with 1024 x 768 as the current default minimum target resolution, it’s really only phones with lower resolutions.
But there’s another, related issue: with the disparity in screen sizes and resolutions comes a compounded variance in pixel density. While a standard desktop 20” widescreen monitor at 1680 x 1050 has a pixel density of 99 pixels per inch, my 15” MacBook Pro running the same resolution is 128PPI. An older 19” CRT at 1024 x 768 is 67PPI, almost half—meaning that elements such as text are physically half as big on the newer screen. And mobile device disparity is even greater: the iPhone 4’s 3.5” display at 640 x 960 is 326PPI.
Designers need to rethink the scales they’ve always used for design. Increasing pixel density means that 10- and 12-pt fonts are basically illegible on many screens. While we’re accustomed to working to the lowest common denominator (for screen resolution), we need to be actively considering higher-end users in terms of pixel density.
One mitigating factor is that most browsers have now adopted the “zoom the entire page” model instead of “make the text larger”, resulting in a better experience for those outliers who we fail with our designs. But relying on technology to compensate for our failure to accommodate our users isn’t a reassuring thought. There is a definite opportunity here for designers focusing on legibility and usability to lead the way on web design trends.
Source: zu.com
Google announced today that they've purchased ITA, a Boston-based company speciailzing in airline data, for $700 million, as rumored a few months back. ITA had been the subject of a hot little bidding war, with Microsoft, Expedia, and Kayak all rumored to be fighting for the company. But Google snagged it. So what does this mean?
In short, it means Google Flight Planner. I don't know if that'll be the actual title, but it's safe to say Google will announce some variation on it in the coming months. Google now has the data to provide search results for all kinds of airline questions, including price comparisons, flight times, availability, and more.
Microsoft, for its part, already has a similar experience built in to Bing, called Travel. Interestingly, some of the data used in Travel comes from ITA, a partnership that Google says will continue, at least for the time being. Here's a statement from Google on what's to come:
"While online flight search is rapidly evolving, we think there is room for more competition and greater innovation. Google has already come up with new ways to organize hard-to-find information like images, newspaper archives, scholarly papers, books and geographic data. Once we’ve completed our acquisition of ITA, we’ll work on creating new flight search tools that will make it easier for you to search for flights, compare flight options and prices and get you quickly to a site where you can buy your ticket."
Pull down the address bar typed URLs history list, use cursor or mouse to point the URL or link that you want to delete, and then press SHIFT-DELETE keys. The URL or link will be removed from the address bar history.
Video from a camera attached to a weather balloon that rose into the
upper stratosphere and recorded the blackness of space.
Homemade Spacecraft from Luke Geissbuhler on Vimeo.
In order to take an innovative idea from the embryo of a concept to market, you need to have the determination to push through failure. The odds are against you no matter the idea and statistics say you are going to fail a few times on your road to success. Knowing this, you have to hedge your bets more effectively so you can adjust your path and continue forward.
Don’t be intimidated by the perceived brilliance of innovative designs, because you are typically seeing the last iteration that has changed compared to its original concept. This happens with adjustment through failure. As Johansson mentioned, Picasso had made around 20,000 (as high as 50,000) works of art in his lifetime and Einstein published 240 papers with a short number of successful creations. Innovative success happens in volume (see image below).

Stevens, G.A. and Burley, J., “3,000 Raw Ideas = 1 Commercial Success!”
Source: smashingmagazine.com
Use this simple PHP script to send direct messages or to receive alerts (SMS, email) through Twitter:
<?php
$result = shell_exec('curl -u TWITTER_USER_SENDER:TWITTER_PASSWORD -d "text=Testing a remote direct message via CURL&user=TWITTER_USER_RECEIVER" http://twitter.com/direct_messages/new.xml');
?>
![Secret Golden Ratio of the Day: Twitter’s Creative Director Doug Bowman says: To anyone curious about #NewTwitter proportions, know that we didn’t leave those ratios to chance.” Paging Tweeting Dan Brown. [laughingsquid.]](http://27.media.tumblr.com/tumblr_l9ihqeJol81qzpwi0o1_500.jpg)
Twitter’s Creative Director Doug Bowman says:
To anyone curious about #NewTwitter proportions, know that we didn’t leave those ratios to chance.”
Prietenii "telecomande" la doctor.
Prietenii "telecomande" la agentia matrimoniala.
O Telecomanda Doua...Nu stiu d-astea - La tribunal
O Telecomanda Doua...Nu stiu d-astea - Bianca lu' Bote
O Telecomanda Doua...Nu stiu d-astea - Dj Alex D. Remix
O Telecomanda Doua...Nu stiu d-astea - Mondenii
Perversa ca pe Targu Ocna intr-o apostare din Rahova timp de 3600 secunde.
In Puii Mei "Perversa ca pe Targu Ocna"
In puii mei - Perversa ca pe Targu Ocna la Bacalaureat
Show Clips The Vogelchecks have no problem showing their affection around the holidays.
Access your reports from your Android phone, iPhone, iPod or iPad from www.dental-web-sites.com/analytics
Download Piwik Mobile for Android
Piwik Mobile gives you access to all reports: Referers, Best keywords, Websites, Top Page URLs, Page Titles, Goals, etc. all you need is an Internet connection.


You can see at a glance how all your websites are doing using the 'All Websites' dashboard.
The app is available in more than 40 languages!


Android devices version 1.6+ and all iOS devices version 3.2+ (iPad, iPhone und iPod Touch).
To prevent getting 404 File Not Found error (traffic coming from links, bookmarks and search engines), .htaccess redirect is better than the meta refresh or redirect tag because there is no delay as the browser reads the .htaccess file first.
Go to your site's root folder (public_html or www), download the .htaccess file to your local computer and edit it with a plain-text editor. If you are using FTP Client software and you don't see any .htaccess file on your server, double check your setting and make sure you have turn on invisible / system files.
To Redirect Certain Page(s):Redirect 301 /oldpage.html http://www.domain.com/newpage.html Redirect 301 /oldpage2.html http://www.domain.com/folder/To Redirect Entire Site:
Redirect 301 / http://www.newdomain.com/
I use the following PHP script to retrieve data from my AdSense account (impressions, clicks, ctr, ecpm, earnings). It's great to be used with a Cron Job to receive daily emails or SMS alerts.
Thanks to Alexander Makarow!
<?php
/* ------ CHANGE THIS -------- */
$username = 'USERNAME@gmail.com';
$password = 'PASSWORD';
/*
* PHP class that can retrieve data from AdSense account
* It's based on PHP AdSense account monitor class (http://www.webtoolkit.info/php-adsense-account-monitor.html)
* Copyright (C) 2009 Alex Polski
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
if (!function_exists('sys_get_temp_dir')) {
function sys_get_temp_dir() {
if (!empty($_ENV['TMP'])) { return realpath($_ENV['TMP']); }
if (!empty($_ENV['TMPDIR'])) { return realpath( $_ENV['TMPDIR']); }
if (!empty($_ENV['TEMP'])) { return realpath( $_ENV['TEMP']); }
$tempfile = tempnam(uniqid(rand(), TRUE), '');
if (file_exists($tempfile)) {
unlink($tempfile);
return realpath(dirname($tempfile));
}
}
}
class AdSense {
var $curl = null;
function AdSense(){
$this->cookieFile = tempnam(sys_get_temp_dir(), 'cookie');
$this->curl = curl_init();
curl_setopt($this->curl, CURLOPT_HEADER, false);
curl_setopt($this->curl, CURLOPT_RETURNTRANSFER, true);
curl_setopt($this->curl, CURLOPT_SSL_VERIFYPEER, false);
curl_setopt($this->curl, CURLOPT_SSL_VERIFYHOST, false);
curl_setopt($this->curl, CURLOPT_FOLLOWLOCATION, true);
curl_setopt($this->curl, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.7) Gecko/20070914 Firefox/2.0.0.7");
curl_setopt($this->curl, CURLOPT_COOKIEFILE, $this->cookieFile);
curl_setopt($this->curl, CURLOPT_COOKIEJAR, $this->cookieFile);
register_shutdown_function(array(&$this, '__destructor'));
}
function __destructor(){
@curl_close($this->curl);
@unlink($this->cookieFile);
}
function connect($username, $password){
curl_setopt($this->curl, CURLOPT_POST, false);
curl_setopt($this->curl, CURLOPT_URL, 'https://www.google.com/adsense/');
$content = curl_exec($this->curl);
curl_setopt($this->curl, CURLOPT_POST, false);
curl_setopt($this->curl, CURLOPT_URL, 'https://www.google.com/adsense/login-box.js');
$content = curl_exec($this->curl);
$content = preg_replace(
array("/\\\\75/", "/\\\\42/", "/\\\\46/", "/\\\\075/"),
array('=', '"', '&', '='),
$content);
preg_match('/src="([^"]+)"/', $content, $match);
$next_url = $match[1];
$next_url = str_replace('&', '&', $next_url);
curl_setopt($this->curl, CURLOPT_POST, false);
curl_setopt($this->curl, CURLOPT_URL, $next_url);
$content = curl_exec($this->curl);
preg_match_all("#<input type=\"hidden\"[^>](.*?)>#", str_replace("\n"," ",$content), $out);
$params = array();
foreach($out[1] as $line) {
$spacecount=1;
$line=str_replace("''",'""',$line);
while ($spacecount>0) $line=str_replace(" "," ",$line,$spacecount);
preg_match("#name=\"(.*?)\" #",$line,$extname);
preg_match("#value=\"(.*?)\" #",$line,$extval);
$params[] = $extname[1] . '=' . urlencode($extval[1]);
}
$params[] = 'Email=' . urlencode($username);
$params[] = 'Passwd=' . urlencode($password);
$params[] = 'null=' . urlencode('Sign in');
curl_setopt($this->curl, CURLOPT_POST, true);
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/accounts/ServiceLoginAuth");
curl_setopt($this->curl, CURLOPT_POSTFIELDS, join('&', $params));
$content = curl_exec($this->curl);
// did we login ?
if (eregi("<a href=\"/adsense/signout\">", $content)) {
return true;
} else {
return false;
}
}
function log_out(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/signout");
curl_exec($this->curl);
}
function parse($content){
preg_match_all('/<td nowrap valign="top" style="text-align:right" class="">(.*?)<\/td>/', $content, $matches);
return array(
"impressions" => $matches[1][0],
"clicks" => $matches[1][1],
"ctr" => $matches[1][2],
"ecpm" => $matches[1][3],
"earnings" => $matches[1][4]
);
}
function today(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview?timePeriod=today");
return $this->parse(curl_exec($this->curl));
}
function yesterday(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview?timePeriod=yesterday");
return $this->parse(curl_exec($this->curl));
}
function last7days(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview?timePeriod=last7days");
return $this->parse(curl_exec($this->curl));
}
function lastmonth(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview?timePeriod=lastmonth");
return $this->parse(curl_exec($this->curl));
}
function thismonth(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview?timePeriod=thismonth");
return $this->parse(curl_exec($this->curl));
}
function sincelastpayment(){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview?timePeriod=sincelastpayment");
return $this->parse(curl_exec($this->curl));
}
function get_report_id_from_name($name){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/overview");
$page = curl_exec($this->curl);
preg_match('~<a href=".*reportId=([0-9]+)">'.$name.'</a>~i', $page, $matches);
if(empty($matches[1])) return false;
return $matches[1];
}
function get_report_as_csv($report_id, $encoding = 'UTF-8'){
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/view-custom.do?reportId=$report_id&outputFormat=TSV_EXCEL");
//By default report is in UTF-16LE
return iconv('UTF-16', $encoding, curl_exec($this->curl));
}
function report($report_id){
$result = array();
curl_setopt($this->curl, CURLOPT_URL, "https://www.google.com/adsense/report/view-custom.do?reportId=$report_id");
$content = curl_exec($this->curl);
if (preg_match('/var\s+reportTable\s+=\s+new\s+AsyncReportTable\(([^\)]+)\);/si', $content, $matches)) {
$params = array();
foreach (explode(",\n", $matches[1]) as $v) {
$params[] = trim($v, " \t'\"\n\r");
}
curl_setopt($this->curl, CURLOPT_URL,
'https://www.google.com/adsense/report/online-stored-reporttable?storedReportId=' .
$params[0] . '&reportUri=' . str_replace('?', '%3F', str_replace('/', '%2F', str_replace('\x', '%', $params[2]))) .
'&formId=' . $params[3] . '&title=' . str_replace('+', '%20', urlencode($params[1])) . '&waitTime0');
do {
$content = curl_exec($this->curl);
if (empty($content)) {
sleep(1);
}
} while (empty($content));
if (preg_match_all('/<tr\s+class="(odd|even)\s+datarow">\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<\/tr>/si', $content, $matches)) {
foreach ($matches[2] as $k => $v) {
$result[$k]['channel'] = preg_replace('/<.+>/', '', $v);
$result[$k]['impressions'] = $matches[3][$k];
$result[$k]['clicks'] = $matches[4][$k];
$result[$k]['ctr'] = $matches[5][$k];
$result[$k]['ecpm'] = $matches[6][$k];
$result[$k]['earnings'] = $matches[7][$k];
}
}
}
return $result;
}
function quick_report($url){
$result = array();
curl_setopt($this->curl, CURLOPT_URL, $url);
$content = curl_exec($this->curl);
if (preg_match('/var\s+reportTable\s+=\s+new\s+AsyncReportTable\(([^\)]+)\);/si', $content, $matches)) {
$params = array();
foreach (explode(",\n", $matches[1]) as $v) {
$params[] = trim($v, " \t'\"\n\r");
}
$reportUri = preg_replace(
array('/&/', '/=/', '/\?/', '/\//'),
array('%26', '%3D', '%3F', '%2F'),
$params[2]);
$reportUri = str_replace('\x', '%', $reportUri);
curl_setopt($this->curl, CURLOPT_URL,
'https://www.google.com/adsense/report/online-stored-reporttable?storedReportId=' .
$params[0] . '&reportUri=' . $reportUri .
'&formId=' . $params[3] . '&title=' . str_replace('+', '%20', urlencode($params[1])) . '&waitTime0');
$tr = 0;
do {
$content = curl_exec($this->curl);
if (empty($content) or $content === true) {
sleep(1);
if (++$tr > 10) {
echo "Can't get the report data!\n";
die;
}
}
} while (empty($content) or $content === true);
if (preg_match_all('/<tr\s+class="(odd|even)\s+datarow">\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<td[^>]*>(.*?)<\/td>\s*' .
'<\/tr>/si', $content, $matches)) {
$day = 0;
$n = 0;
foreach ($matches[3] as $k => $v) {
if ($day === 0) {
$day = date('Y-m-d', strtotime($matches[2][$k]));
}
if (isset($matches[2][$k - 1]) && $matches[2][$k - 1] != $matches[2][$k]) {
$day = date('Y-m-d', strtotime($matches[2][$k]));
$n = 0;
}
$result[$day][$n]['channel'] = preg_replace('/\s*<[^>]+>\s*/', '', $v);
$result[$day][$n]['impressions'] = $matches[4][$k];
$result[$day][$n]['clicks'] = $matches[5][$k];
$result[$day][$n]['ctr'] = $matches[6][$k];
$result[$day][$n]['ecpm'] = $matches[7][$k];
$result[$day][$n]['earnings'] = $matches[8][$k];
$n++;
}
}
}
return $result;
}
}
$adsense = new AdSense();
if ($adsense->connect($username, $password)) {
$today = $adsense->today();
print '<pre>';
print_r ($adsense->today());
print '<pre>';
} else {
die('Could not login to AdSense account.');
};
?>
The simplest way to to generate QR Codes using Google API
<?php
$urlToEncode="http://www.negraru.com";
generateQRwithGoogle($urlToEncode);
function generateQRwithGoogle($chl,$widhtHeight ='150',$EC_level='L',$margin='0') {
$url = urlencode($url);
echo '<img src="http://chart.apis.google.com/chart?chs='.$widhtHeight.
'x'.$widhtHeight.'&cht=qr&chld='.$EC_level.'|'.$margin.
'&chl='.$chl.'" alt="QR code" widhtHeight="'.$size.
'" widhtHeight="'.$size.'"/>';
}
?>
It looks like Gmail is going down. In the last period of time, my Gmail account (Google Apps) had numerous errors and bugs. This are just couple of errors in the last five minutes:

![]()
![]()
Here is what they have to say:
Monday, August 11, 2008 | 6:05 PM
Posted by Todd Jackson, Gmail Product Manager
Many of you had trouble accessing Gmail for a couple of hours this afternoon, and we're really sorry. The issue was caused by a temporary outage in our contacts system that was preventing Gmail from loading properly. Everything should be back to normal by the time you read this.
We heard loud and clear today how much people care about their Gmail accounts. We followed all the emails to our support team and user group, we fielded phone calls from Google Apps customers and friends, and we saw the many Twitter posts. (We also heard from plenty of Googlers, who use Gmail for company email.) We never take for granted the commitment we've made to running an email service that you can count on.
We've identified the source of this issue and fixed it. In addition, as with all issues that affect Gmail and our other services, we're conducting a full review of what went wrong and moving quickly to update our internal systems and procedures accordingly. We don't usually post about problems like this on our blog, but we wanted to make an exception in this case since so many people were impacted. In general, though, if you spot a problem with your Gmail account, please visit the Gmail Help Center and user group, where the Gmail Guides are your fastest source of updates.
Again, we're sorry.
Open terminal, type
cd /Volumesand then
lsto display all volumes and
cd Time Machine Backupsto go into the Time Machine volume.
ls -ato display all files
sudo rm -rf .Trashes
netstat -alpn | grep :80 | awk '{print $5}' |awk -F: '{print $(NF-1)}' |sort | uniq -c | sort -n
Open Terminal and enter the following command (make sure you have administrative rights)
sudo killall -HUP mDNSResponder
dscacheutil -flushcache
lookupd -flushcache
The following steps will get you an iTunes account without entering your credit card info.
The tcpdump command displays out the headers of packets on a network interface that match the boolean expression. To drop ssh traffic from dumping and monitoring operation using the following syntax:
tcpdump -i eth1 -s 1500 port not 22
# apt-get install libfuse2 # apt-get install ntfs-3g # fdisk -l | grep NTFSsample: /dev/sdb1 1 121601 976760001 7 HPFS/NTFS
# mkdir /media/YOUR-FOLDER # mount -t ntfs-3g /dev/sdb1 /media/YOUR-FOLDERTo auto mount it whenever the system starts, modify the file fstab located in etc in your text editor of choice. Be careful! If you damage this file it will not boot.
# vi /etc/fstaband add the line
/dev/sdb1 /media/YOUR-FOLDER ntfs-3g defaults 0 0Save this, and now every time you boot your machine your ntfs drive will be mounted and ready to use!
The CIRA whois response don't contain 'AVAIL' any longer, all available domain name for registration will contain: 'Domain Status: available'
Please note that you need to add 9 spaces between the colon of 'status:' and the word 'available'
whois.cira.ca|Domain status: available
When updating the Debian based system, apt-get may display an error message like:
W: GPG error: http://download.webmin.com sarge Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY D97A3AE911F63C51
Type the following commands:
gpg --keyserver pgpkeys.mit.edu --recv-key D97A3AE911F63C51 gpg -a --export D97A3AE911F63C51 | sudo apt-key add -
sudo /etc/init.d/apache2 restart Reloading web server config: apache2apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1 for ServerName
sudo gedit /etc/apache2/httpd.confAdd the following line to httpd.conf:
ServerName localhostSave the file and restart the server:
sudo /etc/init.d/apache2 restart
<IfModule mod_expires.c> ExpiresActive On ExpiresDefault "access plus 1 month" ExpiresByType image/x-icon "access plus 1 year” # Images ExpiresByType image/gif "access plus 1 month" ExpiresByType image/png "access plus 1 month" ExpiresByType image/jpg "access plus 1 month" ExpiresByType image/jpeg "access plus 1 month" # CSS ExpiresByType text/css "access 1 month” # Javascript ExpiresByType text/javascript "access plus 1 week" ExpiresByType application/x-javascript "access plus 1 week" ExpiresByType application/javascript "access plus 1 week" </IfModule>
Twitter is very popular since some time now, and you probably already have an account there. What about using cURL to tweet from your server without connectiong to Twitter?
<?php
// Set username and password
$username = 'username';
$password = 'password';
// The message you want to send
$message = 'is twittering from php using curl';
// The twitter API address
$url = 'http://twitter.com/statuses/update.xml';
// Alternative JSON version
// $url = 'http://twitter.com/statuses/update.json';
// Set up and execute the curl process
$curl_handle = curl_init();
curl_setopt($curl_handle, CURLOPT_URL, "$url");
curl_setopt($curl_handle, CURLOPT_CONNECTTIMEOUT, 2);
curl_setopt($curl_handle, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($curl_handle, CURLOPT_POST, 1);
curl_setopt($curl_handle, CURLOPT_POSTFIELDS, "status=$message");
curl_setopt($curl_handle, CURLOPT_USERPWD, "$username:$password");
$buffer = curl_exec($curl_handle);
curl_close($curl_handle);
// check for success or failure
if (empty($buffer)) {
echo 'message';
} else {
echo 'success';
}
?>
This is a very basic thing to do with cURL, but with endless possibilities. Once you have a webpage in a PHP variable, you can for example, retrieve a particular information on the page to use on your own website.
<?php
ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "example.com");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
$output = curl_exec($ch);
curl_close($ch);
?>
Do you ever wanted to know the exact download speed of your webserver (or any other?) If yes, you’ll love that code. You just have to initialize the $url variable with any resources from the webserver (images, pdf, etc), place the file on your server and point your browser to it. The output will be a full report of download speed.
<?php error_reporting(E_ALL | E_STRICT);
// Initialize cURL with given url
$url = 'http://download.bethere.co.uk/images/61859740_3c0c5dbc30_o.jpg';
$ch = curl_init($url);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_USERAGENT, 'Sitepoint Examples (thread 581410; http://www.sitepoint.com/forums/showthread.php?t=581410)');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_CONNECTTIMEOUT, 2);
curl_setopt($ch, CURLOPT_TIMEOUT, 60);
set_time_limit(65);
$execute = curl_exec($ch);
$info = curl_getinfo($ch);
// Time spent downloading, I think
$time = $info['total_time']
- $info['namelookup_time']
- $info['connect_time']
- $info['pretransfer_time']
- $info['starttransfer_time']
- $info['redirect_time'];
// Echo friendly messages
header('Content-Type: text/plain');
printf("Downloaded %d bytes in %0.4f seconds.\n", $info['size_download'], $time);
printf("Which is %0.4f mbps\n", $info['size_download'] * 8 / $time / 1024 / 1024);
printf("CURL said %0.4f mbps\n", $info['speed_download'] * 8 / 1024 / 1024);
echo "\n\ncurl_getinfo() said:\n", str_repeat('-', 31 + strlen($url)), "\n";
foreach ($info as $label => $value)
{
printf("%-30s %s\n", $label, $value);
}
?>
In order to make sure that your website is always available to the public, you have to monitor it. In this tutorial, I'll show you how you can easily create a monitoring script that will check your website availability and send an email or sms alert to you if it isn't.
Maybe I’m stating the obvious, but the PHP script has to be on a different server than the one used for the website you’d like to monitor. If the script is hosted on the same server as your site, then it becomes pretty useless: In fact, if your server is down the script will not be able to run and will not let you know.
The best solution is of course a dedicated server, but a home server can be ok as well. Shared web hosting like those provided by Hostgator or WpWebHost have a low price, but most don’t allow you to set up cron jobs, so be careful if you plan to buy.
Please note that depending on your location and cellular phone provider, this part of the tutorial may not work.
The first part of this tutorial is to create the monitor script. Pick up your favorite text editor and create a file named monitor.php. The script is very simple: we only need two functions, one to test if a specific site is available, and the other to alert you by sending an email.
Paste the following in your monitor.php file:
01.function check($host, $find) {
02. $fp = fsockopen($host, 80, $errno, $errstr, 10);
03. if (!$fp) {
04. echo "$errstr ($errno)\n";
05. } else {
06. $header = "GET / HTTP/1.1\r\n";
07. $header .= "Host: $host\r\n";
08. $header .= "Connection: close\r\n\r\n";
09. fputs($fp, $header);
10. while (!feof($fp)) {
11. $str .= fgets($fp, 1024);
12. }
13. fclose($fp);
14. return (strpos($str, $find) !== false);
15. }
16.}
17.
18.function alert($host) {
19. mail('youremail@gmail.com', 'Monitoring', $host.' down');
20.}
21.
22.$host = 'www.domain.com';
23.$find = 'Domain';
24.if (!check($host, $find)) alert($host);
At this point of the tutorial, we have a working monitoring script, but we have to type http://mymonitoringserver.com/monitor.php in a web browser to check our website, which makes our script almost useless.
The solution to that problem is to create a cron task to make the server execute monitor.php every hour. Open a SSH console to your monitor server and type the following:
* * * * /usr/local/bin/php -q /htdocs/www/monitor.php