GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   wordpress security tip: remove your wordpress version number (https://gfy.com/showthread.php?t=927163)

fris 09-11-2009 11:25 AM

wordpress security tip: remove your wordpress version number
 
Gonna make this quick since Im posting this on my iphone.

Some of your, infact a lot that do this are doing it incorrectly.

This is what 95% of the people have that I see.

Code:

remove_action('wp_head', 'wp_generator');

This will remove it from your theme, but it will still show up in your feeds.


All you have to do is add this to your themes functions.php file. (this is the proper way)

Code:

add_filter('the_generator',create_function('$a',"return null;"));

area51 - BANNED FOR LIFE 09-11-2009 11:27 AM

nice tip frissy

mikesouth 09-11-2009 11:45 AM

good idea but where in the file does it actually go?

woj 09-11-2009 11:48 AM

good tip there :thumbsup

fris 09-11-2009 12:50 PM

Quote:

Originally Posted by mikesouth (Post 16307315)
good idea but where in the file does it actually go?

Your theme can have a functions.php file which you can have your own custom functions you can use for your theme, you can also override current core functions.

Here are a couple links worth reading

http://codex.wordpress.org/Theme_Dev...Functions_File

http://www.pearsonified.com/2008/05/...-functions.php

http://yoast.com/wordpress-functions-supercharge-theme/

http://www.flowdrops.com/blog/wordpr...functions-php/

Tjeezers 09-11-2009 01:05 PM

thanks for sharing man
You are a true Ninja

Davy 09-11-2009 01:23 PM

What's "$a"?

fris 09-12-2009 11:04 AM

Quote:

Originally Posted by Davy (Post 16307690)
What's "$a"?

Priority over the default

:thumbsup


All times are GMT -7. The time now is 02:02 PM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123