Wednesday, June 20, 2012

Joomla mobile template

Some Joomla templates support mobile devices. It's the easiest way to create a mobile template for Joomla.


But if you built a template, you can use some extension to present your website on various mobile device types. Mobile Joomla might be one of the first plug-ins recommendations.

You can read this article to know more about Joomla mobile solution.

For concepts of mobile template,  read this article may be helpful for you, too.

Google Sites Html Box


Experiments

The HTML Box will not allow all code, e.g. you cannot make calls to external JavaScript files, but you can use JavaScript embedded on the page.

The HTML box is not the answer to free-reign scripting. You can use more HTML, CSS, Javascript, and jQuery, but you cannot use all of it.

I did notice that the HTML box isn't an iframe like gadgets, so I think that creates room for interesting use of embedding code on your pages. I've had quite an interest in Google Analytics with Google Sites for event tracking.

For how to insert HTML box into your site, please see:
http://support.google.com/sites/bin/answer.py?hl=en&answer=2500646

Thursday, June 14, 2012

10 useful api providers


Today we had 10 new APIs added to our API directory including a Latin America travel site, IP location and information service, biochemical system simulation service, mobile location serviceonline and mobile payment service, digital media streaming service, weather data service and telephone spammer database. Below is more details on each of these new APIs.
CopasiWSCopasiWS API: CopasiWS is a suite of APIs based on COPASI software for simulating biochemical systems. In addition to converting and validating files for use, users can find the steady state of a dynamic system or determine a system's trajectory. One API quantifies the effects of reaction rates on chemical concentrations, while others calculate the sensitivities of biochemical models and their responses to parameter changes. All CopasiWS APIs make use of the SOAP protocol.
DespegarDespegar API: Despegar is a travel agency specializing in Latin American destinations. Visitors to the site can search for hotels, flights and more and find the lowest prices. The API provides access to the data stored by Despegar. Data includes availability of accommodations, hotels, booking, airports, currencies and more. The API uses RESTful calls and responses are formatted in JSON.
GeoIPsGeoIPs API: GeoIPs.com is an application that offers users IP tracking data, web tools and geographic resources. The service lets users identify IP addresses in real-time. The API lets users trace their website visitors by providing their geographic location and IP related information. Developers can integrate the data with their own sites and applicatilns. The API uses RESTful calls and responses are formatted in XML and JSON.
Golm Metabalome DatabaseGolm Metabalome Database API: The Golm Metabolome Database (GMD) offers a collection of APIs that provide programmatic access to the GMD's search functions. These APIs allow users to search for metabolites by inputting GC-MS spectral data consisting of a retention index and mass intensity ratios. Metabolites that don't yet have reference mass spectra included in the GMD can be characterized by the predicted presence or absence of functional groups. There is also a search API specific to the GoBioSpace database, which is part of the GMD. The GMD APIs operate over SOAP, GET, and POST protocols.
GSMA OneAPI Zonal PresenceGSMA OneAPI Zonal Presence API: The GSMA is an association of mobile operators worldwide. Representing more than 800 mobile operators in more than 220 countries, the GSMA supports the standardizing, deployment and promotion of the GSM mobile telephone system. The GSMA also produces industry-leading events such as the Mobile World Congress and Mobile Asia Expo.
The GSMA OneAPI is a set of APIs that expose network capabilities over HTTP. The OneAPI Zonal Presence interface allows a Web application to query a ‘Zone’. A zone is a cluster of one or more Femtocells to which end user phones may be connected. With the Zonal Presence API you can determine the number of users in a zone, be notified of entries to/exits from the Zone, and the user path taken through the Femtocells in a Zone.
HUSAR Bioinformatics LabHUSAR Bioinformatics Lab API: The HUSAR Bioinformatics Lab at DKFZ provides a large number of freely available APIs. Many of these are useful in aligning DNA, RNA, or protein sequences. Alignments can be pairwise or multiple, local or global. Some of the APIs help visualize sequences or alignment results. Others edit biological sequences to make them more comprehensible to researchers.
One large group of APIs is dedicated specifically to working with nucleic acid sequences. Some analyze sequence composition or codon usage, while others locate specific genes, motifs, or CpG islands within a sequence. One group of these APIs focuses on translating DNA sequences to proteins and vice versa. A handful of others focus on working with sequence profiles. Still more look for primers, repeats, restriction sites, or transcription factors. A few others allow the user to play with sequence mutations.
Yet another group of APIs works exclusively with proteins. A few APIs in this category focus on identification and profiling. There are some that assess secondary and tertiary structure, while others focus on determining protein composition and motifs. A couple are designed to simulate mutations in proteins.
A handful of miscellaneous APIs provide background information on sequences, alignment methods, available databases, and other relevant subjects. One simply returns the current EMBOSS version number.
All of HUSAR's services are based on EMBOSS freeware and possess their own individual WSDL endpoints.
LevelUpLevelUp API: LevelUp is an online and mobile payment service. Users can set up their own QR code that allows them to pay various merchants via scanning the QR code. LevelUp also offers users savings when paying with the LevelUp application. Merchants can integrate the LevelUp system with their point-of-sale systems to accept LevelUp payments for goods and services.
The LevelUp API allows developers to access and integrate the functionality of LevelUp with other applications, such as point-of-sale systems and to create new applications. Some example API methods include accepting online payments, accepting mobile payments, and retrieving reporting information. Interested developers should sign up here: https://docs.google.com/spreadsheet/viewform?formkey=dEJOVkZTcU81cTYtVC1rWFNubFRQMXc6MQ#gid=0.
RokuRoku API: The service streams video from affiliated providers via wireless or wired network connections to television sets and other video display devices. Applications can establish public or private channels, paid or free of charge, to provide media content to end-user devices. The provider's SDK supports creation of code that, when uploaded to the service, will retrieve and display media resources.
API methods support detection of device models, authentication of end users and account management, control of user interactions with the platform, and grouping of categories, episodes, etc. with navigation to desired content. Methods also support handling of media resources, including specification of playback formats and streaming from designated sources.
Tenki WeatherTenki Weather API: Tenki is the website of the Japan Weather Association. The Tenki API provides users with weather information such as the forecast, UV and pollen information, umbrella index and more. This data can be integrated with a user's web site or application. The API uses RESTful calls and responses are formatted in XML and JSON.
VemringdeVemringde API: Vemringde is a service that lists phone numbers from unwanted callers. With the vemringde.se API, users can search for information about issues in the database and use it in their own applications. An example use would be to help to block sales calls on an IP phone or mobile phone. The API consists of two parts, the List API lists the most common numbers on vemringde.se. The Search API provides information about any number in the database, it works much like a normal number lookup. The API uses RESTful calls and responses are formatted in XML, JSON, Text and Vcard.

