-
▼
2013
(302)
-
▼
July
(27)
- How to Install Mega Menu in WordPress
- How to Upload Camtasia to WordPress
- How to Login to WordPress.com
- How to Insert an Image Caption URL on WordPress
- How to Create Feedburner Email Box in WordPress
- How to Change the Title of an RSS Feed in WordPress
- How to Make Your Own Wordpress Blog
- How to Change the Post Order in WordPress
- How to Embed an Image in a Default Theme of a Word...
- How to Install Wordpress on Your GoDaddy Hosting A...
- How to Put a Song in a WordPress Blog Post
- How to Create a Folder on the Root Folder of a Wor...
- How to Install WordPress Outside Document Root
- How to Fix a WordPress Database Without Plugins
- How to Add PDF Forms to a WordPress Site
- How to Use PHP Includes in WordPress Posts
- How to Change a Title Subtitle in WordPress
- How to Add a Copyright to Your Wordpress Blog
- How to Increase an Indent in HTML on WordPress
- How to Edit Header Height in WordPress
- How to Increase My Download Size for WordPress
- How to Add a Scrollbar Section to My WordPress Blog
- How to Add a 404 to a Wordpress Template
- How to Add Widgets to Wordpress
- How to Change Old WordPress Tags
- How to Add Links to a WordPress Blog
- How to Install WordPress in Its Own Directory in W...
-
▼
July
(27)
adsense
How to Embed an Image in a Default Theme of a WordPress Blog Page
1. Log in to the WordPress dashboard from the 'wp-admin' directory of your website. Navigate to 'Appearance' from the left-hand menu.
2. Check that the default theme is listed under 'Current Theme.' Depending on your version of WordPress, the name of your default theme is the year of its release spelled out into words like 'Twenty Ten' or 'Twenty Eleven.' Look for the theme under 'Available Themes' if it is not your current theme, and click the 'Activate' link.
3. Click the 'Editor' link to load the 'Edit Themes' screen. Open a template file for the theme by clicking its link under the 'Templates' header. For example, to embed an image in the blog's index, load 'loop.php' into the editor.
4. Add the HTML code for your image first. Here is an example:
Replace 'images/mypic.png' with the path and file name of your image that you want to embed. Change 'My Pic' to the alternative text that you want to display when the image fails to load. Screen readers for the blind also use this text, so make your alternative text useful.
5. Convert the file path to your image to a path that WordPress can use. Use the template tag 'bloginfo()' in the file path to make this work. Give 'bloginfo()' a value of 'template_directory' so the tag loads the full path to the template's directory on your server. Here is the code:
/images/mypic.png' alt='My Pic' />No matter where you install WordPress or name your theme directory, 'bloginfo('template_directory');' will find the correct path. Because 'images' is a directory under the main directory of the theme, WordPress can now find your image.
6. Click the blue 'Update File' button when you finish embedding your image. No matter how you change your content in a page or post, this image will still appear on the pages or posts that use the template you just edited.
1:47 AM | Filed Under | 0 Comments
Comments
Popular Posts
-
1. Log in to your Weebly account. 2. Click 'Theme Editor.' 3. Click on the 'Design' tab. 4. Select 'Edit CSS/HTM...
-
1. Sign up for a publisher account at Bidvertiser. Submit basic contact information and confirm your email address to get started. 2. Lo...
-
1. Log in to your WordPress dashboard. 2. Open the 'Appearance' section on the left side of the WordPress dashboard and then cli...
-
Facebook Widget 1. Create a Facebook fan page for your blog, if you don't already have one. You will have to manually share content wi...
-
1. Open your WordPress Dashboard in your preferred browser. It is accessed at the '/wp-admin' location of your site. For example, ...
-
1. Download and install the WordPress for BlackBerry app via BlackBerry App World. Download the version that corresponds with your BlackBe...
-
1. Go to your WordPress blog's administrative control panel. 2. Click the 'Settings' button on the left-side navigation menu...
-
1. Click the 'Add Contact' button on the 'Add New Post' page. This opens the 'Add a Contact Form' page. 2. Click...
-
1. Register an account with Amazon Web Services Cloud. If you have an existing Amazon account, enter your email address in the appropriate...
-
1. Log into your WordPress.com account using your user name and password. 2. Hover your cursor over the 'My Blogs' tab at the to...
Post a Comment