23 November 2008

Preventing the unsightly yellow highlighting caused by AutoFill

I was asked to prevent the AutoFill feature on the Google Toolbar from highlighting the fields on our website's registration page with yellow. It can be easily switched off, but many users will be unaware of this.

We found one approach to the problem on the Web that involved using JavaScript—far from ideal, and it apparently didn't prevent highlighting of drop down lists. As it turns out, there is an easier way to resolve the issue.

The key is to understand how AutoFill works. It identifies the fields that are highlighted by searching for keywords such as name and email in the source HTML. By eliminating these keywords without changing the appearance of the page we can prevent AutoFill from changing the colour of the input controls on forms.

A simple example of a form with highlighted fields is shown below.

<form action="/" method="post">
  <table>
    <tr>
      <td>Name:</td>
      <td><input type="text" name="name" /></td>
    </tr>
    <tr>
      <td>Email:</td>
      <td><input type="text" name="email" /></td>
    </tr>
  </table>
  <input type="submit" value="Submit" />
</form>

To prevent the yellow highlighting, we must do the following:

  • For displayed text, break the keywords using empty span tags.
  • For keywords in the HTML not displayed to the user, such as attributes, rename them.

These changes fool AutoFill so that the input controls are rendered without the yellow highlighting.

<form action="/" method="post">
  <table>
    <tr>
      <td>Na<span />me:</td>
      <td><input type="text" name="na" /></td>
    </tr>
    <tr>
      <td>Em<span />ail:</td>
      <td><input type="text" name="em" /></td>
    </tr>
  </table>
  <input type="submit" value="Submit" />
</form>

21 November 2008

It won't just be your boss browsing through your records

Those who voted for the ALP in the last federal election believing that they have become the new Third Way force in Australian politics will be disappointed. The Rudd government has produced classic Labor policies, including reducing incentives to participate in the workforce instead of living off welfare, raising taxes on luxury vehicles without considering how the workers employed in this industry would be affected and ISP level Internet filtering—a useless answer to a social problem imposed by government that will fail. Now, they have submitted to union demands that violate your basic rights.


Joe McDonald and Kevin Reynolds, CFMEU officials

Julia Gillard, Minister for Employment and Workplace Relations, is finalising legislation that would give unions unfettered access to the employment records of non-union employees. In response, Michael Keenan, Shadow Minister for Employment and Workplace Relations, said:

Employees should have a right to decide who sees their personal employment records and who does not.

Non Government third parties, such as unions, should not be given any access to an employee’s information, unless the employee has given consent.

Unions are clearly looking for access to employee records to manipulate workers to try and build up their rapidly dying membership bases.

Ms Gillard’s backflips to appease the union movement and the Labor backbench will cost Australians jobs and do untold harm to the Australian economy as we navigate through difficult economic times due to the global financial crisis.

19 November 2008

Rudd's war on everything: the anatomy of political spin

Kevin Rudd's war on everything is one of the less sophisticated examples of his talent for political spin, and it became the source of amusement during question time when Joe Hockey, Shadow Minister for Finance, Competition Policy & Deregulation, asked him about the numerous wars that he has declared since becoming Prime Minister a year ago:

Mr HOCKEY (3.09 pm)—My question is to the Prime Minister. I refer the Prime Minister to his 2007 declared war on drugs, his January 2008 declared war on inflation and yesterday’s declared war on unemployment. I also refer the Prime Minister to the 2007 ‘Rudd’s war on whalers’, the February 2008 ‘A war cabinet to fight disadvantage’, his February 2008 war on downloads, his March 2008 war on pokies, his May war against doping in sport and his October war on bankers’ salary deals. Prime Minister, how goes the war on everything?

Mr Rudd has mastered the usage of keywords to powerful effect. While some voters found Rudd's repetition of phrases such as "education revolution" and "working families" during his 2007 election campaign rather monotonous, others found them inspiring. It might be difficult to accept that merely selecting the right words and using them as frequently as possible with barely any policy detail can win an election, but we must remember that campaigns are designed to appeal to the voters who will determine the outcome of an election, not everybody. A voter might base their decision on little more than 30 seconds of an interview they saw on the 7.30 Report, which they never watch except when changing channels.