Solr: building a real-time recommendation engine

Searching text is what Solr is known for, but did you know that many companies receive an equal or greater business impact through implementing a recommendation engine in addition to their text search capabilities? With a few tweaks, Solr (or Lucene) can also serve as a full featured recommendation engine. Machine learning libraries like Apache Mahout provide excellent behavior-based, off-line recommendation algorithms, but what if you want more control? This talk will demonstrate how to effectively utilize Solr to perform collaborative filtering (users who liked this also liked…), categorical classification and subsequent hierarchical-based recommendations, as well as related-concept extraction and concept based recommendations. Sound difficult? It’s not. Come learn step-by-step how to create a powerful real-time recommendation engine using Apache Solr and see some real-world examples of some of these strategies in action.


Read more at:
http://java.dzone.com/articles/building-real-time-solr?utm_source=feedburner&utm_medium=feed&utm_campaign=Feed%3A+javalobby%2Ffrontpage+%28Javalobby+%2F+Java+Zone%29

Joomla! 2.5: overwrite category blog layout template

Rule to overwrite a view of a component:
1. Add a copy of the component view file to the folder of your template with the following rule structure:
templates/TEMPLATE_NAME/html/EXTENSION_NAME/VIEW_NAME/FILE_NAME.php

2. After that modify it in your way.

To overwrite category blog layout (view): let copy and modify the files below:
-templates/[template name]/html/com_content/category/blog.php: present structure layout options (see meaning of Layout Options at the bottom)
-templates/[template name]/html/com_content/category/blog_item.php: present an item (article) in the blog layout

Layout Options:
# Leading Articles -> This refers to the number of articles that are to be shown to the full width
# Intro Articles -> This refers to the number of articles that are not to be shown to full width
# Columns -> This refers to the number of columns in which the articles will be shown that are identified as #Intro. If #Intro is zero this setting has no effect
# Links -> Number of articles that are to be shown as links. The number of articles should exceed #leading + #Intro

More ref:
http://docs.joomla.org/How_to_override_the_output_from_the_Joomla!_core
http://kiteplans.info/2012/04/18/how-to-joomla-1-7-2-5-full-text-in-category-blog-layout-template-override/
http://forum.joomla.org/viewtopic.php?f=619&t=615539
http://docs.joomla.org/Understanding_Output_Overrides
http://construct-framework.com/intermediate/creating-a-core-output-override-in-construct-unified-for-joomla-16-and-molajo
http://docs.joomla.org/Layout_Overrides_in_Joomla_1.6
http://forum.joomla.org/viewtopic.php?t=677301

Sunday, June 10, 2012

CSS: full screen background

Use background-size property, for example:

body{
padding:0px;
margin:0px;
position: relative;
height: 100%;
width: 100%;
background-image:url('images/background.png');
background-repeat: no-repeat;
background-position: center center;
background-size: cover;
-webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
font-family: arial,helvetica,sans-serif;
}

CSS: What does !important mean?

The !important rule is a way to make your CSS cascade but also have the rules you feel are most crucial always be applied. A rule that has the !important property will always be applied no matter where that rule appears in the CSS document. So if you wanted to make sure that a property always applied, you would add the !important property to the tag.


However, the !important rule was also put in place to help Web page users cope with style sheets that might make pages difficult for them to use or read. Typically, if a user defines a style sheet to view Web pages with, that style sheet will be over-ruled by the Web page author's style sheet. But if the user marks a style as !important, that style will overrule the Web page author's style sheet, even if the author marks their rule as !important.
This is a change from CSS1 to CSS2. In CSS1, author !important rules took precedence over user !important rules. CSS2 changed this to make the user's style sheet have precedence.

Saturday, June 2, 2012

Fix wamp httpd msvcr100.dll not found

Download MS VC++ redistributable package:
https://www.microsoft.com/en-us/download/details.aspx?id=5555

Friday, June 1, 2012

phymyadmin: prevent root login

Add the line:
$cfg['Servers'][$i]['AllowRoot'] = false;
into config.inc.php file, after this line:
$cfg['Servers'][$i]['auth_type'] = ‘cookie’;

Check user browser to switch css

Use global variable: HTTP_USER_AGENT

<?php if(strstr(strtolower($_SERVER['HTTP_USER_AGENT']), 'mobile') || strstr(strtolower($_SERVER['HTTP_USER_AGENT']), 'android')) : ?>
    <!-- your specific css here -->
<?php endif; ?>
Subscribe to RSS Feed Follow me on Twitter!