Tutorial: Integrare Facebook Connect in un sito sviluppato con CMS (Lesson 4)

Spread the love

Siamo giunti oramai all’ultima lezione di questo tutorial e sarete diventati sicuramente degli abili “integratori” di Facebook nel Vostro sito.

Vediamo dunque quest’oggi qualche ultimo particolare per affinare ancor più le nostre personalizzazioni al contenuto di Facebook sul nostro sito web.

Un difetto spesso riscontrato di un nostro utente loggato in Facebook riguarda la dimensione delle foto dell’avatar. E’ necessario per un’essenziale questione estetica far si che tutti gli avatar abbiano la stessa dimensione…cioè come quella di Facebook (48 x 48 Pixel).
Il plug-in di Facebook Connect installato sul nostro CMS però imposta una larghezza standard di 48 Pixel lasciando invariata invece l’altezza (cioè di qualsiasi dimensione), e questo sicuramente creerà un disordine grafico all’interno di un layout magari curato ad hoc. Per permettere il ridimensionamento degli avatar in automatico a quelli delle dimensioni di Facebook (48 x 48 Pixel), procediamo nel seguente modo:

Aprite con Notepad++ (per chi necessitasse di un rinfresco vedi lezione 3) e con questo, editate il file fbConnectLogic.php come abbiamo sempre fatto.

Per effettuare l’editing basta portarsi alla riga 365 (sempre al lato destro del vostro schermo” e cambiare il valore di
size=”thumb” con il parametro di size=”square”.

Il gioco è fatto.

Altra modifica che possiamo ottenere è quella di eliminare il link del profilo Facebook nei commenti qualora egli non sia logato ed inserire un link autonomo.
Per fare ciò, necessiterà all’interno del file comments.php (sempre modificandolo con un editor html), inserire il seguente codice:

<?php
    if(is_user_fbconnect($comment->user_id)){
        comment_author();
    }else{
        comment_author_link();
    }
?>

Così, l’autore del commento non loggato in Facebook avrà libertà di inserire il proprio link.

Finisce qui la mini-guida dell’integrazione tra Facebook ed il nostro sito realizzato con WordPress, molteplici ancora sono le modifiche che possono essere effettuate al plug-in qualora non si scegliesse di utilizzare le Widget standard.

Torneremo sull’argomento qualora ci saranno nuovi sviluppi, per ora l’unico augurio è quello di una “buona Face-integrazione”.

2.646 commenti su “Tutorial: Integrare Facebook Connect in un sito sviluppato con CMS (Lesson 4)”

  1. Hey there would you mind letting me know which webhost you’re working with?
    I’ve loaded your blog in 3 different browsers and
    I must say this blog loads a lot faster then most. Can you recommend a good internet hosting provider at a honest price?

    Thank you, I appreciate it!

    Rispondi
  2. I have been surfing online more than 3 hours today, yet I never found any interesting article like yours.
    It’s pretty worth enough for me. In my view, if all website owners and bloggers made good content as you did,
    the internet will be a lot more useful than ever before.

    Rispondi
  3. Great beat ! I would like to apprentice while you amend your web site, how
    can i subscribe for a blog web site? The account helped me a acceptable deal.
    I had been tiny bit acquainted of this your broadcast provided bright clear concept

    Rispondi
  4. Hi there! I know this is sort of off-topic but I had
    to ask. Does building a well-established website such as yours require a massive amount work?
    I am brand new to blogging but I do write in my diary daily.
    I’d like to start a blog so I can easily share my experience and feelings online.
    Please let me know if you have any kind of ideas or tips for new aspiring bloggers.

    Appreciate it!

    Rispondi
  5. Have you ever considered about including a little bit more than just your articles?

    I mean, what you say is valuable and everything.

    But think about if you added some great photos or video clips
    to give your posts more, “pop”! Your content is
    excellent but with images and clips, this site could undeniably be one of the best in its niche.
    Superb blog!

    Rispondi
  6. Somebody essentially lend a hand to make seriously
    posts I’d state. This is the very first time I frequented your website page and thus
    far? I amazed with the analysis you made to create this actual
    submit incredible. Magnificent activity!

    Rispondi
  7. This design is steller! You obviously know how to keep a reader amused.

    Between your wit and your videos, I was almost moved to start my
    own blog (well, almost…HaHa!) Great job. I really enjoyed what you
    had to say, and more than that, how you presented it.
    Too cool!

    Rispondi
  8. Fantastic goods from you, man. I’ve be mindful your stuff previous to and you’re just extremely
    magnificent. I actually like what you’ve got
    right here, really like what you’re saying and the way in which you are saying it.
    You’re making it entertaining and you still care for to stay it smart.
    I can not wait to read much more from you. That is really a
    tremendous website.

    Rispondi
  9. You made some really good points there. I looked on the net for additional information about the issue and found most individuals
    will go along with your views on this web site.

    Rispondi
  10. We’re a group of volunteers and starting a new scheme in our community.
    Your site provided us with valuable information to work on. You have done a formidable job and our entire community will be thankful
    to you.

    Rispondi
  11. Hey there just wanted to give you a quick heads up. The text in your post seem
    to be running off the screen in Ie. I’m not sure
    if this is a formatting issue or something to do with web browser compatibility but I figured I’d post to let you know.
    The layout look great though! Hope you get the issue solved soon. Kudos

    Rispondi
  12. Great beat ! I wish to apprentice whilst you amend your web site,
    how can i subscribe for a weblog site? The account helped me a appropriate deal.
    I have been tiny bit acquainted of this your broadcast offered
    bright transparent concept

    Rispondi
  13. Generally I don’t learn post on blogs, however I would
    like to say that this write-up very forced me to take
    a look at and do so! Your writing taste has been amazed me.

    Thank you, quite nice post.

    Rispondi
  14. Just wish to say your article is as astonishing. The clearness in your post is simply excellent and i can assume you’re an expert on this subject.
    Well with your permission allow me to grab your RSS feed to keep
    updated with forthcoming post. Thanks a million and
    please keep up the rewarding work.

    Rispondi
  15. Its like you read my mind! You seem to know so much about this, like
    you wrote the book in it or something. I think that you
    can do with a few pics to drive the message home a little bit,
    but other than that, this is excellent blog. A fantastic read.
    I’ll definitely be back.

    Rispondi
  16. I got this website from my pal who informed me about this website and now this time I am browsing this web site and reading
    very informative articles or reviews at this time.

    Rispondi

Lascia un commento