A new mantra that Labor has added to their arsenal of spin is "decisive action", which started to become common when the global economic outlook began to deteriorate. It appeared 16 times in the Hansard of the House of Representatives for November 12: 14 instances from Labor MPs, once in a quote from the The Australian, and once by Liberal MP Tony Abbot:

Mr ABBOTT (Warringah) (10.36 am)—It is always a pleasure to follow the member for Werriwa, who is a strong representative of his constituents and is doing his best to defend the government. I have to say that ‘decisive action’ has joined ‘working families’ as the government’s cliche du jour. The fact is: this is belated action, at least insofar as pensioners are concerned, because the opposition has been calling for strong action to help pensioners since very early on in the year when it became clear that prices were skyrocketing, particularly the prices faced by pensioners and others on low incomes.

16 November 2008

Was Rudd's phone leak a slight against Bush?

Prime Minister Kevin Rudd showed his contempt for parliament during question time when Opposition Leader Malcolm Turnbull pressed him for some basic answers on the damaging leak of the exchange between himself and President Bush in which Mr Bush supposedly asked what the G20 was. When asked about apples, Mr Rudd talks about oranges:

Mr TURNBULL (2.34 pm)—My question is addressed to the Prime Minister. I refer the Prime Minister to the account in the Australian on 25 October of a highly confidential telephone conversation between him and the President of the United States, an account which acclaimed the Prime Minister’s diplomatic knowledge as much as it denigrated that of the US President. Given the Prime Minister now says the Australian article was factually wrong, why did he take no steps to correct the record until after the White House took the unprecedented step of expressly rejecting this self-serving story in the Washington Post three days later?
Mr RUDD—I thank the member for Wentworth for his question. The purpose of my call to the President of the United States was to discuss the importance of the G20. The President was fully aware that was what the conversation was about. We supported the decision by the President to host that meeting, which I will be attending over the course of this weekend—on Saturday. It is an important meeting, it is important for the country’s future, and we will be cooperating closely not just with the government of the United States but with other governments on the key challenges on the global agenda, namely, the global financial crisis, global financial regulation and global economic growth. We will get on with the business of conducting what is an appropriate level of policy coordination with our friends and partners. We will do so in the future. It is the right course of action and we have our sleeves rolled up and intend to get on with it.

Source: House of Representatives Official Hansard

Mr Turnbull asked four questions on the matter, and on each occasion Mr Rudd responded with blather that was irrelevant to the question. Evasive answers from politicians are certainly not unheard of, but usually they are relevant. Rudd wastes question time delivering political commentary in an attempt to make his silence on the matter less conspicuous.

It is not beyond the realms of possibility that Bush gave Rudd the impression that he did not share the same enthusiasm for a summit of the G20, which Australia is a member of, and consequently aroused resentment from our narcissistic Prime Minister. Rudd is a man consumed by fantasies of grandiosity and would be highly sensitive to anything that undermines the vision that he has for himself. If Bush preferred to limit discussions of the financial crisis to the more prestigious G8, which would exclude Australia, then it is quite possible that Bush provoked Rudd's vindictive streak and Rudd sought to devalue Bush by leaking aspects of the conversation that would embarrass him and draw more attention to the G20 group of nations.

We have to wonder, incidentally, why Mr Rudd is still referring to Mr Turnbull as the Member for Wentworth, as shown in the transcript above, even though he became Leader of the Opposition two months ago.

26 July 2008

Google Maps beats online Yellow Pages hands down

The Yellow Pages is just one example of a slow moving dinosaur facing extinction because of its failure to adapt to change. While its end might be inevitable, the current design of their website and the search algorithms employed to generate the results will hasten the decline of its use.

