Sign Up! Login: Password: New User? Forgot? Support
Code 
 
 
Forums 
Forums : General Discussion > Modding Forum post menu
Wasp (Applicant) 11/18/2011 4:06 AM EST : Modding Forum post menu
Wasp
Posts: 169

0
Like

0
Dislike

I could really use some help with editting your forum post menu code. I'm trying to make a menu on my site that has url links, forum posts, videos, pictures etc. I would like to place all this info in a easy to access and read place without taking up a ton of space. I seen your forum post menu and thought I could modify it to suit my needs. Turning out not so good. I'm very new to all this just started dabbing into it really. 

<a rel="prettyPhoto[oCin]" href="http://youtu.be/8wmUx10I18I?hd=1">Video</a>

Now I just broke the forum post to welcome screen function for now so at least the url links and facebox worked proper. Here is the thing though I would like to use prettyPhoto, a lightbox mod I believe instead of facebox within the menu aswell. The line in red would be the normal call to open the box but it's not working at all. Works fine anywhere else on my site.

Tried posting my code but it keeps giving an error no matter how I try to post it.


TopBottom

Mottie (SuperAdmin) 11/18/2011 7:55 AM EST : RE: Modding Forum post menu
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

Hi Wasp!

I can only assume you mean the "Criminal Empire" site, I didn't look at the other guild sites. First off, I'm glad you're using the menu for other stuff, thinking outside of the box is always fun! I don't see any problem with the prettyPhoto lightbox (in the widget on the right). But I do see an script error that has fancybox in it, but really isn't related. So, fix the following and see if everything starts working.

  • Remove the "hide" class from the Welcome message header (in red):

    <h5 class="head hide"> &nbsp;Welcome Message</h5>

  • Wrap whatever part of the welcome message, in the welcome widget in a div with an id of "welcome"

    <div id="welcome"> <!-- welcome message portion that is hidden goes here --> </div>

  • Remove the script causing the error - it's in your custom script ( Control Panel > Custom HTML & Script > Custom Javascript/jQuery > Additional Functions (I think) )

    $(facebox).empty();

    I'm not really sure why this code was needed, but it has nothing to do with facebox.
Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

Wasp (Applicant) 11/18/2011 8:31 AM EST : RE: Modding Forum post menu
Wasp
Posts: 169

0
Like

0
Dislike

Thank you! The main issue I'm having though is the prettyPhoto I was hoping to basically allow that widget on the right to be opened from with in the accordion forum menu. But when I call it, nothing happens well I should say nothing it does open the link but not in the lightbox. This only occurs on the menu widget. The one on the right was just a test to make sure it worked and to style it.

I think wrapping it in the <li></li> tags is what is causing it to not function but I have no idea how to solve that.
TopBottom

Mottie (SuperAdmin) 11/18/2011 11:03 AM EST : RE: Modding Forum post menu
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

Actually it looks like part of the code is missing... the part in red needs be to added:
// load content and display  
 $('#instruct a').click(function(){  
  $(this).parent().addClass('selected');   
  var instLink = $(this).attr('href');
Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

Wasp (Applicant) 11/18/2011 4:23 PM EST : RE: Modding Forum post menu
Wasp
Posts: 169

0
Like

0
Dislike

Right! Forgot I took that out when I was testing somethings. Doh!

Now it seems that a plain url link, like the http://www.swtor.com one in the menu does not work. 

Thanks for your time on this.
TopBottom

Mottie (SuperAdmin) 11/18/2011 5:02 PM EST : RE: Modding Forum post menu
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

Hmm, ok I had to modify the code to fix that one

So, look for the line that has this (in red), I added a bit more so you can find it easier:
  });  
  return false;  
 });  
  
// Mark Link as new or updated depending on the class  
// n0409 = new on 04/09 and u0309 = updated on 03/09  
 var nummon = 3; // keep new/update labels for 3 months (this month + 2 more)
And completely replace the line in red with this:
if (!/http/.test(instLink)) { return false; }
What that does is looks for the "http" in the url. If the link was to a post in the forums, then it's a number - in case you were curious
Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

