a different layout for Cat. Guildbank and one issue with it

Categorizes items in your guildbank(s)

Moderator: Mathos

a different layout for Cat. Guildbank and one issue with it

Postby sileed » Tue Sep 26, 2006 6:38 pm

I posted this on the old forums and am just now finding time to get back to it as I'm still looking for a solution:

Here the deal:

My Roster 1.7.0 http://142.166.40.90/roster/addon.php?r ... =guildbank
This is a slightly modified layout for the page that suits our guilds needs.

I had this working as well with Roster 1.6.0 here:
http://142.166.40.90/FP/addon.php?roste ... =guildbank

Do you see the difference? I copied most of the code exactly - but yet I don't get the same results

You'll notice that in 1.7.0 my item name do not appear in the color of the item - everything is white.

Here's the code from 1.6.0 (with the original code still commented out)
about line 461
Code: Select all
// Construct the image with a URL and put the colored border around it
   if ($color_border) {
      $returnstr .=  '<a href="'.$itemlink[$roster_lang].urlencode(utf8_decode($itemrow['item_name'])).'" target="_itemlink">'."\n".'<img src="'.$img_url.$item_texture.'.'.$img_suffix.'" class="'.$item_quality.'"></a>';
   } else {
      $returnstr .=  '<a href="'.$itemlink[$roster_lang].urlencode(utf8_decode($itemrow['item_name'])).'" target="_itemlink">'."\n".'<img src="'.$img_url.$item_texture.'.'.$img_suffix.'" class="itemsm"></a>';
   
   // If we have more than 1 in total, display the total quantity number on the image
   //if( ($itemrow['quantity'] > 1) && ($itemrow['item_parent'] != 'bags') ) {
      //$returnstr .= '<span class="quant">'.$itemrow['quantity'].'</span>';
      $returnstr .='<td width="515"><font color="'.$item_color.'">'.$itemrow['item_name'];
    $returnstr .='<td width="35" align="center">'. "x".$itemrow['quantity'];


and here's the code from 1.7.0
about line 577
Code: Select all
// Construct the image with a URL and put the colored border around it
   if ($color_border)
   {
      $returnstr .=  '<a href="'.$itemlink[$roster_conf['roster_lang']].urlencode(utf8_decode($itemrow['item_name'])).'" target="_itemlink">'."\n".'<img src="'.$roster_conf['interface_url'].$item_texture.'.'.$roster_conf['img_suffix'].'" class="'.$item_quality.'"></a>';
   }
   else
   {
      $returnstr .=  '<a href="'.$itemlink[$roster_conf['roster_lang']].urlencode(utf8_decode($itemrow['item_name'])).'" target="_itemlink">'."\n".'<img src="'.$roster_conf['interface_url'].$item_texture.'.'.$roster_conf['img_suffix'].'" class="itemsm"></a>';
   
   // If we have more than 1 in total, display the total quantity number on the image
   //if (($itemrow['quantity'] > 1) && ($itemrow['item_parent'] != 'bags'))
   //{
      //$returnstr .= '<span class="quant">'.$itemrow['quantity'].'</span>';
      //$returnstr .='<td width="450" font color="'.$item_color.'">'.$itemrow['item_name'];
    $returnstr .='<td width="450" style="color:"'.$item_color.';">'.$itemrow['item_name'];
    $returnstr .='<td width="35" align="center">'. "x".$itemrow['quantity'];
   }
   // Add the trail to the item-cell
   $returnstr .= '</div></font></td>';


Can anyone help me out as to why the Item Color is not coming through??
Thanks
Sileed
User avatar
sileed
WR.net Apprentice
WR.net Apprentice
 
Posts: 20
Joined: Tue Jul 04, 2006 5:05 pm

Re: a different layout for Cat. Guildbank and one issue with

Postby Mathos » Tue Sep 26, 2006 7:04 pm

You have your single and double quotes mixed up, as this is the result:
Code: Select all
<tr><td><span style="z-index: 1000;" onmouseover="return overlib('<span class=&quot;tooltipline&quot; style=&quot;color:#5c82a3;&quot;>Fpbanktwo</span><span class=&quot;tooltipline&quot; style=&quot;color:#ffffff;&quot;> (183)</span> - <span class=&quot;tooltipline&quot; style=&quot;color:#aaaaaa; font-size:8pt;&quot;>Time:Sep 23rd Sat, 4:46am</span><br /><span class=&quot;tooltipheader&quot; style=&quot;color:#1eff00; font-weight: bold&quot;>Bone Scarab</span><br />');" onmouseout="return nd();">
<
div class="itemsm"><a href="http://www.thottbot.com/index.cgi?i=Bone+Scarab" target="_itemlink">

<
img src="img/Interface//Icons//INV_Scarab_Bone.jpg" class="itemsm"></a></div></span></td><td style="" 1eff00="" width="450">Bone Scarab</td><td align="center" width="35">x183</td></tr
User avatar
Mathos
Gimpy Developer
Gimpy Developer
 
Posts: 117
Joined: Wed Jul 05, 2006 11:00 am

a different layout for Cat. Guildbank and one issue with it

Postby sileed » Tue Sep 26, 2006 7:54 pm

2 things:
I'm not sure I follow you at all, my page source does not look like yours. I changed it from Style=color:# back to font color= and my page source looks the same for 1.7.0 and 1.6.0

It seems the issue is only in Firefox (works ok in IE) am I falling victim to a CSS issue here??
User avatar
sileed
WR.net Apprentice
WR.net Apprentice
 
Posts: 20
Joined: Tue Jul 04, 2006 5:05 pm

a different layout for Cat. Guildbank and one issue with it

Postby PleegWat » Tue Sep 26, 2006 8:00 pm

In the DOM source, I could easily fix it by putting a # in front of the colour number.

When you had it on style=, it turned the STYLE attribute into a seperate tag, which is clearly not going to work.
I <3 /bin/bash
User avatar
PleegWat
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 1636
Joined: Tue Jul 04, 2006 1:43 pm

Re: a different layout for Cat. Guildbank and one issue with

Postby sileed » Tue Sep 26, 2006 8:20 pm

ok taking a look a the code it was a typo after all (I knew it was just couldn't find it) I had<... style=color:"'.item_color.'"> and it should have been <...style=color:#'.item_color.'">

Thanks for the assistance in finding my dumb mistake :)
User avatar
sileed
WR.net Apprentice
WR.net Apprentice
 
Posts: 20
Joined: Tue Jul 04, 2006 5:05 pm


Return to Categorized Guild Bank

Who is online

Users browsing this forum: No registered users and 0 guests

cron