In the past I always tried the online Yellow Pages from my mobile first when I'm on the go, only to be left frustrated by all the unnecessary navigation and confusing results that are full of duplicates. Mobile Google Maps, on the other hand, usually gave me the names and locations of the businesses I was seeking effortlessly, and when it didn't, it was because Google's data was not as up to date as that of the Yellow Pages.

Suppose you were looking for a print shop in the Perth CBD, which has a post code of 6000. A map with the contact details of all the relevant businesses in the area is returned instantly after hitting the search button.

When the same search is entered into the Yellow Pages, the user is swamped with a plethora of categories, including Leasing Services &/or Consultants and Video & DVD Production &/or Duplicating Services. It is quite unnecessary to list every conceivable category that can be linked to the keyword in the most obscure of ways. If the user was looking for cheque printing, they can narrow the search by simply entering "cheque printing".

In analysing the requirements of a piece of software, engineers should strive for the least number of features that offer the most functionality. Unfortunately, they tend to give us the most number of features with the least amount of functionality, which benefits neither the customer nor the software maker. The former, however, is actually more difficult and requires more thought.

14 July 2008

Channel 10 shows mercy on Australian viewers: Big Brother to be axed

I don't think Channel 10 should have axed Big Brother; it shouldn't have been aired in the first place. While it satisfied the voyeuristic appetite of some people who were prepared to sit in front of their TV for hours on end just watching people be people, the rest of us were left in awe at the new precedent it set in trash TV. If there is anything on TV that could put you into a vegetative state and eventually send you brain dead, it would have to be Big Brother. At least the test pattern has music.

Unfortunately, we may not have seen the last of this awful show, brought to you courtesy of Endemol Southern Star, as there are plans to sell it to other networks. Hopefully, Channel 10 will fill the vacancy in its schedule with something less asinine.

8 June 2008

Means test devastates solar panel industry and costs jobs

In an extraordinary move, Dean Mighell, Victorian state secretary of the Electrical Trades Union, has written to the Liberal Party expressing his support for their efforts to have the Labor government reverse the means test for solar panel rebates. They have been joined by the Greens in their condemnation of the policy which is devastating the solar panel industry and has resulted in job losses.

The previous Howard government introduced a rebate of up to $8,000 for the installation of solar panels. In the last Budget, the Labor government imposed a means test that restricts the rebate to households earning less than $100,000 a year.

The explanation offered by the Labor government for this monumental act of fiscal foolishness is ludicrous. On ABC radio, Environment Minister Peter Garrett said "This was a program that was very popular, it was a program that was overheating." In reality, we are witnessing a prime example of Labor's economic mismanagement that has resulted in workers losing their livelihoods. Many businesses in the solar panel industry have reported losing up to 80% of their contracts and have had to lay off employees.

Last year when Labor was in opposition, Mr Garrett and Prime Minister Kevin Rudd announced their policy on solar panels on the premises of Solartec Renewables, a family business located near Canberra. Mr Rudd made the following statement:

"We need to boost renewable energies in general. Solar is the most greenhouse-friendly energy available on the planet and, therefore, we just need to take some practical steps to make it possible for as many families as possible to invest in this."

Since the last Budget, the means test has ruined Solartec Renewables. They have lost $500,000 worth of orders and have had to terminate the employment of three of their staff.

Charges dropped against former part-time $630,000 public servant

Jim McGinty, Attorney-General and Health Minister for Western Australia, would be more than satisfied with the decision of Robert Cock, Director of Public Prosecutions, to not prosecute Dr Neale Fong, former Director General of Health.