Wasp (Applicant) 11/18/2011 5:27 PM EST : RE: Modding Forum post menu
Wasp
Posts: 169

0
Like

0
Dislike

Awesome! I knew I had to do a check for it but I had no idea how to implement it, it's all still new to me.

Thank you a ton, everything seems to be working how I wanted it to now. 
TopBottom

Wasp (Applicant) 12/12/2011 8:37 PM EST : RE: Modding Forum post menu
Wasp
Posts: 169

0
Like

0
Dislike

Hey Mottie I'm having issues with the vertical spacing on my guildportal site, criminal empire. Is there anyway I can reduce the vertical space between my widgets? I've tried setting .spacer height to 0 but that doesn't do anything. 

Also I plugged your new swtor recruitment widget in and it's all wonky. Not sure whats up with that either. Looked at the css, tried making it wider but that didn't help at all.
I'd like to change the tooltip border styling for just the recruitment widget also. Not sure how to go about that.
TopBottom

Mottie (SuperAdmin) 12/13/2011 6:40 AM EST : RE: Modding Forum post menu
ACK!
Mottie
Posts: 3884

0
Like

0
Dislike

Hi Wasp!

It looks like the problem with the spacing is from the bottom border css definitions. I'm not 100% sure how you have it all set up, but if you add the following to your css additions (Control Panel > Custom HTML & Script > Custom CSS > CSS Additions to Standard), it should over-ride the current settings:
.bottomleft, .bottomtile, .bottomright { display: none; }
What that does is just completely hide the bottom of the content box. I had to do this because trying to set the height to zero wasn't working as I would expect it - the current height has an "!important" flag after it so I would have to add the above css after it.

In the recruitment widget, I forgot to allow for different font sizes, so if you add a "line-height" to your cssIcon definition (inside of te swtortalents.css file), it should start looking right, the new part is in blue:

Characters: Mottie Motty Mortie Ooshiny Mot Fudgems
TopBottom

Wasp (Applicant) 12/13/2011 7:01 AM EST : RE: Modding Forum post menu
Wasp
Posts: 169

0
Like

0
Dislike

This is my current css additions for the contentbox.

.ContentBox {  background: transparent; border:0px;}
.ContentBoxTitle, .ContentBoxTitleNoBackground { background: transparent; color: #ffffff; font-weight: bold;  position: relative; top: 3px; left: -25px; }
.topleft { background: url(/GuildFiles/172276/container-title_left2.png) bottom no-repeat; height: 23px; width: 31px; }
.toptile { background: url(/GuildFiles/172276/container-title_fill.png) bottom repeat-x; height: 23px; }
.topright { background: url(/GuildFiles/172276/container-title_right2.png) bottom no-repeat; height: 23px; width:30px; }
.lefttile { background: url(/GuildFiles/172276/left-edge.png)  repeat-y; width: 7px; }
.righttile { background: url(/GuildFiles/172276/right-edge.png) repeat-y; width: 5px; }
.bottomleft { background: url(/GuildFiles/172276/container-footer_left.png)  no-repeat; height: 7px; width: 31px; }
.bottomtile { background: url(/GuildFiles/172276/container-footer_fill.png)  repeat-x; height: 7px; }
.bottomright { background: url(/GuildFiles/172276/container-footer_right.png) no-repeat; height: 7px !important; width: 30px; }
.ContentBoxBody { background: url(/GuildFiles/172276/contentbox_bg_image2.png) top center; padding: 1px 2px;  }

I have a 7px height bottom border, hiding the .bottom 
definitely reduced the vertical spacing but I have a border there that I don't want to hide.

EDIT: I also noticed that in the swtortalents.css file that the .talenticon { float:  } was set to left, while all the screenshots show them on the right.

TopBottom

 
 
Key 
New posts No new posts
New posts ( popular ) No new posts ( popular )
New posts ( sticky ) No new posts ( sticky )
New posts ( locked ) No new posts ( locked )
 
 
Who's Online 
There are   members online.
 
 
So-and-so has logged on!
%title%
%message%