Nexus Theme: Changed Line Height for Bullets in Widgets

This code finally did it (again in Custom CSS):

.widget li, .footer-widget li { line-height: 16px; }
.widget li:before, .footer-widget li:before {  border-width: 5px; content: ""; left: 0; position: absolute; top: 16px; }

The “before” item handles the location of the bullet. Otherwise, alignment between the bullet and the text of off.

Posted in Wordpress | Tagged , , , | Comments Off on Nexus Theme: Changed Line Height for Bullets in Widgets

Nexus Theme: Added Pinterest to Social Buttons

Created two 24×19 images of the Pinterest “P” one gray and one white (for hover).

Added the following code to Custom CSS

#et-social-icons {
width: 256px;
}
/* Sets the hover background color for the button */
#et-social-icons .pinterest a:hover { background: #cb2028; }
/* Sets the "normal" image */
#et-social-icons .pinterest .et-social-normal {
background: url(https://all-offroad.com/main/wp-content/uploads/2014/02/Pinterest.png) no-repeat 19px 22px;}
/* Sets the hover image */
#et-social-icons .pinterest .et-social-hover {
background: url("http://all-offroad.com/main/wp-content/uploads/2014/02/Pinterest-hover.png") no-repeat scroll 9px 20px; background-size: 30px; }

Added the following code to header.php, placed it between the RSS and G+ buttons:

<li class="pinterest">
<a href="http://www.pinterest.com/alloffroad/">
<span class="et-social-normal"><?php esc_html_e( 'Follow Us On Pinterest', 'Nexus' ); ?></span>
<span class="et-social-hover"></span>
</a>
</li>
Posted in Wordpress | Tagged , , , | Comments Off on Nexus Theme: Added Pinterest to Social Buttons

Nexus Theme: Modifications to Home Page

Reduced Headline size by adding:

.et-description h2 {font-size:28px !important;}

to Custom CSS in General Settings

Reduced leading in Excerpt text by adding:

.recent-post p {line-height: 20px;!important;}

to Custom CSS in General Settings

Changed the length of the excerpt by making the following modification to recent_module.php:

Replaced

<p><?php et_nexus_truncate_post( 77 ); ?></p>

with

<p><?php et_nexus_truncate_post( 150 ); ?></p>
Posted in Wordpress | Tagged , , , , | Comments Off on Nexus Theme: Modifications to Home Page

Optimal Image Sizes

Nexus Theme:

  • For featured slider (at least): 582×520
  • For thumbnails (at least): 160×160
  • For header images (at least): 1400×400
Posted in Wordpress | Tagged , , | Comments Off on Optimal Image Sizes

Remove Ellipses (…) from Post Title

Open the file defaultcat.php and search for this line:

<h2><a href="<?php the_permalink() ?>" title="<?php printf(esc_attr__('Permanent Link to %s','eNews'), get_the_title()) ?>"><?php truncate_title(37); ?></a></h2>

Replace it by this:

<h2><a href="<?php the_permalink() ?>" title="<?php printf(esc_attr__('Permanent Link to %s','eNews'), get_the_title()) ?>"><?php the_title(); ?></a></h2>
Posted in Wordpress | Tagged , , , , | Comments Off on Remove Ellipses (…) from Post Title

Background Image Behind Header

Please go to Epanel > General and at the bottom of that , you will see Custom CSS box. Please put this code there

#header {background:url('https://image.png') !important;}
Posted in Wordpress | Tagged , , , , | Comments Off on Background Image Behind Header

Using Git for DNS and DHCP Config Files

# sudo yum install git-core
# git init
Initialized empty Git repository in /.git/
# git add /var/named/chroot/var/named/zones/*
# git commit -m 'Added DNS zone files'
[master (root-commit) a8418bf] Added DNS zone files
Committer: root <root@liminf03.motion.com>
Your name and email address were configured automatically based
on your username and hostname. Please check that they are accurate.
You can suppress this message by setting them explicitly:

