Development
HTML and XHTML
Feb 14th
Do you know what difference between HTML and XHTML? And how it difference?
HTML is HyperText Markup Language and XHTML is eXtend HyperText Markup Language. From the name we can know XHTML is newer than HTML and have something added.
HTML 3.2, HTML 4.0 and HTML 4.0.1 is Original Markup language that have flexible syntax but difficult to parse by program. Why? because HTML tag syntax is
HTML TAG USAGE:
<{command} [attribute[="..."] [attribute[="..."] [...]]]>[...</{command}>]
Are you see what make it difficult? … Yes it is tag and attribute like e.g. <img> <br> or <hr>.
HTML TAG USAGE:
<{command} [attribute[="..."] [attribute[="..."] [...]]]>[...</{command}>]
*** problem part is hilighting
HTML tag below start without close tag because it not need to have. But it make browser or another program hard to parse to use (Microsoft try to automatic fill it before display). but in XHTML, it based on XML. What it’s mean? It mean HTML tag must have end tag or use single tag style. It syntax be
XHTML TAG USAGE:
(<{command} [attribute="" [attribute=""[...]]]>…|<{command} [attribute="" [attribute="" [...]]]/>)
It make you must close all your open tag else use single tag. However if you not use it in strictly mode you also use it like HTML.
Not only “Tag” that make it difference. If I have more time, I’ll talk to that topic again
Welcome to Dynamic HTML tips.
Feb 14th
This is my collection of my experience over 8 years in web developing. Since I’m newbie to now I used too many develop tools and language. But here I’ll focus on Web Application at Client Site only. Such as HTML, XHTML, JavaScript and CSS Style Sheet.
HTML and XHTML, It’s same but difference. My tips will suggest the easier way to use it with text editor.
JavaScript, The Scripting language that provide dynamic to your site. Not all command that support on the browser.
CSS Style Sheet, The easiest way to make web site theme without fix code, its make your web site easy to change theme.
I’ll post it early soon.
the overlook function
Feb 10th
I used to talk about font encoding, I used header() to solve it. Today I found another function to convert the encoding, It’s iconv().
When I finding for encoding converter. I proof reading all and pass the unknown and unrelated topic. iconv is one of it. Because I think it be the function about “icon” … yes icon, an images link/reference to any program or function.
Iconv is the standard programming interface for converting character strings from one character encoding to another in Unix-like operating systems.
In php it’s so easy to use like this
$utf8_string = iconv(“TIS-620″, “UTF-8″, $tis620_string);
Is it easy?
dojo – the javascript toolkit
Feb 6th
Ummm too many times ago. I try to write and javascript by myself. today my boss said “Why dont you try dojo toolkit for you ajax or javascript?”
I ask him for dojo like “what dojo is?” or “how its better than specific javascript?” because i think “Ajax is so easy and javascript i’m not newbie”
The first time of its demo. It attack my ego. Its great tool that provide beautiful web object, ajax and another. I don’t know how can it work. Or how difficult is it for specific perpose.
but I know one, Its demo is too excellence.
Python GUI with wxPython
Feb 3rd
Since my project at company require to use python, 2 or 3 week ago. I must find something to create GUI for client. After talk to cwt. He suggest me to use farpy GUIE and boa constructor. twice require wxPython (It’s wxPython GUIE)
first i try farpy GUIE:
User friendly, Multilanguage generator (Python, Ruby, Perl) but it have some problem about object render (panel object is cover other object) and it have too few wx object
then boa constructor:
When open this program i think “Am I use Borland Delphi?”. Its interface like that. have too many wx object too use, property and argument configable but it panel is difficult to make understand, user interface not friendly like farpy GUIE, hard to configure attribute/property with its panel, syntax balloon have too many property/function (may it gain all property of all object to display)
i try to use farpy but it did not have enough object and some graphics render problem so i change to use BOA. but it not easy i must try to download/install wxPython too many times, because i think my problem is confilct between wxPython and BOA . but it is wxPython 2.8 that i download is too new for boa 0.44 (that i download from its website)
you should download boa lastest version from CVS if you want to use lastest version of wxPython
so i try to create pythonApp in boa and create blank frame and run … it not work
If you want to create wxFrame in boa by easy. Don’t create “pythonApp” try “wx.App” or “wx.Frame” to auto generate python&wx code
i solve this problem with copy generated code to another python IDE (like pydev on eclipse). Please do not do like me !!!
*** Hey i try to post this blog last night but i cannot access it. It have some problem twice Febuary 1st and 2nd night. Hope it not be tonight too. ***
HTTP Header
Feb 2nd
on my testing web. I try to use AJAX on my site and found some error if i use non unicode. may be my page encoding or somethings wrong behind the protocol.
so i try to use UTF-8 for this problem. So i found another problem to solve!!!
i put this line on my HTML
<meta http-equiv=Content-Type content="text/html; charset=UTF-8"/>
it found, but not set my page to UTF-8 as set!! (You can check with page info in firefox)
after search in too many site i found something.
My web server was set default charset/encoding to ISO8859-11 / TIS-620 / WIndows-874/ CP874 (Thai)
so i have only two choice to do. Change web server setting or customize http header
I’ll not talk to change default web server configuration for charset/encoding so i will talk about how to customize http header
php: use command header() to set content-type like this
header(“Content-Type: text/html; charset=UTF-8;”);
jsp: you usually use this in your code
<%@ page language="java" contentType="text/html; charset=UTF-8" %>
so on another programming language must have its own way to do something like this
