Community Forums › Forums › Archived Forums › General Discussion › Change link in the header
Tagged: header
- This topic has 15 replies, 2 voices, and was last updated 10 years, 4 months ago by nutsandbolts.
-
AuthorPosts
-
December 12, 2013 at 10:33 am #78559eriksatieMember
Hi to everyone,
I need help on changing the link in the header, that is now to /blog, because the blog is installed in this folder
I want to change to /
simply as thatI've read around that i need to modify the file header.php but I cannot find it!
I have an Epik themethx in advance
December 12, 2013 at 11:27 am #78567nutsandboltsMemberYour header will link to whatever is set as the home URL in Settings > General.
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 12, 2013 at 12:34 pm #78577eriksatieMemberoh oh
I' have screwed up everyting!
I've changed the URL site from /blog to / and now the backoffice is not loading anymore!please HELP! where I can change back this now?
December 12, 2013 at 12:35 pm #78578nutsandboltsMemberOkay, don't panic.
Ask your host's tech support to change your home URL back to yourdomain.com/blog/ and they'll fix it in your database. If you don't want to use /blog/, you'll need to set up a redirect or move your WP install to the root directory.
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 12, 2013 at 1:54 pm #78590eriksatieMemberok I really would prefer to solve it by myself if possible... I have access to FTP and mysql, but not much experience with database.
can you give me some step-by-step help or point me towards an article where is clearly written what to do and how?
just to give some more info. on the root there is another site, that is working, so move the blog on the root is not an option. I just want to make it working again at /blog
December 12, 2013 at 1:55 pm #78591nutsandboltsMemberSure, no problem.
In phpMyAdmin, click on the database for the blog, then click on the wpoptions table. On the first page, you'll see the URL about 5-6 items down. You can double click to edit the URL and change it back. Then scroll down and use the arrow to go to page two, where you'll see it again. Once you change those, the site should be unbroken. 🙂
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 12, 2013 at 2:24 pm #78599eriksatieMembermmm having access to wp-config.php I thought I would be able to access phpMyAdmin but I can't find the panel.
from wp-config.php I can see that the DB is on another host but I cannot gues the right URL.
is there any way to find it?December 12, 2013 at 2:25 pm #78600nutsandboltsMemberIf your host uses CPanel, you should be able to access phpMyAdmin from there.
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 12, 2013 at 2:28 pm #78602eriksatieMemberunfortunely I cannot access Cpanel, just the FTP.
December 12, 2013 at 2:29 pm #78603nutsandboltsMemberWithout access to phpMyAdmin, unfortunately there's no good way to edit the database.
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 13, 2013 at 2:47 am #78756eriksatieMemberyup! solved, now it is working again. thank you very much! : )
now back to the original question: how to change the link in the logo?
the blog in installed in /blog and also the URL is /blog
in the root there is the "official" site. I want that clicking the logo the user always goes to /December 13, 2013 at 10:24 am #78811nutsandboltsMemberTry this function - I haven't tested it, but it's from Bill Erickson so I'm sure it will work (be sure to replace example.com with your domain):
//* Change logo URL function be_logo_url( $title, $inside, $wrap ) { $inside = sprintf( '<a href="%s" title="%s">%s</a>', esc_url( 'http://www.example.com' ), esc_attr( get_bloginfo( 'name' ) ), get_bloginfo( 'name' ) ); $title = sprintf( '<%s id="title">%s</%s>', $wrap, $inside, $wrap ); return $title; } add_filter( 'genesis_seo_title', 'be_logo_url', 10, 3 );
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 13, 2013 at 10:47 am #78819eriksatieMemberthe functions has changed the link, not the one in the logo image but the one in the title (that should be disabled, but with this functions is has reappeared).
December 13, 2013 at 10:49 am #78820nutsandboltsMemberAre you using the HTML5 version of Epik? If so, try this one instead:
//* Change logo link add_filter( 'genesis_seo_title', 'child_header_title', 10, 3 ); function child_header_title( $title, $inside, $wrap ) { $inside = sprintf( '<a href="http://example.com/" title="%s">%s</a>', esc_attr( get_bloginfo( 'name' ) ), get_bloginfo( 'name' ) ); return sprintf( '<%1$s class="site-title">%2$s</%1$s>', $wrap, $inside ); }
If that one doesn't work, let me know and I'll keep looking for a solution.
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+December 13, 2013 at 11:23 am #78832eriksatieMemberyesss!
really very kind Andrea, thank you very much!
December 13, 2013 at 11:24 am #78833nutsandboltsMemberFantastic! I'm going to mark this thread as resolved, but feel free to open another one if you run into any more issues.
Andrea Whitmer, Owner/Developer, Nuts and Bolts Media
I provide development and training services for designers • Find me on Twitter and Google+ -
AuthorPosts
- The forum ‘General Discussion’ is closed to new topics and replies.