git config –global user.name “Your Name”
git config –global user.email you@example.com

After doing this, you may fix the identity used for this commit with:

git commit –amend –reset-author

3 files changed, 160 insertions(+)
create mode 100644 var/named/chroot/var/named/zones/internal/10.1.10.zone
create mode 100644 var/named/chroot/var/named/zones/internal/motion.com.zone
create mode 100644 var/named/chroot/var/named/zones/named.ca

# git add /var/named/chroot/etc/named.conf
# git commit -m 'Added named config file'

master 3f4fed2] Added named config file
Committer: root <root@liminf03.motion.com>
Your name and email address were configured automatically based
on your username and hostname. Please check that they are accurate.
You can suppress this message by setting them explicitly:

git config –global user.name “Your Name”
git config –global user.email you@example.com

After doing this, you may fix the identity used for this commit with:

git commit –amend –reset-author

1 file changed, 49 insertions(+)
create mode 100644 var/named/chroot/etc/named.conf

# git config --global user.name "root"
# git config --global user.email root@motion.com
# git commit --amend --reset-author
[master d57a9a4] Added named config file
1 file changed, 49 insertions(+)
create mode 100644 var/named/chroot/etc/named.conf

# cd /etc
# git add dhcpd.conf
# git commit -m "Added DHCP server config file"
[master b1cd264] Added DHCP server config file’
1 file changed, 49 insertions(+)
create mode 100644 etc/dhcpd.conf

Posted in Backups, git, System Configuration | Comments Off on Using Git for DNS and DHCP Config Files

Changing the Color of Links

Using the ElegantThemes eBusiness theme, the default color for links did not stand out and links were hard to see. Resolved by making them red. In the style.css file, for the child theme, added the following line of code:

.home-post-wrap-2 a {color: #ff0000 !important; font-weight: bold;}
Posted in Journal, Wordpress | Comments Off on Changing the Color of Links

Fun with mod_rewrite…

Today I had to create some specific/generic rewrite rules. The idea was to allow “motion.com,”www.motion.com,” “www.motion.com/index.html,” and “motion.com/index.html” all go to an index (domain for sale) page. However, let everything else forward to “learninginmotion.com.” So URLs like “www.motion.com/products/index.html” would forward to “www.learninginmotion.com/products/index.html.” The resulting rule was:

RewriteCond %{REQUEST_URI} !^/index.html$
RewriteCond %{REQUEST_URI} !^/$
RewriteRule ^(.*)$ "http\:\/\/www\.learninginmotion\.com/$1" [R=302,L]

That worked almost perfectly, except for one oversight. The secure store uses secure105.inmotionhosting.com/store/… and that was also getting redirected to learninginmotion.com. Also, the other add-on domains were messed up. To fix it, one line was added, so now it looks like:

RewriteCond %{REQUEST_URI} !^/index.html$
RewriteCond %{REQUEST_URI} !^/$
RewriteCond %{HTTP_HOST} !^secure105.inmotionhosting.com$
RewriteCond %{HTTP_HOST} !^voyagesthroughtime.org$
RewriteCond %{HTTP_HOST} !^knowledgeforum.com$
RewriteRule ^(.*)$ "http\:\/\/www\.learninginmotion\.com/$1" [R=302,L]

In the process I discovered another cool little gem. Instead of server up a 404 for non existing pages and directories, you can just redirect them to index.html using:

RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule . index.html [L]

Silly to put this here but, just in case, we shouldn’t forget to start things off by enabling rewrites using:

RewriteEngine On
Posted in Journal, Web Geeking | Comments Off on Fun with mod_rewrite…

Cleaning up…

Today was the real start of the new year cleanup process. Logged into the InMotionHosting account and deleted the nightly backups, leaving the ones from the 1st of each month, and started moving them over to ShareA:IT Archives/Web Backups.

Posted in Journal | Comments Off on Cleaning up…