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.645 commenti su “Tutorial: Integrare Facebook Connect in un sito sviluppato con CMS (Lesson 4)”

  1. Hello there! I know this is kinda off topic but I’d figured I’d ask.
    Would you be interested in exchanging links or maybe guest authoring a blog post or vice-versa?
    My site covers a lot of the same topics as yours and I feel we could greatly benefit
    from each other. If you are interested feel free to shoot me an e-mail.
    I look forward to hearing from you! Superb blog by the way!

    Rispondi
  2. Hi there just wanted to give you a quick heads
    up. The text in your article seem to be running off the screen in Internet explorer.
    I’m not sure if this is a formatting issue or something to do with internet browser compatibility but I thought I’d post
    to let you know. The layout look great though! Hope you get
    the issue resolved soon. Many thanks

    Rispondi
  3. Generally I don’t learn article on blogs, however I wish to say that this write-up very pressured
    me to take a look at and do it! Your writing style has been surprised me.

    Thanks, very great article.

    Rispondi
  4. Excellent blog! Do you have any recommendations for
    aspiring writers? I’m planning to start my own website soon but I’m a little lost on everything.
    Would you suggest starting with a free platform like WordPress or go for a paid option?
    There are so many options out there that I’m completely confused ..

    Any recommendations? Appreciate it!

    Rispondi
  5. Your style is very unique in comparison to other people I’ve read stuff from.
    Thank you for posting when you have the opportunity, Guess I will just bookmark this page.

    Rispondi
  6. I loved as much as you will receive carried out right here.

    The sketch is tasteful, your authored subject matter stylish.
    nonetheless, you command get bought an nervousness over that you wish
    be delivering the following. unwell unquestionably come
    more formerly again since exactly the same nearly very often inside case you shield this increase.

    Rispondi
  7. Hi! This is my first comment here so I just wanted to give a quick shout out and tell you I
    genuinely enjoy reading your articles. Can you
    suggest any other blogs/websites/forums that go over the same subjects?
    Appreciate it!

    Rispondi
  8. Simply wish to say your article is as surprising.
    The clarity on your publish is simply excellent and i could suppose you’re a professional in this subject.
    Well along with your permission let me to take hold of your
    RSS feed to keep up to date with coming near near post.

    Thank you one million and please keep up the enjoyable
    work.

    Rispondi
  9. Wonderful article! That is the type of information that are supposed to
    be shared across the net. Disgrace on the seek engines for not positioning this
    publish higher! Come on over and talk over with my website .
    Thank you =)

    Rispondi
  10. I was suggested this web site by my cousin. I’m not sure whether this post is
    written by him as no one else know such detailed about my trouble.

    You are incredible! Thanks!

    Rispondi
  11. Thanks for a marvelous posting! I seriously enjoyed reading it, you can be a great author.
    I will be sure to bookmark your blog and may
    come back very soon. I want to encourage that you continue your
    great work, have a nice afternoon!

    Rispondi
  12. 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 net will be much more useful than ever before.

    Rispondi
  13. Hey there I am so happy I found your blog page, I really
    found you by error, while I was looking on Bing for something
    else, Regardless I am here now and would just like to say
    many thanks for a remarkable post and a all round entertaining blog (I also love the theme/design), I don’t have time to look over it all
    at the minute but I have book-marked it and also included your RSS feeds, so when I have time I will be back to read a lot more, Please do keep up
    the excellent job.

    Rispondi
  14. I do not know if it’s just me or if perhaps everybody
    else experiencing issues with your website. It appears
    like some of the text within your content are running
    off the screen. Can somebody else please comment and let me know if this is happening to them
    too? This could be a problem with my browser because I’ve had this
    happen previously. Thanks

    Rispondi
  15. Hey I know this is off topic but I was wondering if you knew of any widgets I could add to my blog that
    automatically tweet my newest twitter updates. I’ve been looking for a plug-in like this for quite some time and was hoping maybe you would have
    some experience with something like this. Please let me
    know if you run into anything. I truly enjoy reading your blog and I look
    forward to your new updates.

    Rispondi
  16. I have been surfing online more than 3 hours lately, but I never found any attention-grabbing article like yours.
    It’s lovely price sufficient for me. Personally, if all
    site owners and bloggers made good content as you did, the web
    will likely be a lot more useful than ever before.

    Rispondi
  17. Usually I do not read article on blogs, but I wish to say that this write-up very compelled me to check out
    and do it! Your writing taste has been amazed me. Thank you, quite great article.

    Rispondi
  18. Hello! I know this is kind of off topic but I was wondering which blog platform are you using
    for this website? I’m getting tired of WordPress because I’ve had problems with hackers and I’m looking
    at alternatives for another platform. I would be awesome if you could
    point me in the direction of a good platform.

    Rispondi

Lascia un commento