Anyone here know how to change the Blogroll of the newly created blog?
Anyone here know how to change the Blogroll of the newly created blog?
Hi Ba22Man
/wp-includes/wpmu-functions.php at lines 1222 define the default links that get inserted into the new blog blogrolls.
Just add or change those there and your all set.
tnx for the reply mate.. im gonna try it now.. :)
it works mate.. tnx for your help.. anyway i have tried to add 3 links. only the two links has been included in the blog roll category, thats why the remaining link is not displayed any idea why this happens?
Not sure of the top of my head as i haven't actually modified that function yet, its on the "to do list" :)
Are you sure the third link mirrors the first 2 ?
no.. what i mean is the third link is not showing, because its now placed on the blog roll category. :)
you must add one more line, eg.
$wpdb->query("INSERT INTO $wpdb->categories (cat_ID, cat_name, category_nicename, link_count) VALUES ('{$blogroll_id}', '".addslashes(__('Blogroll'))."', '".sanitize_title(__('Blogroll'))."', 2)");
$wpdb->query("INSERT INTO $wpdb->link2cat (link_id, category_id) VALUES (1, $blogroll_id)");
$wpdb->query("INSERT INTO $wpdb->link2cat (link_id, category_id) VALUES (2, $blogroll_id)");
$wpdb->query("INSERT INTO $wpdb->link2cat (link_id, category_id) VALUES (3, $blogroll_id)");
i have already added another line. it works but it didn't show in the sidebar because its not included in the blog roll category..
Also change the hello world post to use the additional categories. Links only show up if there's posts in the categories.