Posted by Dwayne on December 7, 2010 – 12:04 am
I was looking through my Cpanel recently to find a DB name for a particular blog. I have installed several blogs and there are many other MySql necessary sites / Databases. So when going into MyPhpAdmin to do any type of work, one really should be sure of the DB you need to work on. How do you find it?
For Word press and many other types of php scripts you can look for the Config php file. Inside of your working directory where WordPress is installed for example you will want to find the file named:
wp-config.php
open this file:
look for the line of code that looks similar to this :
define(‘DB_NAME’, ‘*******’);
‘*******’ What ever is in between the ’ ’ marks is your Database name. Usually this format: username_DBname Where DB name is what you will see in PHPmyAdmin. You can then do your modification — change passwords , etc..
Incoming search terms:
Posted by Dwayne on July 3, 2010 – 12:54 pm
I often have to set up blogs or use Word Press as a CMS . I have some preferential settings I like to use. One of them is to have the buttons for text editing available like using BOLD Underlined Text or Italicizing text.
I started writing these tutorials so that I would have a quick reference to re-setting up a blog and configuring a new one for WordPress. WordPress is a great platform but little items like this can make it a bit frustrating to use at times. There should probably be a more user friendly way of ticking this setting on but no such luck. My research has turned this up:
There is a setting under users on the WordPress Control panel. For version 2.9 it says: Your Profile
I clicked it. On the page a check box at the top by default was ticked that said disable the rich text editor. So I unchecked it and now all of the icons for rich text editing have reappeared.
I spent way too much time looking for this setting. I wont have to go far if I forget it the future.
Incoming search terms:
Posted by Dwayne on July 3, 2010 – 12:04 pm
I just needed to set this up for myself so why not write a brief tutorial so I will remember. I originally found this at here
I am repeating this information since I often have to do the same thing on other blogs for clients and such and to further explain some points I messed up on via the original.
In essence to repeat what was said the code below will go into the functions.php of your individual theme. Utilizing CODA i log in to my server and open this folders path: blog > wp-content > themes > your theme name >functions.php . Within functions.php , I just created a space among the other functions and pasted the code below and saved the file — do not close the file as you may need to return to the original state (note that there is a comment added that is different form the original):
// TO LIMIT WordPress Post length on homepage
function string_limit_words($string, $word_limit)
{
$words = explode(' ', $string, ($word_limit + 1));
if(count($words) > $word_limit)
array_pop($words);
return implode(' ', $words);
}
Now In the same folder within your them locate index.php and replace the line :
with :
< ?php $excerpt = get_the_excerpt(); echo string_limit_words($excerpt,40); ?>
I originally tried to just replace the the words : the_content with all of the other code. Now after a couple of tries I slapped my head got it. Not too tough really, and it works very well.
Incoming search terms: