Simple Machines Community Forum

Customizing SMF => SMF Coding Discussion => Topic started by: sonda on January 31, 2008, 04:10:23 PM

Title: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: sonda on January 31, 2008, 04:10:23 PM
This is what my index reads  and I need to be able to have the logo   when clicked on go to  another website.
Hope you can tell be how to re write this and make it happen.   Also the logo is saved in  photo bucket is this ok ?

Quoteif(!($settings['logo_not_show']))
   {
      if (empty($settings['header_logo_url']))
         echo '
                  <a href="', $scripturl, '"><img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/logo.jpg" style="margin: 0px;" alt="', $context['forum_name'], '" title="', $context['forum_name'], '"/></a>';
      else
         echo '
                  <a href="', $scripturl, '"><img src="', $settings['header_logo_url'], '" style="margin: 0px;" alt="', $context['forum_name'], '" /></a>';
   }
   echo '
               </td>';

   if (!empty($settings['show_name_near_logo']))
      echo '   
               <td>
                  <span style="font-family: \'Trebuchet MS\', Verdana, sans-serif; font-size: 150%; color: white; padding-top: 30px; padding-left: 30px; white-space: normal;">', $context['forum_name'], '</span>
               </td>';
   if (!empty($settings['top_right_html']))
      echo '
               <td valign="top" align="right">
                  <div style="color: white; padding-top: 10px; float:right;">', $settings['top_right_html'], '</div>
               </td>';

   echo '
Title: Re: Need some help with logo coding please
Post by: SA™ on January 31, 2008, 09:28:27 PM
Quote from: sonda on January 31, 2008, 04:10:23 PM
This is what my index reads  and I need to be able to have the logo   when clicked on go to  another website.
Hope you can tell be how to re write this and make it happen.   Also the logo is saved in  photo bucket is this ok ?

if(!($settings['logo_not_show']))
   {
      if (empty($settings['header_logo_url']))
         echo '
                  <a href="', $scripturl, '"><img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/logo.jpg" style="margin: 0px;" alt="', $context['forum_name'], '" title="', $context['forum_name'], '"/></a>';
      else
         echo '
                  <a href="', $scripturl, '"><img src="', $settings['header_logo_url'], '" style="margin: 0px;" alt="', $context['forum_name'], '" /></a>';
   }
   echo '
               </td>';

   if (!empty($settings['show_name_near_logo']))
      echo '   
               <td>
                  <span style="font-family: \'Trebuchet MS\', Verdana, sans-serif; font-size: 150%; color: white; padding-top: 30px; padding-left: 30px; white-space: normal;">', $context['forum_name'], '</span>
               </td>';
   if (!empty($settings['top_right_html']))
      echo '
               <td valign="top" align="right">
                  <div style="color: white; padding-top: 10px; float:right;">', $settings['top_right_html'], '</div>
               </td>';

   echo '


change

<a href="', $scripturl, '">

to the link you wont it to point to

<a href="www.yourforum.com ">


then change

<img src="', $settings['images_url'] . '/'. $settings['theme_main_color'], '/logo.jpg"

to the logo you wont to use ie your logo url

<img src="www.yourlogo.com/logo.jpg"
Title: Re: Need some help with logo coding please
Post by: sonda on January 31, 2008, 10:55:09 PM
Thank you very much.

one other question and then will leave you alone :)

this question is in regard to how to get rid of red x   
in the current theme the option is to put   codes in  for

HTML code to be displayed below user info bar
or
HTML code to be displayed at the top right

now if I put in the following  in either space, I get  a red x to the left of the img.  But if I just put in the img  info and leave off the  website info there is no red x   so what am I doing wrong?

<a href ="http://www.swedefarm.com"><img src="<<a href="http://s132.photobucket.com/albums/q12/allcraft/Business%20Cards/?action=view&current=Katie.jpg" target="_blank"><img src="http://i132.photobucket.com/albums/q12/allcraft/Business%20Cards/Katie.jpg" border="0" alt="Katie"></a>
Title: Re: Need some help with logo coding please
Post by: SA™ on January 31, 2008, 10:59:22 PM
try this


<a href ="http://www.swedefarm.com"><img src="http://s132.photobucket.com/albums/q12/allcraft/Business%20Cards/?action=view&current=Katie.jpg" target="_blank"><img src="http://i132.photobucket.com/albums/q12/allcraft/Business%20Cards/Katie.jpg" border="0" alt="Katie"></a>
Title: Re: Need some help with logo coding please
Post by: sonda on January 31, 2008, 11:03:31 PM
nope that still leaves the red x to the left of the image
do you think it might have to do with using photo bucket?
Title: Re: Need some help with logo coding please
Post by: SA™ on January 31, 2008, 11:06:12 PM
try the above code now
Title: Re: Need some help with logo coding please
Post by: sonda on January 31, 2008, 11:12:14 PM
Nope  still there.
Title: Re: Need some help with logo coding please
Post by: SA™ on January 31, 2008, 11:20:04 PM
next :D


