HELP! I just edited the header.php and site is not working!!!!

Community Forums Forums General Discussion HELP! I just edited the header.php and site is not working!!!!

This topic is: not resolved

Tagged: 

This topic contains 21 replies, has 3 voices, and was last updated by  benconnor 1 year, 2 months ago.

Viewing 15 posts - 1 through 15 (of 22 total)
  • Author
    Posts
  • #18605

    benconnor
    Participant
    Post count: 26

    Hi,

    Um… I was just trying to insert open graph tags into the header.php of the genesis folder – I couldn’t find it in my new theme folder.

    Anyway, stupidly I didn’t save a copy of the code before entering it.

    I’VE ACCIDENTALLY DELETED SOMETHING VITAL

    The vital piece of code is somewhere in here:

    wp_head();</** we need this for plugins **/>
    </head>

    Please HELP?

    Can someone please just copy and paste what this code is in here please?

    I will be eternally grateful

    Cheers,

    Ben

    #18615

    Vajrasar Goswami
    Participant
    Post count: 156

    I believe you edited files in the parent folder of themes->genesis->*code files*. Am I right?

    If yes, then you may want to download Genesis 1.9 and replace the old installation of genesis.

    OR

    [I don't know if this would work] You can try and insert this whole code in theme->genesis->header.php

    _______________________________________

    <?php
    /*
    WARNING: This file is part of the core Genesis framework. DO NOT edit
    this file under any circumstances. Please do all modifications
    in the form of a child theme.
    */

    /**
    * Handles the header structure.
    *
    * This file is a core Genesis file and should not be edited.
    *
    * @category Genesis
    * @package Templates
    * @author StudioPress
    * @license http://www.opensource.org/licenses/gpl-license.php GPL v2.0 (or later)
    * @link http://www.studiopress.com/themes/genesis
    */

    do_action( ‘genesis_doctype’ );
    do_action( ‘genesis_title’ );
    do_action( ‘genesis_meta’ );

    wp_head(); /** we need this for plugins **/
    ?>
    </head>
    <body <?php body_class(); ?>>
    <?php
    do_action( ‘genesis_before’ );
    ?>
    <div id=”wrap”>
    <?php
    do_action( ‘genesis_before_header’ );
    do_action( ‘genesis_header’ );
    do_action( ‘genesis_after_header’ );

    echo ‘<div id=”inner”>’;
    genesis_structural_wrap( ‘inner’ );

     


    Twitter – Vajrasar

    #18616

    benconnor
    Participant
    Post count: 26

    Hi Vajrasar,

    Thank you so much!!!!

    That worked a charm.

    All i had to do was whack this back in:

    wp_head(); /** we need this for plugins **/
    ?>
    </head>

    I accidentally removed the ?> bit.

    Thanks!!!

    Just quickly, can you tell me where to add the following facebook metatags so I don’t stuff up again:

    <meta property=”og:title” content=”Ben Connor Music” />
    <meta property=”og:type” content=”musician” />
    <meta property=”og:url” content=”http://benconnormusic.com/q” />
    <meta property=”og:image” content=”http://benconnormusic.com/?attachment_id=1620″ />
    <meta property=”og:site_name” content=”Ben Connor Music” />
    <meta property=”fb:admins” content=”663220279″ />

    My Easy Facebook Share Thumbnail just says ‘Open Graph tags are <meta> tags that you add to the <head> of your website’

    I’m hoping they will ensure that the image that appears on people’s status when they facebook like me is the one that I add to the one above, but I can’t figure out where to put them.

    Cheers,

    Ben

    #18618

    Vajrasar Goswami
    Participant
    Post count: 156

    Refer to this -

    http://www.billerickson.net/wordpress-facebook-like-thesis-genesis/

    See the “Facebook Like in Genesis” Section.


    Twitter – Vajrasar

    #18620

    Vajrasar Goswami
    Participant
    Post count: 156

    For things like this and many, try and use “Genesis Simple Hooks” Plugin.

    http://www.studiopress.com/plugins/simple-hooks


    Twitter – Vajrasar

    #18632

    benconnor
    Participant
    Post count: 26

    Hi Vajrasar,

    Unfortunately that doesn’t work for me as I need to use it for the jetpack plugins I have.

    My major issues seems to be that my facebook Graph API is this:
    {
    “url”: “http://benconnormusic.com/”,
    “type”: “article”,
    “title”: “Ben Connor”,
    “image”: [
    {
    "url": "http://www.yourfamilyyourmoney.com/images/CAP-Affiliate/BIB-banner-160x80.jpg"
    }
    ],
    “description”: “Alternative blues folk rock singer-songwriter”,
    “site_name”: “Ben Connor”,
    “updated_time”: “2013-02-07T12:13:05+0000″,
    “id”: “226841744111572″
    }

    Where is this situated? All i want to do is to change it so the that url is this: http://benconnormusic.com/?attachment_id=1620

    If I can do that I wont have a crappy advertisement appearing when on people’s feeds when they like my stuff.

    Ben

    #18636

    Vajrasar Goswami
    Participant
    Post count: 156

    See this tread. I believe, this is some issue with Jetpack and they will update it

    http://wordpress.org/support/topic/facebook-publicizing-clients-posts-with-wrong-avatar


    Twitter – Vajrasar

    #18644

    anitac
    Participant
    Post count: 6430

    The plugin is recognizing the first image on the site which is the ad code in the Header Right Widget area. Just to test things – drag that off of there into the Inactive Widgets and let’s see what image it picks up first. Let’s start there. No need in fumbling around with all the other stuff yet.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #18645

    anitac
    Participant
    Post count: 6430

    I am using this same plugin on a client using the same theme. Under Settings > Easy Facebook Share Thumbnails – did you upload a default thumbnail? Did you Debug or Validate Your Pages on the plugin page?

    One key point here – the plugin works if there is a “Featured Image” attached to your posts. If there isn’t one, it is to look for the default thumbnail you place in the plugin.

    I went to a post and LIKED it and also tried to Share. I was provided two thumbnail images for the post because the post doesn’t have a featured image attached to it.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #18649

    benconnor
    Participant
    Post count: 26

    Hi Anitac :-)

    Unfortunately I just tried the featured image approach and that didn’t work either.

    The crazy thing is that that image is not the ad code in the right widget. It’s an old ad code that has since been well and truly eradicated – if you look closely you’ll see its different to the one that’s on the site now.

    I’ve tried all sorts of things. I’ve removed the code, deactivated the ad sense plug in, cleared all data from the plug in etc. Each time, I tried the link button and the image remained.

    Oh, I’ve also had a default thumbnail set up on the Easy Facebook Share Thumbnails plugin to no avail.

    The issue is this (as expressed above):

    I did do a debug on the Easy Facebook Share Thumbnails plugin

    Among other things it told me that my Facebook Graph API is this:

    {
    “url”: “http://benconnormusic.com/&#8221;,
    “type”: “article”,
    “title”: “Ben Connor”,
    “image”: [
    {
    "url": "http://www.yourfamilyyourmoney.com/images/CAP-Affiliate/BIB-banner-160x80.jpg"
    }
    ],
    “description”: “Alternative blues folk rock singer-songwriter”,
    “site_name”: “Ben Connor”,
    “updated_time”: “2013-02-07T12:13:05+0000″,
    “id”: “226841744111572″
    }

    The url for that yourfamilyyourmoney banner is lodged into the graph API and I can’t for the life of me determine how to alter the facebook graph API to get it out of there.

    I just want this one put it in it’s place: http://benconnormusic.com/?attachment_id=1620

    The other thing it told me was that I have…

    Errors That Must Be Fixed

    More Than One OG URL Specified:
    Object at URL ‘http://benconnormusic.com’ of type ‘article’ is invalid because it specifies multiple ‘og:url’ values: http://benconnormusic.com, http://benconnormusic.com/.

    I haven’t been able to locate my og:urls either!

    I’ve been at this for five hours and my blog page numbers issue also remains unresolved.

    I’m like the Antithesis to a hacker :-)

    Ben

    #18650

    Vajrasar Goswami
    Participant
    Post count: 156

    I can suggest an alternate fix, but this NOT a standard solution and I have not tried it myself.

    You may navigate to this link via your FTP or cPanel- http://www.yourfamilyyourmoney.com/images/CAP-Affiliate/BIB-banner-160×80.jpg

    Delete the file ‘BIB-banner-160×80.jpg ’.

    Upload your image (that you want to show) and name it ‘BIB-banner-160×80.jpg ’

    That might trick the system into showing that image.

    REMEMBER – Backup the Original Image in any case.

     


    Twitter – Vajrasar

    #18651

    anitac
    Participant
    Post count: 6430

    That could work. Have you optimized your database lately to remove a lot of dead files, etc.? You can use the WP-Optimize plugin – http://wordpress.org/extend/plugins/wp-optimize/screenshots/. You can also use Quick Cache to dump your cache files – http://wordpress.org/extend/plugins/quick-cache/.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #18652

    anitac
    Participant
    Post count: 6430

    Oh and this – http://benconnormusic.com/?attachment_id=1620 is actually leading to a Image Post. It will need to have the actual URL of the image on that post.

    One more thing… changes won’t happen immediately. It takes the search engines and Facebook a little bit of time to catch up to the changes.

    Like I said, I have used both the plugin and theme together for 8 months and my recommendations have worked well for me. I’ll unsubscribe and let someone else chime in here now. Good luck.


    Let me help you customize your theme, responsive header, Buddypress, Agentpress or technical issue!
    Visit me here: Cre8tiveDiva.com | Tweet Me! | Plus Me!
    When asking for help, please provide a link or screen shot showing your problem!

    #18653

    benconnor
    Participant
    Post count: 26

    Weird…

    When I ‘like’ this post (http://benconnormusic.com/song-idea-1/) it shows the YouTube icon.

    I swear to you anitac, I have made the feature image of this post the main photo in the header.

    My brain is melting and it’s 1.18am! Got to be up at 7am.

    Oh dear.

    Be great if you could help :-)

    Ben

    #18870

    benconnor
    Participant
    Post count: 26

    Hi Vajrasar,

    I’ve tried to navigate to http://www.yourfamilyyourmoney.com/images/CAP-Affiliate/BIB-banner-160×80.jpg through my cpanel and FTP, but can’t find it.

    Where would it be?

    Actually, are you sure it would be there?

    The url was generated by yourfamilyyourmoney, of whom I am an affiliate.

    Is there no way to alter the facebook graph API to get it out of there?

    vajrasar

Viewing 15 posts - 1 through 15 (of 22 total)

You must be logged in to reply to this topic.