It is very easy to count DOM-Elements within a HTML-file by using jquery. Here is a little example:
How To Manually Deactivate A WordPress Plugin
A while ago I installed a WordPress Plugin, which I was using with another installation before. After activating the plugin nothing in my WordPress seemed to work the way it had been working before. Or in other words: all I saw was a white browser-screen 🙁 “So, keep calm…”, I thought to myself. Then I … Read more
PHP: Detect Time Of Last Modification Of A File
Do you need to find out in PHP, when a file was modified? Then you should take a look at the PHP-function filemtime. This function expects a filename as parameter and returns the modification-time of this file.
Here is an example:
< ?php echo filemtime('anyfile.html'); ?> |
This PHP-script will output the timestamp of the last modification of the file anyfile.html.
You can also format this by using the date-function:
Display A HTML-List Horizontally
Normally a HTML-list is displayed vertically, which means that each entry is below the previous entry. But for some reasons you might want to display the list vertically, e.g. for a menubar.
Here is a simple way to do that.
For this example I’ll use the following list:
<ul> <li>Item 1</li> <li>Item 2</li> <li>Item 3</li> </ul> |
The result looks like this:
- Item 1
- Item 2
- Item 3
Now, we add some CSS:
PHP: Output An Associative Array
In this article I’ll show you, how to output each element of an an assciative array in PHP. First of all, we need an associative array. In this example I’ll use an array with colors as the key and the corresponding HEX-code of this color as the value.
Let’s start! Here is the associative PHP array:
// Our associative array $arrMembers = array( 'Red'=>'ff0000', 'Green'=>'00ff00', 'Blue'=>'0000ff', 'Yellow'=>'ffff00' ); |
Basic HTML5 Structure
In this article I’ll show you the basic structure of an HTML5 Document. Look at the following code, which is a very basic example of an HTML5-page. <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title> This Text will be shown as the Browsers Tab Heading </title> </head> <body> Here comes the HTML, which will be … Read more
Checklist For Your First Website
If you start in internet-business, and want to build your first website, there are some things, you should think about before you start.
Especially if you are completely new to website-building. Here is a (uncomplete) checklist with some points to clear before you start building your website.
What Is My IP Address
Sometimes it is very useful to know with which IP address you are surfing on the Internet, e.g. when playing online games, etc. If you also want to know how your current IP public address is – here it is: Without warranty
How To Change The Color Scheme In Aptana Studio
Aptana Studio is a great tool for web-development. It offers you a wide range of features. One of this features is syntax-highlighting of sourcecode, which means that different parts of the sourcecode will be displayed with different colors, which makes it easier to read the sourcecode. However, if you don’t like the default theme with … Read more
How Can I Copy A Line In Eclipse?
Eclipse offers you a lot of shortcuts to work even more effectively. If you want to copy a line of code you can do this by using a simple combination of letters on your keyboard. Just be sure, that your cursor is in the line, which you want to copy. Then press Crtl + Alt … Read more