Tech Sharing Blog

Computer knowledge, news, product, SEO, earn money online sharing place

Advertisement

Archive for the ‘ Tips ’ Category

livescore logo Get the latest sport result for all the major league in the world.


Livescore is a site dedicate for sport lovers who want to get the up to date sport result range from soccer, hockey, basketball, tennis to cricket.


I’m not really sure the accuracy of other sport as most of the time i’m only focus on the soccer. The result show on the livescore.com is almost live if compare with the ESPN channel.


Livescore.com is not only available for web user, they also have the iPhone version and WAP version where you may access through your mobile devices to keep your self update on your favorites sport result.


When you on the livescore.com home page, you may get the latest game result just infront of you. By clicking on the score link on the game, you may get the goal scoring time and scorer name.


Hopefully for those sport lovers, you may still get your favorites result while you are away from the TV.

 

livescore home page Get the latest sport result for all the major league in the world.

Livescore.com home page with the latest match on the home page

manchester vs arsenal result Get the latest sport result for all the major league in the world.

Match detail including goal scorer, time and card given out


Popularity: 1% [?]

SQL Server Do’s And Dont’s

By on August 29, 2009

data SQL Server Dos And DontsSo, you are now the leader of a SQL Server based project and this is your first one, perhaps migrating from Access. Or maybe you have performance problems with your SQL Server and don’t know what to do next. Or maybe you simply want to know of some design guidelines for solutions using SQL Server and designing Database Access Layers (DAL): this article is for you.



Even if you are not using SQL Server, most of these design guidelines apply to other DBMS, too: Sybase is a very similar environment for the programmer, and Oracle designs may benefit from this too. I won’t show here how to use specific T-SQL tricks, nor won’t give you miracle solutions for your SQL Server problem. This is by no means a complete, closed issue. What I intend to do is give you some advices for a sound design, with lessons learned through the last years of my life, seeing the same design errors being done again and again.

 

Do know your tools

Please, don’t underestimate this tip. This is the best of all of those you’ll see in this article. You’d be surprised of how many SQL Server programmers don’t even know all T-SQL commands and all of those effective tools SQL Server has.

 

“What? I need to spend a month learning all those SQL commands I’ll never use???” you might say. No, you don’t need to. But spend a weekend at MSDN and browse through all T-SQL commands: the mission here is to learn a lot of what can and what can’t be done. And, in the future, when designing a query, you’ll remember “Hey, there’s this command that does exactly what I need”, and then you’ll refer again to MSDN to see its exact syntax.

 

In this article I’ll assume that you already know the T-SQL syntax or can find about it on MSDN.

  [More]

Popularity: 1% [?]

Most of the developer who working in MS platform will be used to the javascript window.attachEvent.


But maybe some of you don’t know that window.attachEvent is only working on IE7+ and Opera only. Your coding will hit an javascrpit error when running at IE 6 or any version of firefox.


To resolve this issue, you may need to modify your code as such:

Original Code:

window.attachEvent(“onload”, Page_load);

function Page_load(){
//function code
}


Modify code:

//set page event handlers
if (window.attachEvent) {

//IE and Opera
window.attachEvent(“onload”, Page_load);

} else if (window.addEventListener) {

// IE 6
window.addEventListener(“load”, Page_Unload, false);

} else {

//FireFox
document.addEventListener(“load”, Page_Unload, false);

}

function Page_load(){

//function code

}


Popularity: 1% [?]

Submit your site to Bing.com

By on June 20, 2009

bing icon Submit your site to Bing.comAfter few years of search engine being monopoly by Google, Microsoft has announced their new counter weapons toward Google – called Bing.com


This is just a begining for the search engine war. Now come to another part of the new search engine where all the webmaster or the blog owner should do – get your site to index by the new search engine and gain the traffic from Bing


Click here to submit your website to Bing and get’s index by Bing, so that your website can be found.


Besides that, Bing also has the webmaster tools like the Google webmaster tools. Click here to create a web master center account to submit your site and get index and explore to the search engine faster



bing home page Submit your site to Bing.com

Bing home page

Popularity: 2% [?]

Advance SQL Injection

By on June 17, 2009

sqlinjection Advance SQL InjectionThere are a lot of web site attacking method now a days, one of the most attacking method that we can easily found is the SQL Injection.


First of all, before you know about the SQL Injection, you may need to know what is SQL. Structured Query Language (‘SQL’) is a textual language used to interact with relational databases.


There are many varieties of SQL; most dialects that are in common use at the moment are loosely based around SQL-92, the most recent ANSI standard. The typical unit of execution of SQL is the ‘query’, which is a collection of statements that typically return a single ‘result set’. SQL statements can modify the structure of databases (using Data Definition Language statements, or ‘DDL’) and manipulate the contents of databases (using Data Manipulation Language statements, or ‘DML’). In this paper, we will be specifically discussing Transact-SQL, the dialect of SQL used by Microsoft SQL Server.