<a href ="http://www.swedefarm.com"><img src="http://s132.photobucket.com/albums/q12/allcraft/Business%20Cards/Katie.jpg" target="_blank"></a>
Title: Re: Need some help with logo coding please
Post by: sonda on January 31, 2008, 11:21:45 PM
Well that got rid of the red x  BUT now we have two of the same image :)
Title: Re: Need some help with logo coding please
Post by: SA™ on January 31, 2008, 11:23:16 PM
lol try that code again sry
Title: Re: Need some help with logo coding please
Post by: sonda on January 31, 2008, 11:25:25 PM
:)   YEH  you are awsome!!  Thank you so much
Title: Re: Need some help with logo coding please
Post by: SA™ on January 31, 2008, 11:27:21 PM
np glad to help
Title: Re: Need some help with logo coding please
Post by: sonda on January 31, 2008, 11:28:46 PM
:) night
Title: Re: Need some help with logo coding please NEW problem
Post by: sonda on February 01, 2008, 12:32:06 AM
Ok on very first message  re:  link to another web page and logo on left hand side.

logo goes up fine using your codes but does not link to the website.

so this is the chg I made  what did I do wrong??

Quoteif(!($settings['logo_not_show']))
   {
      if (empty($settings['header_logo_url']))
         echo '
                  <a href="www.lonesomedoenubians.com"><img src="http://i132.photobucket.com/albums/q12/allcraft/Business%20Cards/BoardadvertizingVicki-2.jpg"></a>';      else
         echo '
                  <a href="', $scripturl, '"><img src="', $settings['header_logo_url'], '" style="margin: 0px;" alt="', $context['forum_name'], '" /></a>';
   }
   echo '
Title: Re: Need some help with logo coding please/ NEW help needed
Post by: SA™ on February 01, 2008, 12:44:48 AM
if(!($settings['logo_not_show']))
   {
      if (empty($settings['header_logo_url']))
         echo '
                  <a href="http://www.lonesomedoenubians.com"><img src="http://i132.photobucket.com/albums/q12/allcraft/Business%20Cards/BoardadvertizingVicki-2.jpg"></a>';
      else
         echo '
                  <a href="', $scripturl, '"><img src="', $settings['header_logo_url'], '" style="margin: 0px;" alt="', $context['forum_name'], '" /></a>';
   }
   echo '


try that you mised the http:// from the url



Title: Re: Need some help with logo coding please/ NEW help needed
Post by: sonda on February 01, 2008, 01:03:42 AM
Thanks once again  it worked
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: sonda on February 01, 2008, 01:17:07 AM
Template Parse Error!
There was a problem loading the /Themes/dilbermc/index.template.php template or language file. Please check the syntax and try again - remember, single quotes (') often have to be escaped with a slash (\). To see more specific error information from PHP, try accessing the file directly.

You may want to try to refresh this page or use the default theme.
--------------------------------------------------------------------------------

parse error, unexpected '['


Now what do I do ??
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: SA™ on February 01, 2008, 03:23:45 AM
did you get that adding that code to the index template ?

if so can u post it up so i can look at it
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: sonda on February 01, 2008, 03:40:32 AM
OH   you just don't have a clue as to how bad I have screwed up everything on the board now. 
I have lost all colors   can't even get the default smf to work.    and since I just took over this board  I don't even know how to go abt reloading  smf  and can't figure out the  cpanel crap or anything.   Am so upset and the owner of the board is going to have a fit come morning.
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: sonda on July 02, 2009, 09:57:38 AM
OK need some help again  I can't get this to load the picture in the theme setting  and can't figure out what I have done wrong using the same setting
Quote from: sleepy-arcade.ath.cx on January 31, 2008, 11:20:04 PM
next :D


<a href ="http://www.swedefarm.com"><img src="http://s132.photobucket.com/albums/q12/allcraft/Business%20Cards/Katie.jpg" target="_blank"></a>

<a href ="http://www.freewebs.com/caprinebeings"><img src="http://i132.photobucket.com/albums/q12/allcraft/Business%20Cards/BuisnesscardCaprineBeings.jpg" target="_blank"></a>


Now when I copy the HTML code from photobucket I get the following.  but nothing will work the url in the above works but not the picture

<a href="http://s132.photobucket.com/albums/q12/allcraft/?action=view&current=CaprineBeings.jpg" target="_blank"><img src="http://i132.photobucket.com/albums/q12/allcraft/CaprineBeings.jpg" border="0" alt="Caprine Beings"></a>
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: sonda on July 02, 2009, 09:59:53 AM
I also can't get this one to work  with just a picture and no website.  So any help would be appreciated.
<a href="http://s132.photobucket.com/albums/q12/allcraft/?action=view&current=KennyGoatLady.jpg" target="_blank"><img src="http://i132.photobucket.com/albums/q12/allcraft/KennyGoatLady.jpg" border="0" alt="Kenny Goat Lady"></a>
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: sonda on July 02, 2009, 10:32:59 AM
OK  GOT IT working   just wasn't working on IE for some unknown reason but it is now.
Sorry for the bother.
Title: Re: Need some help with logo coding please/ Help Help Help I screwed it all up
Post by: rapvideosguy on July 02, 2009, 10:42:43 AM
yeah IE can be a pain like that..