The appointment of Dr Fong by Mr McGinty to reform WA's troubled health system has been a major embarrassment for the Carpenter government. Despite having to juggle such a demanding position with his commitment as chairman of the WA Football Commission, he was paid $630,000 a year, more than any other public servant in the nation. He set up his own bureaucracy at elite offices on Alvan Street in Subiaco, which costed $450,000 to fit out and $1 million to lease over four years, and wasted taxpayers' money on a string of costly external consultants. Dr Fong resigned in disgrace after the Corruption and Crime Commission (CCC) made adverse findings against him relating to his relationship with lobbyist Brian Burke. A report tabled in Parliament states that Dr Fong:

  • Engaged in serious misconduct by disclosing a restricted matter to Mr Burke, namely that the Commission was investigating a senior Department of Health officer, Mr Michael Moodie.
  • Engaged in misconduct by telling his Minister that he had no recollection of any email communication between himself and Mr Burke and had no personal relationship with Mr Burke while the Commission found evidence to the contrary.
  • Engaged in misconduct by failing to report the disclosure to him by Mr Burke of what Mr Burke claimed to be confidential Cabinet information.

Despite the findings of the CCC and admitting that the prospects of a successful prosecution were good, Mr Cock decided not to pursue charges against Dr Fong. He said that the likely penalty of a $60,000 fine was minor compared to the humiliation he has already suffered because of the investigation. Unfortunately, Dr Fong now sees the decision as a vindication of his actions. At a press conference, he stated "I was always confident that I had not committed an offence and that confidence was supported by my legal advice."

Leader of the state opposition, Troy Buswell, said the move meant there was one law for the rich and one for the poor in Western Australia.

2 June 2008

Labor loses the plot with FuelWatch

Labor has again shown its indifference to small business and is happy to allow large corporations dictate prices. Rudd has chosen to proceed with a national implementation of Western Australia's FuelWatch scheme against the advice given by the following departments:

  • Department of Prime Minister and Cabinet
  • Department of Resources and Energy
  • Department of Finance
  • Department of Industry

They warn of the possibility that the winners will be the large fuel retailers, and the losers the small independent service stations and consumers, which include Labor's "working families".

Treasurer Wayne Swan's response to criticism of the government's decision to ignore the advice of these departments shows that they are rank amateurs in economic management. He stated that they chose to listen to their own "common sense" instead of the "bureaucratic" and "academic" advice of the above four key government departments.

The Regulation Impact Statement (RIS) tabled in Federal Parliament by Assistant Treasurer Chris Bowen clearly states that, as has been demonstrated in Western Australia, the scheme enables fuel retailers with large networks of service stations to employ a strategy of rolling price leaders, putting smaller independent operators at a competitive disadvantage. Ultimately, this could affect motorists with higher fuel prices.

The economic modelling of the analysis released by the Australian Competition and Consumer Commission (ACCC), which the government uses as the foundation for its policy, is highly questionable. Professor Sinclair Davidson from the Institute of Public Affairs (IPA), states that "the ACCC analysis is not convincing," and "the introduction of Coles into petrol retailing totally dominates the effect that the ACCC attributes to FuelWatch." The ACCC has not released the data and has been vague on the econometric techniques used in their analysis. As the Rudd government will soon consider whether to reappoint Graeme Samuel as the chairman of the ACCC when his current term ends on July 31, relying upon the findings of this analysis alone is very naive, but politically this is a convenient option for the government.

3 May 2008

Rudd to axe 70 officers supporting small business

Last year I made a post about Rudd's razor gang that would target Australian government workers. It has come to light that the axe will fall on 70 small business field officers.

Labor has always claimed to be the champion of Aussie battlers – common every day Australians that work hard to make ends meet. Unfortunately, Labor does not hold small business operators in the same esteem, many of whom work staggering hours to stay afloat. In June 2004, of the 1.1 million full-time small business operators:

  • 65.1% usually worked between 35 and 50 hours each week;
  • 30.2% usually worked between 51 and 75 hours each week; and
  • 4.7% usually worked more than 75 hours each week.

Source: Characteristics of Small Business, Australia (Reissue), 2004Australian Bureau of Statistics

This is hardly cutting "fat" in administration so that more can be "delivered to front-line services instead", as Rudd put it before the election. He has made a cut to government services that will directly affect hard working Australians whose businesses employ 3.6 million workers and generate 30% of the nation's economic activity.