/%postname%
Showing posts with label web development. Show all posts
Showing posts with label web development. Show all posts
Make The Post Name As Custom Permalink In Wordpress
I do like to have my permalinks as custom as possible for pretty URLs and for search engine optimization. A personal favorite of mine is using the postname as a permalink. To achieve this, go to the Settings, click Permalinks. On the box that say Custom Structure, enter the code below:
HTML Comments
Inserting a comment in html allows us to easily describe what the code does. It is very useful if you will be handing out the code into a developer so that things get easier when it's the time to work for it. The code below is an example on how insert a comment in html.
<-- css stylesheet reference -->
<link href="css/style.css" rel="stylesheet" />
HTML5 Code Validators
There are two websites that I use for validating code for HTML5. Validating code markup is essential in web development to see if your code is at the web standard level.
http://validator.w3.org
http://validator.nu
http://validator.w3.org
http://validator.nu
Remove WWW in URL through htaccess
I always want to have my website url remove the www in the address so I can have shorter address displayed in the address bar on a web browser and at the same time save keystrokes in typing a URL. Example, I have the website http://www.abc123.com I will just want to have http://abc123.com instead. Just insert the code below in your .htaccess file and you will be able to remove the obvious www in every website address.
RewriteEngine On
RewriteCond %{HTTP_HOST} !^your-site.com$ [NC]
RewriteRule ^(.*)$ http://your-site.com/$1 [L,R=301]
HTML5 Doctype
HTML5 simplified the doctype with a much shorter and easier to remember code markup .
<!doctype html>
That's it! It's the new doctype for the new version of HTML. If you're using HTML5 now, this may not be new to you already.
How to login to MySQL through command line
A simple and fast way (non-graphical) to login to MySQL using a one liner command.
You will prompted to type in the password. Type the password and you're good to go.
mysql -h localhost -u root -p
You will prompted to type in the password. Type the password and you're good to go.
Subscribe to:
Posts (Atom)