SQL Injection occurs when an attacker is able to insert a series of SQL statement into a ‘query’ by manipulating data input into an application.


The attacker may use the try and error method to study the database table structure and may inject the statement either to read, delete, edit your data in database or more  dangerous is they may take control ovre your database server.


The following PDF file explain the SQL injection in more detail, you may download, study and understanding the most common SQL Injection technique use by the attacker.


Advance SQL Injection (232)


Popularity: 1% [?]

There is always the good way to prevent and verify the using enter data, especially for each text box or text area.


The following is script use the event object to check on the key code that the user enter, return false to prevent user to enter.


Disabled space to be enter in javascript

onKeypress=”if (event.keyCode == 32) event.returnValue = false;”


Sample:


Only allow number and . to be enter in javascript

onkeypress=”if (event.keyCode < 47 || event.keyCode /> 57) event.returnValue = false;”


Sample:

Popularity: 1% [?]

Trim a string in Javascript

By on June 13, 2009


Trim is a good features when you try to delete the space at the left most, right most or both the left most and right most of the string. The following trim function is ultilize the javascript Regular expression for the trim function


Left Trim

function ltrim(str){

    return str.replace(/^\s+/, ”);

}


Right Trim

function rtrim(str) {

    return str.replace(/\s+$/, ”);

}


All trim

function alltrim(str) {

    return str.replace(/^\s+|\s+$/g, ”);

}


Popularity: 1% [?]

database symbol Convert varchar into math calculationI try to google, call, msn my friend to find out the solution when I stay back in my office until late night yesterday. But still no luck after few hours of trying.


Thinking of gave up when back to office this morning, but one of my friend suddently send me the solution via MSN. That’s the best present I received by today. I’m not sure how many people will looking for this kind of solution, but any way, will post here to share with all and you may take it if you need it.


Basically the idea is that you put all your select, update or delete statment into the variable and use the execute command to execute the whole variable.

My problem:

I have a formula store in a table which is A+B*C+D. My A = 1, B=2, C=3, D=4.


I managed to replace all my variable with the integer using cursor (This maybe not a good solution, but this is not the main discussion in this post)


The finally answer I get is 1+2*3+4. But the bad thing is in the varchar datatype. I only manage to disply 1+2*3+4 but not the answer of 11.


The solution as below:


Declare @MathFomula Varchar(100)

Set @MathFormula = ’1+2*3+4′

Exec(‘SELECT ‘ + @MathFormula  + ‘ AS Result’


Output: 11


* Remember that * and / will calculate at first before + and -


execute math in sql Convert varchar into math calculation


Popularity: 3% [?]

Window Run Command

By on May 22, 2009

I believe most of the advance computer user will know how to ultilize the window run command. But for the normal user may not ultilized it but more prefer to click by mouse.

runcommandwindow Window Run Command

The most common use command is [cmd] and also [notepad]. By using the window run command, you may just press on [Window Key] + [R] on your keyboard and type the command.


The following are some of the window run command that you may or may not use, but I suggest if possible try to remember the most common use which will help you to save your time and also reduce the movement of your hand.


Accessibility Controls
access.cpl


Add Hardware Wizard
hdwwiz.cpl


Add/Remove Programs
appwiz.cpl


Administrative Tools
control admintools


Automatic Updates
wuaucpl.cpl


Bluetooth Transfer Wizard
fsquirt


Calculator
calc


Certificate Manager
certmgr.msc


Character Map
charmap


Check Disk Utility
chkdsk


Clipboard Viewer
clipbrd


Command Prompt
cmd


Component Services
dcomcnfg


Computer Management
compmgmt.msc


Date and Time Properties
timedate.cpl


DDE Shares
ddeshare


Device Manager
devmgmt.msc


Direct X Control Panel (If Installed)*
directx.cpl


Direct X Troubleshooter
dxdiag


Disk Cleanup Utility
cleanmgr


Disk Defragment
dfrg.msc


Disk Management
diskmgmt.msc


[More]

Popularity: 1% [?]

google labs logo Google search features in GmailThe most recent addition to Gmail Labs is a feature that lets you quickly add Google search results to a message. Instead of opening a new tab, typing the query and copying the results, you can now search directly from Gmail. The box that shows up lets you copy the results or just the web addresses, but you can also drag the links to your message.



google search features in gmail 1 Google search features in Gmail

Google search result pop up box in Gmail


send the google search result in gmail with few clicks Google search features in Gmail

Send the Google Search result in Gmail with few clicks

[More]

Popularity: 1% [?]

SEO Powered by Platinum SEO from Techblissonline